I need help understanding the following theorem.

Theorem.Suppose d is a positive integer. If there is one solution to the Fermt-Pell equation (1): , then there are infinitely many solutions. If there is one solution to the Fermat-Pell equation (2): , then there are infinitely many solutions to both (1) and (2).

Proof.

Suppose there are integers a and b,

,where c will shortly be chosen to be . Suppose further that for some there are integers and such that

.When n = 1 this is possible with and . Set

[This is where I'm confused, how do they get these equations? I'm lost from here on.]These values are legal since

,

.

and

,[...] The rest of the proof follows, but I think I posted the relavent parts.

.

Thanks.