reserve a,b,c,k,m,n for Nat;
reserve i,j,x,y for Integer;
reserve p,q for Prime;
reserve r,s for Real;

theorem Th55:
  { [x,y] where x,y is positive Nat: (2*x+1)^2 - 2*y^2 + 1 = 0 } is infinite
  proof
    deffunc R(Complex,Complex) = (2*$1+1)^2-2*$2^2+1;
    set A = {[x,y] where x,y is positive Nat: R(x,y) = 0};
A1: R(3,5) = 0;
    then [3,5] in A;
    then reconsider A as non empty set;
    deffunc p1(Real,Real) = 3*$1+2*$2+1;
    deffunc p2(Real,Real) = 4*$1+3*$2+2;
    defpred P[object,Element of [:NAT,NAT:],Element of [:NAT,NAT:]] means
    $3 = [p1($2`1,$2`2),p2($2`1,$2`2)];
    set f = recSeqCart(3,5,3,2,1,4,3,2);
A2: dom f = NAT by PARTFUN1:def 2;
    defpred N[Nat] means f.$1 in A;
    f.0 = [3,5] by NUMBER08:def 10;
    then
A3: N[0] by A1;
A4: N[a] implies N[a+1]
    proof
      assume N[a];
      then consider x,y being positive Nat such that
A5:   f.a = [x,y] & R(x,y) = 0;
      set m = (f.a)`1;
      set n = (f.a)`2;
A6:   f.(a+1) = [p1(m,n),p2(m,n)] by NUMBER08:def 10;
      R(p1(m,n),p2(m,n)) = 0 by A5;
      hence thesis by A6;
    end;
A7: N[a] from NAT_1:sch 2(A3,A4);
A8: rng f c= A
    proof
      let y be object;
      assume y in rng f;
      then ex k being object st k in dom f & f.k = y by FUNCT_1:def 3;
      hence thesis by A7;
    end;
    f is one-to-one by NUMBER08:92;
    hence thesis by A2,A8,CARD_1:59;
  end;
