crocoddyl  1.3.0
Contact RObot COntrol by Differential DYnamic programming Library (Crocoddyl)
box-fddp.hpp
1 // BSD 3-Clause License
3 //
4 // Copyright (C) 2019-2020, University of Edinburgh
5 // Copyright note valid unless otherwise stated in individual files.
6 // All rights reserved.
8 
9 #ifndef CROCODDYL_CORE_SOLVERS_BOX_FDDP_HPP_
10 #define CROCODDYL_CORE_SOLVERS_BOX_FDDP_HPP_
11 
12 #include <Eigen/Cholesky>
13 #include <vector>
14 
15 #include "crocoddyl/core/solvers/fddp.hpp"
16 #include "crocoddyl/core/solvers/box-qp.hpp"
17 
18 namespace crocoddyl {
19 
20 class SolverBoxFDDP : public SolverFDDP {
21  public:
22  EIGEN_MAKE_ALIGNED_OPERATOR_NEW
23 
24  explicit SolverBoxFDDP(boost::shared_ptr<ShootingProblem> problem);
25  virtual ~SolverBoxFDDP();
26 
27  virtual void allocateData();
28  virtual void computeGains(const std::size_t& t);
29  virtual void forwardPass(const double& steplength);
30 
31  const std::vector<Eigen::MatrixXd>& get_Quu_inv() const;
32 
33  protected:
34  BoxQP qp_;
35  std::vector<Eigen::MatrixXd> Quu_inv_;
36  Eigen::VectorXd du_lb_;
37  Eigen::VectorXd du_ub_;
38 };
39 
40 } // namespace crocoddyl
41 
42 #endif // CROCODDYL_CORE_SOLVERS_BOX_FDDP_HPP_
This class implements a Box QP solver based on a Projected Newton method.
Definition: box-qp.hpp:79