
A practical procedure for solving (REF ) with the landmark
Hamiltonian above is called shooting, where we replace the end-point
condition \(\mathbf {q}_1\)  with a guess for \(\mathbf {p}_0\) , and iteratively update
\(\mathbf {p}_0\)  using automatically computed adjoint (or backward) equations
until \(\mathbf {q}_1\)  compares to \(\mathbf {q}(1)\)  below a certain tolerance. We
will perform this procedure directly with an automatic differentiation package
Theano [1]}, see
[2]}, [3]} for more details on the
implementation. This section concludes with some theoretical results.

Let \(\nu \)  be bounded from below away from zero by \(\nu _\text{inf}\in \mathbb {R}\)  and
from above by \(0<\sigma ^2\in \mathbb {R}\) . Then there exists a minimiser of
(REF ) admissible to (REF ).


The functional in (REF ) is not convex so we work with a
reformulation to ensure the required lower semi-continuity. Define a
variable \(w^i_t = \sqrt{\nu (q_t^i)} p^i_t\)  in the problem:
\(\inf _{\begin{array}{c}u \in L^2([0,1],\,V)\\ \mathbf {q}\in H^1([0,1],\,\mathbb {R}^{d\times M})\\\mathbf {w}\in L^2([0,1],\,\mathbb {R}^{d\times M})\end{array}}& \int _0^1\frac{1}{2}\left(\Vert u_t\Vert ^2_V + \sum _{i=1}^M |w_t^i|^2\right)\text{d} t\\& \dot{\mathbf {q}_t^i} = u_t(\mathbf {q}_t) + \sqrt{\nu (\mathbf {q}_t)} \mathbf {w}_t\\& \mathbf {q}_0,\,\mathbf {q}_1\text{ fixed}\) 
