stateObservation::SensorBase Class Referenceabstract

The base class for sensors. This must be derived to implement a sensor. More...

#include <state-observation/sensors-simulation/sensor-base.hpp>

Inheritance diagram for stateObservation::SensorBase:
Collaboration diagram for stateObservation::SensorBase:

Public Member Functions

 SensorBase ()
 default constructor More...
 
virtual ~SensorBase ()
 virtual destructor More...
 
virtual Vector getMeasurements (bool noisy=true)=0
 
virtual void setState (const Vector &state, TimeIndex k)=0
 Sets the value of the state at instant k. More...
 
virtual void setNoise (NoiseBase *)
 
virtual NoiseBasegetNoise () const
 gets the pointer on the measurements noise More...
 
virtual void resetNoise ()
 removes the noise More...
 
virtual TimeIndex getTime () const =0
 gets the current time, pure virtual method More...
 
virtual Index getStateSize () const =0
 gets the state vector size. Pure virtual method. More...
 
virtual Index getMeasurementSize () const =0
 get the size of the measurements. Pure virtual method. More...
 
virtual Vector stateVectorZero () const
 gets a zero vector of the size of a state vector More...
 
virtual bool checkStateVector (const Vector &) const
 checks whether a vector is correctly sized or not More...
 

Protected Attributes

NoiseBasenoise_
 

Detailed Description

The base class for sensors. This must be derived to implement a sensor.

Constructor & Destructor Documentation

◆ SensorBase()

stateObservation::SensorBase::SensorBase ( )

default constructor

◆ ~SensorBase()

virtual stateObservation::SensorBase::~SensorBase ( )
inlinevirtual

virtual destructor

Member Function Documentation

◆ checkStateVector()

virtual bool stateObservation::SensorBase::checkStateVector ( const Vector ) const
virtual

checks whether a vector is correctly sized or not

◆ getMeasurements()

virtual Vector stateObservation::SensorBase::getMeasurements ( bool  noisy = true)
pure virtual

gets the measurement of the current time. We can choose to consider noise or not (default is noisy)

Implemented in stateObservation::AlgebraicSensor.

◆ getMeasurementSize()

virtual Index stateObservation::SensorBase::getMeasurementSize ( ) const
pure virtual

get the size of the measurements. Pure virtual method.

Implemented in stateObservation::AlgebraicSensor.

◆ getNoise()

virtual NoiseBase* stateObservation::SensorBase::getNoise ( ) const
virtual

gets the pointer on the measurements noise

◆ getStateSize()

virtual Index stateObservation::SensorBase::getStateSize ( ) const
pure virtual

gets the state vector size. Pure virtual method.

Implemented in stateObservation::AlgebraicSensor.

◆ getTime()

virtual TimeIndex stateObservation::SensorBase::getTime ( ) const
pure virtual

gets the current time, pure virtual method

Implemented in stateObservation::AlgebraicSensor.

◆ resetNoise()

virtual void stateObservation::SensorBase::resetNoise ( )
virtual

removes the noise

◆ setNoise()

virtual void stateObservation::SensorBase::setNoise ( NoiseBase )
virtual

Sets a pointer on the noise on the measurements. The class does NOT destroy the noise when the destructor is called.

◆ setState()

virtual void stateObservation::SensorBase::setState ( const Vector state,
TimeIndex  k 
)
pure virtual

Sets the value of the state at instant k.

Implemented in stateObservation::AlgebraicSensor.

◆ stateVectorZero()

virtual Vector stateObservation::SensorBase::stateVectorZero ( ) const
virtual

gets a zero vector of the size of a state vector

Member Data Documentation

◆ noise_

NoiseBase* stateObservation::SensorBase::noise_
protected

The documentation for this class was generated from the following file: