reserve X for set;
reserve k,m,n for Nat;
reserve i for Integer;
reserve a,b,c,d,e,g,p,r,x,y for Real;
reserve z for Complex;

theorem Th17:
  0 <= r implies sin.r <= r
proof
  assume 0 <= r;
  then reconsider A = [.0,r.] as non empty closed_interval Subset of REAL
  by MEASURE5:def 3,XXREAL_1:1;
A1: dom cos = REAL by FUNCT_2:def 1;
    then dom (cos|A)=A by RELAT_1:62;
    then cos|A is total by PARTFUN1:def 2;
    then reconsider cA=cos||A as Function of A,REAL;
A2: cA|A is bounded & cA is integrable
    proof
      cos|A is continuous;
      hence thesis by INTEGRA5:def 1,INTEGRA5:11,10,A1;
    end;
A3: integral(cA) = sin.r
    proof
      thus integral(cA) = integral(cos,A) by INTEGRA5:def 2
      .= integral(cos,0,r) by INTEGRA5:19
      .= sin.r - sin.0 by INTEGRA7:24
      .= sin.r by SIN_COS:30;
    end;
    set Z0 = #Z 0;
A4: dom Z0 = REAL by FUNCT_2:def 1;
    then dom (Z0|A)=A by RELAT_1:62;
    then Z0|A is total by PARTFUN1:def 2;
    then reconsider ZA = Z0||A as Function of A,REAL;
A5: ZA|A is bounded & ZA is integrable
    proof
      Z0|A is continuous;
      hence thesis by A4,INTEGRA5:def 1,INTEGRA5:11,10;
    end;
A6: integral(ZA) = r
    proof
      set Z1 = #Z 1;
A7:   (0+1)(#)Z0 = Z0 by RFUNCT_1:21;
A8:   Z1.r = r #Z 1 by TAYLOR_1:def 1
      .= r by PREPOWER:35;
A9:   Z1.0 = 0 #Z 1 by TAYLOR_1:def 1
      .= 0 by PREPOWER:35;
      thus integral(ZA) = integral(Z0,A) by INTEGRA5:def 2
      .= integral(Z0,0,r) by INTEGRA5:19
      .= Z1.r - Z1.0 by A7,INTEGRA7:30
      .= r by A8,A9;
    end;
    for r st r in A holds cA.r <= ZA.r
    proof
      let r;
      assume
A10:  r in A;
      then ZA.r = Z0.r by FUNCT_1:49;
      then A11:ZA.r = r #Z 0 by TAYLOR_1:def 1
      .= 1 by PREPOWER:34;
      cos r <= 1 by SIN_COS6:6;
      hence thesis by A11,A10,FUNCT_1:49;
    end;
    hence sin.r <= r by A2,A3,A5,A6,INTEGRA2:34;
  end;
