Parses the given string and evaluates it on request. More...
#include <parsedFormula.hh>


Public Types | |
| typedef concepts::Sequence < std::pair< std::string, std::string > > | RepSeq |
Public Member Functions | |
| ParsedFormulaBase () | |
| ParsedFormulaBase (const ParsedFormulaBase< dim > &frm) | |
| Copy constructor. | |
| void | set (const std::string formula, uint i=0, RepSeq rep=RepSeq()) |
Sets the i th formula. | |
Protected Member Functions | |
| Real | process_ (const Real3d &p, uint i=0) const |
Processing the i th formula. | |
Protected Attributes | |
| std::string | formula_ [dim] |
| The original formula. | |
Private Attributes | |
| uint | len_ [dim] |
| Length of the parsed formula. | |
| Array< uchar > | pgm_ [dim] |
| The parsed formula. | |
Parses the given string and evaluates it on request.
The following operations and functions are allowed in the formula: + - / and *, (), ^ for exponentiation (also with broken exponents but only with positive bases) and the following formulae:
x, y and z are allowed as variables and pi is defined.
Definition at line 56 of file parsedFormula.hh.
| typedef concepts::Sequence<std::pair<std::string,std::string> > concepts::ParsedFormulaBase< dim >::RepSeq |
Definition at line 58 of file parsedFormula.hh.
| concepts::ParsedFormulaBase< dim >::ParsedFormulaBase | ( | ) | [inline] |
Definition at line 60 of file parsedFormula.hh.
| concepts::ParsedFormulaBase< dim >::ParsedFormulaBase | ( | const ParsedFormulaBase< dim > & | frm | ) | [inline] |
Copy constructor.
Definition at line 67 of file parsedFormula.hh.
| Real concepts::ParsedFormulaBase< dim >::process_ | ( | const Real3d & | p, |
| uint | i = 0 |
||
| ) | const [protected] |
Processing the i th formula.
| void concepts::ParsedFormulaBase< dim >::set | ( | const std::string | formula, |
| uint | i = 0, |
||
| RepSeq | rep = RepSeq() |
||
| ) |
Sets the i th formula.
std::string concepts::ParsedFormulaBase< dim >::formula_[dim] [protected] |
The original formula.
Definition at line 81 of file parsedFormula.hh.
uint concepts::ParsedFormulaBase< dim >::len_[dim] [private] |
Length of the parsed formula.
Definition at line 86 of file parsedFormula.hh.
Array<uchar> concepts::ParsedFormulaBase< dim >::pgm_[dim] [private] |
The parsed formula.
Definition at line 84 of file parsedFormula.hh.