Paper 3, Section I, G

Number Theory
Part II, 2010

(i) Let MM and NN be positive integers, such that NN is not a perfect square. If M<NM<\sqrt{N}, show that every solution of the equation

x2Ny2=Mx^{2}-N y^{2}=M

in positive integers x,yx, y comes from some convergent of the continued fraction of N\sqrt{N}.

(ii) Find a solution in positive integers x,yx, y of

x229y2=5x^{2}-29 y^{2}=5