bioptim icon indicating copy to clipboard operation
bioptim copied to clipboard

Lagrange objective should be calculated at each integration steps

Open pariterre opened this issue 5 years ago • 3 comments

Currently the objective Lagrange functions (and constraint for MINIMIZE) are only computed at the nodes (as for the continuity constraints. However, this approximation may gets ugly if the function is highly nonlinear and the shooting nodes are spread apart.

A solution would be to use the intermediate points of the integration (for ERK at least).

pariterre avatar Nov 26 '20 19:11 pariterre

Also this integration should be optional (the current behavior should be available) and the type of integration should be accessible (Piecewise constant, Trapezoïdal, etc.)

pariterre avatar Nov 26 '20 19:11 pariterre

@Ipuch Check what happens in COLLOCATION

pariterre avatar Apr 19 '22 15:04 pariterre

It's the same with COLLOCATION. As an intermediate way, one could use #458, trapezoidal integration instead of rectangle integration.

Ipuch avatar Apr 27 '23 20:04 Ipuch