ECF
1.5
D:
Projekt
ECF_trunk
examples
CGP
src
utility
expression_evaluation.h
1
#ifndef ECF_CARTESIAN_EXPRESSION_EVALUATION_H
2
#define ECF_CARTESIAN_EXPRESSION_EVALUATION_H
3
#include <string>
4
#include <map>
5
#include <set>
6
#include <stack>
7
#include <iostream>
8
#include <cmath>
9
#include <vector>
10
#include <boost/algorithm/string.hpp>
11
12
namespace
utility{
13
static
std::string init[] = {
"+"
,
"-"
,
"*"
,
"/"
,
"^"
,
"sqrt"
,
"sin"
,
"max"
,
"min"
,
"cos"
,
"ln"
};
14
static
std::set<std::string> existingOperators(init, init +
sizeof
(init)/
sizeof
(init[0]) );
15
double
evaluateExpression(
const
std::map<std::string,double>& variables, std::string expression);
16
}
17
#endif
//ECF_CARTESIAN_EXPRESSION_EVALUATION_H
Generated on Wed Aug 3 2022 17:50:42 for ECF by
1.9.4