loco-3d / crocoddyl

Crocoddyl is an optimal control library for robot control under contact sequence. Its solver is based on various efficient Differential Dynamic Programming (DDP)-like algorithms
BSD 3-Clause "New" or "Revised" License
858 stars 174 forks source link

Cost increases when using 'crocoddyl.SolverFDDP' #1087

Closed Schortenger closed 2 years ago

Schortenger commented 2 years ago

Hi, I'm using crocoddyl.SolverFDDP(problem) to solve an OCP, but the cost increases at some iterations. Is this solver using line search? If so, how can the cost go increasing? Looking forward to the reply. Thanks~

cmastalli commented 2 years ago

The solver handles dynamic feasibility as well. This is in contrast to the classical DDP algorithm. It means that it could increase a little the cost as a trade-off to decrease the infeasibility.

This behaviours appear in line search procedure used by NLP solvers, so this is orthogonal. However, answering your question, FDDP performs a rollout of the dynamics, which can be interpreted as nonlinear search.

For more details see: https://arxiv.org/pdf/1909.04947.pdf.

I will close this issue, but do not hesitate to ask further questions if it is needed.