helper class representing a formula with variables given by an id v More...
#include <qle/math/compiledformula.hpp>
Public Types | |
enum | Operator { none , plus , minus , multiply , divide , max , min , pow , abs , gtZero , geqZero , negate , exp , log } |
Public Member Functions | |
CompiledFormula () | |
CompiledFormula (const Real x) | |
CompiledFormula (const Size v) | |
CompiledFormula (const CompiledFormula &f) | |
CompiledFormula (CompiledFormula &&f) | |
CompiledFormula & | operator= (const CompiledFormula &) |
CompiledFormula & | operator= (CompiledFormula &&) |
template<class I > | |
Real | operator() (I begin, I end) const |
Real | operator() (const std::vector< Real > &values) const |
CompiledFormula & | operator+= (const CompiledFormula &) |
CompiledFormula & | operator-= (const CompiledFormula &) |
CompiledFormula & | operator*= (const CompiledFormula &) |
CompiledFormula & | operator/= (const CompiledFormula &) |
CompiledFormula | operator- () const |
Private Attributes | |
Operator | op_ |
Real | x_ |
Size | v_ |
std::vector< CompiledFormula > | args_ |
Friends | |
CompiledFormula | operator+ (CompiledFormula, const CompiledFormula &) |
CompiledFormula | operator- (CompiledFormula, const CompiledFormula &) |
CompiledFormula | operator* (CompiledFormula, const CompiledFormula &) |
CompiledFormula | operator/ (CompiledFormula, const CompiledFormula &) |
CompiledFormula | max (CompiledFormula, const CompiledFormula &) |
CompiledFormula | min (CompiledFormula, const CompiledFormula &) |
CompiledFormula | pow (CompiledFormula, const CompiledFormula &) |
CompiledFormula | gtZero (CompiledFormula) |
CompiledFormula | geqZero (CompiledFormula) |
CompiledFormula | abs (CompiledFormula) |
CompiledFormula | exp (CompiledFormula) |
CompiledFormula | log (CompiledFormula) |
CompiledFormula | unaryOp (CompiledFormula, Operator op) |
CompiledFormula | binaryOp (CompiledFormula, const CompiledFormula &, Operator op) |
helper class representing a formula with variables given by an id v
Definition at line 40 of file compiledformula.hpp.
enum Operator |
Enumerator | |
---|---|
none | |
plus | |
minus | |
multiply | |
divide | |
max | |
min | |
pow | |
abs | |
gtZero | |
geqZero | |
negate | |
exp | |
log |
Definition at line 42 of file compiledformula.hpp.
CompiledFormula | ( | ) |
Definition at line 43 of file compiledformula.hpp.
CompiledFormula | ( | const Real | x | ) |
CompiledFormula | ( | const Size | v | ) |
CompiledFormula | ( | const CompiledFormula & | f | ) |
Definition at line 48 of file compiledformula.hpp.
CompiledFormula | ( | CompiledFormula && | f | ) |
CompiledFormula & operator= | ( | const CompiledFormula & | f | ) |
CompiledFormula & operator= | ( | CompiledFormula && | f | ) |
Real operator() | ( | I | begin, |
I | end | ||
) | const |
Definition at line 91 of file compiledformula.hpp.
Real operator() | ( | const std::vector< Real > & | values | ) | const |
Definition at line 55 of file compiledformula.hpp.
CompiledFormula & operator+= | ( | const CompiledFormula & | y | ) |
CompiledFormula & operator-= | ( | const CompiledFormula & | y | ) |
CompiledFormula & operator*= | ( | const CompiledFormula & | y | ) |
CompiledFormula & operator/= | ( | const CompiledFormula & | y | ) |
CompiledFormula operator- | ( | ) | const |
Definition at line 87 of file compiledformula.cpp.
|
friend |
Definition at line 98 of file compiledformula.cpp.
|
friend |
Definition at line 103 of file compiledformula.cpp.
|
friend |
Definition at line 108 of file compiledformula.cpp.
|
friend |
Definition at line 113 of file compiledformula.cpp.
|
friend |
Definition at line 159 of file compiledformula.cpp.
|
friend |
Definition at line 162 of file compiledformula.cpp.
|
friend |
Definition at line 165 of file compiledformula.cpp.
|
friend |
Definition at line 142 of file compiledformula.cpp.
|
friend |
Definition at line 145 of file compiledformula.cpp.
|
friend |
Definition at line 148 of file compiledformula.cpp.
|
friend |
Definition at line 151 of file compiledformula.cpp.
|
friend |
Definition at line 154 of file compiledformula.cpp.
|
friend |
Definition at line 118 of file compiledformula.cpp.
|
friend |
Definition at line 128 of file compiledformula.cpp.
|
private |
Definition at line 83 of file compiledformula.hpp.
|
private |
Definition at line 84 of file compiledformula.hpp.
|
private |
Definition at line 85 of file compiledformula.hpp.
|
private |
Definition at line 86 of file compiledformula.hpp.