robotoc
robotoc - efficient ROBOT Optimal Control solvers
Loading...
Searching...
No Matches
robotoc::UnconstrDynamics Class Reference

Inverse dynamics constraint without constraints (floating base or contacts). More...

#include <unconstr_dynamics.hpp>

Public Member Functions

 UnconstrDynamics (const Robot &robot)
 Constructs the inverse dynamics. More...
 
 UnconstrDynamics ()
 Default constructor. More...
 
 ~UnconstrDynamics ()=default
 Default destructor. More...
 
 UnconstrDynamics (const UnconstrDynamics &)=default
 Default copy constructor. More...
 
UnconstrDynamicsoperator= (const UnconstrDynamics &)=default
 Default copy operator. More...
 
 UnconstrDynamics (UnconstrDynamics &&) noexcept=default
 Default move constructor. More...
 
UnconstrDynamicsoperator= (UnconstrDynamics &&) noexcept=default
 Default move assign operator. More...
 
void evalUnconstrDynamics (Robot &robot, const SplitSolution &s)
 Computes the residual in the unconstrained dynamics constraint. More...
 
void linearizeUnconstrDynamics (Robot &robot, const double dt, const SplitSolution &s, SplitKKTResidual &kkt_residual)
 Linearizes the unconstrained dynamics constraint. More...
 
void condenseUnconstrDynamics (SplitKKTMatrix &kkt_matrix, SplitKKTResidual &kkt_residual)
 Condenses the unconstrained dynamics constraint. More...
 
void expandPrimal (SplitDirection &d) const
 Expands the primal variables, i.e., computes the Newton direction of the condensed primal variable (control input torques) of this stage. More...
 
template<int p = 1>
double primalFeasibility () const
 
double KKTError () const
 Returns squared norm of the KKT residual, that is, the residual in the unconstrained dynamics constraint. More...
 
template<typename MatrixType1 , typename MatrixType2 >
void getStateFeedbackGain (const Eigen::MatrixBase< MatrixType1 > &Ka, const Eigen::MatrixBase< MatrixType2 > &Ku) const
 
template<typename MatrixType1 , typename MatrixType2 , typename MatrixType3 , typename MatrixType4 >
void getStateFeedbackGain (const Eigen::MatrixBase< MatrixType1 > &Kaq, const Eigen::MatrixBase< MatrixType2 > &Kav, const Eigen::MatrixBase< MatrixType3 > &Kuq, const Eigen::MatrixBase< MatrixType4 > &Kuv) const
 

Static Public Member Functions

static void expandDual (const double dt, const SplitKKTMatrix &kkt_matrix, const SplitKKTResidual &kkt_residual, SplitDirection &d)
 Expands the dual variables, i.e., computes the Newton direction of the condensed dual variable (Lagrange multiplier) of this stage. More...
 

Detailed Description

Inverse dynamics constraint without constraints (floating base or contacts).

Constructor & Destructor Documentation

◆ UnconstrDynamics() [1/4]

robotoc::UnconstrDynamics::UnconstrDynamics ( const Robot robot)

Constructs the inverse dynamics.

Parameters
[in]robotRobot model.

◆ UnconstrDynamics() [2/4]

robotoc::UnconstrDynamics::UnconstrDynamics ( )

Default constructor.

◆ ~UnconstrDynamics()

robotoc::UnconstrDynamics::~UnconstrDynamics ( )
default

Default destructor.

◆ UnconstrDynamics() [3/4]

robotoc::UnconstrDynamics::UnconstrDynamics ( const UnconstrDynamics )
default

Default copy constructor.

◆ UnconstrDynamics() [4/4]

robotoc::UnconstrDynamics::UnconstrDynamics ( UnconstrDynamics &&  )
defaultnoexcept

Default move constructor.

Member Function Documentation

◆ condenseUnconstrDynamics()

void robotoc::UnconstrDynamics::condenseUnconstrDynamics ( SplitKKTMatrix kkt_matrix,
SplitKKTResidual kkt_residual 
)

Condenses the unconstrained dynamics constraint.

Parameters
[in]kkt_matrixSplit KKT matrix of this time stage.
[in]kkt_residualSplit KKT residual of this time stage.

◆ evalUnconstrDynamics()

void robotoc::UnconstrDynamics::evalUnconstrDynamics ( Robot robot,
const SplitSolution s 
)

Computes the residual in the unconstrained dynamics constraint.

Parameters
[in]robotRobot model.
[in]sSplit solution of this time stage.

◆ expandDual()

static void robotoc::UnconstrDynamics::expandDual ( const double  dt,
const SplitKKTMatrix kkt_matrix,
const SplitKKTResidual kkt_residual,
SplitDirection d 
)
static

Expands the dual variables, i.e., computes the Newton direction of the condensed dual variable (Lagrange multiplier) of this stage.

Parameters
[in]dtTime step of this time stage.
[in]kkt_matrixSplit KKT matrix of this time stage.
[in]kkt_residualSplit KKT residual of this time stage.
[in,out]dSplit direction of this time stage.

◆ expandPrimal()

void robotoc::UnconstrDynamics::expandPrimal ( SplitDirection d) const

Expands the primal variables, i.e., computes the Newton direction of the condensed primal variable (control input torques) of this stage.

Parameters
[in,out]dSplit direction of this time stage.

◆ getStateFeedbackGain() [1/2]

template<typename MatrixType1 , typename MatrixType2 >
void robotoc::UnconstrDynamics::getStateFeedbackGain ( const Eigen::MatrixBase< MatrixType1 > &  Ka,
const Eigen::MatrixBase< MatrixType2 > &  Ku 
) const
inline

◆ getStateFeedbackGain() [2/2]

template<typename MatrixType1 , typename MatrixType2 , typename MatrixType3 , typename MatrixType4 >
void robotoc::UnconstrDynamics::getStateFeedbackGain ( const Eigen::MatrixBase< MatrixType1 > &  Kaq,
const Eigen::MatrixBase< MatrixType2 > &  Kav,
const Eigen::MatrixBase< MatrixType3 > &  Kuq,
const Eigen::MatrixBase< MatrixType4 > &  Kuv 
) const
inline

◆ KKTError()

double robotoc::UnconstrDynamics::KKTError ( ) const
inline

Returns squared norm of the KKT residual, that is, the residual in the unconstrained dynamics constraint.

Returns
Squared norm of the residual in the unconstrained dynamics constraint.

◆ linearizeUnconstrDynamics()

void robotoc::UnconstrDynamics::linearizeUnconstrDynamics ( Robot robot,
const double  dt,
const SplitSolution s,
SplitKKTResidual kkt_residual 
)

Linearizes the unconstrained dynamics constraint.

Parameters
[in]robotRobot model.
[in]dtTime step of this time stage.
[in]sSplit solution of this time stage.
[in,out]kkt_residualSplit KKT residual of this time stage.

◆ operator=() [1/2]

UnconstrDynamics & robotoc::UnconstrDynamics::operator= ( const UnconstrDynamics )
default

Default copy operator.

◆ operator=() [2/2]

UnconstrDynamics & robotoc::UnconstrDynamics::operator= ( UnconstrDynamics &&  )
defaultnoexcept

Default move assign operator.

◆ primalFeasibility()

template<int p = 1>
double robotoc::UnconstrDynamics::primalFeasibility ( ) const
inline

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