I've been messing around with the coordinates and got this:
If we have a general invertible transformation of the type Q=Q(q,p,t)\Leftrightarrow q=q(Q,P,t) and P=P(q,p,t)\Leftrightarrow p=p(P,Q,t) then the following is true:
\begin{matrix}
\dot{q}=\frac{\partial q}{\partial...