cpp_robotics::OCPCost
#include <ocp_cost.hpp>
Inherited by cpp_robotics::OCPCostQuadratic, cpp_robotics::OCPCostServoQuadratic
Public Types
Name | |
---|---|
using std::shared_ptr< OCPCost > | SharedPtr |
Public Functions
Name | |
---|---|
OCPCost(size_t nx, size_t nu, size_t horizon) | |
OCPCost(std::shared_ptr< OCPDynamics > model, size_t horizon) | |
virtual double | eval(const Eigen::VectorXd & x, const Eigen::VectorXd & u, const size_t i) const =0 |
virtual double | eval_terminal(const Eigen::VectorXd & x) const =0 |
virtual Eigen::VectorXd | jacobian_x(const Eigen::VectorXd & x, const Eigen::VectorXd & u, const size_t i) const |
virtual Eigen::VectorXd | jacobian_u(const Eigen::VectorXd & x, const Eigen::VectorXd & u, const size_t i) const |
virtual Eigen::MatrixXd | hessian_xx(const Eigen::VectorXd & x, const Eigen::VectorXd & u, const size_t i) const |
virtual Eigen::MatrixXd | hessian_uu(const Eigen::VectorXd & x, const Eigen::VectorXd & u, const size_t i) const |
virtual Eigen::MatrixXd | hessian_ux(const Eigen::VectorXd & x, const Eigen::VectorXd & u, const size_t i) const |
virtual Eigen::VectorXd | jacobian_x_terminal(const Eigen::VectorXd & x) const |
virtual Eigen::MatrixXd | hessian_xx_terminal(const Eigen::VectorXd & x) const |
bool | is_terminal(const size_t i) const |
size_t | state_size() const |
size_t | input_size() const |
size_t | horizon() const |
Public Attributes
Name | |
---|---|
double | eps |
Public Types Documentation
using SharedPtr
using cpp_robotics::OCPCost::SharedPtr = std::shared_ptr<OCPCost>;
Public Functions Documentation
function OCPCost
inline OCPCost(
size_t nx,
size_t nu,
size_t horizon
)
function OCPCost
inline OCPCost(
std::shared_ptr< OCPDynamics > model,
size_t horizon
)
function eval
virtual double eval(
const Eigen::VectorXd & x,
const Eigen::VectorXd & u,
const size_t i
) const =0
Reimplemented by: cpp_robotics::OCPCostQuadratic::eval, cpp_robotics::OCPCostServoQuadratic::eval
function eval_terminal
virtual double eval_terminal(
const Eigen::VectorXd & x
) const =0
Reimplemented by: cpp_robotics::OCPCostQuadratic::eval_terminal, cpp_robotics::OCPCostServoQuadratic::eval_terminal
function jacobian_x
inline virtual Eigen::VectorXd jacobian_x(
const Eigen::VectorXd & x,
const Eigen::VectorXd & u,
const size_t i
) const
Reimplemented by: cpp_robotics::OCPCostQuadratic::jacobian_x, cpp_robotics::OCPCostServoQuadratic::jacobian_x
function jacobian_u
inline virtual Eigen::VectorXd jacobian_u(
const Eigen::VectorXd & x,
const Eigen::VectorXd & u,
const size_t i
) const
Reimplemented by: cpp_robotics::OCPCostQuadratic::jacobian_u, cpp_robotics::OCPCostServoQuadratic::jacobian_u
function hessian_xx
inline virtual Eigen::MatrixXd hessian_xx(
const Eigen::VectorXd & x,
const Eigen::VectorXd & u,
const size_t i
) const
Reimplemented by: cpp_robotics::OCPCostQuadratic::hessian_xx, cpp_robotics::OCPCostServoQuadratic::hessian_xx
function hessian_uu
inline virtual Eigen::MatrixXd hessian_uu(
const Eigen::VectorXd & x,
const Eigen::VectorXd & u,
const size_t i
) const
Reimplemented by: cpp_robotics::OCPCostQuadratic::hessian_uu, cpp_robotics::OCPCostServoQuadratic::hessian_uu
function hessian_ux
inline virtual Eigen::MatrixXd hessian_ux(
const Eigen::VectorXd & x,
const Eigen::VectorXd & u,
const size_t i
) const
Reimplemented by: cpp_robotics::OCPCostQuadratic::hessian_ux, cpp_robotics::OCPCostServoQuadratic::hessian_ux
function jacobian_x_terminal
inline virtual Eigen::VectorXd jacobian_x_terminal(
const Eigen::VectorXd & x
) const
Reimplemented by: cpp_robotics::OCPCostQuadratic::jacobian_x_terminal, cpp_robotics::OCPCostServoQuadratic::jacobian_x_terminal
function hessian_xx_terminal
inline virtual Eigen::MatrixXd hessian_xx_terminal(
const Eigen::VectorXd & x
) const
Reimplemented by: cpp_robotics::OCPCostQuadratic::hessian_xx_terminal, cpp_robotics::OCPCostServoQuadratic::hessian_xx_terminal
function is_terminal
inline bool is_terminal(
const size_t i
) const
function state_size
inline size_t state_size() const
function input_size
inline size_t input_size() const
function horizon
inline size_t horizon() const
Public Attributes Documentation
variable eps
double eps = 1e-6;
Updated on 2024-05-28 at 06:55:39 +0000