31 #ifndef DIRECTRANSCRIPTION_HPP_
32 #define DIRECTRANSCRIPTION_HPP_
40 #include <Eigen/Dense>
42 #include <dynamical_systems/base/DynamicsBase.hpp>
43 #include <dynamical_systems/base/DerivativesBaseDS.hpp>
48 namespace DirectTrajectoryOptimization {
54 template<
class DIMENSIONS>
59 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
61 typedef typename DIMENSIONS::state_vector_t state_vector_t;
62 typedef typename DIMENSIONS::control_vector_t control_vector_t;
63 typedef typename DIMENSIONS::state_vector_array_t state_vector_array_t;
64 typedef typename DIMENSIONS::control_vector_array_t control_vector_array_t;
65 typedef typename DIMENSIONS::control_gain_matrix_t control_gain_matrix_t;
66 typedef typename DIMENSIONS::state_matrix_t state_matrix_t;
79 std::vector<std::shared_ptr<DynamicsBase<DIMENSIONS> > > dynamics,
80 std::vector<std::shared_ptr<DerivativesBaseDS<DIMENSIONS> > > derivatives,
81 std::shared_ptr<BaseClass::CostFunctionBase<DIMENSIONS> > costFunction,
83 Eigen::Vector2d duration,
int number_of_nodes,
bool methodVerbose) :
85 constraints, duration, number_of_nodes, methodVerbose) {
88 std::cout <<
"DTO Object successfully created" << std::endl;
96 virtual void evalSparseJacobianConstraint(
double* val)
override;
97 virtual void evaluateDefects(Eigen::VectorXd & defect_vector)
override;
99 virtual void SetDircolMethod(
const int &dcm)
override;
101 int dircol_method = 0;
102 state_matrix_t I_y = state_matrix_t::Identity();
This class implements Direct transcription.
Definition: direct_transcription.hpp:55
This class serves as a base interface for inheriting classes.
Definition: base_method_interface.hpp:60
Base class for constraints.
DTODirectTranscription(std::vector< std::shared_ptr< DynamicsBase< DIMENSIONS > > > dynamics, std::vector< std::shared_ptr< DerivativesBaseDS< DIMENSIONS > > > derivatives, std::shared_ptr< BaseClass::CostFunctionBase< DIMENSIONS > > costFunction, std::vector< std::shared_ptr< BaseClass::ConstraintsBase< DIMENSIONS > > > constraints, Eigen::Vector2d duration, int number_of_nodes, bool methodVerbose)
Constructor of DTODirectTranscription.
Definition: direct_transcription.hpp:78
Base class for TO constraints.
Definition: ConstraintsBase.hpp:46
Base class to derive cost functions.
Base class for direct methods.