Public Member Functions | Protected Member Functions | Protected Attributes

User-interface to integrate a DynamicSystem, possibly over multiple stages. More...

#include <integration_algorithm.hpp>

Inheritance diagram for IntegrationAlgorithm:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual returnValue addStage (const DynamicSystem &dynamicSystem_, const Grid &stageIntervals, const IntegratorType &integratorType_=INT_UNKNOWN)
virtual returnValue addTransition (const Transition &transition_)
virtual returnValue clear ()
returnValue deleteAllSeeds ()
returnValue evaluate (VariablesGrid *x, VariablesGrid *xa, VariablesGrid *p, VariablesGrid *u, VariablesGrid *w)
returnValue evaluate (OCPiterate &_iter)
returnValue evaluateSensitivities ()
returnValue evaluateSensitivities (const BlockMatrix &seed, BlockMatrix &hessian)
returnValue getBackwardSensitivities (BlockMatrix &D) const
returnValue getBackwardSensitivities (DVector &Dx_x0, DVector &Dx_p=emptyVector, DVector &Dx_u=emptyVector, DVector &Dx_w=emptyVector) const
returnValue getForwardSensitivities (BlockMatrix &D) const
returnValue getForwardSensitivities (DVector &Dx) const
returnValue getX (DVector &xEnd) const
returnValue getX (VariablesGrid &X) const
returnValue getXA (DVector &xaEnd) const
returnValue getXA (VariablesGrid &XA) const
returnValue integrate (VariablesGrid *x, VariablesGrid *xa, VariablesGrid *p, VariablesGrid *u, VariablesGrid *w)
returnValue integrate (double t0, double tend, const DVector &x0, const DVector &xa=emptyVector, const DVector &p=emptyVector, const DVector &u=emptyVector, const DVector &w=emptyVector)
returnValue integrate (const Grid &t, const DVector &x0, const DVector &xa=emptyVector, const DVector &p=emptyVector, const DVector &u=emptyVector, const DVector &w=emptyVector)
returnValue integrateSensitivities ()
returnValue integrateSensitivities (const BlockMatrix &seed, BlockMatrix &hessian)
 IntegrationAlgorithm ()
 IntegrationAlgorithm (const IntegrationAlgorithm &rhs)
BooleanType isAffine () const
IntegrationAlgorithmoperator= (const IntegrationAlgorithm &rhs)
returnValue setBackwardSeed (const BlockMatrix &seed)
returnValue setBackwardSeed (const DVector &seed)
returnValue setForwardSeed (const BlockMatrix &xSeed_, const BlockMatrix &pSeed_=emptyBlockMatrix, const BlockMatrix &uSeed_=emptyBlockMatrix, const BlockMatrix &wSeed_=emptyBlockMatrix)
returnValue setForwardSeed (const DVector &xSeed, const DVector &pSeed=emptyVector, const DVector &uSeed=emptyVector, const DVector &wSeed=emptyVector)
returnValue setUnitBackwardSeed ()
returnValue setUnitForwardSeed ()
returnValue unfreeze ()
virtual ~IntegrationAlgorithm ()

Protected Member Functions

virtual returnValue setupLogging ()
virtual returnValue setupOptions ()

Protected Attributes

ShootingMethodintegrationMethod
OCPiterate iter

Detailed Description

User-interface to integrate a DynamicSystem, possibly over multiple stages.

The class IntegrationAlgorithm serves as a user-interface to integrate a DynamicSystem, possibly over multiple stages.

Author:
Boris Houska, Hans Joachim Ferreau

Definition at line 56 of file integration_algorithm.hpp.


Constructor & Destructor Documentation

Default constructor.

Definition at line 48 of file integration_algorithm.cpp.

Copy constructor (deep copy).

Definition at line 59 of file integration_algorithm.cpp.

Destructor.

Definition at line 71 of file integration_algorithm.cpp.


Member Function Documentation

returnValue IntegrationAlgorithm::addStage ( const DynamicSystem dynamicSystem_,
const Grid stageIntervals,
const IntegratorType integratorType_ = INT_UNKNOWN 
) [virtual]

Set the Differential Equations stage by stage.

Definition at line 98 of file integration_algorithm.cpp.

returnValue IntegrationAlgorithm::addTransition ( const Transition transition_) [virtual]

Set the Transition stages.

Definition at line 106 of file integration_algorithm.cpp.

Deletes all stages and transitions and resets the DynamicDiscretization.

Definition at line 112 of file integration_algorithm.cpp.

Deletes all seeds that have been set with the methods above.
This function will also give the corresponding memory free.

Returns:
SUCCESSFUL_RETURN
RET_NO_SEED_ALLOCATED

Definition at line 249 of file integration_algorithm.cpp.

Evaluates the descretized DifferentialEquation at a specified
VariablesGrid. The results are written into the residuum of the
type VariablesGrid. This routine is for a simple evaluation only.
If sensitivities are needed use one of the routines below
instead.

Returns:
SUCCESSFUL_RETURN
RET_INVALID_ARGUMENTS
or a specific error message form an underlying
discretization instance.
Parameters:
xdifferential states
xaalgebraic states
pparameters
ucontrols
wdisturbances

Definition at line 119 of file integration_algorithm.cpp.

Definition at line 130 of file integration_algorithm.cpp.

Evaluates the sensitivities.

Returns:
SUCCESSFUL_RETURN
RET_NOT_FROZEN

Definition at line 256 of file integration_algorithm.cpp.

Evaluates the sensitivities and the hessian.

Returns:
SUCCESSFUL_RETURN
RET_NOT_FROZEN

Definition at line 268 of file integration_algorithm.cpp.

Returns the result for the backward sensitivities in BlockMatrix form.

Returns:
SUCCESSFUL_RETURN
RET_INPUT_OUT_OF_RANGE
Parameters:
Dthe result for the forward sensitivi- ties

Definition at line 365 of file integration_algorithm.cpp.

Returns the result for the backward sensitivities at the time tend.

Parameters:
Dx_x0backward sensitivities w.r.t. the initial states
Dx_pbackward sensitivities w.r.t. the parameters
Dx_ubackward sensitivities w.r.t. the controls
Dx_wbackward sensitivities w.r.t. the disturbance

Returns:
SUCCESSFUL_RETURN
RET_INPUT_OUT_OF_RANGE

Definition at line 372 of file integration_algorithm.cpp.

Returns the result for the forward sensitivities in BlockMatrix form.

Returns:
SUCCESSFUL_RETURN
RET_INPUT_OUT_OF_RANGE
Parameters:
Dthe result for the forward sensitivi- ties

Definition at line 335 of file integration_algorithm.cpp.

Returns the result for the forward sensitivities at the time tend.

Parameters:
Dxthe result for the forward sensitivities.

Returns:
SUCCESSFUL_RETURN
RET_INPUT_OUT_OF_RANGE

Definition at line 342 of file integration_algorithm.cpp.

Returns the result for the differential states at time tend.

Parameters:
xEndthe result for the states at time tend.
Returns:
SUCCESSFUL_RETURN

Definition at line 293 of file integration_algorithm.cpp.

Returns the requested output on the specified grid. Note
that the output X will be evaluated based on polynomial
interpolation depending on the order of the integrator.

Parameters:
Xthe differential states on the grid.

Returns:
SUCCESSFUL_RETURN
RET_TRAJECTORY_NOT_FROZEN

Definition at line 313 of file integration_algorithm.cpp.

Returns the result for the algebraic states at time tend.

Parameters:
xaEndthe result for the algebraic states at time tend.
Returns:
SUCCESSFUL_RETURN

Definition at line 303 of file integration_algorithm.cpp.

Returns the requested output on the specified grid. Note
that the output X will be evaluated based on polynomial
interpolation depending on the order of the integrator.

Parameters:
XAthe algebraic states on the grid.

Returns:
SUCCESSFUL_RETURN
RET_TRAJECTORY_NOT_FROZEN

Definition at line 323 of file integration_algorithm.cpp.

Parameters:
xdifferential states
xaalgebraic states
pparameters
ucontrols
wdisturbances

Definition at line 140 of file integration_algorithm.cpp.

returnValue IntegrationAlgorithm::integrate ( double  t0,
double  tend,
const DVector x0,
const DVector xa = emptyVector,
const DVector p = emptyVector,
const DVector u = emptyVector,
const DVector w = emptyVector 
)

Starts the integration of the right hand side at time t0.
If neither the maximum number of allowed iteration is
exceeded nor any other error occurs the functions stops the
integration at time tend.

Returns:
SUCCESFUL_RETURN or
a error message that depends on the specific
integration routine. (cf. the corresponding header
file that implements the integration routine)
Parameters:
t0the start time
tendthe end time
x0the initial state
xathe initial algebraic state
pthe parameters
uthe controls
wthe disturbance

Definition at line 151 of file integration_algorithm.cpp.

returnValue IntegrationAlgorithm::integrate ( const Grid t,
const DVector x0,
const DVector xa = emptyVector,
const DVector p = emptyVector,
const DVector u = emptyVector,
const DVector w = emptyVector 
)

Starts the integration of the right hand side at time t0.
If neither the maximum number of allowed iteration is
exceeded nor any other error occurs the functions stops the
integration at time tend.
In addition, results at intermediate grid points can be
stored. Note that these grid points are for storage only and
have nothing to do the integrator steps.

Returns:
SUCCESFUL_RETURN or
a error message that depends on the specific
integration routine. (cf. the corresponding header
file that implements the integration routine)
Parameters:
tthe grid [t0,tend]
x0the initial state
xathe initial algebraic state
pthe parameters
uthe controls
wthe disturbance

Definition at line 172 of file integration_algorithm.cpp.

Evaluates the sensitivities.

Returns:
SUCCESSFUL_RETURN
RET_NOT_FROZEN

Definition at line 262 of file integration_algorithm.cpp.

Evaluates the sensitivities and the hessian.

Returns:
SUCCESSFUL_RETURN
RET_NOT_FROZEN

Definition at line 274 of file integration_algorithm.cpp.

Definition at line 287 of file integration_algorithm.cpp.

IntegrationAlgorithm & IntegrationAlgorithm::operator= ( const IntegrationAlgorithm rhs)

Assignment operator (deep copy).

Definition at line 78 of file integration_algorithm.cpp.

Define a backward seed in form of a block matrix.
Here, the block matrix should have N block columns,
where N is the number of points of the union grid.
The i-th column is associated with the i-th grid
point in the union grid. Note that the directions
can itself be organized in sub-blocks as long as
all dimensions fit together.

Returns:
SUCCESFUL_RETURN
RET_INPUT_OUT_OF_RANGE
Parameters:
seedthe seed matrix

Definition at line 224 of file integration_algorithm.cpp.

Define a backward seed

Returns:
SUCCESFUL_RETURN
RET_INPUT_OUT_OF_RANGE
Parameters:
seedthe backward seed

Definition at line 231 of file integration_algorithm.cpp.

returnValue IntegrationAlgorithm::setForwardSeed ( const BlockMatrix xSeed_,
const BlockMatrix pSeed_ = emptyBlockMatrix,
const BlockMatrix uSeed_ = emptyBlockMatrix,
const BlockMatrix wSeed_ = emptyBlockMatrix 
)

Define a forward seed in form of a block matrix.
Here, the block matrix should have N block rows,
where N is the number of points of the union grid.
The i-th row is associated with the i-th grid
point in the union grid. Note that the direction
can itself be organized in sub-blocks as long as
all dimensions fit together.

Returns:
SUCCESFUL RETURN
RET_INPUT_OUT_OF_RANGE
Parameters:
xSeed_the seed in x-direction
pSeed_the seed in p-direction
uSeed_the seed in u-direction
wSeed_the seed in w-direction

Definition at line 193 of file integration_algorithm.cpp.

returnValue IntegrationAlgorithm::setForwardSeed ( const DVector xSeed,
const DVector pSeed = emptyVector,
const DVector uSeed = emptyVector,
const DVector wSeed = emptyVector 
)

Define a forward seed matrix.

Returns:
SUCCESFUL RETURN
RET_INPUT_OUT_OF_RANGE
Parameters:
xSeedthe seed w.r.t states
pSeedthe seed w.r.t parameters
uSeedthe seed w.r.t controls
wSeedthe seed w.r.t disturbances

Definition at line 203 of file integration_algorithm.cpp.

Defines the first order backward seed to be
a unit matrix.

Returns:
SUCCESFUL_RETURN
RET_INPUT_OUT_OF_RANGE

Definition at line 242 of file integration_algorithm.cpp.

Defines the first order forward seed to be
the unit-directions matrix.

Returns:
SUCCESFUL_RETURN
RET_INPUT_OUT_OF_RANGE

Definition at line 218 of file integration_algorithm.cpp.

Prototype member function for setting-up the logging information at initialization of derived classes.

Returns:
SUCCESSFUL_RETURN

Reimplemented from Logging.

Definition at line 451 of file integration_algorithm.cpp.

Prototype member function for setting-up the option list(s) at initialization of derived classes.

Returns:
SUCCESSFUL_RETURN

Reimplemented from Options.

Definition at line 422 of file integration_algorithm.cpp.

Definition at line 281 of file integration_algorithm.cpp.


Member Data Documentation

Definition at line 380 of file integration_algorithm.hpp.

Definition at line 381 of file integration_algorithm.hpp.


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


acado
Author(s): Milan Vukov, Rien Quirynen
autogenerated on Sat Jun 8 2019 19:40:24