DUECA/DUSIME
Loading...
Searching...
No Matches
Public Member Functions | List of all members
Integrator Class Reference

This class creates a single integrator, if requested with limits on its state. More...

#include <Integrator.hxx>

Inheritance diagram for Integrator:
Inheritance graph
[legend]
Collaboration diagram for Integrator:
Collaboration graph
[legend]

Public Member Functions

 Integrator (double dt=0.01)
 Default constructor.
 
 Integrator (double lower_limit, double upper_limit, double dt=0.01)
 Constructor for Integrator with limits.
 
 ~Integrator ()
 Destructor.
 
void setDT (double dt)
 (Re-)discretize the integrator to match timestep size 'dt'
 
void setSaturationLimits (const Vector &lower, const Vector &upper)
 Set the limits on the states.
 
void setSaturationLimits (double lower_limit, double upper_limit)
 Set the limits for this integrator.
 
void acceptState (const Vector &x_new)
 Accept a new state.
 
void acceptState (double x_new)
 Accept a new state.
 
const Vector & step (const Vector &u)
 Calculate a single time step, return the output vector.
 
const Vector & step (double u)
 Calculate a single time step, return the output vector.
 
- Public Member Functions inherited from LimitedLinearSystem
 LimitedLinearSystem ()
 Default constructor.
 
 LimitedLinearSystem (const Vector &num, const Vector &den, double dt)
 This constructs a SISO system, on the basis of continuous time transfer function.
 
 LimitedLinearSystem (const LimitedLinearSystem &)
 Copy constructor.
 
 LimitedLinearSystem (const Matrix &A, const Matrix &B, const Matrix &C, const Matrix &D, double dt)
 This constructs a system, on the basis of a continuous time state space system.
 
virtual ~LimitedLinearSystem ()
 Destructor.
 
LimitedLinearSystemoperator= (const LimitedLinearSystem &o)
 Assignment of one system to another.
 
void setSaturationLimits (const Vector &lower, const Vector &upper)
 Set the saturation limits for the states.
 
bool isSaturated () const
 Returns true if one or more of the states are saturated.
 
void acceptState (const Vector &x_new)
 Accept a new state.
 
void reset ()
 Reset state, output, and saturation.
 
- Public Member Functions inherited from LinearSystem
 LinearSystem ()
 Default constructor.
 
 LinearSystem (const Vector &num, const Vector &den, double dt)
 This constructs a SISO system, on the basis of continuous time transfer function.
 
 LinearSystem (const LinearSystem &)
 Copy constructor.
 
 LinearSystem (const Matrix &A, const Matrix &B, const Matrix &C, const Matrix &D, double dt)
 This constructs a system, on the basis of a continuous time state space system.
 
 LinearSystem (const Matrix &phi, const Matrix &psi, const Matrix &C, const Matrix &D)
 This constructs a system, on the basis of a discrete time state space system.
 
virtual ~LinearSystem ()
 Destructor.
 
LinearSystemoperator= (const LinearSystem &o)
 Assignment of one system to another.
 
void createFromNumDen (const Vector &num, const Vector &den, double dt)
 Create a system from numerator, denominator input.
 
void createFromABCD (const Matrix &A, const Matrix &B, const Matrix &C, const Matrix &D, double dt)
 Create from matrices.
 
void createFromPhiPsiCD (const Matrix &phi, const Matrix &psi, const Matrix &C, const Matrix &D)
 Create from matrices, discrete.
 
const Vector & getY () const
 Obtain the output vector.
 
const Vector & getX () const
 Obtain the state vector.
 
Vector & getX ()
 Obtain the state vector for modification.
 
const Matrix & getPhi () const
 Additional output, transition.
 
const Matrix & getPsi () const
 Input matrix discrete system.
 
const Matrix & getC () const
 Output matrix.
 
const Matrix & getD () const
 Feedthrough matrix.
 

Additional Inherited Members

- Protected Attributes inherited from LimitedLinearSystem
Vector ul
 Upper limit.
 
Vector ll
 Lower limit.
 
bool saturation
 Keep track of saturation.
 
- Protected Attributes inherited from LinearSystem
unsigned n
 Order of the system.
 
unsigned m
 Number of outputs.
 
Matrix Phi
 Transition matrix.
 
Matrix Psi
 Input matrix.
 
Matrix C
 Output matrix.
 
Matrix D
 Feedthrough matrix.
 
Vector x
 The state vector.
 
Vector y
 The output vector.
 

Detailed Description

This class creates a single integrator, if requested with limits on its state.

Member Function Documentation

◆ setDT()

void Integrator::setDT ( double dt)

(Re-)discretize the integrator to match timestep size 'dt'

Parameters
dtThe timestep size that should be used to discretize the integrator.

◆ acceptState() [1/2]

void Integrator::acceptState ( const Vector & x_new)
virtual

Accept a new state.

Parameters
x_newVector with the new state.

Reimplemented from LinearSystem.

◆ acceptState() [2/2]

void Integrator::acceptState ( double x_new)

Accept a new state.

Parameters
x_newVector with the new state.

◆ step() [1/2]

const Vector & Integrator::step ( const Vector & u)
virtual

Calculate a single time step, return the output vector.

Parameters
uInput vector.

Reimplemented from LimitedLinearSystem.

◆ step() [2/2]

const Vector & Integrator::step ( double u)
virtual

Calculate a single time step, return the output vector.

Parameters
uInput variable. Only valid for SI systems.

Reimplemented from LimitedLinearSystem.


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