I have the following problem:

Prove that the sqrt(2+sqrt(2)) is irrational.

I did the problem similarly to how one of my TAs showed in a tutorial.

Let the sqrt(2+sqrt(2)) = a. Square both sides. This is:

2+sqrt(2)=a

sqrt(2)=(a^2)-2 Square both sides

2=(a^4)-(4a^2)+4

0=(a^4)-(4a^2)+2

Because the factors of 2 (namely 1, -1, 2, -2) do not solve the following equation, we can assume that the original function is irrational.

My question is, what theorem, reasoning, or whatever allows for this to be true and do you think this is adequate for a proof?