state-observation 1.7.0
Loading...
Searching...
No Matches
algebraic-sensor.hpp
Go to the documentation of this file.
1
10#ifndef SIMULATIONALGEBRAICSENSORHPP
11#define SIMULATIONALGEBRAICSENSORHPP
12
13#include <boost/assert.hpp>
14#include <Eigen/Core>
15
16#include <state-observation/api.h>
18
19namespace stateObservation
20{
35{
36public:
39
41 virtual ~AlgebraicSensor() {}
42
45 virtual Vector getMeasurements(bool noisy = true);
46
48 virtual void setState(const Vector & state, TimeIndex k);
49
51 virtual TimeIndex getTime() const;
52
54 virtual Index getStateSize() const;
55
57 virtual Index getMeasurementSize() const;
58
63
64protected:
68
69 virtual Index getStateSize_() const = 0;
70
71 virtual Index getMeasurementSize_() const = 0;
72
74
75 virtual void checkState_(const Vector &);
76
78
80
82
84
86
88
90
92};
93
94} // namespace stateObservation
95
96#endif // SIMULATIONALGEBRAICSENSORHPP
The base class for algebraic sensors. Algebraic sensors are sensors which depend only on the state va...
Definition algebraic-sensor.hpp:35
Vector directInputToOutput_
Definition algebraic-sensor.hpp:83
bool storedNoiselessMeasurement_
Definition algebraic-sensor.hpp:89
virtual Index getStateSize_() const =0
AlgebraicSensor()
Default constructor.
virtual void setState(const Vector &state, TimeIndex k)
Sets the value of the state at instant k.
virtual Vector computeNoiselessMeasurement_()=0
virtual Index concatenateWithInput(Index n)
TimeIndex time_
Definition algebraic-sensor.hpp:77
virtual void checkState_(const Vector &)
bool storedNoisyMeasurement_
Definition algebraic-sensor.hpp:85
Vector state_
Definition algebraic-sensor.hpp:81
virtual Index getMeasurementSize() const
get the size of the measurements. Pure virtual method.
virtual ~AlgebraicSensor()
virtual destructor
Definition algebraic-sensor.hpp:41
Index concat_
Definition algebraic-sensor.hpp:79
Vector noiselessMeasurement_
Definition algebraic-sensor.hpp:91
virtual Vector getMeasurements(bool noisy=true)
virtual TimeIndex getTime() const
gets the current time
virtual Index getStateSize() const
gets the state vector size. Pure virtual method.
virtual Index getMeasurementSize_() const =0
Vector noisyMeasurement_
Definition algebraic-sensor.hpp:87
The base class for sensors. This must be derived to implement a sensor.
Definition sensor-base.hpp:31
Definition bidim-elastic-inv-pendulum-dyn-sys.hpp:21
long int TimeIndex
Definition definitions.hpp:139
Eigen::MatrixXd Matrix
Dynamic sized Matrix.
Definition definitions.hpp:100
Eigen::Index Index
Definition definitions.hpp:138
Eigen::VectorXd Vector
Dynamic sized scalar vector.
Definition definitions.hpp:76
Implements the base class of all sensors.