Changelog:
CVS Log messages:
Definition in file FloatFun.h.
#include "jbltools/sfh/FloatFunBase.h"
#include "jbltools/sfh/JBLMath.h"
#include "jbltools/sfh/BaseCutBase.h"
#include "jbltools/sfh/BaseCutPoR.h"
#include "jbltools/sfh/FillIteratorPoR.h"
#include "jbltools/sfh/FloatFunPoR.h"
#include "jbltools/sfh/ROListPoR.h"
Include dependency graph for FloatFun.h:
This graph shows which files directly or indirectly include this file:
Go to the source code of this file.
Compounds | |
class | ConstFun |
A FloatFun that returns a constant value. More... | |
class | FloatFunComp |
Abstract base class for comparisons between FloatFun objects. More... | |
Functions | |
const FloatFun & | operator+ (const FloatFun &arg_) |
Variables | |
<<<<<<< FloatFun.hclassFloatFloatFunLessEqual:publicFloatFloatFunComp{public:FloatFloatFunLessEqual(floatlhs_, constFloatFun &rhs_):FloatFloatFunComp(lhs_, rhs_,"%8f<=(%s)"){}virtualbooloperator()() const{returnlhs<=rhs();}protected:virtual~FloatFloatFunLessEqual(){}};classFloatFloatFunGreater:publicFloatFloatFunComp{public:FloatFloatFunGreater(floatlhs_, constFloatFun &rhs_):FloatFloatFunComp(lhs_, rhs_,"%8f >(%s)"){}virtualbooloperator()() const{returnlhs >rhs();}protected:virtual~FloatFloatFunGreater(){}};classFloatFloatFunGreaterEqual:publicFloatFloatFunComp{public:FloatFloatFunGreaterEqual(floatlhs_, constFloatFun &rhs_):FloatFloatFunComp(lhs_, rhs_,"%8f >=(%s)"){}virtualbooloperator()() const{returnlhs >=rhs();}protected:virtual~FloatFloatFunGreaterEqual(){}};classFloatFloatFunEqual:publicFloatFloatFunComp{public:FloatFloatFunEqual(floatlhs_, constFloatFun &rhs_):FloatFloatFunComp(lhs_, rhs_,"%8f==(%s)"){}virtualbooloperator()() const{returnlhs==rhs();}protected:virtual~FloatFloatFunEqual(){}};classFloatFloatFunNotEqual:publicFloatFloatFunComp{public:FloatFloatFunNotEqual(floatlhs_, constFloatFun &rhs_):FloatFloatFunComp(lhs_, rhs_,"%8f!=(%s)"){}virtualbooloperator()() const{returnlhs!=rhs();}protected:virtual~FloatFloatFunNotEqual(){}};classFloatFunFloatComp:publicFloatFunComp{public:FloatFunFloatComp(constFloatFun &lhs_, floatrhs_, constchar *format="FloatFunFloatComp(%s, float)");virtualfloatlhsValue() const{returnlhs();}virtualfloatrhsValue() const{returnrhs;}virtualconstFillIterator *getIterator() const{returnlhs.getIterator();}virtualconstchar *getName() const{returnname;}protected:virtual~FloatFunFloatComp(){delete[]name;name=0;}constFloatFun &lhs;floatrhs;char *name;private:FloatFunFloatComp(constFloatFunFloatComp &source);FloatFunFloatComp &operator=(constFloatFunFloatComp &source);};classFloatFunFloatLess:publicFloatFunFloatComp{public:FloatFunFloatLess(constFloatFun &lhs_, floatrhs_):FloatFunFloatComp(lhs_, rhs_,"(%s)<%8f"){}virtualbooloperator()() const{returnlhs()< rhs;}protected:virtual~FloatFunFloatLess(){}};classFloatFunFloatLessEqual:publicFloatFunFloatComp{public:FloatFunFloatLessEqual(constFloatFun &lhs_, floatrhs_):FloatFunFloatComp(lhs_, rhs_,"(%s)<=%8f"){}virtualbooloperator()() const{returnlhs()<=rhs;}protected:virtual~FloatFunFloatLessEqual(){}};classFloatFunFloatGreater:publicFloatFunFloatComp{public:FloatFunFloatGreater(constFloatFun &lhs_, floatrhs_):FloatFunFloatComp(lhs_, rhs_,"(%s)>%8f"){}virtualbooloperator()() const{returnlhs()>rhs;}protected:virtual~FloatFunFloatGreater(){}};classFloatFunFloatGreaterEqual:publicFloatFunFloatComp{public:FloatFunFloatGreaterEqual(constFloatFun &lhs_, floatrhs_):FloatFunFloatComp(lhs_, rhs_,"(%s)>=%8f"){}virtualbooloperator()() const{returnlhs()>=rhs;}protected:virtual~FloatFunFloatGreaterEqual(){}};classFloatFunFloatEqual:publicFloatFunFloatComp{public:FloatFunFloatEqual(constFloatFun &lhs_, floatrhs_):FloatFunFloatComp(lhs_, rhs_,"(%s)==%8f"){}virtualbooloperator()() const{returnlhs()==rhs;}protected:virtual~FloatFunFloatEqual(){}};classFloatFunFloatNotEqual:publicFloatFunFloatComp{public:FloatFunFloatNotEqual(constFloatFun &lhs_, floatrhs_):FloatFunFloatComp(lhs_, rhs_,"(%s)!=%8f"){}virtualbooloperator()() const{returnlhs()!=rhs;}protected:virtual~FloatFunFloatNotEqual(){}};classCollectiveFloatFun:publicFloatFun{public:CollectiveFloatFun(constFloatFunPoR &fun_=0, constBaseCutPoR &cut_=0, constFillIteratorPoR &intiter_=0, constFillIteratorPoR &extiter_=0, constchar *format="(CollectiveFloatFun(%s,%s,%s,%s)");virtualconstFillIterator *getIterator() const{returnextiter;}virtualconstchar *getName() const{returnname;}protected:virtual~CollectiveFloatFun(){delete[]name;name=0;}voidcheckIterators();voidmakeName(constchar *format);constFloatFun *fun;constBaseCut *cut;FillIterator *intiter;constFillIterator *extiter;char *name;private:CollectiveFloatFun(constCollectiveFloatFun &source);CollectiveFloatFun &operator=(constCollectiveFloatFun &source);};classMaxFloatFun:publicCollectiveFloatFun{public:MaxFloatFun(constFloatFunPoR &fun_=0, constBaseCutPoR &cut_=0, constFillIteratorPoR &intiter_=0, constFillIteratorPoR &extiter_=0):CollectiveFloatFun(fun_, cut_, intiter_, extiter_, "max(%s,%s,%s,%s)"){}virtualfloatoperator()() const;protected:virtual~MaxFloatFun(){}};classMinFloatFun:publicCollectiveFloatFun{public:MinFloatFun(constFloatFunPoR &fun_=0, constBaseCutPoR &cut_=0, constFillIteratorPoR &intiter_=0, constFillIteratorPoR &extiter_=0):CollectiveFloatFun(fun_, cut_, intiter_, extiter_, "min(%s,%s,%s,%s)"){}virtualfloatoperator()() const;protected:virtual~MinFloatFun(){}};classSumFloatFun:publicCollectiveFloatFun{public:SumFloatFun(constFloatFunPoR &fun_=0, constBaseCutPoR &cut_=0, constFillIteratorPoR &intiter_=0, constFillIteratorPoR &extiter_=0):CollectiveFloatFun(fun_, cut_, intiter_, extiter_, "sum(%s,%s,%s,%s)"){}virtualfloatoperator()() const;protected:virtual~SumFloatFun(){}};classAverageFloatFun:publicCollectiveFloatFun{public:AverageFloatFun(constFloatFunPoR &fun_=0, constBaseCutPoR &cut_=0, constFillIteratorPoR &intiter_=0, constFillIteratorPoR &extiter_=0):CollectiveFloatFun(fun_, cut_, intiter_, extiter_, "average(%s,%s,%s,%s)"){}virtualfloatoperator()() const;protected:virtual~AverageFloatFun(){}};classCachedFloatFun:publicFloatFun, publicCachedO{public:CachedFloatFun(constROListPoR &rol, constFloatFun &arg_);virtualfloatoperator()() const;virtualvoidinvalidateCache(){cacheValid=false;}virtualconstchar *getName() const{returnCachedFloatFun::name;}protected:virtual~CachedFloatFun(){delete[]name;name=0;}constFloatFun &arg;mutableboolcacheValid;mutablefloatcachedValue;char *name;private:CachedFloatFun(constCachedFloatFun &rhs);CachedFloatFun &operator=(constCachedFloatFun &rhs);};classCachedFloatFunIt:publicFloatFun, publicCachedO{public:CachedFloatFunIt(constROListPoR &rol, constFloatFun &arg_, constFillIterator &iter_);virtualfloatoperator()() const;virtualconstFillIterator *getIterator() const{return &iter;}virtualvoidinvalidateCache(){cacheValid.resize(0);cachedValues.resize(0);}virtualconstchar *getName() const{returnname;}protected:voidgrowCache(unsignedints) const;virtual~CachedFloatFunIt(){delete[]name;name=0;}constFloatFun &arg;constFillIterator &iter;mutablestd::vector< bool >cacheValid;mutablestd::vector< float >cachedValues;char *name;private:CachedFloatFunIt(constCachedFloatFunIt &rhs);CachedFloatFunIt &operator=(constCachedFloatFunIt &rhs);};inlineFloatFun &operator+(constFloatFun &lhs_, constFloatFun &rhs_){return *newSumOfTwoFuns(lhs_, rhs_);}inlineFloatFun &operator+(constFloatFun &lhs_, floatrhs_){return *newScalarSumFloatFun(rhs_, lhs_);}inlineFloatFun &operator+(floatlhs_, constFloatFun &rhs_){return *newScalarSumFloatFun(lhs_, rhs_);}inlineFloatFun &operator-(constFloatFun &lhs_, constFloatFun &rhs_){return *newDiffOfTwoFuns(lhs_, rhs_);}inlineFloatFun &operator-(constFloatFun &lhs_, floatrhs_){return *newScalarSumFloatFun(-rhs_, lhs_, 1, NamedO::str('(')+lhs_.getName()+")-"+NamedO::str(rhs_));}inlineFloatFun &operator-(floatlhs_, constFloatFun &rhs_){return *newScalarSumFloatFun(lhs_, rhs_,-1, NamedO::str(lhs_)+"-("+rhs_.getName()+')');}inlineFloatFun &operator-(constFloatFun &arg_){return *newScalarProductFloatFun("-", -1, arg_);}inlineFloatFun &operator *(constFloatFun &lhs_, constFloatFun &rhs_){if(&lhs_==&rhs_) return *newSquareFloatFun(lhs_);return *newProdOfTwoFuns(lhs_, rhs_);}inlineFloatFun &operator *(floatlhs_, constFloatFun &rhs_){return *newScalarProductFloatFun(lhs_, rhs_);}inlineFloatFun &operator *(constFloatFun &lhs_, floatrhs_){return *newScalarProductFloatFun(rhs_, lhs_);}=======FloatFun &sqrt(constFloatFun &arg_);>>>> FloatFun & | tan (const FloatFun &arg_) |
Tangent of a FloatFun. |