reserve x for set;
reserve a, b, c for Real;
reserve m, n, m1, m2 for Nat;
reserve k, l for Integer;
reserve p, q for Rational;
reserve s1, s2 for Real_Sequence;

theorem Th67:
  for a be Real ex s being Rational_Sequence st
  s is convergent & lim s = a & for n holds s.n<=a
proof
  let a be Real;
  deffunc O(Nat) = [\($1+1)*a/]/($1+1);
  consider s being Real_Sequence such that
A1: for n holds s.n = O(n) from SEQ_1:sch 1;
  rng s c= RAT
  proof
    let y be object;
    assume y in rng s;
    then consider n being Element of NAT such that
A2: s.n = y by FUNCT_2:113;
    s.n = O(n) by A1;
    hence thesis by A2,RAT_1:def 2;
  end;
  then reconsider s as Rational_Sequence by RELAT_1:def 19;
  deffunc O(Nat) = 1/($1+1);
  consider s2 being Real_Sequence such that
A3: for n holds s2.n = O(n) from SEQ_1:sch 1;
  reconsider a1 = a as Element of REAL by XREAL_0:def 1;
  set s1 = seq_const a;
  take s;
  set s3 = s1 - s2;
A4: s2 is convergent by A3,SEQ_4:31;
  then
A5: s3 is convergent;
A6: now
    let n;
    (n+1)*a <= [\(n+1)*a/] + 1 by INT_1:29;
    then (n+1)*a - 1 <= [\(n+1)*a/] + 1 - 1 by XREAL_1:9;
    then ((n+1)*a - 1)*(n+1)" <= [\(n+1)*a/]/(n+1) by XREAL_1:64;
    then (a/(n+1))*(n+1) - 1/(n+1) <= s.n by A1;
    then a - 1/(n+1) <= s.n by XCMPLX_1:87;
    then s1.n - 1/(n+1) <= s.n by SEQ_1:57;
    then
A7: s1.n - s2.n <= s.n by A3;
    [\(n+1)*a/] <= (n+1)*a by INT_1:def 6;
    then [\(n+1)*a/]*(n+1)" <= a*(n+1)*(n+1)" by XREAL_1:64;
    then [\(n+1)*a/]*(n+1)" <= a*((n+1)*(n+1)");
    then [\(n+1)*a/]*(n+1)" <= a*1 by XCMPLX_0:def 7;
    then [\(n+1)*a/]/(n+1) <= s1.n by SEQ_1:57;
    hence s3.n <= s.n & s.n <= s1.n by A1,A7,RFUNCT_2:1;
  end;
  lim s2 = 0 by A3,SEQ_4:31;
  then
A8: lim s3 = s1.0 - 0 by A4,SEQ_4:42
    .= a by SEQ_1:57;
A9: lim s1 = s1.0 by SEQ_4:26
    .= a by SEQ_1:57;
  hence s is convergent by A5,A8,A6,SEQ_2:19;
  thus lim s = a by A5,A8,A9,A6,SEQ_2:20;
  let n;
  s.n<=s1.n by A6;
  hence thesis by SEQ_1:57;
end;
