Source

project-euler / project-euler / 47.txt

Full commit
Let's suppose that N = ab^2 can N+1 = cd^2 ?

ab^2+1 = cd^2
1 = cd^2-ab^2 = (dc'+ba')(dc'-ba')

Yes!

N = 8 = 2 * 2^2 ; N+1 = 9 = 1 * 3^3


p_1^2 

(a*2+1)*(b*2+1)^2 + 2 = (c*2+1)*(d*2+1)^2