Point $H$ is the orthocenter of $\triangle ABC$. Let $AD$ and $CM$ be the altitudes. Show that $BM^2-BD^2=HD^2-HM^2$.
By Pythagorean theorem: 1) $\triangle BCM \rightarrow BM^2=BC^2-CM^2$ and 2) $\triangle ABD \rightarrow BD^2-AB^2-AD^2$. How to approach the problem further?
Write Pytagorean theorem in right triangles which includes also the point $H$, say $HCD$ and $HAM$.
Better, try $HBM$ and $HBD$.