1#ifndef ROBOTOC_OCP_SOLVER_HPP_
2#define ROBOTOC_OCP_SOLVER_HPP_
111 void solve(const
double t, const Eigen::VectorXd& q, const Eigen::VectorXd& v,
112 const
bool init_solver=true);
145 const std::
string& option="") const;
171 void setSolution(const std::
string& name, const Eigen::VectorXd& value);
183 double KKTError(const
double t, const Eigen::VectorXd& q,
184 const Eigen::VectorXd& v);
209 void disp(std::ostream& os) const;
211 friend std::ostream& operator<<(std::ostream& os,
241 void updateSolution(const
double t, const Eigen::VectorXd& q,
242 const Eigen::VectorXd& v);
Direct multiple shooting method of the optimal control problems.
Definition: direct_multiple_shooting.hpp:32
The state feedback and feedforward policy of LQR subproblem at a time stage.
Definition: lqr_policy.hpp:16
Line search for optimal control problems.
Definition: line_search.hpp:25
Optimal control problem solver by Riccati recursion.
Definition: ocp_solver.hpp:41
const RiccatiFactorization & getRiccatiFactorization() const
Gets the Riccati factorizations. This can be interpreted as locally approximated cost-to-go functions...
OCPSolver(OCPSolver &&) noexcept=default
Default move constructor.
double KKTError() const
Returns the l2-norm of the KKT residuals using the results of OCPsolver::updateSolution() or OCPsolve...
const Solution & getSolution() const
Get the solution over the horizon.
const TimeDiscretization & getTimeDiscretization() const
Gets the discretization.
OCPSolver()
Default constructor.
OCPSolver & operator=(const OCPSolver &)=default
Default copy assign operator.
const aligned_vector< LQRPolicy > & getLQRPolicy() const
Gets of the local LQR policies over the horizon.
void setRobotProperties(const RobotProperties &properties)
Sets a collection of the properties for robot model in this solver.
~OCPSolver()=default
Default destructor.
void disp(std::ostream &os) const
Displays the optimal control problem solver onto a ostream.
const SolverStatistics & getSolverStatistics() const
Gets the solver statistics.
OCPSolver(const OCP &ocp, const SolverOptions &solver_options=SolverOptions())
Construct optimal control problem solver.
void setSolution(const Solution &s)
Sets the solution guess over the horizon.
void setSolverOptions(const SolverOptions &solver_options)
Sets the solver option.
void solve(const double t, const Eigen::VectorXd &q, const Eigen::VectorXd &v, const bool init_solver=true)
Solves the optimal control problem. Internally calls updateSolutio() and discretize().
void discretize(const double t)
Discretizes the problem and reiszes the data structures.
void initConstraints()
Initializes the priaml-dual interior point method for inequality constraints.
OCPSolver(const OCPSolver &)=default
Default copy constructor.
Riccati recursion solver for optimal control problems. Solves the KKT system in linear time complexit...
Definition: riccati_recursion.hpp:26
Dynamics and kinematics model of robots. Wraps pinocchio::Model and pinocchio::Data....
Definition: robot.hpp:32
Solution interpolator.
Definition: solution_interpolator.hpp:17
Solution to the optimal control problem split into a time stage.
Definition: split_solution.hpp:20
The switching time optimization (STO) problem.
Definition: switching_time_optimization.hpp:24
Time discretization of the optimal control problem.
Definition: time_discretization.hpp:20
A timer class to take benchmarks.
Definition: timer.hpp:12
Definition: constraint_component_base.hpp:17
aligned_vector< SplitKKTMatrix > KKTMatrix
The KKT matrix of the optimal control problem.
Definition: kkt_matrix.hpp:16
aligned_vector< SplitSolution > Solution
Solution to the optimal control problem.
Definition: solution.hpp:16
aligned_vector< SplitDirection > Direction
Newton direction of the solution to the optimal control problem.
Definition: direction.hpp:16
std::vector< T, Eigen::aligned_allocator< T > > aligned_vector
std vector with Eigen::aligned_allocator.
Definition: aligned_vector.hpp:14
aligned_vector< SplitKKTResidual > KKTResidual
The KKT residual of the optimal control problem.
Definition: kkt_residual.hpp:16
aligned_vector< SplitRiccatiFactorization > RiccatiFactorization
Riccati factorization matices of the LQR subproblem.
Definition: riccati_factorization.hpp:16
The optimal control problem.
Definition: ocp.hpp:22
Collection of the robot properties, which can change after constructing robot models.
Definition: robot_properties.hpp:30
Options of optimal control solvers.
Definition: solver_options.hpp:17
Statistics of optimal control solvers.
Definition: solver_statistics.hpp:17