reserve n,m,k for Nat;
reserve a,p,r for Real;
reserve s,s1,s2,s3 for Real_Sequence;

theorem
  p>1 & (for n st n>=1 holds s.n = 1/n to_power p) implies s is summable
proof
  assume that
A1: p>1 and
A2: for n st n>=1 holds s.n = 1/n to_power p;
  defpred X[Nat,Real] means ($1=0 & $2=1) or ($1>=1 & $2=1/
  $1 to_power p);
A3: for n being Element of NAT ex r being Element of REAL st X[n,r]
  proof
   let n be Element of NAT;
A4:  n <> 0 implies n >= 0+1 by NAT_1:13;
    per cases;
   suppose
A5:   n = 0;
    reconsider jj = 1 as Real;

    take jj;
    thus thesis by A5,Lm2;
   end;
   suppose
A6:   n > 0;
     reconsider n1 = 1/n to_power p as Element of REAL by XREAL_0:def 1;
    take n1;
    thus thesis by A6,A4;
   end;
  end;
  consider s1 such that
A7: for n being Element of NAT holds X[n,s1.n] from FUNCT_2:sch 3(A3);
  deffunc V(Nat) = 2 to_power $1 * s1.(2 to_power $1);
  consider s2 such that
A8: for n holds s2.n = V(n) from SEQ_1:sch 1;
A9: s1.0 = 1 by A7;
  now
    let n;
    now
      per cases by NAT_1:6;
      suppose
A10:     n=0;
        then (n+1) #R p >= 1 by A1,PREPOWER:85;
        then
A11:    (n+1) to_power p >= 1 by POWER:def 2;
        s1.(n+1) = 1/(n+1) to_power p by A7;
        hence s1.(n+1)<=s1.n by A9,A10,A11,XREAL_1:211;
      end;
      suppose
A12:    ex m be Nat st n=m+1;
A13: n in NAT by ORDINAL1:def 12;
        n to_power p > 0 by POWER:34,A12;
        then 1/n to_power p > 0;
        then
A14:    s1.n>0 by A7,A13;
A15:    n/(n+1)<=1 by NAT_1:11,XREAL_1:183;
A16:    n/(n+1)>0 by A12;
        s1.(n+1)/s1.n = (1/(n+1) to_power p)/s1.n by A7
          .= (1/(n+1) to_power p)/(1/n to_power p) by A7,A12
          .= (1/(n+1) to_power p) * n to_power p
          .= n to_power p / (n+1) to_power p
          .= (n/(n+1)) to_power p by A12,POWER:31
          .= (n/(n+1)) #R p by A16,POWER:def 2;
        then s1.(n+1)/s1.n <= (n/(n+1)) #R 0 by A1,A16,A15,PREPOWER:84;
        then s1.(n+1)/s1.n <= 1 by A12,PREPOWER:71;
        hence s1.(n+1)<=s1.n by A14,XREAL_1:187;
      end;
    end;
    hence s1.(n+1)<=s1.n;
  end;
  then
A17: s1 is non-increasing;
A18: now
    let n;
    assume n>=0;
A19: n+1>=0+1 by XREAL_1:6;
    (s^\1).n = s.(n+1) by NAT_1:def 3
      .= 1/(n+1) to_power p by A2,A19
      .= s1.(n+1) by A7
      .= (s1^\1).n by NAT_1:def 3;
    hence (s1^\1).n>=(s^\1).n;
  end;
  deffunc U(Nat) = $1-root (s2.$1);
  consider s3 such that
A20: for n holds s3.n = U(n) from SEQ_1:sch 1;
A21: now
    let n;
A22: 2 to_power n > 0 by POWER:34;
    thus
A23: s2.n = 2 to_power n * s1.(2 to_power n) by A8
      .= 2 to_power n * (1/(2 to_power n) to_power p) by A7,A22
      .= 2 to_power n * (1/2 to_power (n*p)) by POWER:33
      .= 2 to_power n * 2 to_power (-n*p) by POWER:28
      .= 2 to_power (n+-n*p) by POWER:27
      .= 2 to_power ((1-p)*n);
    hence s2.n>=0 by POWER:34;
    s2.n = 2 to_power (1-p) to_power n by A23,POWER:33;
    hence s3.n = n-root (2 to_power (1-p) to_power n) by A20;
  end;
A0: 2 to_power (1-p) is set by TARSKI:1;
A24: now
    let n be Nat;
A25: n+1>=0+1 & 2 to_power (1-p) >= 0 by POWER:34,XREAL_1:6;
    thus (s3^\1).n = s3.(n+1) by NAT_1:def 3
      .= (n+1)-root (2 to_power (1-p) to_power (n+1)) by A21
      .= 2 to_power (1-p) by A25,POWER:4;
  end;
  then
A26: s3^\1 is constant by A0;
  then lim (s3^\1) = (s3^\1).0 by SEQ_4:26
    .= 2 to_power (1-p) by A24;
  then
A27: lim s3 = 2 to_power (1-p) by A26,SEQ_4:22;
A28: now
    let n;
    now
      per cases by NAT_1:6;
      suppose
        n=0;
        hence s1.n >= 0 by A7;
      end;
      suppose
A29:     ex m be Nat st n=m+1;
A30: n in NAT by ORDINAL1:def 12;
        n to_power p > 0 by POWER:34,A29;
        then 1/n to_power p >= 0;
        hence s1.n>=0 by A7,A30;
      end;
    end;
    hence s1.n>=0 & s2.n = 2 to_power n * s1.(2 to_power n) by A8;
  end;
A31: now
    let n;
A32: n+1>=0+1 by XREAL_1:6;
A33: s1.(n+1)>=0 by A28;
    (s^\1).n = s.(n+1) by NAT_1:def 3
      .= 1/(n+1) to_power p by A2,A32
      .= s1.(n+1) by A7
      .= (s1^\1).n by NAT_1:def 3;
    hence (s^\1).n>=0 by A33,NAT_1:def 3;
  end;
A34: s3 is convergent by A26,SEQ_4:21;
  1-p<0 by A1,XREAL_1:49;
  then lim s3 < 1 by A27,POWER:36;
  then s2 is summable by A20,A21,A34,Th28;
  then s1 is summable by A17,A28,Th31;
  then s1^\1 is summable by Th12;
  then s^\1 is summable by A31,A18,Th19;
  hence thesis by Th13;
end;
