reserve i,j,n,n1,n2,m,k,l,u for Nat,
        r,r1,r2 for Real,
        x,y for Integer,
        a,b for non trivial Nat,
        F for XFinSequence,
        cF,cF1,cF2 for complex-valued XFinSequence,
        c,c1,c2 for Complex;
reserve x,y,x1,u,w for Nat;
reserve n,m,k for Nat,
        p,q for n-element XFinSequence of NAT,
        i1,i2,i3,i4,i5,i6 for Element of n,
        a,b,d,f for Integer;

theorem Th34:
  for i1,i2,i3 st n<>0 holds
    {p: p.i3 = Product (1+((p.i1) * idseq (p.i2))) & p.i1 >= 1}
  is diophantine Subset of n -xtuples_of NAT
proof
  let i1,i2,i3;set n12=n+13;
  defpred R[XFinSequence of NAT] means
    $1.i3 = Product (1+(($1.i1) * idseq ($1.i2))) & $1.i1 >= 1;
  set RR = {p: R[p] };
assume
A1: n<>0;
    n=n+0;then
    reconsider X1=i1,X=i2,Y=i3, U=n,W=n+1,Y1=n+2,Y2=n+3,Y3=n+4,Y4=n+5,
      Y5 = n+6,X1W=n+7,WX=n+8,Y1Y2=n+9,Y1Y2Y3=n+10,X1X=n+11,ONE=n+12
      as Element of n12 by HILB10_3:2,3;
    defpred P0[XFinSequence of NAT] means 1* $1.X1 >= 0* $1.Y+1;
A2: {p where p is n12-element XFinSequence of NAT:P0[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:8;
    defpred P1[XFinSequence of NAT] means 1* $1.U > 1* $1.Y+0;
A3:   {p where p is n12-element XFinSequence of NAT:P1[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:7;
    defpred P2[XFinSequence of NAT] means 1* $1.X1W = 1* $1.X1 * $1.W;
A4:   {p where p is n12-element XFinSequence of NAT:P2[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:9;
    defpred P3[XFinSequence of NAT] means $1.ONE = 1;
A5:   {p where p is n12-element XFinSequence of NAT:P3[p]}
       is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:14;
    defpred P4[XFinSequence of NAT] means
      1*$1.X1W,1*$1.ONE are_congruent_mod 1*$1.U;
A6: {p where p is n12-element XFinSequence of NAT:P4[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:21;
    defpred P5[XFinSequence of NAT] means $1.Y1= ($1.X1) |^ ($1.X);
A7: {p where p is n12-element XFinSequence of NAT:P5[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:24;
    defpred P6[XFinSequence of NAT] means $1.Y2= ($1.X)!;
A8: {p where p is n12-element XFinSequence of NAT:P6[p]}
      is diophantine Subset of n12 -xtuples_of NAT by Th32;
    defpred P7[XFinSequence of NAT] means 1*$1.WX= 1*$1.W+1*$1.X+0;
A9:  {p where p is n12-element XFinSequence of NAT:P7[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:11;
    defpred P8[XFinSequence of NAT] means
      $1.WX >= $1.X & $1.Y3= $1.WX choose $1.X;
A10: {p where p is n12-element XFinSequence of NAT:P8[p]}
      is diophantine Subset of n12 -xtuples_of NAT by Th30;
    defpred P9[XFinSequence of NAT] means 1* $1.Y1Y2 = 1* $1.Y1 * $1.Y2;
A11: {p where p is n12-element XFinSequence of NAT:P9[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:9;
    defpred PA[XFinSequence of NAT] means 1* $1.Y1Y2Y3 = 1* $1.Y1Y2 * $1.Y3;
A12: {p where p is n12-element XFinSequence of NAT:PA[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:9;
    defpred PB[XFinSequence of NAT] means
      1*$1.Y1Y2Y3,1*$1.Y are_congruent_mod 1*$1.U;
A13: {p where p is n12-element XFinSequence of NAT:PB[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:21;
    defpred PC[XFinSequence of NAT] means 1* $1.X1X = 1* $1.X1 * $1.X;
A14: {p where p is n12-element XFinSequence of NAT:PC[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:9;
    defpred PD[XFinSequence of NAT] means 1* $1.Y4 = 1* $1.X1X +1;
A15: {p where p is n12-element XFinSequence of NAT:PD[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:6;
    defpred PE[XFinSequence of NAT] means $1.Y5= ($1.Y4) |^ ($1.X);
A16: {p where p is n12-element XFinSequence of NAT:PE[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:24;
    defpred PF[XFinSequence of NAT] means 1* $1.U > 1* $1.Y5+0;
A17: {p where p is n12-element XFinSequence of NAT:PF[p]}
      is diophantine Subset of n12 -xtuples_of NAT by HILB10_3:7;
    defpred C1[XFinSequence of NAT] means P0[$1] & P1[$1];
A18: {p where p is n12-element XFinSequence of NAT:C1[p]}
      is diophantine Subset of n12 -xtuples_of NAT
      from HILB10_3:sch 3(A2,A3);
    defpred C2[XFinSequence of NAT] means C1[$1] & P2[$1];
A19: {p where p is n12-element XFinSequence of NAT:C2[p]}
      is diophantine Subset of n12 -xtuples_of NAT
      from HILB10_3:sch 3(A18,A4);
    defpred C3[XFinSequence of NAT] means C2[$1] & P3[$1];
A20: {p where p is n12-element XFinSequence of NAT:C3[p]}
      is diophantine Subset of n12 -xtuples_of NAT
      from HILB10_3:sch 3(A19,A5);
    defpred C4[XFinSequence of NAT] means C3[$1] & P4[$1];
A21: {p where p is n12-element XFinSequence of NAT:C4[p]}
      is diophantine Subset of n12 -xtuples_of NAT
      from HILB10_3:sch 3(A20,A6);
    defpred C5[XFinSequence of NAT] means C4[$1] & P5[$1];
A22: {p where p is n12-element XFinSequence of NAT:C5[p]}
      is diophantine Subset of n12 -xtuples_of NAT
      from HILB10_3:sch 3(A21,A7);
    defpred C6[XFinSequence of NAT] means C5[$1] & P6[$1];
A23: {p where p is n12-element XFinSequence of NAT:C6[p]}
      is diophantine Subset of n12 -xtuples_of NAT
      from HILB10_3:sch 3(A22,A8);
    defpred C7[XFinSequence of NAT] means C6[$1] & P7[$1];
A24: {p where p is n12-element XFinSequence of NAT:C7[p]}
      is diophantine Subset of n12 -xtuples_of NAT
      from HILB10_3:sch 3(A23,A9);
    defpred C8[XFinSequence of NAT] means C7[$1] & P8[$1];
A25: {p where p is n12-element XFinSequence of NAT:C8[p]}
      is diophantine Subset of n12 -xtuples_of NAT
      from HILB10_3:sch 3(A24,A10);
    defpred C9[XFinSequence of NAT] means C8[$1] & P9[$1];
A26: {p where p is n12-element XFinSequence of NAT:C9[p]}
      is diophantine Subset of n12 -xtuples_of NAT from
      HILB10_3:sch 3(A25,A11);
    defpred CA[XFinSequence of NAT] means C9[$1] & PA[$1];
A27: {p where p is n12-element XFinSequence of NAT:CA[p]}
      is diophantine Subset of n12 -xtuples_of NAT from
      HILB10_3:sch 3(A26,A12);
    defpred CB[XFinSequence of NAT] means CA[$1] & PB[$1];
A28: {p where p is n12-element XFinSequence of NAT:CB[p]}
      is diophantine Subset of n12 -xtuples_of NAT from
      HILB10_3:sch 3(A27,A13);
    defpred CC[XFinSequence of NAT] means CB[$1] & PC[$1];
A29: {p where p is n12-element XFinSequence of NAT:CC[p]}
      is diophantine Subset of n12 -xtuples_of NAT from
      HILB10_3:sch 3(A28,A14);
    defpred CD[XFinSequence of NAT] means CC[$1] & PD[$1];
A30: {p where p is n12-element XFinSequence of NAT:CD[p]}
      is diophantine Subset of n12 -xtuples_of NAT from
      HILB10_3:sch 3(A29,A15);
    defpred CE[XFinSequence of NAT] means CD[$1] & PE[$1];
A31: {p where p is n12-element XFinSequence of NAT:CE[p]}
      is diophantine Subset of n12 -xtuples_of NAT from
      HILB10_3:sch 3(A30,A16);
    defpred CF[XFinSequence of NAT] means CE[$1] & PF[$1];
    set PP = {p where p is n12-element XFinSequence of NAT:CF[p]};
A32: PP is diophantine Subset of n12 -xtuples_of NAT
      from HILB10_3:sch 3(A31,A17);
    reconsider PPn = {p|n where p is n12-element XFinSequence of NAT:p in PP}
      as diophantine Subset of n -xtuples_of NAT by NAT_1:11,HILB10_3:5,A32;
A33:  PPn c= RR
    proof
      let x be object;
      assume x in PPn;
      then consider p be n12-element XFinSequence of NAT such that
A34:    x= p|n & p in PP;
      ex q be n12-element XFinSequence of NAT st q=p & CF[q] by A34;
      then
A35:    R[p] by Th20;
      (p|n).X1 = p.i1 & (p|n).X = p.i2 & (p|n).Y = p.i3 by A1,HILB10_3:4;
      hence thesis by A35,A34;
    end;
    RR c= PPn
    proof
      let x be object;
      assume x in RR;
      then consider p such that
A36:     x=p & R[p];
      consider u,w,y1,y2,y3,y4,y5 be Nat such that
A37:    u > p.i3 & (p.i1)*w,1 are_congruent_mod u & y1 = (p.i1)|^(p.i2) &
        y2= (p.i2)! & y3 = (w+(p.i2)) choose (p.i2) &
        y1*y2*y3,p.i3 are_congruent_mod u & y4=1+(p.i1)*(p.i2) &
        y5 = y4|^(p.i2) & u > y5 by A36,Th20;
      reconsider u,w,n,y1,y2,y3,y4,y5 as Element of NAT by ORDINAL1:def 12;
      reconsider x1w = (p.i1)*w,wx=w+(p.i2), y12=y1*y2,y123=y1*y2*y3,
      x1x=(p.i1)*(p.i2),One=1 as Element of NAT;
      set Y1 = <%u%>^<%w%>^<%y1%>^<%y2%>^<%y3%>^<%y4%>^<%y5%>^<%x1w%>^<%wx%>,
      Y2=<%y12%>^<%y123%>^<%x1x%>^<%One%>;
      set Y = Y1 ^Y2;
      set PY = p ^ Y;
      reconsider PY as XFinSequence of NAT;
A38:  len p = n & len Y = 13 & len Y1=9 & len Y2=4 by CARD_1:def 7;
A39:  PY|n =p by A38,AFINSQ_1:57;
A40:  PY.i2 = (PY|n).i2 by A1,HILB10_3:4
        .= p.i2 by A38,AFINSQ_1:57;
      0 in dom Y by AFINSQ_1:66;
      then
A41:  PY.(n+0) = Y.0 by A38,AFINSQ_1:def 3
        .= Y1.0 by A38,AFINSQ_1:51
        .= u by AFINSQ_1:50;
      1 in dom Y by A38,AFINSQ_1:66;
      then
A42:  PY.(n+1) = Y.1 by A38,AFINSQ_1:def 3
        .= Y1.1 by A38,AFINSQ_1:51
        .= w by AFINSQ_1:50;
      2 in dom Y by A38,AFINSQ_1:66;
      then
A43:  PY.(n+2) = Y.2 by A38,AFINSQ_1:def 3
        .= Y1.2 by A38,AFINSQ_1:51
        .= y1 by AFINSQ_1:50;
      3 in dom Y by A38,AFINSQ_1:66;
      then
A44:  PY.(n+3) = Y.3 by A38,AFINSQ_1:def 3
        .= Y1.3 by A38,AFINSQ_1:51
        .= y2 by AFINSQ_1:50;
      4 in dom Y by A38,AFINSQ_1:66;
      then
A45:  PY.(n+4) = Y.4 by A38,AFINSQ_1:def 3
        .= Y1.4 by A38,AFINSQ_1:51
        .= y3 by AFINSQ_1:50;
      5 in dom Y by A38,AFINSQ_1:66;
      then
A46:  PY.(n+5) = Y.5 by A38,AFINSQ_1:def 3
        .= Y1.5 by A38,AFINSQ_1:51
        .= y4 by AFINSQ_1:50;
      6 in dom Y by A38,AFINSQ_1:66;
      then
A47:  PY.(n+6) = Y.6 by A38,AFINSQ_1:def 3
        .= Y1.6 by A38,AFINSQ_1:51
        .= y5 by AFINSQ_1:50;
      7 in dom Y by A38,AFINSQ_1:66;
      then
A48:  PY.(n+7) = Y.7 by A38,AFINSQ_1:def 3
        .= Y1.7 by A38,AFINSQ_1:51
        .= x1w by AFINSQ_1:50;
      8 in dom Y by A38,AFINSQ_1:66;
      then
A49:  PY.(n+8) = Y.8 by A38,AFINSQ_1:def 3
        .= Y1.8 by A38,AFINSQ_1:51
        .= wx by AFINSQ_1:50;
A50:  9 in dom Y & 0 in dom Y2 by A38,AFINSQ_1:66;
      then
A51:  PY.(n+9) = Y.(9+0) by A38,AFINSQ_1:def 3
        .= Y2.0 by A38,A50,AFINSQ_1:def 3
        .= y12 by AFINSQ_1:45;
A52:  10 in dom Y & 1 in dom Y2 by A38,AFINSQ_1:66;
      then
A53:  PY.(n+10) = Y.(9+1) by A38,AFINSQ_1:def 3
        .= Y2.1 by A38,A52,AFINSQ_1:def 3
        .= y123 by AFINSQ_1:45;
A54:  11 in dom Y & 2 in dom Y2 by A38,AFINSQ_1:66;
      then
A55:  PY.(n+11) = Y.(9+2) by A38,AFINSQ_1:def 3
        .= Y2.2 by A38,A54,AFINSQ_1:def 3
        .= x1x by AFINSQ_1:45;
A56:  12 in dom Y & 3 in dom Y2 by A38,AFINSQ_1:66;
      then
A57:  PY.(n+12) = Y.(9+3) by A38,AFINSQ_1:def 3
        .= Y2.3 by A38,A56,AFINSQ_1:def 3
        .= One by AFINSQ_1:45;
      CF[PY] by A36,A37,A39,A1,HILB10_3:4,A40,A41,A42,A43,A44,A45,A46,A47,
                A48,A49,A51,A53,A55,A57,NAT_1:11;
      then PY in PP;
      hence thesis by A39,A36;
    end;
    hence thesis by A33,XBOOLE_0:def 10;
end;
