Given a generic configuration space modelled on a Riemannian manifold $(Q$,$\langle , \rangle)$, I want to prove that the Hamiltonian is a constant of motion.
Setup
The kinetic energy $K:TQ \to \mathbb{R}$ is given. by $K(p,v) := \frac{1}{2}\langle v,v \rangle_p$.
A potential energy function $V:Q \to \mathbb{R}$ is given.
Newton's Equations are:
$$ \nabla_{\dot{q}} \dot{q} = -\nabla V, \ \text{where } \nabla \ \text{is given by the Levi Civita connection from } \langle , \rangle. $$
The Hamiltonian $H: TQ \to \mathbb{R}$ is then given by $$ H(p,v) = K(p,v) + V(p). $$
I want to show that, along a curve $q:I\subset\mathbb{R} \to Q$ satisfying Newton's equations, we have $$ \frac{d}{dt} H(q(t),\dot{q}(t)) = 0. $$
Work
I will omit the argument $t$ in the following: $$ \begin{align} \frac{d}{dt} H(q,\dot{q}) &= \frac{d}{dt} K(q,\dot{q}) + \frac{d}{dt}V(q) \\ &= \frac{1}{2} \frac{d}{dt} \langle \dot{q}, \dot{q} \rangle_q + dV(q)\Big(\frac{d}{dt}\Big) \\ &= \langle \nabla_{\frac{d}{dt}} \dot{q}, \dot{q} \rangle_q + \langle \nabla V, \frac{d}{dt} \rangle_q \\ &= \langle \nabla_{\frac{d}{dt}} \dot{q}, \dot{q} \rangle_q - \langle \nabla_{\dot{q}} \dot{q}, \frac{d}{dt} \rangle_q. \end{align} $$
However, I am not confident that in general $$ \langle \nabla_B A,A \rangle - \langle \nabla_A A, B \rangle = 0, $$
so I think I may be forgetting something specific to these vector fields. Either that or I have made some mistake with notation.