I am reading a proof of the following theorem concerning Girsanov's Theorem.
Let be $M$ a continuous local $P$- martingale. Then $M-\langle M,Y\rangle$ is a continuos local $Q$ martingale.
Here $Y_t=\int_0^t\frac{1}{Z_s}dZ_s$ and $Z_t$ is the radon nikodym density $\frac{dQ}{dP}_{\mid F_t}$. I do not understand the following part in the proof:
Why is $\int_0^t\frac{1}{Z_s}d\langle M,Z\rangle=\langle M,Y\rangle_t$ true?
Any help here is highly appreciated.
The original proof:
From $Z_t=Z_0\exp(Y_t-\frac12\langle Y\rangle_t$ we have $dZ_t=Z_tdY_t$ thus $$(\frac {1}{Z}\circ \langle M,Z\rangle)_t=\int_0^t\frac{1}{Z_s}Z_sd\langle M,Y\rangle_s=\langle M,Y\rangle$$
Heuristically $$dZ=YdY$$ implies that $$\frac{dZ}{Z}=dY.$$
Then $$dM\frac{dZ}{Z}=dY dM$$ which is equivalent to $\frac{1}{Z} d\langle Z,M\rangle=d\langle Y,M\rangle$. Integrating both sides gives the desired result