Public Types | |
typedef CostModelAbstractTpl< Scalar > | Base |
typedef CostDataAbstractTpl< Scalar > | CostDataAbstract |
typedef CostDataNumDiffTpl< Scalar > | Data |
typedef DataCollectorAbstractTpl< Scalar > | DataCollectorAbstract |
typedef MathBaseTpl< Scalar > | MathBase |
typedef MathBaseTpl< Scalar >::MatrixXs | MatrixXs |
typedef boost::function< void(const typename MathBaseTpl< Scalar >::VectorXs &)> | ReevaluationFunction |
typedef MathBaseTpl< Scalar >::VectorXs | VectorXs |
![]() | |
typedef ActivationModelAbstractTpl< Scalar > | ActivationModelAbstract |
typedef ActivationModelQuadTpl< Scalar > | ActivationModelQuad |
typedef CostDataAbstractTpl< Scalar > | CostDataAbstract |
typedef DataCollectorAbstractTpl< Scalar > | DataCollectorAbstract |
typedef MathBaseTpl< Scalar > | MathBase |
typedef MathBase::MatrixXs | MatrixXs |
typedef StateMultibodyTpl< Scalar > | StateMultibody |
typedef MathBase::VectorXs | VectorXs |
Public Member Functions | |
CostModelNumDiffTpl (const boost::shared_ptr< Base > &model) | |
Construct a new CostModelNumDiff object from a CostModelAbstract. More... | |
virtual | ~CostModelNumDiffTpl () |
Default destructor of the CostModelNumDiff object. | |
virtual void | calc (const boost::shared_ptr< CostDataAbstract > &data, const Eigen::Ref< const VectorXs > &x, const Eigen::Ref< const VectorXs > &u) |
virtual void | calcDiff (const boost::shared_ptr< CostDataAbstract > &data, const Eigen::Ref< const VectorXs > &x, const Eigen::Ref< const VectorXs > &u) |
virtual boost::shared_ptr< CostDataAbstract > | createData (DataCollectorAbstract *const data) |
Create a Data object. More... | |
const Scalar & | get_disturbance () const |
Get the disturbance_ object. More... | |
const boost::shared_ptr< Base > & | get_model () const |
Get the model_ object. More... | |
bool | get_with_gauss_approx () |
Identify if the Gauss approximation is going to be used or not. More... | |
void | set_disturbance (const Scalar &disturbance) |
Set the disturbance_ object. More... | |
void | set_reevals (const std::vector< ReevaluationFunction > &reevals) |
Register functions that updates the shared data computed for a system rollout The updated data is used to evaluate of the gradient and hessian. More... | |
![]() | |
CostModelAbstractTpl (boost::shared_ptr< StateMultibody > state, boost::shared_ptr< ActivationModelAbstract > activation, const std::size_t &nu) | |
CostModelAbstractTpl (boost::shared_ptr< StateMultibody > state, boost::shared_ptr< ActivationModelAbstract > activation) | |
CostModelAbstractTpl (boost::shared_ptr< StateMultibody > state, const std::size_t &nr, const std::size_t &nu) | |
CostModelAbstractTpl (boost::shared_ptr< StateMultibody > state, const std::size_t &nr) | |
void | calc (const boost::shared_ptr< CostDataAbstract > &data, const Eigen::Ref< const VectorXs > &x) |
void | calcDiff (const boost::shared_ptr< CostDataAbstract > &data, const Eigen::Ref< const VectorXs > &x) |
const boost::shared_ptr< ActivationModelAbstract > & | get_activation () const |
const std::size_t & | get_nu () const |
template<class ReferenceType > | |
ReferenceType | get_reference () const |
const boost::shared_ptr< StateMultibody > & | get_state () const |
template<class ReferenceType > | |
void | set_reference (ReferenceType ref) |
Public Attributes | |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef _Scalar | Scalar |
![]() | |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef _Scalar | Scalar |
Protected Attributes | |
Scalar | disturbance_ |
Numerical disturbance used in the numerical differentiation. | |
boost::shared_ptr< Base > | model_ |
Model of the cost. | |
std::vector< ReevaluationFunction > | reevals_ |
Functions that needs execution before calc or calcDiff. | |
![]() | |
boost::shared_ptr< ActivationModelAbstract > | activation_ |
std::size_t | nu_ |
boost::shared_ptr< StateMultibody > | state_ |
VectorXs | unone_ |
Additional Inherited Members | |
![]() | |
virtual void | get_referenceImpl (const std::type_info &, void *) const |
virtual void | set_referenceImpl (const std::type_info &, const void *) |
|
explicit |
Construct a new CostModelNumDiff object from a CostModelAbstract.
model |
|
virtual |
Implements CostModelAbstractTpl< _Scalar >.
|
virtual |
Implements CostModelAbstractTpl< _Scalar >.
|
virtual |
Create a Data object.
data | is the DataCollector used by the original model. |
Reimplemented from CostModelAbstractTpl< _Scalar >.
const boost::shared_ptr<Base>& get_model | ( | ) | const |
Get the model_ object.
const Scalar& get_disturbance | ( | ) | const |
Get the disturbance_ object.
void set_disturbance | ( | const Scalar & | disturbance | ) |
Set the disturbance_ object.
disturbance | is the value used to find the numerical derivative |
bool get_with_gauss_approx | ( | ) |
Identify if the Gauss approximation is going to be used or not.
void set_reevals | ( | const std::vector< ReevaluationFunction > & | reevals | ) |
Register functions that updates the shared data computed for a system rollout The updated data is used to evaluate of the gradient and hessian.
reevals | are the registered functions. |