Scroll down for a solution to this problem.
We provide a solution to the more general case of two similar isosceles triangles both having top angle α smaller than 180°. Construct vectors a and b along the sides as shown, R being a counterclockwise rotation over α. The vector connecting common vertex and midpoint is then (a+Rb)/2, whereas the bottom vertices are connected by b-Ra.
Now taking the dot product of those two, it must be 0 because of the right angle. So, (a+Rb)·(b-Ra)=0. This works out as a·b-Ra·Rb=a·Ra–b·Rb. Now the left side is 0, because rotations do not change the dot product. The right side equals (|a|2-|b|2)cos(α).