Project Chrono: chrono::ChLinkTSDA::ODE Class Reference

Public Member Functions | List of all members
chrono::ChLinkTSDA::ODE Class Referenceabstract

## Description

Class to be used as a callback interface for specifying the ODE, y' = f(t,y); y(0) = y0.

`#include <ChLinkTSDA.h>`

## Public Member Functions
virtual unsigned int | GetNumStates () const =0
| Specify number of states (dimension of y).
virtual void | SetInitialConditions (ChVectorDynamic<> &states, const ChLinkTSDA &link)=0
| Set initial conditions.
virtual void | CalculateRHS (double time, const ChVectorDynamic<> &states, ChVectorDynamic<> &rhs, const ChLinkTSDA &link)=0
| Calculate and return the ODE right-hand side at the provided time and states.
virtual bool | CalculateJac (double time, const ChVectorDynamic<> &states, const ChVectorDynamic<> &rhs, ChMatrixDynamic<> &jac, const ChLinkTSDA &link)
| Calculate the Jacobian of the ODE right-hand side with rerspect to the ODE states.

## Member Function Documentation

## ◆ CalculateJac()

virtual bool chrono::ChLinkTSDA::ODE::CalculateJac | ( | double | time,
|  | const ChVectorDynamic<> & | states,
|  | const ChVectorDynamic<> & | rhs,
|  | ChMatrixDynamic<> & | jac,
|  | const ChLinkTSDA & | link )
| inlinevirtual

Calculate the Jacobian of the ODE right-hand side with rerspect to the ODE states.

Only used if the link force is declared as stiff. If provided, load df/dy into the provided matrix 'jac' (already set to zero before the call) and return 'true'. In that case, the user-provided Jacobian will overwrite the default finite-difference approximation.

Parameters

  time | current time
  states | current ODE states
  rhs | current ODE right-hand side vector
  jac | output Jacobian matrix
  link | associated TSDA link

## ◆ CalculateRHS()

virtual void chrono::ChLinkTSDA::ODE::CalculateRHS | ( | double | time,
|  | const ChVectorDynamic<> & | states,
|  | ChVectorDynamic<> & | rhs,
|  | const ChLinkTSDA & | link )
| pure virtual

Calculate and return the ODE right-hand side at the provided time and states.

Must load f(t,y).

Parameters

  time | current time
  states | current ODE states
  rhs | output ODE right-hand side vector
  link | associated TSDA link

## ◆ SetInitialConditions()

virtual void chrono::ChLinkTSDA::ODE::SetInitialConditions | ( | ChVectorDynamic<> & | states,
|  | const ChLinkTSDA & | link )
| pure virtual

Set initial conditions.

Must load y0 = y(0).

Parameters

  states | output initial conditions vector
  link | associated TSDA link

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

- D:/W/B/src/chrono-9.0.1/src/chrono/physics/ChLinkTSDA.h