I need to show that the general least square formula "inv(HWH')H'W" is equivalent to another form.

I describe the problem in detail in the attached pdf file.

least_squares.pdf

I will greatly appreciate if anyone can tell me how to prove that equivalence, or at least give me a name of a book/paper(anything) which proves (or at least mentions) this equivalence.

thanx.