 
 
	 
In file ../include/EST_SCFG.h:
| class EST_SCFG_Rule | 
A stochastic context free grammar rule.
| ![[more]](icon1.gif)  | EST_SCFG_Rule () | 
| ![[more]](icon1.gif)  | EST_SCFG_Rule (const EST_SCFG_Rule &r) | 
| ![[more]](icon1.gif)  | EST_SCFG_Rule (double prob, int p, int m) Create a unary rule | 
| ![[more]](icon1.gif)  | EST_SCFG_Rule (double prob, int p, int q, int r) Create a binary rule | 
| ![[more]](icon1.gif) double | prob () const The rule's probability | 
| ![[more]](icon1.gif) void | set_prob (double p) set the probability | 
| ![[more]](icon1.gif) est_scfg_rtype | type () const rule type | 
| ![[more]](icon1.gif) int | mother () const | 
| ![[more]](icon1.gif) int | daughter1 () const In a unary rule this is a terminal, in a binary rule it is a nonterminal | 
| ![[more]](icon1.gif) int | daughter2 () const | 
| ![[more]](icon1.gif) void | set_rule (double prob, int p, int m) | 
| ![[more]](icon1.gif) void | set_rule (double prob, int p, int q, int r) | 
A stochastic context free grammar rule.At present only two types of rule are supported: est_scfg_binary_rule and est_scfg_unary_rule. This is sufficient for the representation of grammars in Chomsky Normal Form. Each rule also has a probability associated with it. Terminals and noterminals are represented as ints using the EST_Discretes in EST_SCFG to reference the actual alphabets.
Although this class includes a ``probability'' nothing in the rule itself enforces it to be a true probability. It is responsibility of the classes that use this rule to enforce that condition if desired.
 EST_SCFG_Rule()
 EST_SCFG_Rule()
 EST_SCFG_Rule(const EST_SCFG_Rule &r)
 EST_SCFG_Rule(const EST_SCFG_Rule &r)
 EST_SCFG_Rule(double prob, int p, int m)
 EST_SCFG_Rule(double prob, int p, int m)
 EST_SCFG_Rule(double prob, int p, int q, int r)
 EST_SCFG_Rule(double prob, int p, int q, int r)
 double prob() const
double prob() const 
 void set_prob(double p)
void set_prob(double p)
 est_scfg_rtype type() const
est_scfg_rtype type() const 
 int mother() const
int mother() const 
 int daughter1() const
int daughter1() const 
 int daughter2() const
int daughter2() const 
 void set_rule(double prob, int p, int m)
void set_rule(double prob, int p, int m)
 void set_rule(double prob, int p, int q, int r)
void set_rule(double prob, int p, int q, int r)
Alphabetic index HTML hierarchy of classes or Java
 
This page is part of the 
Edinburgh Speech Tools Library documentation
Copyright  University of Edinburgh 1997
Contact:  
         speech_tools@cstr.ed.ac.uk