31 #ifndef GRT_DERIVATIVE_HEADER
32 #define GRT_DERIVATIVE_HEADER
34 #include "../CoreModules/PreProcessing.h"
100 virtual bool reset();
243 enum DerivativeOrders{FIRST_DERIVATIVE=1,SECOND_DERIVATIVE};
249 #endif //GRT_DERIVATIVE_HEADER
bool setDelta(Float delta)
UINT filterSize
The size of the filter used to filter the input data before the derivative is computed.
bool setDerivativeOrder(UINT derivativeOrder)
The MovingAverageFilter implements a low pass moving average filter.
VectorFloat yy
A buffer holding the previous input value(s)
Float getDerivative(UINT derivativeOrder=0)
VectorFloat yyy
A buffer holding the previous first derivative values.
Float computeDerivative(const Float x)
virtual bool loadModelFromFile(std::string filename)
Derivative & operator=(const Derivative &rhs)
VectorFloat getDerivatives(UINT derivativeOrder=0)
virtual bool process(const VectorFloat &inputVector)
bool filterData
Flags if the input data should be filtered before the derivative is computed.
Float delta
The estimated time between sensor samples.
virtual bool saveModelToFile(std::string filename) const
bool enableFiltering(bool filterData)
UINT derivativeOrder
The order of the derivative that will be computed (either FIRST_DERIVATIVE or SECOND_DERIVATIVE) ...
Derivative(UINT derivativeOrder=FIRST_DERIVATIVE, Float delta=1, UINT numDimensions=1, bool filterData=true, UINT filterSize=3)
bool setFilterSize(UINT filterSize)
virtual bool deepCopyFrom(const PreProcessing *preProcessing)
MovingAverageFilter filter
The filter used to low pass filter the input data.