Shooting

HamiltonianDynamic.shoot(h, solver, it, controls=None, intermediates=None, t1=1.0)[source]

Shoot the hamiltonian system. integrate ODE, associe a gd et mom initiaux la trajectoire lien article. minimisation energie definit par le modele. obtient trajectoire minimisante.

Parameters
  • h (HamiltonianDynamic.Hamiltonian) – The hamiltonian system that will be shot.

  • it (int) – The number of iterations the solver will do.

  • solver (str) –

    Numerical scheme that will be used to integrate the system.

    Supported solvers are :

    • ’torch_euler’ : Euler scheme

    The following solvers uses torchdiffeq :

    • ’euler’ : Euler scheme

    • ’midpoint’ : RK2 scheme

    • ’rk4’ : RK$ scheme

  • controls (iterable, default=None) –

    Optional iterable of tensors representing the controls at each step that will be filled to the deformation module.

    controls has to be of length it. Each element i of controls has to be an iterable of size len(h.module.modules) each element j representing the controls given to the module j of h.module.

  • intermediates (dict, default=None) – Dictionnary that will be filled with intermediate states and controls.