# Proofs

proof_type: f_proof
decl_type: formula
library: trig
theory: sincos_def
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp)
   (typepred "asin(x!1)")
   (expand "abs")
   (lemma "sin_phase_asin" ("xa" "x!1"))
   (case-replace "x!1<0")
   (("1"
     (lemma "asin_strict_increasing")
     (expand "strict_increasing?")
     (inst - "x!1" "0")
     (("1"
       (rewrite "asin_0")
       (assert)
       (expand "sin")
       (lemma "floor_div" ("x" "asin(x!1)" "py" "2*pi" "i" "-1"))
       (assert))
      ("2" (expand "abs") (assert))))
    ("2"
     (assert)
     (expand "sin")
     (typepred "asin(x!1)")
     (expand "abs")
     (lemma "asin_strict_increasing")
     (expand "strict_increasing?")
     (case-replace "x!1=0")
     (("1" (rewrite "asin_0") (assert))
      ("2"
       (inst - "0" "x!1")
       (("1"
         (rewrite "asin_0")
         (assert)
         (lemma "floor_0" ("x" "asin(x!1) / (2 * pi)"))
         (rewrite "div_mult_pos_lt1" -1)
         (rewrite "div_mult_pos_le2" -1)
         (flatten)
         (replace -1)
         (assert))
        ("2" (expand "abs") (assert))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos_def
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp)
   (typepred "x!1")
   (typepred "acos(x!1)")
   (("1"
     (expand "cos")
     (lemma "floor_0" ("x" "acos(x!1) / (2 * pi)"))
     (rewrite "div_mult_pos_lt1" -1)
     (rewrite "div_mult_pos_le2" -1)
     (assert)
     (replace -1)
     (assert)
     (rewrite "cos_phase_acos"))
    ("2"
     (expand "abs")
     (case-replace "x!1<0")
     (("1" (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos_def
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp)
   (typepred "atan(a!1)")
   (case-replace "2 * atan_value(1)=pi/2")
   (("1"
     (lemma "tan_tan_value" ("a" "atan(a!1)"))
     (split -1)
     (("1"
       (expand "tan_value")
       (lemma "atan_bij")
       (replace -2 1)
       (hide -2 -3)
       (lemma "comp_inverse_left[real, real_abs_lt_pi2]"
        ("f" "atan" "x" "a!1"))
       (("1" (propax)) ("2" (propax))))
      ("2" (propax)) ("3" (propax))))
    ("2" (expand "pi") (expand "atan") (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos_def
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp)
   (typepred "x!1")
   (lemma "asin_bij")
   (lemma "bijective_inverse[real_abs_le1, real_abs_le_pi2]"
    ("f" "asin" "y" "x!1" "x" "sin(x!1)"))
   (("1"
     (assert)
     (hide 2)
     (rewrite "sin_sin_value" 1)
     (("1" (expand "sin_value") (propax)) ("2" (expand "abs") (assert))))
    ("2" (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos_def
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp)
   (lemma "acos_bij")
   (typepred "x!1")
   (typepred "cos(x!1)")
   (lemma "bijective_inverse[real_abs_le1, nnreal_le_pi]"
    ("f" "acos" "x" "cos(x!1)" "y" "x!1"))
   (("1"
     (assert)
     (hide 2)
     (rewrite "cos_cos_value" 1)
     (expand "cos_value")
     (propax))
    ("2" (propax))
    ("3"
     (expand "abs")
     (case-replace "cos(x!1) < 0")
     (("1" (assert)) ("2" (assert))))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: sincos_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (typepred "x!1")
   (lemma "tan_value_TCC" ("a" "x!1"))
   (expand "abs")
   (case-replace "x!1<0")
   (("1" (assert)) ("2" (assert) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skolem 1 ("x"))
   (lemma "sin_convergence" ("x" "x"))
   (lemma "derivative_equivalence1[real]"
    ("f" "sin" "x" "x" "D" "cos(x)"))
   (("1" (assert)) ("2" (skosimp*) (inst + "x!1+1") (assert))
    ("3" (lemma deriv_domain_real) (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (expand "deriv")
   (lemma "extensionality"
    ("f" "(LAMBDA (x: real): deriv(sin, x))" "g" "cos"))
   (("1"
     (split -1)
     (("1" (propax))
      ("2"
       (hide 2)
       (skosimp*)
       (lemma "derivative_equivalence1[real]"
        ("f" "sin" "x" "x!1" "D" "cos(x!1)"))
       (("1" (lemma "sin_convergence" ("x" "x!1")) (assert))
        ("2"
         (lemma "sin_derivable")
         (skosimp*)
         (inst + "x!2+1")
         (assert))
        ("3" (lemma deriv_domain_real) (propax))))))
    ("2" (lemma "sin_derivable") (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp*)
   (lemma "cos_convergence" ("x" "x!1"))
   (lemma "derivative_equivalence1[real]"
    ("f" "cos" "x" "x!1" "D" "-sin(x!1)"))
   (("1" (assert)) ("2" (skosimp*) (inst + "x!2+1") (assert))
    ("3" (lemma deriv_domain_real) (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (expand "deriv")
   (lemma "cos_convergence")
   (lemma "derivative_equivalence1[real]" ("f" "cos"))
   (("1"
     (lemma "extensionality"
      ("f" "(LAMBDA (x: real): deriv(cos, x))" "g" "-sin"))
     (("1"
       (split -1)
       (("1" (propax))
        ("2"
         (hide 2)
         (skosimp*)
         (expand "-")
         (inst - "x!1")
         (inst - "-sin(x!1)" "x!1")
         (assert))))
      ("2"
       (hide 2)
       (skosimp*)
       (inst - "x!1")
       (inst - "-sin(x!1)" "x!1")
       (assert))))
    ("2" (skosimp*) (inst + "x!1+1") (assert))
    ("3" (lemma deriv_domain_real) (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp*)
   (lemma "sin_derivable" ("x" "x0!1"))
   (lemma "derivable_continuous[real]" ("f" "sin" "x" "x0!1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp*)
   (lemma "cos_derivable" ("x" "x0!1"))
   (lemma "derivable_continuous[real]" ("f" "cos" "x" "x0!1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skolem 1 ("n"))
   (case "FORALL (n:nat): derivable_n_times?(sin, n) AND derivable_n_times?(cos,n)")
   (("1"
     (case "FORALL (n:nat): nderiv(n, sin) = (LAMBDA (x: real): sin((n * pi / 2) + x)) AND nderiv(n,cos) = LAMBDA (x:real): cos((n*pi/2)+x)")
     (("1" (inst - "n") (inst - "n") (flatten) (assert))
      ("2"
       (hide 2)
       (copy -1)
       (induct "n" 1)
       (("1"
         (expand "nderiv")
         (lemma "extensionality"
          ("f" "sin" "g" "(LAMBDA (x: real): sin(x + (0 * pi / 2)))"))
         (split -1)
         (("1" (propax)) ("2" (skosimp*) (assert))))
        ("2"
         (expand "nderiv")
         (lemma "extensionality"
          ("f" "cos" "g" "(LAMBDA (x: real): cos(x + (0 * pi / 2)))"))
         (split -1)
         (("1" (propax)) ("2" (skosimp*) (assert))))
        ("3"
         (skosimp*)
         (expand "nderiv" 1)
         (lemma "deriv_sin_fun")
         (replace -1)
         (replace -3)
         (lemma "deriv_cos_fun")
         (replace -1)
         (lemma "extensionality"
          ("f"
           "(LAMBDA (x: real): cos((j!1 * pi / 2) + x))"
           "g"
           "(LAMBDA (x: real): sin(x + ((j!1 * pi + pi) / 2)))"))
         (split -1)
         (("1"
           (replace -1)
           (case "FORALL (n:nat,f:nderiv_fun(n)): nderiv(n,-f) = -nderiv(n,f)")
           (("1"
             (inst - "j!1" "sin")
             (replace -1)
             (replace -5)
             (hide-all-but 1)
             (expand "-")
             (lemma "extensionality"
              ("f"
               "(LAMBDA (x_1: real): -sin(x_1 + (j!1 * pi / 2)))"
               "g"
               "(LAMBDA (x: real): cos(x + ((j!1 * pi + pi) / 2)))"))
             (split)
             (("1" (propax))
              ("2"
               (hide 2)
               (skosimp*)
               (rewrite "cos_sin")
               (rewrite "neg_sin")
               (expand "pi")
               (assert))))
            ("2"
             (inst - "j!1")
             (flatten)
             (hide-all-but 1)
             (induct "n")
             (("1" (expand "nderiv") (propax))
              ("2"
               (skosimp*)
               (expand "nderiv" 1)
               (lemma "deriv_neg_fun[real]" ("ff" "f!1"))
               (replace -1)
               (inst - "deriv(f!1)"))
              ("3"
               (hide 2)
               (induct "n")
               (("1" (expand "derivable_n_times?") (propax))
                ("2"
                 (skosimp*)
                 (expand "derivable_n_times?" 1)
                 (typepred "f!1")
                 (expand "derivable_n_times?" -1)
                 (flatten -1)
                 (lemma "neg_derivable_fun[real]" ("f" "f!1"))
                 (assert)
                 (lemma "deriv_neg_fun[real]" ("ff" "f!1"))
                 (replace -1 1)
                 (inst - "deriv(f!1)"))))))
            ("3"
             (hide-all-but 1)
             (induct "n")
             (("1" (skosimp*) (expand "derivable_n_times?") (propax))
              ("2"
               (skosimp*)
               (expand "derivable_n_times?" 1)
               (lemma "neg_derivable_fun[real]" ("f" "f!1"))
               (assert)
               (typepred "f!1")
               (expand "derivable_n_times?" -1)
               (flatten)
               (assert)
               (lemma "deriv_neg_fun[real]" ("ff" "f!1"))
               (replace -1)
               (inst - "deriv(f!1)"))))))
          ("2"
           (skosimp*)
           (hide-all-but 1)
           (lemma "cos_sin" ("a" "(j!1 * pi / 2) + x!1"))
           (expand "pi")
           (assert))))
        ("4" (skosimp*) (inst - "n!2") (flatten))
        ("5" (skosimp*) (inst - "n!2") (flatten))
        ("6" (skosimp*) (inst - "n!2") (flatten))
        ("7" (skosimp*) (inst - "n!2") (flatten))))
      ("3" (skosimp*) (inst - "n!1") (flatten -2))
      ("4" (skosimp*) (inst - "n!1") (flatten))))
    ("2"
     (hide 2)
     (induct "n")
     (("1" (expand "derivable_n_times?") (propax))
      ("2" (expand "derivable_n_times?") (propax))
      ("3"
       (skosimp*)
       (expand "derivable_n_times?" 1)
       (lemma "sin_derivable_fun")
       (lemma "cos_derivable_fun")
       (lemma "deriv_sin_fun")
       (lemma "deriv_cos_fun")
       (replace -1)
       (replace -2)
       (assert)
       (case "FORALL (n:nat,f:[real->real]): derivable_n_times?(f,n) => derivable_n_times?(-f,n)")
       (("1" (inst - "j!1" "sin") (assert))
        ("2"
         (hide-all-but 1)
         (induct "n")
         (("1" (expand "derivable_n_times?") (propax))
          ("2"
           (skosimp*)
           (expand "derivable_n_times?" (-2 1))
           (flatten -2)
           (lemma "neg_derivable_fun[real]" ("f" "f!1"))
           (assert)
           (inst -2 "deriv(f!1)")
           (assert)
           (lemma "deriv_neg_fun[real]" ("ff" "f!1"))
           (replace -1 1)
           (propax))))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (induct "n")
   (("1" (expand "derivable_n_times?") (propax))
    ("2"
     (expand "nderiv")
     (lemma "extensionality"
      ("f" "cos" "g" "(LAMBDA (x: real): cos(x + (0 * pi / 2)))"))
     (split -1)
     (("1" (propax)) ("2" (skosimp*) (assert))))
    ("3"
     (skosimp*)
     (expand "derivable_n_times?" 1)
     (lemma "cos_derivable_fun")
     (replace -1)
     (lemma "deriv_cos_fun")
     (replace -1)
     (expand "nderiv" 1)
     (replace -1)
     (case "FORALL (n:nat,f:[real->real]): derivable_n_times?(f,n) => derivable_n_times?(-f,n)")
     (("1"
       (case "FORALL (n: nat, f: nderiv_fun(n)): nderiv(n, -f) = -nderiv(n, f)")
       (("1"
         (inst -2 "j!1" "sin")
         (lemma "nderiv_sin_fun" ("n" "j!1"))
         (flatten -1)
         (assert)
         (inst - "j!1" "sin")
         (replace -3)
         (replace -2)
         (hide-all-but 1)
         (expand "-")
         (lemma "extensionality"
          ("f"
           "(LAMBDA (x_1: real): -sin(x_1 + (j!1 * pi / 2)))"
           "g"
           "(LAMBDA (x: real): cos(x + ((j!1 * pi + pi) / 2)))"))
         (split -1)
         (("1" (propax))
          ("2"
           (hide 2)
           (skosimp*)
           (rewrite "sin_cos")
           (expand "pi")
           (assert))))
        ("2"
         (hide-all-but (-1 1))
         (induct "n")
         (("1" (expand "nderiv") (propax))
          ("2"
           (skosimp*)
           (expand "nderiv" 1)
           (typepred "f!1")
           (expand "derivable_n_times?" -1)
           (flatten)
           (lemma "neg_derivable_fun[real]" ("f" "f!1"))
           (assert)
           (lemma "deriv_neg_fun[real]" ("ff" "f!1"))
           (replace -1)
           (inst -5 "deriv(f!1)"))
          ("3"
           (hide 2)
           (skosimp*)
           (typepred "f!1")
           (inst - "n!2" "f!1")
           (assert))))
        ("3"
         (hide-all-but (-1 1))
         (skosimp*)
         (typepred "f!1")
         (inst - "n!1" "f!1")
         (assert))))
      ("2"
       (hide-all-but 1)
       (induct "n")
       (("1" (expand "derivable_n_times?") (propax))
        ("2"
         (skosimp*)
         (expand "derivable_n_times?" (1 -2))
         (flatten)
         (lemma "neg_derivable_fun[real]" ("f" "f!1"))
         (assert)
         (lemma "deriv_neg_fun[real]" ("ff" "f!1"))
         (replace -1)
         (inst - "deriv(f!1)")
         (assert))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "Taylors" ("f" "sin" "n" "2*n!1+2" "aa" "0" "bb" "x!1"))
   (("1"
     (lemma "nderiv_sin_fun" ("n" "2*n!1+3"))
     (flatten)
     (replace -1)
     (case "FORALL (n:nat): sigma(0, 2 * n + 2,
                                        LAMBDA (nn:nat):
                                          IF nn > 2 * n + 2 THEN 0
                                          ELSIF nn = 0 THEN sin(0)
                                          ELSE nderiv(nn, sin)(0) * (x!1 - 0) ^ nn / factorial(nn)
                                          ENDIF) = sin_series_n(x!1, n)")
     (("1" (inst - "n!1") (assert))
      ("2"
       (hide-all-but 1)
       (expand "sin_series_n")
       (induct "n")
       (("1"
         (expand "sin_series_term")
         (expand "sigma")
         (expand "sigma")
         (expand "sigma")
         (expand "factorial")
         (expand "factorial")
         (expand "factorial")
         (lemma "nderiv_sin_fun")
         (inst-cp - "1")
         (inst - "2")
         (flatten)
         (replace -2)
         (replace -4)
         (rewrite "sin_0")
         (simplify 1)
         (lemma "sin_pi2")
         (lemma "sin_pi")
         (replace -1)
         (replace -2)
         (assert)
         (rewrite "expt_x0" 1)
         (assert))
        ("2"
         (skosimp*)
         (expand "sigma" 1)
         (expand "sigma" 1 1)
         (lemma "sigma_eq[nat]"
          ("low"
           "0"
           "high"
           "j!1"
           "F"
           "LAMBDA (i: nat):
                                         IF i > 1 + j!1 THEN 0 ELSE sin_series_term(x!1)(i) ENDIF"
           "G"
           "LAMBDA (i: nat):
                                        IF i > j!1 THEN 0 ELSE sin_series_term(x!1)(i) ENDIF"))
         (split -1)
         (("1"
           (replace -1)
           (hide -1)
           (lemma "sigma_eq[nat]"
            ("low"
             "0"
             "high"
             "2+2*j!1"
             "G"
             "LAMBDA (nn: nat):
                                             IF nn > 2 + 2 * j!1 THEN 0
                                             ELSIF nn = 0 THEN sin(0)
                                             ELSE nderiv(nn, sin)(0) * x!1 ^ nn / factorial(nn)
                                             ENDIF"
             "F"
             "LAMBDA (nn: nat):
                                             IF nn > 4 + 2 * j!1 THEN 0
                                             ELSIF nn = 0 THEN sin(0)
                                             ELSE nderiv(nn, sin)(0) * x!1 ^ nn / factorial(nn)
                                             ENDIF"))
           (("1"
             (split -1)
             (("1"
               (replace -1)
               (replace -2)
               (hide-all-but 1)
               (lemma "nderiv_sin_fun" ("n" "3+2*j!1"))
               (lemma "nderiv_sin_fun" ("n" "4+2*j!1"))
               (flatten)
               (replace -2)
               (replace -4)
               (simplify 1)
               (expand "sin_series_term")
               (hide-all-but 1)
               (lemma "sin_k_pi" ("k" "2+j!1"))
               (lemma "sin_k_pi2" ("k" "j!1+1"))
               (replace -1)
               (replace -2)
               (assert))
              ("2"
               (hide-all-but 1)
               (skosimp*)
               (typepred "n!2")
               (assert))))
            ("2"
             (hide-all-but 1)
             (skosimp*)
             (lemma "nderiv_sin_fun" ("n" "nn!1"))
             (flatten))
            ("3"
             (hide-all-but 1)
             (skosimp*)
             (lemma "nderiv_sin_fun" ("n" "nn!1"))
             (flatten))))
          ("2" (hide-all-but 1) (skosimp*) (assert))))
        ("3"
         (hide 2)
         (skosimp*)
         (lemma "nderiv_sin_fun" ("n" "nn!1"))
         (flatten))))
      ("3"
       (hide-all-but 1)
       (skosimp*)
       (lemma "nderiv_sin_fun" ("n" "nn!1"))
       (flatten))))
    ("2" (hide 2) (assert) (expand "connected?") (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "Taylors" ("f" "cos" "n" "2*n!1+1" "aa" "0" "bb" "x!1"))
   (("1"
     (lemma "nderiv_cos_fun" ("n" "2*n!1+2"))
     (flatten)
     (replace -1)
     (case "FORALL (n:nat): sigma(0, 2 * n + 1,
                                        LAMBDA (nn:nat):
                                          IF nn > 2 * n + 1 THEN 0
                                          ELSIF nn = 0 THEN cos(0)
                                          ELSE nderiv(nn, cos)(0) * (x!1 - 0) ^ nn / factorial(nn)
                                          ENDIF) = cos_series_n(x!1, n)")
     (("1" (inst - "n!1") (assert))
      ("2"
       (hide-all-but 1)
       (expand "cos_series_n")
       (induct "n")
       (("1"
         (expand "sigma")
         (expand "sigma")
         (expand "cos_series_term")
         (rewrite "cos_0")
         (lemma "nderiv_cos_fun" ("n" "1"))
         (flatten)
         (replace -2)
         (simplify)
         (lemma "cos_pi2")
         (replace -1)
         (assert))
        ("2"
         (skosimp*)
         (expand "sigma" 1)
         (expand "sigma" 1 1)
         (lemma "sigma_eq[nat]"
          ("low"
           "0"
           "high"
           "1+2*j!1"
           "G"
           "LAMBDA (nn: nat):
                                       IF nn > 1 + 2 * j!1 THEN 0
                                       ELSIF nn = 0 THEN cos(0)
                                       ELSE nderiv(nn, cos)(0) * x!1 ^ nn / factorial(nn)
                                       ENDIF"
           "F"
           "LAMBDA (nn: nat):
                                       IF nn > 3 + 2 * j!1 THEN 0
                                       ELSIF nn = 0 THEN cos(0)
                                       ELSE nderiv(nn, cos)(0) * x!1 ^ nn / factorial(nn)
                                       ENDIF"))
         (("1"
           (split -1)
           (("1"
             (replace -1)
             (replace -2)
             (hide -1 -2)
             (lemma "sigma_eq[nat]"
              ("low"
               "0"
               "high"
               "j!1"
               "F"
               "LAMBDA (i: nat):
                                                   IF i > j!1 THEN 0 ELSE cos_series_term(x!1)(i) ENDIF"
               "G"
               "LAMBDA (i: nat):
                                                     IF i > 1 + j!1 THEN 0 ELSE cos_series_term(x!1)(i) ENDIF"))
             (split -1)
             (("1"
               (replace -1)
               (simplify 1)
               (hide -1)
               (lemma "nderiv_cos_fun" ("n" "3+2*j!1"))
               (lemma "nderiv_cos_fun" ("n" "2+2*j!1"))
               (flatten)
               (replace -2)
               (replace -4)
               (simplify 1)
               (hide-all-but 1)
               (lemma "cos_k_pi" ("k" "j!1+1"))
               (lemma "cos_eq_0" ("a" "((2 * (j!1 * pi) + 3 * pi) / 2)"))
               (flatten -1)
               (hide -1)
               (split -1)
               (("1"
                 (replace -1)
                 (replace -2)
                 (expand "cos_series_term")
                 (assert))
                ("2" (hide-all-but 1) (inst + "j!1+1") (assert))))
              ("2" (hide 2) (skosimp*) (assert))))
            ("2" (hide-all-but 1) (skosimp*) (assert))))
          ("2"
           (hide-all-but 1)
           (skosimp*)
           (lemma "nderiv_cos_fun" ("n" "nn!1"))
           (flatten))
          ("3"
           (hide-all-but 1)
           (skosimp*)
           (lemma "nderiv_cos_fun" ("n" "nn!1"))
           (flatten))))
        ("3"
         (hide 2)
         (skosimp*)
         (lemma "nderiv_cos_fun" ("n" "nn!1"))
         (flatten))))
      ("3"
       (hide-all-but 1)
       (skosimp*)
       (lemma "nderiv_cos_fun" ("n" "nn!1"))
       (flatten))))
    ("2" (hide 2) (assert) (expand "connected?") (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: deriv_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "connected_deriv_domain[T]")
   (lemma "connected_domain")
   (lemma "not_one_element")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: deriv_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "scal_cont_fun[T]")
   (inst - "(LAMBDA (x: T): sin(alpha!1 * x))" "k!1")
   (assert)
   (expand "*" -1)
   (hide 2)
   (lemma "composition_cont_fun[T,real]")
   (inst - "(LAMBDA (x:T): alpha!1*x)" "(LAMBDA (x:real): sin(x))")
   (expand "o ")
   (assert)
   (hide 2)
   (split +)
   (("1"
     (lemma "scal_cont_fun[T]")
     (inst - "id[T]" "alpha!1")
     (expand "id")
     (expand "*")
     (assert)
     (hide 2)
     (lemma "identity_cont_fun[T]")
     (expand "I")
     (propax))
    ("2"
     (lemma "sin_continuous")
     (expand "continuous?" 1)
     (skosimp*)
     (inst?)
     (assert)
     (expand "continuous?")
     (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: deriv_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "scal_cont_fun[T]")
   (inst - "(LAMBDA (x: T): cos(alpha!1 * x))" "k!1")
   (assert)
   (expand "*" -1)
   (hide 2)
   (lemma "composition_cont_fun[T,real]")
   (inst - "(LAMBDA (x:T): alpha!1*x)" "(LAMBDA (x:real): cos(x))")
   (expand "o ")
   (assert)
   (hide 2)
   (split +)
   (("1"
     (lemma "scal_cont_fun[T]")
     (inst - "id[T]" "alpha!1")
     (expand "id")
     (expand "*")
     (assert)
     (hide 2)
     (lemma "identity_cont_fun[T]")
     (expand "I")
     (propax))
    ("2"
     (lemma "cos_continuous")
     (expand "continuous?" 1)
     (skosimp*)
     (inst?)
     (assert)
     (expand "continuous?")
     (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: deriv_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "scal_derivable_fun[T]")
   (inst - "k!1" "(LAMBDA (x: T): sin(alpha!1 * x))")
   (assert)
   (expand "*")
   (hide 2)
   (lemma "comp_derivable_fun[T,real]")
   (("1"
     (inst - "(LAMBDA (x:T): alpha!1*x)" "(LAMBDA (x:real): sin(x))")
     (assert)
     (hide 2)
     (split +)
     (("1"
       (lemma "scal_derivable_fun[T]")
       (inst - "alpha!1" "id[T]")
       (assert)
       (expand "id")
       (expand "*")
       (hide 2)
       (lemma "id_derivable_fun[T]")
       (propax))
      ("2"
       (expand "derivable?")
       (lemma "sin_derivable")
       (skosimp*)
       (inst?)
       (case-replace "(LAMBDA (x: real): sin(x)) =  sin")
       (apply-extensionality 1 :hide? t))))
    ("2" (lemma "not_one_element") (propax))
    ("3" (lemma "deriv_domain") (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: deriv_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "scal_derivable_fun[T]")
   (inst - "k!1" "(LAMBDA (x: T): cos(alpha!1 * x))")
   (assert)
   (expand "*")
   (hide 2)
   (lemma "comp_derivable_fun[T,real]")
   (("1"
     (inst - "(LAMBDA (x:T): alpha!1*x)" "(LAMBDA (x:real): cos(x))")
     (assert)
     (hide 2)
     (split +)
     (("1"
       (lemma "scal_derivable_fun[T]")
       (inst - "alpha!1" "id[T]")
       (assert)
       (expand "id")
       (expand "*")
       (hide 2)
       (lemma "id_derivable_fun[T]")
       (propax))
      ("2"
       (expand "derivable?")
       (skosimp*)
       (lemma "cos_derivable")
       (inst?)
       (assert)
       (case-replace "(LAMBDA (x: real): cos(x)) =  cos")
       (apply-extensionality 1 :hide? t))))
    ("2" (lemma "not_one_element") (propax))
    ("3" (lemma "deriv_domain") (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: deriv_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (auto-rewrite-theory "analysis_ax@derivatives_lam[T]")
   (case "derivable?[T](LAMBDA (x: T): sin(alpha!1 * x))")
   (("1"
     (lemma "deriv_scal_fun[T]")
     (inst - "k!1" "(LAMBDA (x: T): sin(alpha!1 * x))")
     (assert)
     (expand "*")
     (assert)
     (apply-extensionality 2 :hide? t)
     (hide -1)
     (lemma "deriv_comp_fun[T,real]")
     (inst - "(LAMBDA (x:T): alpha!1*x)" "(LAMBDA (x:real): sin(x))")
     (("1"
       (expand "o ")
       (replace -1)
       (hide -1)
       (assert)
       (expand "*")
       (lemma deriv_scal_fun[T])
       (inst - "alpha!1" "id[T]")
       (("1"
         (assert)
         (expand "id")
         (expand "*")
         (assert)
         (lemma "deriv_id_fun[T]")
         (replace -1)
         (assert)
         (lemma "deriv_sin_fun")
         (case-replace "(LAMBDA (x: real): sin(x)) = sin")
         (("1" (replace -2) (assert))
          ("2" (apply-extensionality 1 :hide? t))))
        ("2" (lemma "id_derivable_fun[T]") (expand "id") (propax))))
      ("2"
       (lemma sin_derivable_fun)
       (case-replace "(LAMBDA (x: real): sin(x)) = sin")
       (apply-extensionality 1 :hide? t))))
    ("2"
     (assert)
     (hide 3)
     (lemma "sin_derivable")
     (inst?)
     (inst - "1")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: deriv_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (auto-rewrite-theory "analysis_ax@derivatives_lam[T]")
   (case "derivable?[T](LAMBDA (x: T): cos(alpha!1 * x))")
   (("1"
     (lemma "deriv_scal_fun[T]")
     (inst - "k!1" "(LAMBDA (x: T): cos(alpha!1 * x))")
     (assert)
     (expand "*")
     (assert)
     (apply-extensionality 2 :hide? t)
     (hide -1)
     (lemma "deriv_comp_fun[T,real]")
     (inst - "(LAMBDA (x:T): alpha!1*x)" "(LAMBDA (x:real): cos(x))")
     (("1"
       (expand "o ")
       (replace -1)
       (hide -1)
       (assert)
       (expand "*")
       (lemma deriv_scal_fun[T])
       (inst - "alpha!1" "id[T]")
       (("1"
         (assert)
         (expand "id")
         (expand "*")
         (assert)
         (lemma "deriv_id_fun[T]")
         (replace -1)
         (assert)
         (lemma "deriv_cos_fun")
         (case-replace "(LAMBDA (x: real): cos(x)) = cos")
         (("1" (replace -2) (assert) (hide -) (expand "-") (assert))
          ("2" (apply-extensionality 1 :hide? t))))
        ("2" (lemma "id_derivable_fun[T]") (expand "id") (propax))))
      ("2"
       (lemma cos_derivable_fun)
       (case-replace "(LAMBDA (x: real): cos(x)) = cos")
       (apply-extensionality 1 :hide? t))))
    ("2"
     (assert)
     (hide 3)
     (lemma "cos_derivable")
     (inst?)
     (inst - "1")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (auto-rewrite-theory "derivatives_lam[T]")
   (("1"
     (lemma "derivable_scal1_lam[T]")
     (inst -1 "(k!1/a!1)" "LAMBDA(x:T):sin(a!1 * x + b!1)")
     (("1"
       (lemma "composition_derivable_fun[T,real]")
       (inst -1 "(LAMBDA(x:T): a!1*x + b!1)" "(LAMBDA(x:real): sin(x))")
       (assert)
       (expand "o")
       (lemma "sin_derivable_fun")
       (case-replace "(LAMBDA (x: real): sin(x))=sin")
       (apply-extensionality 1))
      ("2" (assert))))
    ("2" (lemma "not_one_element") (propax))
    ("3"
     (lemma "deriv_domain[T]")
     (("1" (propax)) ("2" (lemma "not_one_element") (propax))
      ("3" (lemma "connected_domain") (propax))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (auto-rewrite-theory "derivatives_lam[T]")
   (("1"
     (lemma "derivable_scal1_lam[T]")
     (inst -1 "(k!1/a!1)" "LAMBDA(x:T):cos(a!1 * x + b!1)")
     (("1"
       (lemma "composition_derivable_fun[T,real]")
       (assert)
       (expand "o")
       (inst -1 "(LAMBDA(x:T): a!1*x + b!1)" "(LAMBDA(x:real): cos(x))")
       (assert)
       (lemma "cos_derivable_fun")
       (case-replace "(LAMBDA (x: real): cos(x))=cos")
       (apply-extensionality 1))
      ("2" (assert))))
    ("2" (lemma "not_one_element") (propax))
    ("3"
     (lemma "deriv_domain[T]")
     (("1" (propax)) ("2" (lemma "not_one_element") (propax))
      ("3" (lemma "connected_domain") (propax))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (auto-rewrite-theory "derivatives_lam[T]")
   (("1"
     (case "derivable?[T](LAMBDA(x:T):sin(b!1 + a!1*x))")
     (("1"
       (lemma "deriv_scal_fun[T]")
       (inst - "k!1" "(LAMBDA(x:T):sin(b!1 + a!1 * x))")
       (("1"
         (assert)
         (expand "*")
         (assert)
         (apply-extensionality 2 :hide? t)
         (hide -1)
         (lemma "deriv_comp_fun[T,real]")
         (inst - "(LAMBDA(x:T):a!1*x + b!1)" "(LAMBDA(x:real): sin(x))")
         (("1"
           (expand "o")
           (replace -1)
           (hide -1)
           (assert)
           (expand "*")
           (ground)
           (lemma "deriv_sin_fun")
           (case-replace "(LAMBDA(x:real): sin(x)) = sin")
           (("1" (replace -2) (assert))
            ("2" (apply-extensionality 1 :hide? t))))
          ("2"
           (lemma "sincos.sin_derivable_fun")
           (case-replace "(LAMBDA(x:real):sin(x))=sin")
           (apply-extensionality 1 :hide? t))))
        ("2" (assert))))
      ("2"
       (hide 3)
       (lemma "comp_derivable_fun[T,real]")
       (inst - "(LAMBDA (x:T): b!1 + a!1 * x)"
        "(LAMBDA(x:real): sin(x))")
       (assert)
       (hide 2)
       (lemma "sin_derivable_fun")
       (case-replace "(LAMBDA (x: real): sin(x))=sin")
       (apply-extensionality 1 :hide? t))))
    ("2" (hide 3) (lemma "not_one_element") (propax))
    ("3"
     (hide (2 3))
     (assert)
     (lemma "deriv_domain[T]")
     (("1" (propax)) ("2" (hide 2) (lemma "not_one_element") (propax))
      ("3" (lemma "connected_domain") (propax))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (auto-rewrite-theory "derivatives_lam[T]")
   (("1"
     (case "derivable?[T](LAMBDA(x:T):cos(b!1 + a!1*x))")
     (("1"
       (lemma "deriv_scal_fun[T]")
       (inst - "k!1" "(LAMBDA(x:T):cos(b!1 + a!1 * x))")
       (("1"
         (assert)
         (expand "*")
         (assert)
         (apply-extensionality 2 :hide? t)
         (hide -1)
         (lemma "deriv_comp_fun[T,real]")
         (inst - "(LAMBDA(x:T):a!1*x + b!1)" "(LAMBDA(x:real): cos(x))")
         (("1"
           (expand "o")
           (replace -1)
           (hide -1)
           (assert)
           (expand "*")
           (lemma "deriv_cos_fun")
           (case-replace "(LAMBDA (x: real): cos(x))=cos")
           (("1"
             (hide -1)
             (replace -1)
             (hide -1)
             (hide -1)
             (assert)
             (hide 2)
             (grind))
            ("2" (apply-extensionality 1 :hide? t))))
          ("2"
           (lemma "sincos.cos_derivable_fun")
           (case-replace "(LAMBDA (x: real): cos(x))=cos")
           (apply-extensionality 1 :hide? t))))
        ("2" (hide 2) (hide 2) (assert))))
      ("2"
       (hide 2)
       (hide 2)
       (lemma "comp_derivable_fun[T,real]")
       (inst - "(LAMBDA (x:T): b!1 + a!1 * x)"
        "(LAMBDA(x:real): cos(x))")
       (assert)
       (hide 2)
       (lemma "cos_derivable_fun")
       (case-replace "(LAMBDA (x: real): cos(x))=cos")
       (apply-extensionality 1 :hide? t))))
    ("2" (hide 3) (hide 2) (lemma "not_one_element") (propax))
    ("3"
     (hide 2 3)
     (lemma "deriv_domain[T]")
     (("1" (propax)) ("2" (hide 2) (lemma "not_one_element") (propax))
      ("3" (hide 2) (lemma "connected_domain") (propax))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "integrable?")
   (expand "antiderivative?")
   (lemma "derivable_sin_lin")
   (inst -1 "alpha!1" "theta!1" "k!1")
   (assert)
   (inst 2
    "(LAMBDA (x: T): (k!1 / alpha!1) * sin(alpha!1 * x + theta!1))")
   (split)
   (("1" (propax))
    ("2"
     (lemma "deriv_sin_lin")
     (assert)
     (inst -1 "alpha!1" "theta!1" "k!1/alpha!1")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "integrable?")
   (expand "antiderivative?")
   (lemma "derivable_cos_lin")
   (inst -1 "alpha!1" "theta!1" "-k!1")
   (assert)
   (inst 2
    "(LAMBDA (x: T): -k!1 / alpha!1 * cos(alpha!1 * x + theta!1))")
   (split)
   (("1" (propax))
    ("2"
     (lemma "deriv_cos_lin")
     (assert)
     (inst -1 "alpha!1" "theta!1" "k!1/alpha!1")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
script:
  (""
   (skeep)
   (lemma "indef_integral_thm[T]")
   (inst -1 "(LAMBDA (t: T): -(v / w) * cos(theta + w * t))")
   (case "derivable?((LAMBDA (t: T): -(v / w) * cos(theta + w * t)))")
   (("1"
     (assert)
     (hide -1)
     (skosimp*)
     (inst + "c!1")
     (lemma "deriv_cos_lin")
     (inst -1 "w" "theta" "v/w")
     (assert))
    ("2"
     (hide 2)
     (lemma "derivable_cos_lin")
     (inst -1 "w" "theta" "v")
     (hide -2)
     (typepred "w")
     (assert)
     (hide -1)
     (lemma "derivable_neg_lam[T]")
     (inst -1 "(LAMBDA (t: T): v / w * cos(w * t + theta))")
     (hide -2)
     (assert))
    ("3" (lemma "not_one_element") (propax))
    ("4"
     (lemma "deriv_domain[T]")
     (("1" (propax)) ("2" (lemma "not_one_element") (propax))
      ("3" (lemma "connected_domain") (propax))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (lemma "indef_integral_thm[T]")
   (inst -1 "(LAMBDA (t: T): (v / w) * sin(theta + w * t))")
   (case "derivable?((LAMBDA (t: T): (v / w) * sin(theta + w * t)))")
   (("1"
     (assert)
     (skosimp*)
     (inst + "c!1")
     (lemma "deriv_sin_lin")
     (inst -1 "w" "theta" "v/w")
     (typepred "w")
     (assert))
    ("2"
     (lemma "derivable_sin_lin")
     (inst -1 "w" "theta" "v")
     (typepred "w")
     (assert))
    ("3" (lemma "not_one_element") (propax))
    ("4"
     (lemma "deriv_domain[T]")
     (("1" (propax)) ("2" (lemma "not_one_element") (propax))
      ("3" (lemma "connected_domain") (propax))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "fundamental_indef[T]")
   (inst - "t1!1" "t2!1" "LAMBDA (t: T): v!1 * sin(theta!1 + w!1 * t)")
   (assert)
   (case-replace
    "continuous?(LAMBDA (t: T): v!1 * sin(w!1 * t + theta!1))")
   (("1"
     (flatten)
     (hide -1 -2 1)
     (lemma "integral_sin")
     (inst - "theta!1" "v!1" "w!1")
     (assert)
     (skosimp*)
     (replace -1)
     (hide -1)
     (expand "+")
     (expand "const_fun")
     (assert))
    ("2"
     (auto-rewrite-theory "continuous_lambda[T]")
     (hide -1 -2 2 3)
     (lemma "scal_mult_cont[T]")
     (inst - "(LAMBDA (t: T): sin(w!1 * t + theta!1))" "v!1")
     (hide 2)
     (lemma "composition_cont_fun[T, real]")
     (expand "o")
     (inst - "(LAMBDA(t:T):w!1 * t + theta!1)"
      "(LAMBDA(t:real): sin(t))")
     (assert)
     (hide 2)
     (case-replace "(LAMBDA(t:real):sin(t))=sin")
     (("1" (lemma "sin_continuous_fun") (propax))
      ("2" (apply-extensionality 1 :hide? t))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "fundamental_indef[T]")
   (inst - "t1!1" "t2!1" "LAMBDA (t: T): v!1 * cos(theta!1 + w!1 * t)")
   (case-replace
    "continuous?(LAMBDA (t: T): v!1 * cos(w!1 * t + theta!1))")
   (("1"
     (flatten)
     (lemma "integral_cos")
     (inst - "theta!1" "v!1" "w!1")
     (assert)
     (skosimp*)
     (replace -1)
     (hide -1 -2 -3)
     (expand "+")
     (expand "const_fun")
     (assert))
    ("2"
     (hide 2)
     (auto-rewrite-theory "continuous_lambda[T]")
     (hide -1)
     (lemma "scal_mult_cont[T]")
     (inst - "(LAMBDA (t: T): cos(w!1 * t + theta!1))" "v!1")
     (hide 2)
     (lemma "composition_cont_fun[T, real]")
     (expand "o")
     (inst - "(LAMBDA(t:T):w!1 * t + theta!1)"
      "(LAMBDA(t:real): cos(t))")
     (assert)
     (hide 2)
     (case-replace "(LAMBDA(t:real):cos(t))=cos")
     (("1" (lemma "cos_continuous_fun") (propax))
      ("2" (apply-extensionality 1 :hide? t))))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "deriv_domain[T]")
   (("1" (propax)) ("2" (lemma "not_one_element") (propax))
    ("3" (lemma "connected_domain") (propax))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (auto-rewrite-theory "derivatives_lam[T]")
   (("1"
     (hide 1)
     (lemma "derivable_scal1_lam[T]")
     (inst -1 "k!1" "(LAMBDA (x:T): sin(b!1 + a!1 * x))")
     (hide 2)
     (lemma "composition_derivable_fun[T,real]")
     (inst - "(LAMBDA(x:T): a!1*x + b!1)" "(LAMBDA(x:real): sin(x))")
     (assert)
     (expand "o")
     (hide 2)
     (lemma "sin_derivable_fun")
     (assert)
     (case-replace "(LAMBDA(x:real): sin(x))=sin")
     (apply-extensionality 1 :hide? t))
    ("2" (hide 2 3) (lemma "not_one_element") (propax))
    ("3"
     (hide 2 3)
     (lemma "deriv_domain[T]")
     (("1" (propax)) ("2" (hide 2) (lemma "not_one_element") (propax))
      ("3" (hide 2) (lemma "connected_domain") (propax))))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (auto-rewrite-theory "derivatives_lam[T]")
   (("1"
     (hide 1)
     (lemma "derivable_scal1_lam[T]")
     (inst - "-k!1" "(LAMBDA (x: T): cos(b!1 + a!1 * x))")
     (hide 2)
     (lemma "composition_derivable_fun[T,real]")
     (inst - "LAMBDA(x:T): a!1 * x + b!1" "LAMBDA(x:real):cos(x)")
     (expand "o")
     (assert)
     (hide 2)
     (lemma "cos_derivable_fun")
     (case-replace "(LAMBDA (x: real): cos(x))=cos")
     (apply-extensionality 1 :hide? t))
    ("2" (lemma "not_one_element") (propax))
    ("3"
     (lemma "deriv_domain[T]")
     (("1" (propax)) ("2" (lemma "not_one_element") (propax))
      ("3" (lemma "connected_domain") (propax))))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "derivable_Integrable?[T]")
   (("1"
     (inst - "t1!1" "t2!1"
      " LAMBDA (t: T): v!1 * sin(theta!1 + w!1 * t)")
     (assert)
     (hide 3)
     (lemma "derivable_sin_lin")
     (inst - "w!1" "theta!1" "v!1*w!1")
     (assert))
    ("2" (lemma "not_one_element") (propax))
    ("3" (lemma "connected_domain") (propax))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: integral_indef_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "derivable_Integrable?[T]")
   (("1"
     (inst - "t1!1" "t2!1"
      " LAMBDA (t: T): v!1 * cos(theta!1 + w!1 * t)")
     (assert)
     (hide 3)
     (lemma "derivable_cos_lin")
     (inst - "w!1" "theta!1" "v!1*w!1")
     (assert))
    ("2" (lemma "not_one_element") (propax))
    ("3" (lemma "connected_domain") (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "sin_derivable[T]")
   (inst?)
   (lemma "derivable_Integrable?")
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "cos_derivable[T]")
   (inst?)
   (assert)
   (lemma "derivable_Integrable?")
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "fundamental3")
   (inst?)
   (inst - "(LAMBDA (x: T): -k!1 / alpha!1* cos(alpha!1 * x))")
   (assert)
   (lemma "cos_derivable[T]")
   (inst - "alpha!1" "-k!1/alpha!1")
   (assert)
   (lemma "deriv_cos[T]")
   (inst - "alpha!1" "-k!1/alpha!1")
   (assert)
   (hide-all-but 1)
   (lemma "sin_continuous[T]")
   (inst?))


proof_type: f_proof
decl_type: formula
library: trig
theory: integral_sincos
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "fundamental3")
   (inst?)
   (inst - "(LAMBDA (x: T): k!1 / alpha!1* sin(alpha!1 * x))")
   (assert)
   (lemma "sin_derivable[T]")
   (inst - "alpha!1" "k!1/alpha!1")
   (assert)
   (lemma "deriv_sin[T]")
   (inst - "alpha!1" "k!1/alpha!1")
   (assert)
   (hide-all-but 1)
   (lemma "cos_continuous[T]")
   (inst?))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp)
   (case "forall (x:posreal): x<pi/2 => cos(x) > 0")
   (("1"
     (lemma "trichotomy" ("x" "a!1"))
     (split -1)
     (("1" (inst - "a!1") (("1" (assert)) ("2" (assert))))
      ("2" (replace -1) (rewrite "cos_0") (assert))
      ("3"
       (inst - "-a!1")
       (("1" (assert) (rewrite "cos_neg")) ("2" (assert))))))
    ("2"
     (hide-all-but 1)
     (skosimp)
     (expand "cos")
     (typepred "x!1")
     (lemma "posreal_div_posreal_is_posreal" ("px" "x!1" "py" "2*pi"))
     (lemma "both_sides_div_pos_lt1" ("pz" "2*pi" "x" "x!1" "y" "pi/2"))
     (assert)
     (rewrite "div_div2" -1)
     (lemma "div_cancel1" ("n0z" "pi" "x" "1/4"))
     (replace -1)
     (hide -1)
     (lemma "floor_def" ("x" "x!1 / (2 * pi)"))
     (flatten)
     (lemma "trichotomy" ("x" "floor(x!1 / (2 * pi))"))
     (split -1)
     (("1" (assert))
      ("2"
       (replace -1)
       (assert)
       (hide -1 -2 -3 -4 -5)
       (expand "cos_phase")
       (lemma "posreal_div_posreal_is_posreal" ("px" "x!1" "py" "pi"))
       (lemma "both_sides_div_pos_lt1" ("pz" "pi" "x" "x!1" "y" "pi/2"))
       (replace -5 -1)
       (lemma "div_cancel1" ("n0z" "pi" "x" "1/2"))
       (replace -1)
       (flatten -2)
       (hide -1)
       (lemma "floor_def" ("x" "x!1 / pi"))
       (flatten)
       (lemma "trichotomy" ("x" "floor(x!1 / pi)"))
       (split -1)
       (("1" (assert))
        ("2"
         (replace -1)
         (lemma "cos_value_strict_decreasing")
         (expand "strict_decreasing?")
         (inst - "x!1" "pi/2")
         (assert)
         (rewrite "cos_value_pi2")
         (assert))
        ("3" (assert))))
      ("3" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "cos_sin" ("a" "a!1-pi/2"))
   (lemma "cos_gt_0" ("a" "a!1-pi/2"))
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "<=")
   (split -1)
   (("1"
     (split -2)
     (("1" (lemma "sin_gt_0" ("a" "a!1")) (assert))
      ("2" (replace -1) (rewrite "sin_pi") (assert))))
    ("2" (replace -1) (replace -1 1 rl) (rewrite "sin_0") (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "<=")
   (split -1)
   (("1"
     (split -2)
     (("1" (lemma "cos_gt_0" ("a" "a!1")) (assert))
      ("2" (replace -1) (rewrite "cos_pi2") (assert))))
    ("2"
     (replace -1 * rl)
     (lemma "cos_neg" ("a" "pi/2"))
     (rewrite "cos_pi2")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "neg_cos" ("a" "a!1-pi"))
   (assert)
   (lemma "cos_gt_0" ("a" "a!1-pi"))
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "<=" (-1 -2))
   (split -1)
   (("1"
     (split -2)
     (("1" (lemma "sin_lt_0" ("a" "a!1")) (assert))
      ("2" (replace -1) (rewrite "sin_2pi") (assert))))
    ("2" (replace -1 1 rl) (rewrite "sin_pi") (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "<=" (-1 -2))
   (split -1)
   (("1"
     (split -2)
     (("1" (lemma "cos_lt_0" ("a" "a!1")) (assert))
      ("2" (replace -1) (rewrite "cos_3pi2") (assert))))
    ("2" (replace -1 * rl) (rewrite "cos_pi2") (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "tan")
   (lemma "sin_gt_0" ("a" "a!1"))
   (lemma "cos_gt_0" ("a" "a!1"))
   (assert)
   (lemma "posreal_div_posreal_is_posreal"
    ("px" "sin(a!1)" "py" "cos(a!1)"))
   (propax))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (name "BB" "a!1 - 2 * pi")
   (case-replace "a!1 = BB + 2*pi")
   (("1"
     (hide -1 -2)
     (assert)
     (case-replace "-pi/2 <= BB AND BB <= 0")
     (("1"
       (hide -2 -3)
       (rewrite "cos_plus")
       (rewrite "cos_2pi")
       (rewrite "sin_2pi")
       (flatten)
       (assert)
       (lemma "cos_gt_0")
       (inst?)
       (lemma "cos_pi2")
       (lemma "cos_neg")
       (inst -1 "pi/2")
       (ground))
      ("2" (assert))))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (case "sin(a!1) - sin(b!1) > 0")
   (("1" (assert))
    ("2"
     (hide 2)
     (assert)
     (lemma "sin_plus")
     (inst -1 "(a!1+b!1)/2" "(a!1-b!1)/2")
     (lemma "sin_minus")
     (inst -1 "(a!1+b!1)/2" "(a!1-b!1)/2")
     (replace -2 * lr)
     (replace -1 * lr)
     (hide -2 -1)
     (assert)
     (assert)
     (lemma "pos_times_gt")
     (inst -1 "2" "sin((a!1 - b!1) / 2) * cos((a!1 + b!1) / 2)")
     (replace -1 * lr)
     (hide -1)
     (flatten)
     (hide 1)
     (rewrite "pos_times_gt" 1)
     (assert)
     (flatten)
     (hide 1)
     (rewrite "sin_gt_0")
     (rewrite "cos_gt_0"))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (prop)
   (("1" (lemma "sin_increasing_imp") (inst -1 "b!1" "a!1") (assert))
    ("2" (rewrite "sin_increasing_imp"))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "sin_increasing")
   (skosimp)
   (inst -1 "pi-b!1" "pi-a!1")
   (rewrite "sin_minus")
   (rewrite "sin_pi")
   (rewrite "cos_pi")
   (rewrite "sin_minus")
   (rewrite "sin_pi")
   (rewrite "cos_pi")
   (assert)
   (case-replace "-1 * (sin(b!1) * -1) = sin(b!1)")
   (("1"
     (hide -1)
     (case-replace "-1 * (sin(a!1) * -1) = sin(a!1)")
     (("1" (hide -1) (ground)) ("2" (assert))))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "sin_increasing")
   (inst -1 "a!1-3*pi/2" "b!1-3*pi/2")
   (assert)
   (rewrite "sin_minus")
   (rewrite "cos_3pi2")
   (rewrite "sin_3pi2")
   (rewrite "sin_minus")
   (rewrite "cos_3pi2")
   (rewrite "sin_3pi2")
   (ground))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "sin_increasing")
   (inst -1 "a!1-pi/2" "b!1-pi/2")
   (assert)
   (rewrite "sin_minus")
   (rewrite "sin_pi2")
   (rewrite "cos_pi2")
   (assert)
   (rewrite "sin_minus")
   (rewrite "sin_pi2")
   (rewrite "cos_pi2")
   (assert)
   (ground))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "tan")
   (lemma "cos_gt_0")
   (inst -1 "a!1")
   (lemma "cos_gt_0")
   (inst -1 "b!1")
   (assert)
   (case "a!1>0" "b!1<0")
   (("1"
     (case "EXISTS (d: real): sin(a!1) / cos(a!1) > d AND d >= sin(b!1) / cos(b!1)")
     (("1" (skosimp*) (assert))
      ("2"
       (hide 2)
       (inst 1 "0")
       (rewrite "pos_div_gt" 1)
       (rewrite "sin_gt_0")
       (rewrite "neg_div_ge" 1)
       (lemma "sin_gt_0")
       (inst -1 "-b!1")
       (rewrite "sin_neg" -1)
       (case "0 < -b!1 AND -b!1 < pi IMPLIES sin(b!1) < 0")
       (("1" (hide -2) (assert)) ("2" (ground))))))
    ("2"
     (case "EXISTS (d: real): sin(a!1) / cos(a!1) > d AND d >= sin(b!1) / cos(b!1)")
     (("1" (skosimp*) (assert))
      ("2"
       (hide 3)
       (inst + "sin(b!1)/cos(a!1)")
       (split)
       (("1"
         (lemma "both_sides_div_pos_lt1")
         (inst -1 "cos(a!1)" "sin(b!1)" "sin(a!1)")
         (assert)
         (lemma "sin_increasing")
         (inst -1 "a!1" "b!1")
         (assert))
        ("2"
         (case "(sin(b!1) = 0 OR
                       sin(b!1) > 0 AND cos(a!1) <= cos(b!1) OR
                        sin(b!1) < 0 AND cos(a!1) >= cos(b!1))")
         (("1"
           (assert)
           (split -1)
           (("1"
             (flatten)
             (lemma "both_sides_div_pos_le2")
             (inst -1 "cos(b!1)" "cos(a!1)" "sin(b!1)")
             (("1" (assert)) ("2" (assert))))
            ("2"
             (flatten)
             (lemma "both_sides_div_pos_le3")
             (inst -1 "sin(b!1)" "cos(b!1)" "cos(a!1)")
             (("1" (assert)) ("2" (assert))))))
          ("2"
           (lemma "cos_decreasing")
           (inst -1 "a!1" "b!1")
           (assert)
           (lemma "sin_ge_0")
           (inst -1 "b!1")
           (assert))))))))
    ("3"
     (case "EXISTS (d: real): sin(a!1) / cos(a!1) > d AND d >= sin(b!1) / cos(b!1)")
     (("1" (skosimp*) (assert))
      ("2"
       (hide 3)
       (inst + "sin(b!1)/cos(a!1)")
       (split)
       (("1"
         (lemma "both_sides_div_pos_gt1")
         (inst -1 "cos(a!1)" "sin(a!1)" "sin(b!1)")
         (assert)
         (hide 2)
         (rewrite "sin_increasing"))
        ("2"
         (case "(sin(b!1) = 0 OR
                       sin(b!1) > 0 AND cos(a!1) <= cos(b!1) OR
                        sin(b!1) < 0 AND cos(a!1) >= cos(b!1))")
         (("1"
           (assert)
           (split -1)
           (("1"
             (flatten)
             (lemma "both_sides_div_pos_le2")
             (inst -1 "cos(b!1)" "cos(a!1)" "sin(b!1)")
             (("1" (assert)) ("2" (assert))))
            ("2"
             (lemma "both_sides_div_pos_le3")
             (inst -1 "sin(b!1)" "cos(b!1)" "cos(a!1)")
             (("1" (assert)) ("2" (flatten) (assert))))))
          ("2"
           (hide 2)
           (lemma "sin_gt_0")
           (inst -1 "-b!1")
           (rewrite "sin_neg" -1)
           (case "0 < -b!1 AND -b!1 < pi IMPLIES sin(b!1) < 0")
           (("1"
             (hide -2)
             (assert)
             (lemma "cos_decreasing")
             (inst -1 "-b!1" "-a!1")
             (rewrite "cos_neg" -1)
             (rewrite "cos_neg" -1)
             (assert))
            ("2" (assert))))))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (prop)
   (("1"
     (case "a!1=b!1")
     (("1" (replace -1 * lr) (assert))
      ("2"
       (lemma "trich_gt")
       (inst -1 "a!1" "b!1")
       (replace 1 * lr)
       (prop)
       (lemma "tan_increasing_imp")
       (inst -1 "b!1" "a!1")
       (assert))))
    ("2" (rewrite "tan_increasing_imp"))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (case-replace "a!1=b!1")
   (("1" (ground))
    ("2"
     (lemma "sin_increasing")
     (inst-cp -1 "b!1" "a!1")
     (inst -1 "a!1" "b!1")
     (ground))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "sin_decreasing")
   (inst -1 "a!1" "b!1")
   (assert)
   (lemma "sin_decreasing")
   (inst -1 "b!1" "a!1")
   (assert)
   (ground))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "cos_increasing")
   (inst-cp -1 "b!1" "a!1")
   (inst -1 "a!1" "b!1")
   (ground))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "cos_decreasing")
   (inst-cp -1 "b!1" "a!1")
   (inst -1 "a!1" "b!1")
   (ground))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "tan_increasing")
   (inst-cp -1 "b!1" "a!1")
   (inst -1 "a!1" "b!1")
   (ground))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (case "a <= pi/2")
   (("1"
     (lemma "sin_increasing")
     (inst?)
     (assert)
     (replaces -1)
     (ground))
    ("2"
     (lemma "sin_decreasing")
     (inst -1 "pi-b" "a")
     (assert)
     (lemma "neg_sin")
     (inst -1 "-b")
     (rewrite "sin_neg")
     (ground))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (case "a <= pi/2")
   (("1" (lemma "sin_increasing") (inst -1 "b" "a") (assert) (ground))
    ("2"
     (lemma "sin_decreasing")
     (inst -1 "a" "pi-b")
     (assert)
     (lemma "neg_sin")
     (inst -1 "-b")
     (rewrite "sin_neg")
     (ground))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: trig_ineq
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "Tan?")
   (lemma "cos_eq_0_2pi" ("a" "-a!1"))
   (assert)
   (rewrite "cos_neg")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "trichotomy" ("x" "x!1"))
   (expand "atan2")
   (split -1)
   (("1"
     (assert)
     (lemma "trichotomy" ("x" "y!1"))
     (split -1)
     (("1"
       (assert)
       (typepred "atan(y!1 / x!1)")
       (rewrite "pi_value")
       (lemma "atan_strict_increasing")
       (expand "strict_increasing?")
       (inst - "0" "y!1/x!1")
       (lemma "posreal_div_posreal_is_posreal" ("px" "y!1" "py" "x!1"))
       (assert)
       (rewrite "atan_0")
       (expand "abs")
       (assert)
       (expand "atan")
       (assert))
      ("2" (replace -1) (assert) (rewrite "atan_0") (assert))
      ("3"
       (assert)
       (lemma "atan_strict_increasing")
       (expand "strict_increasing?")
       (typepred "atan(y!1 / x!1)")
       (inst - "y!1/x!1" "0")
       (lemma "both_sides_div_pos_gt1" ("x" "0" "y" "y!1" "pz" "x!1"))
       (assert)
       (rewrite "atan_0")
       (expand "abs")
       (assert)
       (rewrite "pi_value")
       (expand "atan")
       (assert))))
    ("2"
     (replace -1)
     (assert)
     (lemma "trichotomy" ("x" "y!1"))
     (split -1)
     (("1" (assert)) ("2" (assert)) ("3" (assert))))
    ("3"
     (assert)
     (hide -2)
     (lemma "trichotomy" ("x" "y!1"))
     (split -1)
     (("1"
       (assert)
       (lemma "both_sides_div_neg_gt1")
       (inst - "x!1" "0" "y!1")
       (assert)
       (lemma "atan_strict_increasing")
       (expand "strict_increasing?")
       (inst - "y!1/x!1" "0")
       (rewrite "atan_0")
       (typepred "atan(y!1/x!1)")
       (expand "abs")
       (assert)
       (assert)
       (rewrite "pi_value")
       (expand "atan")
       (assert))
      ("2" (assert) (replace -1) (rewrite "atan_0") (assert))
      ("3"
       (lemma "negreal_div_negreal_is_posreal" ("nx" "y!1" "ny" "x!1"))
       (("1"
         (lemma "atan_strict_increasing")
         (expand "strict_increasing?")
         (inst - "0" "y!1/x!1")
         (rewrite "atan_0")
         (assert)
         (typepred "atan(y!1/x!1)")
         (expand "abs")
         (rewrite "pi_value")
         (expand "atan")
         (assert))
        ("2" (assert))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "atan2_0_2pi" ("x" "x!1" "y" "y!1"))
   (replace -2 -1)
   (flatten -1)
   (lemma "trichotomy" ("x" "x!1"))
   (split -1)
   (("1"
     (assert)
     (hide -3 -4 -6)
     (case "y!1>=0")
     (("1" (assert) (flatten -3) (assert))
      ("2" (assert) (flatten -3) (assert))))
    ("2"
     (assert)
     (lemma "trichotomy" ("x" "y!1"))
     (split -1)
     (("1" (assert) (flatten (-3 -4)) (assert)) ("2" (assert))
      ("3" (assert) (flatten (-5 -6)) (assert))))
    ("3"
     (assert)
     (hide -2 -5 -6)
     (case "y!1>=0")
     (("1" (assert) (flatten -3) (assert))
      ("2" (assert) (flatten -3) (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "atan2")
   (lemma "both_sides_times_pos_gt1" ("x" "x!1" "y" "0" "pz" "pz!1"))
   (replace -1)
   (case "x!1>0")
   (("1"
     (assert)
     (lemma "both_sides_times_pos_ge1" ("x" "y!1" "y" "0" "pz" "pz!1"))
     (replace -1)
     (case "y!1>=0")
     (("1" (assert)) ("2" (assert))))
    ("2"
     (assert)
     (case "x!1=0")
     (("1"
       (assert)
       (lemma "both_sides_times_pos_gt1" ("x" "y!1" "y" "0" "pz" "pz!1"))
       (replace -1)
       (propax))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "atan2")
   (lemma "both_sides_times1" ("x" "x!1" "y" "0" "n0z" "nz!1"))
   (replace -1)
   (case "y!1=0")
   (("1"
     (replace -1)
     (rewrite "atan_0")
     (simplify 1)
     (case "x!1>0")
     (("1"
       (assert)
       (lemma "both_sides_times_neg_lt1" ("x" "x!1" "y" "0" "nz" "nz!1"))
       (assert))
      ("2"
       (assert)
       (lemma "both_sides_times_neg_lt1" ("x" "x!1" "y" "0" "nz" "nz!1"))
       (assert))))
    ("2"
     (assert)
     (case "y!1>0")
     (("1"
       (hide -2)
       (assert)
       (lemma "both_sides_times_neg_gt1" ("x" "0" "y" "y!1" "nz" "nz!1"))
       (assert)
       (case "x!1>0")
       (("1"
         (assert)
         (lemma "both_sides_times_neg_gt1"
          ("x" "0" "y" "x!1" "nz" "nz!1"))
         (assert))
        ("2"
         (lemma "both_sides_times_neg_gt1"
          ("x" "0" "y" "x!1" "nz" "nz!1"))
         (assert)
         (case "x!1=0")
         (("1" (assert)) ("2" (assert))))))
      ("2"
       (assert)
       (case "x!1=0")
       (("1"
         (assert)
         (lemma "both_sides_times_neg_gt1"
          ("x" "0" "y" "y!1" "nz" "nz!1"))
         (assert))
        ("2"
         (assert)
         (case "x!1>0")
         (("1"
           (assert)
           (lemma "both_sides_times_neg_gt1"
            ("x" "0" "y" "x!1" "nz" "nz!1"))
           (assert))
          ("2"
           (assert)
           (lemma "both_sides_times_neg_gt1"
            ("y" "0" "x" "x!1" "nz" "nz!1"))
           (assert)
           (lemma "both_sides_times_neg_gt1"
            ("y" "0" "x" "y!1" "nz" "nz!1"))
           (assert))))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (case "x > 0 AND y > 0")
   (("1"
     (flatten)
     (hide -3)
     (expand "atan2")
     (assert)
     (lemma "atan_sub_swap")
     (inst?)
     (assert))
    ("2"
     (case "x < 0 AND y < 0")
     (("1"
       (flatten)
       (hide -3 1)
       (expand "atan2")
       (assert)
       (lemma "atan_sub_swap")
       (inst?)
       (assert))
      ("2" (hide 3) (grind-reals))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (case "x > 0 AND y < 0")
   (("1"
     (hide -2)
     (flatten)
     (expand "atan2")
     (assert)
     (expand "sign")
     (lemma "atan_sub_swap")
     (inst?)
     (assert))
    ("2"
     (case "x < 0 AND y > 0")
     (("1"
       (hide -2 1)
       (flatten)
       (expand "sign")
       (assert)
       (expand "atan2")
       (lemma "atan_sub_swap")
       (inst?)
       (assert))
      ("2" (hide 3) (grind-reals))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (lemma "atan_0")
   (split)
   (("1"
     (flatten)
     (replaces -1)
     (case "y > 0")
     (("1" (expand "atan2") (assert)) ("2" (expand "atan2") (assert))))
    ("2"
     (flatten)
     (replaces -1)
     (case "x > 0")
     (("1" (expand "atan2") (assert)) ("2" (expand "atan2") (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (case "FORALL (x:posreal): x < pi => sin(x) > 0")
   (("1"
     (case "FORALL (x: nnreal): x < pi => atan2(cos(x), sin(x)) = x")
     (("1"
       (skolem 1 ("a"))
       (case "a < pi")
       (("1" (inst -2 "a") (assert))
        ("2"
         (inst -1 "a-pi")
         (("1"
           (assert)
           (rewrite "cos_minus")
           (rewrite "sin_minus")
           (rewrite "sin_pi")
           (rewrite "cos_pi")
           (assert)
           (lemma "atan2_cancel_neg"
            ("x" "cos(a)" "y" "sin(a)" "nz" "-1"))
           (case-replace "a=pi")
           (("1" (rewrite "sin_pi") (rewrite "cos_pi") (assert))
            ("2"
             (lemma "sin_eq_0_2pi" ("a" "a"))
             (assert)
             (inst - "a-pi")
             (assert)
             (rewrite "sin_minus" -3)
             (rewrite "cos_pi")
             (rewrite "sin_pi")
             (assert))))
          ("2" (assert))))))
      ("2"
       (hide 2)
       (skolem 1 ("a"))
       (flatten)
       (inst - "a")
       (("1"
         (assert)
         (expand "atan2")
         (lemma "trichotomy" ("x" "cos(a)"))
         (split)
         (("1"
           (assert)
           (case "a<pi/2")
           (("1"
             (rewrite "tan_rew")
             (("1" (rewrite "atan_tan") (expand "abs") (propax))
              ("2" (expand "Tan?") (assert))))
            ("2"
             (lemma "cos_value_strict_decreasing")
             (case-replace "a=pi/2")
             (("1" (rewrite "cos_pi2") (assert))
              ("2"
               (expand "strict_decreasing?")
               (inst - "pi/2" "a")
               (rewrite "cos_value_pi2")
               (assert)
               (lemma "cos_cos_value" ("a" "a"))
               (assert))))))
          ("2" (replace -1) (lemma "cos_eq_0_2pi" ("a" "a")) (assert))
          ("3"
           (assert)
           (lemma "cos_value_strict_decreasing")
           (expand "strict_decreasing?")
           (lemma "trich_lt" ("x" "a" "y" "pi/2"))
           (split)
           (("1"
             (inst - "a" "pi/2")
             (rewrite "cos_value_pi2")
             (assert)
             (rewrite "cos_cos_value" -3)
             (assert))
            ("2" (replace -1) (rewrite "cos_pi2") (assert))
            ("3"
             (hide -2)
             (name "b" "a-pi/2")
             (lemma "sin_plus")
             (lemma "cos_plus")
             (inst - "b" "pi/2")
             (inst - "b" "pi/2")
             (rewrite "cos_pi2")
             (rewrite "sin_pi2")
             (assert)
             (replace -3 -1 rl)
             (replace -3 -2 rl)
             (assert)
             (replace -3)
             (replace -1)
             (replace -2)
             (hide -1 -2)
             (lemma "atan_neg" ("x" "cos(b)/sin(b)"))
             (replace -1 1)
             (lemma "posreal_div_posreal_is_posreal"
              ("px" "cos(b)" "py" "sin(b)"))
             (lemma "atan_inv" ("px" "cos(b) / sin(b)"))
             (("1"
               (rewrite "div_div1" -1)
               (assert)
               (case-replace "((1 * sin(b)) / cos(b))=tan(b)")
               (("1"
                 (rewrite "atan_tan" -2)
                 (("1" (assert)) ("2" (expand "abs") (assert))))
                ("2" (expand "tan") (assert))
                ("3" (expand "Tan?") (assert))))
              ("2" (assert))))))))
        ("2"
         (assert)
         (case-replace "a=0")
         (("1"
           (rewrite "cos_0")
           (rewrite "sin_0")
           (expand "atan2")
           (rewrite "atan_0"))
          ("2" (assert))))))
      ("3"
       (hide 2)
       (skosimp)
       (lemma "sin2_cos2" ("a" "x!1"))
       (replace -3)
       (replace -4)
       (expand "sq")
       (assert))))
    ("2"
     (hide 2)
     (skosimp)
     (case "x!1<=pi/2")
     (("1"
       (rewrite "sin_sin_value")
       (lemma "sin_value_strict_increasing")
       (expand "strict_increasing?")
       (inst - "0" "x!1")
       (("1" (rewrite "sin_value_0") (assert))
        ("2" (expand "abs") (assert))))
      ("2"
       (rewrite "sin_sin_phase")
       (expand "sin_phase")
       (lemma "floor_div" ("x" "2*x!1" "py" "pi" "i" "1"))
       (assert)
       (lemma "sin_value_strict_increasing")
       (expand "strict_increasing?")
       (inst - "0" "pi-x!1")
       (("1" (rewrite "sin_value_0") (assert))
        ("2" (expand "abs") (assert))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp*)
   (case "FORALL (x:real): sin(atan(x)) = x/sqrt(1+sq(x))")
   (("1"
     (expand "atan2")
     (case "x!1>0")
     (("1"
       (assert)
       (case "y!1>=0")
       (("1" (inst - "y!1/x!1") (assert))
        ("2"
         (inst - "y!1/x!1")
         (lemma "sin_period" ("a" "atan(y!1 / x!1)" "j" "1"))
         (assert))))
      ("2"
       (assert)
       (case "x!1=0")
       (("1"
         (assert)
         (replace -1)
         (rewrite "sin_pi2")
         (rewrite "sin_3pi2"))
        ("2"
         (assert)
         (rewrite "neg_sin" :dir rl)
         (inst - "y!1/x!1")
         (assert))))))
    ("2"
     (hide-all-but 1)
     (skosimp*)
     (case "FORALL (px:posreal):sin(atan(px)) = px / sqrt(1 + sq(px))")
     (("1"
       (lemma "trichotomy" ("x" "x!2"))
       (split -1)
       (("1" (inst - "x!2") (assert))
        ("2"
         (replace -1)
         (rewrite "atan_0")
         (rewrite "sin_0")
         (rewrite "sq_0")
         (rewrite "sqrt_1")
         (assert))
        ("3"
         (inst - "-x!2")
         (("1"
           (rewrite "atan_neg")
           (rewrite "sin_neg")
           (rewrite "sq_neg")
           (assert))
          ("2" (assert))))))
      ("2"
       (hide 2)
       (skosimp*)
       (expand "sin")
       (case "floor(atan(px!1) / (2 * pi)) = 0")
       (("1"
         (replace -1)
         (simplify)
         (hide -1)
         (lemma "atan_strict_increasing")
         (expand "strict_increasing?")
         (inst - "0" "px!1")
         (rewrite "atan_0")
         (assert)
         (case "atan(px!1)<pi/2")
         (("1"
           (lemma "phase_sin_q1" ("x" "atan(px!1)"))
           (("1"
             (assert)
             (lemma "sin_q1" ("x" "atan(px!1)"))
             (assert)
             (lemma "sin_value_atan" ("x" "px!1"))
             (assert))
            ("2" (assert))))
          ("2"
           (hide 2)
           (typepred "atan(px!1)")
           (expand "abs")
           (rewrite "pi_value")
           (expand "atan")
           (assert))))
        ("2"
         (hide 2)
         (lemma "floor_def" ("x" "atan(px!1) / (2 * pi)"))
         (rewrite "div_mult_pos_lt1")
         (rewrite "div_mult_pos_le2")
         (flatten)
         (name-replace "K1" "floor(atan(px!1) / (2 * pi))")
         (typepred "atan(px!1)")
         (expand "abs")
         (lemma "atan_strict_increasing")
         (expand "strict_increasing?")
         (inst - "0" "px!1")
         (rewrite "atan_0")
         (assert)
         (rewrite "pi_value")
         (expand "atan")
         (case "K1>=1")
         (("1"
           (lemma "both_sides_times_pos_ge1"
            ("x" "K1" "y" "1" "pz" "8*atan_value(1)"))
           (assert))
          ("2"
           (lemma "both_sides_times_pos_le1"
            ("x" "K1" "y" "-1" "pz" "8*atan_value(1)"))
           (case "K1<=-1")
           (("1" (assert)) ("2" (assert))))))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp*)
   (case "FORALL (x:real): cos(atan(x)) = 1/sqrt(1+sq(x))")
   (("1"
     (expand "atan2")
     (lemma "trichotomy" ("x" "x!1"))
     (split -1)
     (("1"
       (assert)
       (lemma "cos_period" ("a" "atan(y!1 / x!1)" "j" "1"))
       (replace -1 1 rl)
       (case "y!1>=0")
       (("1"
         (assert)
         (expand ">=" -1)
         (expand "<=" -1)
         (split -1)
         (("1"
           (lemma "both_sides_div_pos_lt1"
            ("x" "0" "y" "y!1" "pz" "x!1"))
           (inst - "y!1/x!1"))
          ("2"
           (replace -1 * rl)
           (rewrite "atan_0")
           (rewrite "sq_0")
           (rewrite "sqrt_1")
           (rewrite "cos_0")
           (assert))))
        ("2"
         (assert)
         (case "y!1<0")
         (("1"
           (lemma "both_sides_div_pos_lt1"
            ("y" "0" "x" "y!1" "pz" "x!1"))
           (inst - "-(y!1/x!1)")
           (rewrite "atan_neg" -5)
           (rewrite "cos_neg" -5)
           (case "sq(-(y!1 / x!1)) =sq(y!1 / x!1)")
           (("1" (assert)) ("2" (hide-all-but 1) (grind))))
          ("2" (assert))))))
      ("2"
       (replace -1)
       (assert)
       (case "y!1>0")
       (("1" (assert) (rewrite "cos_pi2"))
        ("2" (rewrite "cos_3pi2") (assert))))
      ("3"
       (assert)
       (rewrite "neg_cos" :dir rl)
       (inst - "y!1/x!1")
       (assert))))
    ("2"
     (hide-all-but 1)
     (skosimp*)
     (case "FORALL (px:posreal): cos(atan(px)) = cos_value(atan(px))")
     (("1"
       (lemma "trichotomy" ("x" "x!2"))
       (split -1)
       (("1"
         (inst - "x!2")
         (("1"
           (lemma "cos_value_atan" ("nnx" "x!2"))
           (("1" (assert)) ("2" (assert))))
          ("2" (assert))))
        ("2"
         (replace -1)
         (rewrite "atan_0")
         (rewrite "cos_0")
         (rewrite "sq_0")
         (rewrite "sqrt_1")
         (assert))
        ("3"
         (inst - "-x!2")
         (("1"
           (lemma "cos_value_atan" ("nnx" "-x!2"))
           (("1"
             (replace -1 -3)
             (rewrite "atan_neg" -3)
             (rewrite "cos_neg" -3)
             (rewrite "sq_neg" -3))
            ("2" (assert))))
          ("2" (assert))))))
      ("2"
       (hide 2)
       (skosimp*)
       (case "0 < atan(px!1) & atan(px!1) < pi/2")
       (("1"
         (flatten)
         (name-replace "K1" "atan(px!1)")
         (expand "cos")
         (case "floor(K1 / (2 * pi)) = 0")
         (("1"
           (replace -1)
           (lemma "phase_sin_q1" ("x" "K1"))
           (("1" (assert) (lemma "cos_q1" ("x" "K1")) (assert))
            ("2" (assert))))
          ("2"
           (hide 2)
           (lemma "floor_def" ("x" "K1/(2*pi)"))
           (rewrite "div_mult_pos_lt1")
           (rewrite "div_mult_pos_le2")
           (flatten)
           (name-replace "K2" "floor(K1 / (2 * pi))")
           (case "K2>=1")
           (("1"
             (lemma "both_sides_times_pos_ge1"
              ("x" "K2" "y" "1" "pz" "2*pi"))
             (assert))
            ("2"
             (case "K2<=-1")
             (("1"
               (lemma "both_sides_times_pos_le1"
                ("x" "K2" "y" "-1" "pz" "2*pi"))
               (assert))
              ("2" (assert))))))))
        ("2"
         (hide 2)
         (lemma "atan_strict_increasing")
         (expand "strict_increasing?")
         (inst - "0" "px!1")
         (rewrite "atan_0")
         (assert)
         (typepred "atan(px!1)")
         (expand "abs")
         (expand "pi")
         (expand "atan")
         (assert))))
      ("3"
       (hide 2)
       (skosimp*)
       (lemma "atan_strict_increasing")
       (expand "strict_increasing?")
       (inst - "0" "px!1")
       (rewrite "atan_0")
       (typepred "atan(px!1)")
       (expand "abs")
       (expand "pi")
       (expand "atan")
       (assert))))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (assert)
   (split -1)
   (("1"
     (lemma "both_sides_times1" ("x" "x!1" "y" "0" "n0z" "pz!1"))
     (assert))
    ("2"
     (lemma "both_sides_times1" ("x" "y!1" "y" "0" "n0z" "pz!1"))
     (assert))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "both_sides_times1" ("x" "y!1" "y" "0" "n0z" "nz!1"))
   (lemma "both_sides_times1" ("x" "x!1" "y" "0" "n0z" "nz!1"))
   (assert))


proof_type: t_proof
decl_type: tcc
library: trig
theory: atan2
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (typepred "a!1")
   (lemma "sin_eq_0_2pi" ("a" "a!1"))
   (lemma "cos_eq_0_2pi" ("a" "a!1"))
   (assert)
   (split -1)
   (("1" (split -2) (("1" (assert)) ("2" (assert))))
    ("2" (split -2) (("1" (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "to2pi")
   (typepred "alpha")
   (typepred "floor(alpha / (2 * pi))")
   (div-by -5 "2*pi")
   (div-by -4 "2*pi")
   (name-replace "aa" "alpha/(2*pi)")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "to2pi")
   (lemma "sin_period")
   (inst -1 "a" "-(floor(a / (2 * pi)))")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "to2pi")
   (lemma "cos_period")
   (inst -1 "a" "-(floor(a / (2 * pi)))")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "to2pi" 1 2)
   (lemma "to2pi_period")
   (inst -1 "a+b" "-floor(a / (2 * pi))")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "to2pi" 1 2)
   (lemma "to2pi_period")
   (inst -1 "b!1 - a!1" "floor((a!1 / (2 * pi)))")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "to2pi")
   (typepred "floor(a / (2 * pi))")
   (div-by -3 "2*pi")
   (div-by -4 "2*pi")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "to2pi" 1 2)
   (lemma "to2pi_period")
   (inst - "a!1+b!1" "-floor(a!1/(2*pi))")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (case "a!1 < 2*pi*floor(b!1/(2*pi))")
   (("1"
     (inst 1 "floor(b!1 / (2 * pi))")
     (hide 2)
     (split)
     (("1" (assert))
      ("2"
       (typepred "floor(b!1 / (2 * pi))")
       (hide -2 -3 -4 -5)
       (mult-by -1 "2*pi")
       (assert))))
    ("2"
     (hide 2)
     (inst 2 "floor(b!1 / (2 * pi))")
     (typepred "floor(b!1 / (2 * pi))")
     (mult-by -2 "2*pi")
     (mult-by -1 "2*pi")
     (split)
     (("1" (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (lemma "sin_gt")
   (inst -1 "to2pi(a+pi/2)-pi/2" "b")
   (assert)
   (typepred "to2pi(pi / 2 + a)")
   (assert)
   (replaces -3 :dir rl)
   (case-replace "sin(a) = sin(to2pi(pi/2+a) - pi/2)")
   (("1" (assert))
    ("2"
     (hide-all-but 1)
     (expand "to2pi")
     (lemma "sin_period")
     (inst -1 "a" "-floor((pi / 2 + a) / (2 * pi))")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (lemma "sin_lt")
   (inst -1 "to2pi(a+pi/2)-pi/2" "b")
   (assert)
   (typepred "to2pi(pi / 2 + a)")
   (assert)
   (replaces -3 :dir rl)
   (case-replace "sin(a) = sin(to2pi(pi/2+a) - pi/2)")
   (("1" (assert))
    ("2"
     (hide-all-but 1)
     (expand "to2pi")
     (lemma "sin_period")
     (inst -1 "a" "-floor((pi / 2 + a) / (2 * pi))")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (name-replace "bb" "a+pi/2" :hide? nil)
   (move-terms -1 l 2)
   (replaces -1)
   (rewrite "cos_minus")
   (rewrite "cos_pi2")
   (rewrite "sin_pi2")
   (assert)
   (rewrite "sin_id_to2pi" :dir rl)
   (split 1)
   (("1"
     (flatten)
     (split)
     (("1"
       (typepred "to2pi(bb)")
       (case-replace "to2pi(bb) = 0")
       (("1" (rewrite "sin_0") (assert)) ("2" (assert))))
      ("2" (lemma "sin_le_0") (inst?) (assert))))
    ("2" (flatten) (lemma "sin_gt_0") (inst?) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: to2pi
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (name-replace "bb" "a+pi/2" :hide? nil)
   (move-terms -1 l 2)
   (replaces -1)
   (rewrite "cos_minus")
   (rewrite "cos_pi2")
   (rewrite "sin_pi2")
   (assert)
   (rewrite "sin_id_to2pi" :dir rl)
   (split 1)
   (("1" (flatten) (lemma "sin_lt_0") (inst?) (assert))
    ("2" (flatten) (lemma "sin_ge_0") (inst?) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_inverses
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "Tan?")
   (typepred "x!1")
   (flatten)
   (lemma "cos_eq_0")
   (inst?)
   (assert)
   (skosimp*)
   (hide -4)
   (replace -1)
   (hide -1)
   (case "i!1 = 0")
   (("1" (assert))
    ("2"
     (mult-by -1 "2")
     (assert)
     (mult-by -2 "2")
     (assert)
     (case-replace "2 * (pi / 2) = pi")
     (("1"
       (hide -1)
       (assert)
       (case "i!1 > 0")
       (("1" (assert) (mult-by -1 "2*pi") (assert))
        ("2"
         (case "i!1 < -1")
         (("1" (mult-by -1 "2*pi") (assert)) ("2" (assert))))))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_inverses
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "Tan?")
   (typepred "x!1")
   (lemma "cos_eq_0_2pi")
   (inst?)
   (assert)
   (lemma "cos_period")
   (inst?)
   (inst -1 "1")
   (replace -1)
   (hide -1)
   (lemma "cos_eq_0_2pi")
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "sin2_cos2")
   (inst -1 "pi/4")
   (lemma "sin_cos_pi4")
   (case "sq(sin(pi / 4)) = sq(cos(pi / 4))")
   (("1"
     (replace -1 :hide? t)
     (hide -1)
     (ground)
     (case "sqrt(2 * sq(cos(pi / 4))) = sqrt(1)")
     (("1"
       (case "sqrt(1)=1")
       (("1"
         (replace -1 :hide? t)
         (rewrite "sqrt_times")
         (rewrite "sqrt_sq")
         (("1"
           (hide -2)
           (lemma "both_sides_div1")
           (inst -1 "sqrt(2)" "sqrt(2) * cos(pi / 4)" "1")
           (ground))
          ("2"
           (hide -1 -2 2)
           (lemma "cos_decreasing")
           (inst -1 "pi/2" "pi/4")
           (ground)
           (rewrite "cos_pi2")
           (ground))))
        ("2" (hide -1 -2 2) (assert))))
      ("2" (expand "sq") (ground) (replace -1) (assert))))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "cos_plus")
   (inst -1 "pi/2" "pi/4")
   (case-replace "pi / 2 + pi / 4 = 3*pi/4")
   (("1"
     (hide -1)
     (rewrite "cos_pi2")
     (rewrite "cos_pi4")
     (rewrite "sin_pi4")
     (rewrite "sin_pi2")
     (assert))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "sin_plus")
   (inst -1 "pi/4" "pi/2")
   (case-replace "pi/2 + pi / 4 = 3*pi/4")
   (("1"
     (hide -1)
     (rewrite "cos_pi4")
     (rewrite "sin_pi4")
     (rewrite "sin_pi2")
     (rewrite "cos_pi2")
     (assert))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "sin_pi6_cos_pi3")
   (case "cos(pi / 6) = sin(pi / 3)")
   (("1"
     (case "sin(pi / 3) = sin(pi/6+pi/6)")
     (("1"
       (rewrite "sin_plus" -1)
       (hide -2)
       (case-replace
        "cos(pi / 6) * sin(pi / 6) + sin(pi / 6) * cos(pi / 6) =  2 * cos(pi / 6) * sin(pi / 6)")
       (("1"
         (hide -1)
         (lemma "both_sides_times1")
         (inst -1 "cos(pi/6)" "sin(pi/6)" "1/2")
         (("1" (assert))
          ("2"
           (lemma "cos_eq_0")
           (inst?)
           (assert)
           (skosimp*)
           (hide -2 -3 1)
           (case "1/6 = 1/2 +i!1")
           (("1" (hide -2) (assert))
            ("2"
             (assert)
             (lemma "both_sides_times1")
             (inst -1 "pi" "1 / 6" "1 / 2 + i!1")
             (assert))))))
        ("2" (assert))))
      ("2" (assert))))
    ("2" (rewrite "sin_pi3_cos_pi6"))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "sin_pi6")
   (lemma "cos2")
   (inst?)
   (rewrite "sqrt_eq" :dir rl)
   (rewrite "sqrt_sq")
   (("1"
     (replace -2)
     (replace -1)
     (hide -1 -2)
     (both-sides-f 1 "sq")
     (("1" (sq-simp) (("1" (grind)) ("2" (hide 2) (grind))))
      ("2" (rewrite "sq_eq") (grind))))
    ("2" (rewrite "cos_ge_0"))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "cos_plus")
   (inst -1 "pi" "pi/4")
   (rewrite "cos_pi")
   (rewrite "cos_pi4")
   (rewrite "sin_pi")
   (rewrite "sin_pi4")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "sin_plus")
   (inst -1 "pi" "pi/4")
   (rewrite "sin_pi")
   (rewrite "sin_pi4")
   (rewrite "cos_pi")
   (rewrite "cos_pi4")
   (assert))


proof_type: t_proof
decl_type: tcc
library: trig
theory: trig_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "Tan?")
   (lemma "cos_eq_0")
   (inst?)
   (ground)
   (skosimp*)
   (hide -1 -3)
   (case-replace "pi / 2 + i!1 * pi = (1/2+i!1)*pi")
   (("1"
     (hide -1)
     (lemma "both_sides_times1")
     (inst -1 "pi" "(1 / 2 + i!1) " "2/3")
     (assert))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "atan_tan")
   (inst - "pi/4")
   (("1" (expand "tan") (rewrite "sin_pi4") (rewrite "cos_pi4") (assert))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "atan_tan")
   (inst - "pi/6")
   (("1" (expand "tan") (rewrite "sin_pi6") (rewrite "cos_pi6") (assert))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "atan_tan")
   (inst - "pi/3")
   (("1" (expand "tan") (rewrite "sin_pi3") (rewrite "cos_pi3") (assert))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_values
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (lemma "tan_atan")
   (inst?)
   (lemma "tan_gt_0")
   (inst?)
   (lemma "tan_lt_0")
   (inst?)
   (lemma "tan_0")
   (ground))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("a" "b"))
   (split 1)
   (("1"
     (flatten)
     (lemma "trichotomy" ("x" "a"))
     (split -1)
     (("1"
       (expand "atan2")
       (assert)
       (lemma "trichotomy" ("x" "b"))
       (split -1)
       (("1"
         (assert)
         (lemma "posreal_div_posreal_is_posreal" ("px" "b" "py" "a"))
         (lemma "atan_strict_increasing")
         (expand "strict_increasing?")
         (inst - "0" "b/a")
         (rewrite "atan_0")
         (assert))
        ("2" (propax))
        ("3"
         (assert)
         (hide 1)
         (typepred "atan(b/a)")
         (hide -1)
         (expand "abs")
         (assert))))
      ("2"
       (replace -1)
       (expand "atan2")
       (case-replace "b>0")
       (("1" (assert)) ("2" (assert))))
      ("3"
       (hide 1)
       (expand "atan2")
       (assert)
       (typepred "atan(b/a)")
       (hide -1)
       (expand "abs")
       (assert))))
    ("2"
     (flatten)
     (replace -2)
     (expand "atan2")
     (assert)
     (rewrite "atan_0"))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("a" "b"))
   (typepred "b")
   (split 1)
   (("1"
     (flatten)
     (lemma "trichotomy" ("x" "a"))
     (split -1)
     (("1"
       (expand "atan2")
       (assert)
       (typepred "atan(b/a)")
       (case-replace "b>=0")
       (("1" (assert))
        ("2" (assert) (hide (-1 -5 2)) (expand "abs") (assert))))
      ("2" (assert) (replace -1) (expand "atan2") (assert))
      ("3"
       (assert)
       (hide -3 1)
       (expand "atan2")
       (typepred "atan(b/a)")
       (hide -1)
       (expand "abs")
       (assert))))
    ("2" (flatten) (assert) (replace -1) (expand "atan2") (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("a" "b"))
   (typepred "b")
   (lemma "trichotomy" ("x" "a"))
   (split -1)
   (("1"
     (expand "atan2")
     (assert)
     (hide -2)
     (typepred "atan(b/a)")
     (case-replace "b>=0")
     (("1" (assert)) ("2" (assert) (hide -1) (expand "abs") (assert))))
    ("2"
     (assert)
     (replace -1)
     (expand "atan2")
     (case-replace "b>0")
     (("1" (assert)) ("2" (assert))))
    ("3"
     (assert)
     (hide -2)
     (expand "atan2")
     (split 1)
     (("1"
       (flatten)
       (lemma "atan_bij")
       (expand "bijective?")
       (flatten)
       (expand "injective?")
       (inst - "0" "b/a")
       (rewrite "atan_0")
       (assert))
      ("2" (flatten) (replace -1) (rewrite "atan_0"))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("a" "b"))
   (typepred "b")
   (expand "atan2")
   (split 1)
   (("1"
     (flatten)
     (lemma "trichotomy" ("x" "a"))
     (split -1)
     (("1"
       (assert)
       (typepred "atan(b / a)")
       (case-replace "b >= 0")
       (("1" (assert))
        ("2" (assert) (hide -1 -5 2) (expand "abs") (assert))))
      ("2"
       (assert)
       (case-replace "b>=0")
       (("1" (assert)) ("2" (assert))))
      ("3"
       (assert)
       (hide -3 1)
       (typepred "atan(b / a)")
       (hide -1)
       (expand "abs")
       (assert))))
    ("2" (flatten) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("a" "b"))
   (typepred "b")
   (expand "atan2")
   (split 1)
   (("1"
     (flatten)
     (lemma "trichotomy" ("x" "a"))
     (split -1)
     (("1"
       (typepred "atan(b/a)")
       (("1"
         (assert)
         (case-replace "b=0")
         (("1" (rewrite "atan_0") (assert))
          ("2" (assert) (hide -1 -6) (expand "abs") (assert))))
        ("2" (assert))))
      ("2" (assert) (lift-if) (assert))
      ("3"
       (assert)
       (hide -4 1)
       (typepred "atan(b/a)")
       (hide -1)
       (expand "abs")
       (assert))))
    ("2"
     (flatten)
     (assert)
     (hide -3)
     (typepred "atan(b/a)")
     (hide -1)
     (lemma "posreal_div_posreal_is_posreal" ("px" "b" "py" "a"))
     (lemma "atan_strict_increasing")
     (expand "strict_increasing?")
     (inst - "0" "b/a")
     (rewrite "atan_0")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("a" "b"))
   (typepred "b")
   (lemma "trichotomy" ("x" "a"))
   (split -1)
   (("1"
     (expand "atan2")
     (assert)
     (typepred "atan(b/a)")
     (case-replace "b>=0")
     (("1" (assert))
      ("2"
       (assert)
       (flatten)
       (hide -1 -4)
       (assert)
       (expand "abs" -1)
       (assert))))
    ("2"
     (replace -1)
     (expand "atan2")
     (case-replace "b>0")
     (("1" (assert)) ("2" (assert) (flatten) (assert))))
    ("3"
     (expand "atan2")
     (assert)
     (typepred "atan(b / a)")
     (hide -1 -4)
     (assert)
     (lemma "atan_strict_increasing")
     (expand "strict_increasing?")
     (lemma "trichotomy" ("x" "b"))
     (split -1)
     (("1"
       (lemma "both_sides_div_neg_lt1" ("nz" "a" "y" "0" "x" "b"))
       (inst - "b/a" "0")
       (rewrite "atan_0")
       (assert)
       (expand "abs")
       (assert))
      ("2" (replace -1) (rewrite "atan_0") (assert))
      ("3"
       (lemma "both_sides_div_neg_lt1" ("nz" "a" "y" "b" "x" "0"))
       (inst - "0" "b/a")
       (rewrite "atan_0")
       (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("a" "b"))
   (typepred "b")
   (lemma "trichotomy" ("x" "a"))
   (split -1)
   (("1"
     (expand "atan2")
     (typepred "atan(b / a)")
     (("1"
       (case-replace "b >= 0")
       (("1" (assert))
        ("2"
         (assert)
         (hide -1 -4)
         (flatten)
         (assert)
         (expand "abs")
         (assert))))
      ("2" (assert))))
    ("2"
     (replace -1)
     (expand "atan2")
     (flatten)
     (case-replace "b>0")
     (("1" (assert)) ("2" (assert))))
    ("3"
     (expand "atan2")
     (typepred "atan(b / a)")
     (("1"
       (assert)
       (lemma "atan_strict_increasing")
       (expand "strict_increasing?")
       (lemma "atan_0")
       (lemma "trichotomy" ("x" "b"))
       (split -1)
       (("1"
         (lemma "both_sides_div_neg_lt1" ("nz" "a" "y" "0" "x" "b"))
         (inst - "b/a" "0")
         (assert))
        ("2" (assert))
        ("3"
         (lemma "both_sides_div_neg_lt1" ("nz" "a" "x" "0" "y" "b"))
         (inst - "0" "b/a")
         (assert))))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("a" "b"))
   (typepred "b")
   (lemma "trichotomy" ("x" "a"))
   (expand "atan2")
   (split -1)
   (("1"
     (typepred "atan(b / a)")
     (("1"
       (case-replace "b>=0")
       (("1" (assert))
        ("2"
         (assert)
         (lemma "atan_strict_increasing")
         (expand "strict_increasing?")
         (lemma "both_sides_div_pos_lt1" ("pz" "a" "x" "b" "y" "0"))
         (inst - "b/a" "0")
         (rewrite "atan_0")
         (assert)
         (hide -3)
         (expand "abs")
         (assert))))
      ("2" (assert))))
    ("2"
     (assert)
     (flatten)
     (case-replace "b>0")
     (("1" (assert)) ("2" (assert))))
    ("3" (typepred "atan(b/a)") (("1" (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "atan_tan")
   (inst - "pi/4")
   (("1"
     (expand "tan")
     (assert)
     (rewrite "sin_pi4")
     (rewrite "cos_pi4")
     (assert)
     (case-replace "1 / sqrt(2) / (1 / sqrt(2)) = 1")
     (("1" (expand "atan2") (assert)) ("2" (hide 2) (field 1))))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "atan2")
   (lemma "atan_tan")
   (inst - "-pi/4")
   (("1"
     (expand "tan")
     (move-terms 1 l 2)
     (assert)
     (case-replace "-pi / 4 = -(pi/4)")
     (("1"
       (hide -1)
       (rewrite "sin_neg")
       (rewrite "cos_neg")
       (rewrite "sin_pi4")
       (rewrite "cos_pi4")
       (case-replace "1 / sqrt(2) / (-1 / sqrt(2)) = -1")
       (field 1))
      ("2" (assert))))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "atan2")
   (lemma "atan_tan")
   (inst - "-pi/4")
   (("1"
     (expand "tan")
     (move-terms 1 l 2)
     (assert)
     (case-replace "-pi / 4 = -(pi/4)")
     (("1"
       (hide -1)
       (rewrite "sin_neg")
       (rewrite "cos_neg")
       (rewrite "sin_pi4")
       (rewrite "cos_pi4")
       (case-replace "-(1 / sqrt(2)) / (1 / sqrt(2)) = -1")
       (field 1))
      ("2" (assert))))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "atan_tan")
   (inst - "pi/4")
   (("1"
     (expand "tan")
     (assert)
     (rewrite "sin_pi4")
     (rewrite "cos_pi4")
     (assert)
     (case-replace "1 / sqrt(2) / (1 / sqrt(2)) = 1")
     (("1" (expand "atan2") (assert)) ("2" (field 1))))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "atan2")
   (case "sqrt(3) >= 0")
   (("1" (assert) (rewrite "atan_sqrt3"))
    ("2" (hide 2) (lemma "sqrt_gt") (inst - "3" "0") (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "atan2")
   (case-replace "sqrt(3) > 0")
   (("1" (assert) (rewrite "atan_1sqrt3"))
    ("2" (hide 2) (lemma "sqrt_gt") (inst - "3" "0") (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan2_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "atan2")
   (lemma "atan_neg")
   (inst - "1/sqrt(3)")
   (case-replace "sqrt(3) > 0")
   (("1" (assert) (rewrite "atan_1sqrt3") (assert)) ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "atan_pos_le1_ub")
   (expand "atan_series_n")
   (expand "sigma" 1 1)
   (expand "sigma" 1 1)
   (move-terms 1 r 1)
   (("1"
     (assert)
     (expand "atan_series_term")
     (expand "atan_series_coef")
     (lemma "not_even_m1_pow")
     (inst?)
     (split -1)
     (("1"
       (replaces -1)
       (lemma "even_m1_pow")
       (inst?)
       (split -1)
       (("1"
         (replaces -1)
         (case "(x ^ (5 + 4 * n)) * (1 / (5 + 4 * n)) < (x ^ (5 + 4 * n)) / (3 + 4 * n)")
         (("1"
           (case "(x ^ (5 + 4 * n)) / (3 + 4 * n) <= (x ^ (3 + 4 * n)) / (3 + 4 * n)")
           (("1" (assert))
            ("2"
             (hide -1 2)
             (grind-reals)
             (rewrite "both_sides_expt_lt1_le")
             (case "x=1")
             (("1" (replaces -1) (grind)) ("2" (assert))))))
          ("2"
           (hide 2)
           (case "x ^ (5+4 *n) > 0")
           (("1" (name-replace "aa" "x^(5+4*n)") (grind-reals))
            ("2" (hide 2) (rewrite "expt_pos"))))))
        ("2" (hide-all-but 1) (grind))))
      ("2" (hide-all-but -1) (grind))))
    ("2" (skosimp*) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "atan_pos_le1_lb")
   (expand "atan_series_n")
   (expand "sigma" 1 2)
   (expand "sigma" 1 2)
   (move-terms 1 r 3)
   (("1"
     (assert)
     (expand "atan_series_term")
     (expand "atan_series_coef")
     (lemma "not_even_m1_pow")
     (inst -1 "3+2*n")
     (split -1)
     (("1"
       (replaces -1)
       (lemma "even_m1_pow")
       (inst?)
       (split -1)
       (("1"
         (replaces -1)
         (case "(x ^ (5 + 4 * n))/(7 + 4 * n) < (x ^ (5 + 4 * n)) * (1 / (5 + 4 * n))")
         (("1"
           (case "(x ^ (7 + 4 * n))/(7+4*n) <=  (x ^ (5 + 4 * n))/(7+4*n)")
           (("1" (assert))
            ("2"
             (hide -1 2)
             (grind-reals)
             (rewrite "both_sides_expt_lt1_le")
             (case-replace "x=1")
             (("1" (grind)) ("2" (assert))))))
          ("2"
           (hide 2)
           (case "x ^ (5+4*n) > 0")
           (("1" (name-replace "aa" "x^(5+4*n)") (grind-reals))
            ("2" (hide 2) (rewrite "expt_pos"))))))
        ("2" (hide-all-but 1) (grind))))
      ("2" (hide-all-but -1) (grind))))
    ("2" (skosimp*) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (skosimp)
   (expand "atan_pos_le1_lb")
   (expand "atan_pos_le1_ub")
   (case "FORALL (n:posnat): 0 < x!1^n/n")
   (("1"
     (case "FORALL (n,m:posnat): n < m => x!1^m/m < x!1^n/n")
     (("1"
       (case-replace "atan_series_n(x!1, 1 + 2 * n!1) < atan(x!1)")
       (("1"
         (lemma "atan_series" ("x" "x!1" "n" "1+2*n!1"))
         (rewrite "abs_expt" -1 :dir rl)
         (expand "abs" -1)
         (assert)
         (expand "atan_series_n")
         (expand "sigma" -1)
         (name-replace "UB" "sigma(0, 2 * n!1, atan_series_term(x!1))")
         (hide -2)
         (expand "atan_series_term")
         (expand "atan_series_coef")
         (lemma "not_even_m1_pow" ("i" "1+2*n!1"))
         (split -1)
         (("1" (replace -1) (inst - "3+4*n!1" "5+4*n!1") (assert))
          ("2" (hide-all-but -1) (expand "even?") (propax))))
        ("2"
         (hide 2)
         (lemma "atan_series" ("x" "x!1" "n" "2+2*n!1"))
         (rewrite "abs_expt" -1 :dir rl)
         (expand "abs")
         (assert)
         (expand "atan_series_n")
         (expand "sigma" -1)
         (name-replace "LB"
          "sigma(0, 1 + 2 * n!1, atan_series_term(x!1))")
         (expand "atan_series_term")
         (expand "atan_series_coef")
         (lemma "even_m1_pow" ("i" "2+2*n!1"))
         (split -1)
         (("1"
           (replace -1)
           (hide -1)
           (inst - "5 + 4 * n!1" "7 + 4 * n!1")
           (assert)
           (inst-cp - "7 + 4 * n!1")
           (assert))
          ("2" (expand "even?") (inst + "n!1+1") (assert))))))
      ("2"
       (hide 2)
       (skosimp)
       (case-replace "x!1=1")
       (("1"
         (rewrite "expt_1i")
         (rewrite "expt_1i")
         (lemma "both_sides_div_pos_lt2")
         (inst - "m!1" "n!2" "1")
         (assert))
        ("2"
         (lemma "both_sides_expt_lt1_lt"
          ("lt1x" "x!1" "i" "m!1" "j" "n!2"))
         (("1"
           (assert)
           (lemma "lt_div_lt_pos1"
            ("px" "x!1 ^ m!1" "y" "x!1 ^ n!2" "pz" "n!2" "w" "m!1"))
           (("1" (assert))
            ("2" (lemma "expt_pos" ("px" "x!1" "i" "m!1")) (assert))))
          ("2" (assert))))))))
    ("2"
     (hide 2)
     (skosimp)
     (lemma "expt_pos" ("px" "x!1" "i" "n!2"))
     (("1" (rewrite "div_mult_pos_lt2") (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (case "FORALL (n: nat, px: posreal):
                               px <= 1 => atan_pos_le1_lb(n, px) < atan_pos_le1_lb(n+1, px)")
   (("1"
     (case "FORALL (n: nat,pn:posnat, px: posreal):
                                     px <= 1 => atan_pos_le1_lb(n, px) < atan_pos_le1_lb(n+pn, px)")
     (("1"
       (skosimp)
       (inst - "n!1" "m!1-n!1" "px!1")
       (("1" (assert)) ("2" (assert))))
      ("2"
       (hide 2)
       (induct "pn")
       (("1" (assert)) ("2" (assert))
        ("3"
         (skosimp*)
         (case-replace "j!1=0")
         (("1" (assert) (hide -1 -2 -3) (inst - "n!1" "px!1") (assert))
          ("2"
           (assert)
           (inst - "n!1" "px!1")
           (assert)
           (inst - "j!1+n!1" "px!1")
           (assert))))))))
    ("2"
     (hide 2)
     (skosimp)
     (expand "atan_pos_le1_lb")
     (expand "atan_series_n")
     (expand "sigma" 1 2)
     (expand "sigma" 1 2)
     (name-replace "SUM" "sigma(0, 1 + 2 * n!1, atan_series_term(px!1))")
     (("1"
       (expand "atan_series_term")
       (expand "atan_series_coef")
       (expand "^")
       (expand "expt" 1 3)
       (expand "expt" 1 3)
       (expand "expt" 1 4)
       (case-replace "expt((-1), 2 + 2 * n!1)=1")
       (("1"
         (typepred "expt(px!1, 5 + 4 * n!1)")
         (hide -1 -3)
         (name-replace "PX" "expt(px!1, 5 + 4 * n!1)")
         (lemma "posreal_times_posreal_is_posreal"
          ("px" "PX" "py" "1 / (5 + 4 * n!1)-sq(px!1)/(7 + 4 * n!1)"))
         (("1" (expand "sq") (assert))
          ("2"
           (hide 2)
           (lemma "div_mult_pos_lt1"
            ("py" "7+4*n!1" "z" "sq(px!1)" "x" "1/(5+4*n!1)"))
           (lemma "sq_nz_pos" ("nz" "px!1"))
           (lemma "div_mult_pos_lt2"
            ("py" "5 + 4 * n!1" "z" "7 + 4 * n!1" "x" "1"))
           (lemma "sq_le" ("nna" "px!1" "nnb" "1"))
           (assert)
           (name-replace "LHS" "sq(px!1) / (7 + 4 * n!1)")
           (name-replace "RHS" "1 / (5 + 4 * n!1)")
           (assert))))
        ("2"
         (hide-all-but 1)
         (lemma "expt_times" ("n0x" "-1" "i" "2" "j" "1+n!1"))
         (expand "^" -1 1)
         (expand "^" -1 1)
         (replace -1)
         (hide -1)
         (expand "expt")
         (expand "expt")
         (expand "expt")
         (rewrite "sq_rew")
         (rewrite "sq_neg")
         (rewrite "expt_1i"))))
      ("2" (skosimp*) (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (case "FORALL (n: nat, px: posreal):
                                                           px <= 1 => atan_pos_le1_ub(n, px) > atan_pos_le1_ub(n+1, px)")
   (("1"
     (case "FORALL (n: nat,pn:posnat, px: posreal):
                                                                         px <= 1 => atan_pos_le1_ub(n, px) > atan_pos_le1_ub(n+pn, px)")
     (("1"
       (skosimp)
       (inst - "n!1" "m!1-n!1" "px!1")
       (("1" (assert)) ("2" (assert))))
      ("2"
       (hide 2)
       (induct "pn")
       (("1" (assert)) ("2" (assert))
        ("3"
         (skosimp*)
         (case-replace "j!1=0")
         (("1" (assert) (hide -1 -2 -3) (inst - "n!1" "px!1") (assert))
          ("2"
           (assert)
           (inst - "n!1" "px!1")
           (assert)
           (inst - "j!1+n!1" "px!1")
           (assert))))))))
    ("2"
     (hide 2)
     (skosimp)
     (expand "atan_pos_le1_ub")
     (expand "atan_series_n")
     (expand "sigma" 1 2)
     (expand "sigma" 1 2)
     (name-replace "SUM" "sigma(0, 2 * n!1, atan_series_term(px!1))")
     (("1"
       (move-terms 1 l)
       (assert)
       (expand "atan_series_term")
       (expand "atan_series_coef")
       (expand "^")
       (expand "expt" 1 3)
       (expand "expt" 1 3)
       (expand "expt" 1 4)
       (case-replace "expt((-1), 1 + 2 * n!1)= -1")
       (("1"
         (hide -1)
         (cancel-by 1 "expt(px!1, 3 + 4 * n!1)")
         (hide -1 2)
         (case "5 > 3 * (px!1 * px!1)")
         (("1"
           (case "4 * n!1 >=  4 * (n!1 * px!1 * px!1)")
           (("1" (assert) (grind-reals))
            ("2"
             (hide -1 2)
             (cancel-by 1 "n!1")
             (cancel-by 2 "4")
             (rewrite "sq" :dir rl)
             (lemma "sq_le")
             (inst?)
             (rewrite "sq_1")
             (assert))))
          ("2"
           (hide 2)
           (rewrite "sq" :dir rl)
           (lemma "sq_le")
           (inst?)
           (assert))))
        ("2"
         (hide-all-but 1)
         (lemma "not_even_m1_pow")
         (inst -1 "1+2*n!1")
         (split -1)
         (("1" (expand "^" -1 1) (propax)) ("2" (hide 1) (grind))))))
      ("2" (skosimp*) (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "pi_lbn" :assert? none)
   (div-by 1 "4")
   (lemma "atan_pos_le1_lb_lt")
   (inst?)
   (lemma "atan_pos_le1_ub_lt")
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (case "forall(i,n:nat):pi_lbn(n) < pi_lbn(n+1+i)")
   (("1" (inst -1 "k-n-1" "n") (assert))
    ("2"
     (hide 2)
     (induct "i")
     (("1" (skosimp) (assert) (rewrite "pi_lbn_lt"))
      ("2"
       (skeep)
       (skosimp)
       (inst -1 "n!1+1")
       (lemma "pi_lbn_lt")
       (inst -1 "n!1")
       (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: closer bounds
script:
  (""
   (skosimp)
   (expand "pi_lbn")
   (expand "pi_ubn")
   (lemma "atan_1")
   (lemma "atan_pos_le1_bounds" ("x" "1/5" "n" "n!1"))
   (lemma "atan_pos_le1_bounds" ("x" "1/239" "n" "n!1"))
   (assert)
   (flatten)
   (expand "pi")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "pi_lbn")
   (lemma "atan_pos_le1_ub_dec" ("n" "n!1" "m" "m!1" "px" "1/239"))
   (lemma "atan_pos_le1_lb_inc" ("n" "n!1" "m" "m!1" "px" "1/5"))
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "pi_ubn")
   (assert)
   (lemma "atan_pos_le1_lb_inc" ("px" "1/239" "n" "n!1" "m" "m!1"))
   (lemma "atan_pos_le1_ub_dec" ("px" "1/5" "n" "n!1" "m" "m!1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "atan_pos_lb")
   (expand "atan_pos_ub")
   (case-replace "x!1<=1")
   (("1" (lemma "atan_pos_le1_bounds" ("x" "x!1" "n" "n!1")) (assert))
    ("2"
     (assert)
     (lemma "atan_inv" ("px" "x!1"))
     (lemma "pi_bounds" ("n" "n!1"))
     (lemma "atan_pos_le1_bounds" ("x" "1/x!1" "n" "n!1"))
     (rewrite "div_mult_pos_lt2" -1)
     (rewrite "div_mult_pos_le1" -1)
     (flatten)
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "atan_lb")
   (expand "atan_ub")
   (case-replace "x!1>0")
   (("1"
     (lemma "atan_pos_bounds" ("n" "n!1" "x" "x!1"))
     (assert)
     (flatten)
     (assert))
    ("2"
     (case-replace "x!1=0")
     (("1" (rewrite "atan_0") (assert))
      ("2"
       (lemma "atan_pos_bounds" ("n" "n!1" "x" "-x!1"))
       (assert)
       (rewrite "atan_neg")
       (flatten)
       (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "atan_pos_lb")
   (case-replace "px!1 <= 1")
   (("1"
     (lemma "atan_pos_le1_lb_inc" ("px" "px!1" "n" "n!1" "m" "m!1"))
     (assert))
    ("2"
     (assert)
     (case "1<px!1")
     (("1"
       (hide 1)
       (lemma "div_mult_pos_lt1" ("py" "px!1" "z" "1" "x" "1"))
       (assert)
       (lemma "atan_pos_le1_ub_dec" ("px" "1/px!1" "n" "n!1" "m" "m!1"))
       (assert)
       (lemma "pi_lb_inc" ("n" "n!1" "m" "m!1"))
       (assert))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "atan_pos_ub")
   (case-replace "px!1 <= 1")
   (("1"
     (lemma "atan_pos_le1_ub_dec" ("px" "px!1" "n" "n!1" "m" "m!1"))
     (assert))
    ("2"
     (assert)
     (case "1<px!1")
     (("1"
       (hide 1)
       (lemma "div_mult_pos_lt1" ("py" "px!1" "z" "1" "x" "1"))
       (assert)
       (lemma "atan_pos_le1_lb_inc" ("px" "1/px!1" "n" "n!1" "m" "m!1"))
       (assert)
       (lemma "pi_ub_dec" ("n" "n!1" "m" "m!1"))
       (assert))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (";;; Proof pi_lb_pi-1 for formula atan_approx.pi_lb_pi"
   ";;; developed with shostak decision procedures"
   (skosimp)
   (expand "pi_lbn")
   (expand "pi")
   (rewrite "atan_1")
   (lemma "atan_pos_le1_bounds" ("x" "1/5" "n" "n!1"))
   (lemma "atan_pos_le1_bounds" ("x" "1/239" "n" "n!1"))
   (assert)
   (flatten)
   (hide -1 -4)
   (expand "atan_pos_le1_ub")
   (expand "atan_pos_le1_lb")
   (lemma "atan_series" ("x" "1/5" "n" "2*n!1+1"))
   (expand "abs" -1 1)
   (assert)
   (lemma "atan_series" ("x" "1/239" "n" "2*n!1"))
   (expand "abs" -1 1)
   (lemma "expt_pos" ("px" "1/5" "i" "5+4*n!1"))
   (lemma "posreal_div_posreal_is_posreal"
    ("px" "(1 / 5) ^ (5 + 4 * n!1)" "py" "5 + 4 * n!1"))
   (expand "abs" -4)
   (lemma "expt_pos" ("px" "1/239" "i" "3+4*n!1"))
   (lemma "posreal_div_posreal_is_posreal"
    ("px" "(1 / 239) ^ (3 + 4 * n!1)" "py" "3 + 4 * n!1"))
   (expand "abs" -5)
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (";;; Proof pi_ub_pi-1 for formula atan_approx.pi_ub_pi"
   ";;; developed with shostak decision procedures"
   (skosimp)
   (expand "pi_ubn")
   (expand "pi")
   (rewrite "atan_1")
   (lemma "atan_pos_le1_bounds" ("x" "1/5" "n" "n!1"))
   (lemma "atan_pos_le1_bounds" ("x" "1/239" "n" "n!1"))
   (assert)
   (flatten)
   (hide -2 -3)
   (expand "atan_pos_le1_ub")
   (expand "atan_pos_le1_lb")
   (lemma "atan_series" ("x" "1/239" "n" "2*n!1+1"))
   (expand "abs" -1 1)
   (assert)
   (lemma "atan_series" ("x" "1/5" "n" "2*n!1"))
   (expand "abs" -1 1)
   (lemma "expt_pos" ("px" "1/239" "i" "5+4*n!1"))
   (lemma "posreal_div_posreal_is_posreal"
    ("px" "(1 / 239) ^ (5 + 4 * n!1)" "py" "5 + 4 * n!1"))
   (expand "abs" -4)
   (lemma "expt_pos" ("px" "1/5" "i" "3+4*n!1"))
   (lemma "posreal_div_posreal_is_posreal"
    ("px" "(1 / 5) ^ (3 + 4 * n!1)" "py" "3 + 4 * n!1"))
   (expand "abs" -5)
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "pi_lbn")
   (expand "atan_pos_le1_lb")
   (expand "atan_pos_le1_ub")
   (expand "atan_series_n")
   (name "SUM1" "sigma(0, 1 + 2 * n!1, atan_series_term(1 / 5))")
   (("1"
     (replace -1)
     (name "SUM2" "sigma(0, 2 * n!1, atan_series_term(1 / 239))")
     (replace -1)
     (expand "sigma" 1)
     (expand "sigma" 1)
     (replace -1)
     (replace -2)
     (assert)
     (expand "atan_series_term")
     (expand "atan_series_coef")
     (hide -1 -2)
     (lemma "expt_times" ("n0x" "-1" "i" "2" "j" "n!1+1"))
     (expand "^" -1 2)
     (expand "expt" -1)
     (expand "expt" -1)
     (expand "expt" -1)
     (rewrite "sq_rew")
     (rewrite "sq_neg")
     (rewrite "expt_1i")
     (replace -1)
     (assert)
     (lemma "expt_plus" ("n0x" "-1" "i" "2+2*n!1" "j" "1"))
     (replace -2)
     (rewrite "expt_x1")
     (replace -1)
     (lemma "expt_plus" ("n0x" "-1" "i" "1" "j" "2*n!1"))
     (rewrite "expt_x1")
     (lemma "expt_times" ("n0x" "-1" "i" "2" "j" "n!1"))
     (expand "^" -1 2)
     (expand "expt" -1)
     (expand "expt" -1)
     (expand "expt" -1)
     (rewrite "sq_rew")
     (rewrite "sq_neg")
     (rewrite "expt_1i")
     (replace -1)
     (replace -2)
     (hide-all-but 1)
     (lemma "expt_plus" ("n0x" "1/5" "i" "2" "j" "5+4*n!1"))
     (lemma "expt_plus" ("n0x" "1/239" "i" "2" "j" "3+4*n!1"))
     (expand "^" -1 2)
     (expand "^" -2 2)
     (expand "expt")
     (expand "expt")
     (expand "expt")
     (replace -1)
     (replace -2)
     (hide -1 -2)
     (assert)
     (name-replace "DRL1" "(1 / 239) ^ (3 + 4 * n!1)")
     (name-replace "DRL2" "(1 / 5) ^ (5 + 4 * n!1)")
     (assert)
     (case-replace
      "16 * ((1 / 5 * (1 / 5) * (-1 / (7 + 4 * n!1))) * DRL2) = -16*(DRL2 * (1 / (175 + 100 * n!1)))")
     (("1"
       (hide -1)
       (assert)
       (case-replace
        "-4 * (DRL1 * (-1 / (3 + 4 * n!1))) = 4 * (DRL1 * (1 / (3 + 4 * n!1)))")
       (("1"
         (hide -1)
         (assert)
         (assert)
         (lemma "both_sides_times1"
          ("n0z"
           "DRL1"
           "x"
           "-4 * ((1 / 239 * (1 / 239) * (1 / (5 + 4 * n!1))))"
           "y"
           "-4*(1 / (285605 + 228484 * n!1))"))
         (replace -1 1)
         (hide -1)
         (assert))
        ("2" (hide 2) (assert))))
      ("2"
       (hide 2)
       (assert)
       (grind)
       (lemma "both_sides_times1"
        ("n0z"
         "DRL2"
         "x"
         "16 * ((1 / 5 * (1 / 5) * (-1 / (7 + 4 * n!1))))"
         "y"
         "-16 *(1 / (175 + 100 * n!1))"))
       (replace -1 1)
       (hide -1)
       (assert))))
    ("2" (skosimp*) (assert))))


proof_type: j_proof
decl_type: tcc
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (case "pi_lbn(n) > 0")
   (("1" (assert))
    ("2"
     (hide 2)
     (case "pi_lbn(0) > 0")
     (("1"
       (lemma "pi_lbn_LT")
       (inst -1 "0" "n")
       (("1" (assert)) ("2" (assert))))
      ("2" (hide 2) (grind))))))


proof_type: j_proof
decl_type: tcc
library: trig
theory: atan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (case "pi_ubn(n) > 0")
   (("1" (assert))
    ("2"
     (hide 2)
     (lemma "pi_bounds")
     (inst?)
     (flatten)
     (lemma "pi_lb_pos")
     (inst?)
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: exp_term
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (induct "m")
   (("1"
     (skosimp)
     (rewrite "expt_x0")
     (expand "exp_term")
     (expand "abs")
     (assert))
    ("2"
     (skosimp*)
     (inst - "a!1" "n!1")
     (assert)
     (case "abs(exp_term(a!1)(n!1)) /= 0")
     (("1"
       (rewrite "expt_plus" 2)
       (rewrite "expt_x1" 2)
       (case "abs(exp_term(a!1)(j!1 * n!1 + n!1)) <= abs(exp_term(a!1)(n!1)) * abs(exp_term(a!1)(j!1 * n!1))")
       (("1"
         (assert)
         (lemma "both_sides_times_pos_le1"
          ("pz"
           "abs(exp_term(a!1)(n!1))"
           "x"
           "abs(exp_term(a!1)(j!1 * n!1))"
           "y"
           "abs(exp_term(a!1)(n!1)) ^ j!1"))
         (assert))
        ("2"
         (hide 3 -2)
         (expand "exp_term")
         (case-replace "n!1=0")
         (("1" (assert) (expand "abs") (assert))
          ("2"
           (assert)
           (case-replace "j!1=0")
           (("1" (assert) (expand "abs" 2 3) (assert))
            ("2"
             (assert)
             (rewrite "abs_mult" 3 :dir rl)
             (rewrite "div_times" 3)
             (rewrite "expt_plus" 3 :dir rl)
             (rewrite "abs_div" 3)
             (rewrite "abs_div" 3)
             (expand "abs" 3 4)
             (expand "abs" 3 2)
             (rewrite "abs_expt" 3 :dir rl)
             (case "abs(a!1)>0")
             (("1"
               (lemma "expt_pos" ("px" "abs(a!1)" "i" "(j!1+1)*n!1"))
               (("1"
                 (lemma "posreal_times_posreal_is_posreal"
                  ("px" "factorial(n!1)" "py" "factorial(j!1 * n!1)"))
                 (lemma "both_sides_div_pos_lt2"
                  ("px"
                   "factorial(j!1 * n!1 + n!1)"
                   "pz"
                   "abs(a!1) ^ (j!1 * n!1 + n!1)"
                   "py"
                   "factorial(n!1) * factorial(j!1 * n!1)"))
                 (("1"
                   (assert)
                   (hide 4 5 -2 -3 6)
                   (case "forall (pn,pm:posnat): factorial(pm)*factorial(pn) < factorial(pn+pm)")
                   (("1" (inst - "n!1" "j!1*n!1") (assert))
                    ("2"
                     (hide-all-but 1)
                     (induct "pn")
                     (("1" (assert)) ("2" (assert))
                      ("3"
                       (skosimp*)
                       (case-replace "j!2=0")
                       (("1"
                         (expand "factorial" 1 2)
                         (expand "factorial" 1 3)
                         (expand "factorial" 1 1)
                         (assert))
                        ("2"
                         (assert)
                         (inst - "pm!1")
                         (expand "factorial" 2 3)
                         (expand "factorial" 2 2)
                         (lemma "lt_times_lt_pos1"
                          ("px"
                           "factorial(pm!1) * factorial(j!2)"
                           "y"
                           "factorial(pm!1 + j!2)"
                           "nnz"
                           "1+j!2"
                           "w"
                           "1+j!2+pm!1"))
                         (assert))))))))
                  ("2" (assert))))
                ("2" (propax))))
              ("2"
               (expand "abs")
               (case-replace "a!1<0")
               (("1" (assert)) ("2" (assert))))))))))))
      ("2"
       (hide-all-but (1 2))
       (expand "exp_term")
       (case-replace "n!1=0")
       (("1" (expand "abs") (assert))
        ("2"
         (assert)
         (rewrite "abs_div")
         (expand "abs" -1 2)
         (rewrite "abs_expt" -1 :dir rl)
         (lemma "expt_nonzero" ("n0x" "abs(a!1)" "i" "n!1"))
         (("1" (assert))
          ("2"
           (expand "abs")
           (case-replace "a!1<0")
           (("1" (assert)) ("2" (assert))))))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: exp_term
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "exp_term")
   (case-replace "n!1=0")
   (("1"
     (expand "factorial")
     (expand "factorial")
     (rewrite "expt_x1")
     (expand "abs" 2 2)
     (assert))
    ("2"
     (assert)
     (rewrite "abs_div")
     (rewrite "abs_div")
     (expand "abs" 3 4)
     (expand "abs" 3 2)
     (rewrite "abs_expt" 3 :dir rl)
     (rewrite "abs_expt" 3 :dir rl)
     (case "0 < abs(a!1)")
     (("1"
       (rewrite "expt_plus" 3)
       (rewrite "expt_x1")
       (expand "factorial" 3 1)
       (lemma "both_sides_times_pos_lt1"
        ("x"
         "abs(a!1)/(1+n!1)"
         "y"
         "1"
         "pz"
         "abs(a!1) ^ n!1 / factorial(n!1)"))
       (("1"
         (rewrite "div_times" -1)
         (assert)
         (hide 4)
         (rewrite "div_mult_pos_lt1" 1))
        ("2"
         (lemma "expt_pos" ("px" "abs(a!1)" "i" "n!1"))
         (("1" (rewrite "div_mult_pos_gt1" 1) (assert))
          ("2" (assert))))))
      ("2"
       (expand "abs")
       (case "a!1<0")
       (("1" (assert)) ("2" (assert))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: exp_term
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "tends_to_0?")
   (skosimp)
   (case "EXISTS n: abs(exp_term(n0a!1)(n)) < 1")
   (("1"
     (skosimp)
     (name "N" "floor(abs(n0a!1)+1)")
     (lemma "floor_def" ("x" "abs(n0a!1)+1"))
     (replace -2)
     (flatten)
     (case "N>=1")
     (("1"
       (case "FORALL (px: posreal):
                     px < 1 IMPLIES (FORALL (py:posreal): EXISTS (n:posnat): px^n < py)")
       (("1"
         (case "0<abs(n0a!1)")
         (("1"
           (case "0<abs(exp_term(n0a!1)(n!1))")
           (("1"
             (inst - "abs(exp_term(n0a!1)(n!1))")
             (("1"
               (assert)
               (inst - "epsilon!1")
               (skosimp)
               (name "M" "max(N,n!2)*n!1")
               (inst + "M")
               (skosimp)
               (case "forall (n:nat): abs(exp_term(n0a!1)(M+n)) <= abs(exp_term(n0a!1)(M))")
               (("1"
                 (inst - "i!1-M")
                 (("1"
                   (assert)
                   (lemma "exp_term_power"
                    ("a" "n0a!1" "n" "n!1" "m" "max(N,n!2)"))
                   (replace -3)
                   (lemma "both_sides_expt_lt1_le"
                    ("lt1x"
                     "abs(exp_term(n0a!1)(n!1))"
                     "i"
                     "max(N,n!2)"
                     "j"
                     "n!2"))
                   (assert))
                  ("2"
                   (expand "M")
                   (expand "max")
                   (case-replace "N<=n!2")
                   (("1"
                     (assert)
                     (case-replace "N<n!2")
                     (("1" (assert)) ("2" (assert))))
                    ("2" (assert))))))
                ("2"
                 (hide 2 -4)
                 (induct "n")
                 (("1" (assert))
                  ("2"
                   (skosimp*)
                   (expand "exp_term")
                   (lemma "expt_plus"
                    ("n0x" "n0a!1" "i" "1" "j" "M+j!1"))
                   (rewrite "expt_x1")
                   (replace -1)
                   (hide -1)
                   (expand "factorial" 1 1)
                   (assert)
                   (case "M >=1")
                   (("1"
                     (assert)
                     (rewrite "abs_div" 1)
                     (rewrite "abs_div" 1)
                     (rewrite "abs_div" -2)
                     (expand "abs" -2 4)
                     (expand "abs" -2 2)
                     (expand "abs" 1 4)
                     (lemma "posreal_times_posreal_is_posreal"
                      ("px" "1+M+j!1" "py" "factorial(M + j!1)"))
                     (expand "abs" 1 2)
                     (assert)
                     (rewrite "abs_mult" 1)
                     (lemma "le_times_le_pos"
                      ("nnx"
                       "abs(n0a!1)/(1+M+j!1)"
                       "y"
                       "1"
                       "nnz"
                       "abs(n0a!1 ^ (M + j!1)) / factorial(M + j!1)"
                       "w"
                       "abs(n0a!1 ^ M) / factorial(M)"))
                     (assert)
                     (split -1)
                     (("1" (assert) (rewrite "div_times" -1) (assert))
                      ("2"
                       (hide -1 2)
                       (rewrite "div_mult_pos_le1" 1)
                       (expand "M")
                       (expand "max")
                       (case-replace "N<=n!2")
                       (("1"
                         (assert)
                         (lemma "le_times_le_pos"
                          ("nnx" "1" "y" "n!1" "nnz" "N" "w" "n!2"))
                         (assert)
                         (case-replace "N<n!2")
                         (("1" (assert)) ("2" (assert))))
                        ("2"
                         (assert)
                         (lemma "both_sides_times_pos_le1"
                          ("pz" "N" "x" "1" "y" "n!1"))
                         (assert))))))
                    ("2"
                     (expand "M")
                     (expand "max")
                     (case-replace "N<=n!2")
                     (("1"
                       (case-replace "N<n!2")
                       (("1"
                         (assert)
                         (case-replace "n!1=0")
                         (("1" (assert))
                          ("2"
                           (lemma "posreal_times_posreal_is_posreal"
                            ("px" "n!2" "py" "n!1"))
                           (("1" (assert)) ("2" (assert))))))
                        ("2"
                         (assert)
                         (case-replace "n!1=0")
                         (("1" (assert))
                          ("2"
                           (assert)
                           (lemma "posreal_times_posreal_is_posreal"
                            ("px" "N" "py" "n!1"))
                           (assert))))))
                      ("2"
                       (assert)
                       (lemma "posreal_times_posreal_is_posreal"
                        ("px" "N" "py" "n!1"))
                       (("1" (assert))
                        ("2"
                         (case-replace "n!1=0")
                         (("1" (assert)) ("2" (assert))))))))))))))
              ("2" (assert))))
            ("2"
             (hide-all-but (-1 1))
             (expand "exp_term")
             (rewrite "abs_div")
             (case-replace "n!1=0")
             (("1" (expand "abs") (assert)) ("2" (assert))))))
          ("2"
           (hide-all-but 1)
           (expand "abs")
           (case-replace "n0a!1 < 0")
           (("1" (assert)) ("2" (assert))))))
        ("2"
         (hide-all-but 1)
         (skosimp)
         (lemma "small_expt" ("px" "px!1"))
         (assert)
         (skosimp*)
         (inst - "py!1")
         (skosimp)
         (case-replace "n!2=0")
         (("1"
           (assert)
           (expand "expt")
           (inst + "1")
           (rewrite "expt_x1")
           (assert))
          ("2"
           (inst + "n!2")
           (("1" (expand "^") (propax)) ("2" (assert))))))))
      ("2" (assert))))
    ("2"
     (hide 2)
     (case "FORALL (n: nat, pn: posnat): pn ^ n <= factorial(pn + n)")
     (("1"
       (lemma "floor_def" ("x" "abs(n0a!1) + 1"))
       (flatten)
       (expand "exp_term")
       (name-replace "N" "floor(abs(n0a!1) + 1)")
       (case "N>=1")
       (("1"
         (assert)
         (inst + "2*N*N")
         (lemma "both_sides_times_pos_le1" ("pz" "N" "x" "1" "y" "N"))
         (assert)
         (rewrite "abs_div" 1)
         (expand "abs" 1 2)
         (rewrite "div_mult_pos_lt1" 1)
         (rewrite "abs_expt" 1 :dir rl)
         (rewrite "expt_times" 1)
         (inst - "N*N" "N*N")
         (lemma "both_sides_expt_pos_lt"
          ("px" "abs(n0a!1)^2" "py" "N*N" "pm" "N*N"))
         (assert)
         (hide 2 -5 -1)
         (expand "^")
         (expand "expt")
         (expand "expt")
         (expand "expt")
         (lemma "lt_times_lt_pos1"
          ("px" "abs(n0a!1)" "y" "N" "nnz" "abs(n0a!1)" "w" "N"))
         (assert))
        ("2" (assert))))
      ("2"
       (hide 2)
       (induct "n")
       (("1" (skosimp) (rewrite "expt_x0") (assert))
        ("2"
         (skosimp*)
         (inst - "pn!1")
         (rewrite "expt_plus")
         (expand "factorial" 1)
         (lemma "lt_times_lt_pos1"
          ("px"
           "pn!1 ^ j!1"
           "y"
           "factorial(pn!1 + j!1)"
           "nnz"
           "pn!1"
           "w"
           "1+j!1+pn!1"))
         (rewrite "expt_x1" 1)
         (assert))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "sin_term")
   (expand "^")
   (expand "expt" 1 2)
   (expand "expt" 1 2)
   (expand "expt" 1 1)
   (name-replace "X" "expt((-1), n!1) * expt(a!1, 1 + 2 * n!1)")
   (rewrite "cross_mult")
   (expand "factorial" 1 1)
   (expand "factorial" 1 1)
   (expand "factorial" 1 5)
   (typepred "factorial(1+2*n!1)")
   (name-replace "F" "factorial(1 + 2 * n!1)")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "sin_term")
   (case-replace "a!1=0")
   (("1"
     (expand "^")
     (name-replace "S" "expt((-1), n!1)")
     (expand "expt")
     (assert))
    ("2"
     (lemma "expt_plus" ("i" "1" "j" "2*n!1"))
     (inst-cp - "a!1")
     (("1"
       (inst - "-a!1")
       (("1"
         (replace -1)
         (replace -2)
         (rewrite "expt_x1")
         (rewrite "expt_x1")
         (lemma "expt_times" ("i" "2" "j" "n!1"))
         (inst-cp - "a!1")
         (("1"
           (inst - "-a!1")
           (("1"
             (case-replace "(-a!1) ^ 2 = a!1 ^ 2")
             (("1" (assert)) ("2" (hide-all-but (1 2)) (grind))))
            ("2" (assert))))
          ("2" (assert))))
        ("2" (assert))))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "sin_term")
   (rewrite "div_mult_pos_gt1" 2)
   (rewrite "div_mult_pos_lt1" 2)
   (rewrite "zero_times1")
   (rewrite "expt_plus" 2)
   (rewrite "expt_x1")
   (name-replace "S" "(-1)^n!1")
   (lemma "both_sides_times_neg_lt1"
    ("nz" "-1" "x" "S * a!1 ^ (3 + 2 * n!1)" "y" "0"))
   (replace -1 2)
   (hide -1)
   (expand ">")
   (lemma "trichotomy" ("x" "S"))
   (split -1)
   (("1"
     (lemma "both_sides_times_pos_lt1" ("pz" "S" "x" "0"))
     (("1"
       (rewrite "zero_times1" -1)
       (inst-cp - "a!1 ^ (1 + 2 * n!1)")
       (assert)
       (replace -2 2)
       (inst - "a!1 ^ (3 + 2 * n!1)")
       (replace -1 2)
       (hide -1 -2)
       (hide -1)
       (expand "^")
       (expand "expt" 2 1)
       (expand "expt" 2 1)
       (case-replace "0 < expt(a!1, (1 + 2 * n!1))")
       (("1"
         (assert)
         (lemma "posreal_times_posreal_is_posreal"
          ("px" "a!1*a!1" "py" "expt(a!1, 1 + 2 * n!1)"))
         (("1" (assert))
          ("2"
           (hide -1 3)
           (lemma "trichotomy" ("x" "a!1"))
           (split -1)
           (("1"
             (lemma "both_sides_times_pos_lt1"
              ("pz" "a!1" "x" "0" "y" "a!1"))
             (("1" (assert)) ("2" (assert))))
            ("2" (assert))
            ("3"
             (lemma "both_sides_times_neg_lt1"
              ("nz" "a!1" "x" "0" "y" "a!1"))
             (("1" (assert)) ("2" (assert))))))))
        ("2"
         (assert)
         (case "0 <a!1*a!1")
         (("1"
           (lemma "both_sides_times_pos_lt1"
            ("pz" "a!1*a!1" "x" "0" "y" "expt(a!1, 1 + 2 * n!1)"))
           (assert))
          ("2"
           (hide -1 2)
           (lemma "trichotomy" ("x" "a!1"))
           (split -1)
           (("1"
             (lemma "both_sides_times_pos_lt1"
              ("pz" "a!1" "x" "0" "y" "a!1"))
             (("1" (assert)) ("2" (assert))))
            ("2" (assert))
            ("3"
             (lemma "both_sides_times_neg_lt1"
              ("nz" "a!1" "x" "0" "y" "a!1"))
             (("1" (assert)) ("2" (assert))))))))))
      ("2" (assert))))
    ("2"
     (expand "S" -1)
     (lemma "expt_nonzero" ("n0x" "-1" "i" "n!1"))
     (assert))
    ("3"
     (lemma "both_sides_times_neg_lt1" ("nz" "S" "x" "0"))
     (("1"
       (inst-cp - "a!1 ^ (1 + 2 * n!1)")
       (inst - "a!1 ^ (3 + 2 * n!1)")
       (assert)
       (replace -1)
       (replace -2)
       (hide -1 -2 -3)
       (case "0<a!1*a!1")
       (("1"
         (expand "^")
         (expand "expt" 2 1)
         (expand "expt" 2 1)
         (lemma "both_sides_times_pos_lt1"
          ("pz" "a!1*a!1" "x" "expt(a!1, 1 + 2 * n!1)" "y" "0"))
         (("1"
           (assert)
           (replace -1 2 rl)
           (rewrite "zero_times1")
           (hide -1 -2)
           (case-replace "expt(a!1, 1 + 2 * n!1) * (a!1 * a!1) < 0")
           (("1" (assert)) ("2" (assert))))
          ("2" (assert))))
        ("2"
         (hide 3)
         (lemma "trichotomy" ("x" "a!1"))
         (split -1)
         (("1"
           (lemma "both_sides_times_pos_lt1"
            ("pz" "a!1" "x" "0" "y" "a!1"))
           (("1" (assert)) ("2" (assert))))
          ("2" (assert))
          ("3"
           (lemma "both_sides_times_neg_lt1"
            ("nz" "a!1" "x" "0" "y" "a!1"))
           (("1" (assert)) ("2" (assert))))))))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "sin_term")
   (skosimp*)
   (rewrite "div_cancel3")
   (lemma "expt_nonzero" ("n0x" "-1" "i" "n!1"))
   (split)
   (("1"
     (flatten)
     (replace -1)
     (expand "^" 1 2)
     (expand "expt")
     (assert))
    ("2"
     (flatten)
     (rewrite "zero_times1")
     (rewrite "zero_times3")
     (lemma "expt_nonzero" ("n0x" "a!1" "i" "1+2*n!1"))
     (("1" (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "sin_term_nonzero" ("a" "a!1" "n" "n!1"))
   (assert)
   (split)
   (("1" (flatten) (assert)) ("2" (flatten) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "sin_term")
   (skosimp)
   (case-replace "a!1=0")
   (("1" (expand "^" 1 2) (expand "expt") (assert))
    ("2"
     (rewrite "expt_plus")
     (rewrite "expt_x1")
     (rewrite "expt_times")
     (lemma "expt_pos" ("px" "a!1^2" "i" "n!1"))
     (("1"
       (lemma "posreal_div_posreal_is_posreal"
        ("px" "(a!1 ^ 2) ^ n!1" "py" "factorial(1 + 2 * n!1)"))
       (("1"
         (lemma "both_sides_times_pos_gt1"
          ("pz"
           "(a!1 ^ 2) ^ n!1 / factorial(1 + 2 * n!1)"
           "x"
           "(-1)^n!1*a!1"
           "y"
           "0"))
         (("1"
           (rewrite "zero_times1")
           (replace -1 2)
           (hide-all-but (1 2))
           (case "forall (n:nat): (-1)^(2*n) =1")
           (("1"
             (lemma "trichotomy" ("x" "a!1"))
             (split -1)
             (("1"
               (assert)
               (split 2)
               (("1"
                 (flatten)
                 (lemma "even_or_odd")
                 (inst - "n!1")
                 (assert)
                 (hide 1 2)
                 (expand "odd?")
                 (skosimp)
                 (replace -1)
                 (rewrite "expt_plus")
                 (rewrite "expt_x1")
                 (inst - "j!1")
                 (("1" (assert)) ("2" (assert))))
                ("2"
                 (flatten)
                 (expand "even?")
                 (skosimp)
                 (inst - "j!1")
                 (("1" (assert)) ("2" (assert))))))
              ("2" (propax))
              ("3"
               (assert)
               (split 2)
               (("1"
                 (flatten)
                 (lemma "even_or_odd" ("x" "n!1"))
                 (assert)
                 (hide 1)
                 (expand "even?")
                 (skosimp)
                 (inst - "j!1")
                 (("1" (assert)) ("2" (assert))))
                ("2"
                 (flatten)
                 (expand "odd?")
                 (skosimp)
                 (replace -1)
                 (rewrite "expt_plus")
                 (rewrite "expt_x1")
                 (inst - "j!1")
                 (("1" (assert)) ("2" (assert))))))))
            ("2"
             (hide-all-but 1)
             (skosimp)
             (rewrite "expt_times")
             (expand "^" 1 1)
             (expand "expt")
             (expand "expt")
             (expand "expt")
             (rewrite "expt_1i"))))
          ("2" (assert))))
        ("2" (assert))))
      ("2"
       (hide-all-but (1 2))
       (lemma "pos_times_lt" ("x" "a!1" "y" "a!1"))
       (grind))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "trichotomy" ("x" "a!1"))
   (split -1)
   (("1"
     (assert)
     (lemma "sin_term_gt0" ("a" "a!1" "n" "n!1"))
     (assert)
     (rewrite "even_or_odd")
     (split 1)
     (("1" (flatten) (assert))
      ("2"
       (flatten)
       (assert)
       (lemma "sin_term_nonzero" ("a" "a!1" "n" "n!1"))
       (assert))))
    ("2"
     (replace -1)
     (assert)
     (lemma "sin_term_zero" ("a" "0" "n" "n!1"))
     (assert))
    ("3"
     (assert)
     (lemma "sin_term_gt0" ("a" "a!1" "n" "n!1"))
     (assert)
     (rewrite "even_or_odd")
     (split 1)
     (("1" (flatten) (assert))
      ("2"
       (flatten)
       (assert)
       (lemma "sin_term_nonzero" ("a" "a!1" "n" "n!1"))
       (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (case-replace "a!1=0")
   (("1"
     (hide -1)
     (expand "tends_to_0?")
     (skosimp)
     (inst + "0")
     (skosimp)
     (expand "sin_term")
     (expand "^" 1 2)
     (assert)
     (expand "expt" 1)
     (rewrite "abs_div")
     (expand "abs")
     (assert))
    ("2"
     (lemma "exp_tends_to_0" ("n0a" "a!1"))
     (("1"
       (expand "exp_term")
       (expand "sin_term")
       (expand "tends_to_0?")
       (skosimp*)
       (inst - "epsilon!1")
       (skosimp)
       (inst + "1+2*n!1")
       (skosimp)
       (inst - "1+2*i!1")
       (assert)
       (rewrite "abs_div")
       (rewrite "abs_div")
       (rewrite "abs_mult")
       (case-replace "abs((-1) ^ i!1) = 1")
       (("1" (assert))
        ("2"
         (hide-all-but 1)
         (case "(-1)^2 =1")
         (("1"
           (case "even?(i!1)")
           (("1"
             (expand "even?")
             (skosimp)
             (replace -1)
             (rewrite "expt_times")
             (replace -2)
             (rewrite "expt_1i")
             (expand "abs")
             (propax))
            ("2"
             (rewrite "even_or_odd")
             (expand "odd?")
             (skosimp)
             (replace -1)
             (rewrite "expt_plus")
             (rewrite "expt_times")
             (replace -2)
             (rewrite "expt_x1")
             (rewrite "expt_1i")
             (expand "abs")
             (assert))))
          ("2" (hide 2) (grind))))))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "cos_term")
   (case-replace "n!1=0")
   (("1"
     (assert)
     (rewrite "expt_x1")
     (expand "factorial")
     (expand "factorial")
     (expand "factorial")
     (expand "^")
     (expand "expt")
     (expand "expt")
     (expand "expt")
     (grind))
    ("2"
     (assert)
     (rewrite "expt_plus" 2)
     (name-replace "S" "(-1)^n!1")
     (rewrite "expt_x1")
     (expand "factorial" 2 1)
     (expand "factorial" 2 2)
     (expand "factorial" 2 1)
     (case-replace "a!1=0")
     (("1" (expand "^") (expand "expt") (assert))
      ("2"
       (rewrite "expt_plus" 3)
       (typepred "factorial(2*n!1)")
       (name-replace "F" "factorial(2*n!1)")
       (expand "^" 3 1)
       (expand "expt")
       (expand "expt")
       (expand "expt")
       (rewrite "cross_mult"))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "cos_term")
   (skosimp)
   (case-replace "n!1=0")
   (assert)
   (case-replace "a!1=0")
   (("1" (assert))
    ("2"
     (lemma "expt_times" ("i" "2" "j" "n!1"))
     (inst-cp - "a!1")
     (inst - "-a!1")
     (case-replace "(-a!1) ^ 2 = a!1 ^ 2")
     (("1" (assert)) ("2" (hide-all-but (1 2)) (grind))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "cos_term")
   (case-replace "n!1=0")
   (("1"
     (assert)
     (rewrite "expt_x1")
     (expand "factorial")
     (expand "factorial")
     (expand "factorial")
     (case "a!1^2>0")
     (("1" (assert))
      ("2"
       (hide -1 3)
       (lemma "trichotomy" ("x" "a!1"))
       (split -1)
       (("1"
         (lemma "both_sides_times_pos_lt1"
          ("pz" "a!1" "x" "0" "y" "a!1"))
         (("1" (grind)) ("2" (assert))))
        ("2" (assert))
        ("3"
         (lemma "both_sides_times_neg_lt1"
          ("nz" "a!1" "x" "0" "y" "a!1"))
         (("1" (grind)) ("2" (assert))))))))
    ("2"
     (assert)
     (expand "^")
     (expand "expt" 3 2)
     (expand "expt" 3 2)
     (expand "expt" 3 1)
     (name-replace "S" "expt((-1), n!1) * expt(a!1, (2 * n!1))")
     (case "a!1*a!1>0")
     (("1"
       (assert)
       (rewrite "div_mult_pos_gt1" 3)
       (rewrite "div_mult_pos_lt1" 3)
       (rewrite "zero_times1")
       (lemma "trichotomy" ("x" "S"))
       (split -1)
       (("1"
         (assert)
         (lemma "both_sides_times_pos_lt1"
          ("pz" "S" "x" "-1*(a!1*a!1)" "y" "0"))
         (assert))
        ("2"
         (expand "S" -1)
         (lemma "expt_nonzero" ("n0x" "-1" "i" "n!1"))
         (lemma "expt_nonzero" ("n0x" "a!1" "i" "2*n!1"))
         (expand "^")
         (assert))
        ("3"
         (lemma "both_sides_times_neg_lt1"
          ("nz" "S" "x" "-1*(a!1*a!1)" "y" "0"))
         (("1" (assert)) ("2" (assert))))))
      ("2"
       (hide 2 4)
       (lemma "trichotomy" ("x" "a!1"))
       (split -1)
       (("1"
         (lemma "both_sides_times_pos_lt1"
          ("pz" "a!1" "x" "0" "y" "a!1"))
         (("1" (assert)) ("2" (assert))))
        ("2" (assert))
        ("3"
         (lemma "both_sides_times_neg_lt1"
          ("nz" "a!1" "x" "0" "y" "a!1"))
         (("1" (assert)) ("2" (assert))))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1"
     (flatten)
     (replace -1)
     (expand "cos_term")
     (assert)
     (expand "^" 1)
     (expand "expt")
     (assert))
    ("2"
     (flatten)
     (split -1)
     (("1" (replace -1) (expand "cos_term") (assert))
      ("2"
       (assert)
       (expand "cos_term")
       (case-replace "n!1=0")
       (("1" (assert))
        ("2"
         (assert)
         (lemma "expt_nonzero" ("n0x" "a!1" "i" "2*n!1"))
         (assert)
         (lemma "expt_nonzero" ("n0x" "-1" "i" "n!1"))
         (lemma "div_cancel3"
          ("x"
           "(-1) ^ n!1 * a!1 ^ (2 * n!1)"
           "n0z"
           "factorial(2 * n!1)"
           "y"
           "0"))
         (replace -1 -5)
         (hide -1)
         (rewrite "zero_times3" -4))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "cos_term_nonzero" ("a" "a!1" "n" "n!1"))
   (split)
   (("1" (flatten) (assert) (flatten) (assert)) ("2" (flatten) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "cos_term")
   (case-replace "n!1=0")
   (("1" (assert))
    ("2"
     (assert)
     (rewrite "div_mult_pos_gt1")
     (rewrite "zero_times1")
     (split)
     (("1"
       (flatten)
       (expand ">")
       (rewrite "pos_times_lt" -1)
       (case-replace "a!1=0")
       (("1" (expand "^") (expand "expt") (propax))
        ("2"
         (assert)
         (case "a!1^2 > 0")
         (("1"
           (lemma "expt_pos" ("px" "a!1^2" "i" "n!1"))
           (("1"
             (rewrite "expt_times")
             (assert)
             (hide -1 -2 1)
             (rewrite "even_or_odd" 1)
             (expand "odd?")
             (skosimp)
             (replace -2)
             (hide -2 1)
             (rewrite "expt_plus")
             (rewrite "expt_times")
             (rewrite "expt_x1")
             (case-replace "(-1) ^ 2 = 1")
             (("1" (rewrite "expt_1i") (assert))
              ("2" (hide -1) (grind))))
            ("2" (assert))))
          ("2"
           (hide-all-but (1 2))
           (expand "^")
           (expand "expt")
           (expand "expt")
           (expand "expt")
           (lemma "pos_times_lt" ("x" "a!1" "y" "a!1"))
           (assert)
           (flatten)
           (lemma "trichotomy" ("x" "a!1"))
           (split -1)
           (("1" (assert)) ("2" (propax)) ("3" (assert))))))))
      ("2"
       (flatten)
       (case-replace "(-1)^n!1=1")
       (("1"
         (rewrite "expt_times")
         (lemma "expt_pos" ("px" "a!1^2" "i" "n!1"))
         (("1" (propax))
          ("2"
           (hide-all-but (1 2))
           (expand "^")
           (expand "expt")
           (expand "expt")
           (expand "expt")
           (lemma "pos_times_lt" ("x" "a!1" "y" "a!1"))
           (assert)
           (flatten)
           (lemma "trichotomy" ("x" "a!1"))
           (split -1)
           (("1" (assert)) ("2" (propax)) ("3" (assert))))))
        ("2"
         (hide-all-but (-1 1))
         (expand "even?")
         (skosimp)
         (replace -1 1)
         (hide -1)
         (rewrite "expt_times")
         (case-replace "(-1)^2 =1")
         (("1" (rewrite "expt_1i")) ("2" (hide 2) (grind))))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "cos_term")
   (case-replace "n!1=0")
   (("1" (assert) (expand "odd?") (propax))
    ("2"
     (assert)
     (case-replace "a!1=0")
     (("1" (assert) (expand "^") (expand "expt") (assert))
      ("2"
       (assert)
       (case "(-1) ^ n!1 < 0 IFF odd?(n!1)")
       (("1"
         (lemma "both_sides_times_pos_lt1"
          ("x"
           "(-1) ^ n!1"
           "pz"
           "a!1 ^ (2 * n!1) / factorial(2 * n!1)"
           "y"
           "0"))
         (("1"
           (replace -2 -1)
           (rewrite "zero_times1")
           (assert)
           (split 3)
           (("1" (flatten) (assert)) ("2" (flatten) (assert))))
          ("2"
           (case "a!1^2>0")
           (("1"
             (lemma "expt_pos" ("px" "a!1^2" "i" "n!1"))
             (("1"
               (rewrite "expt_times" 1)
               (assert)
               (lemma "posreal_div_posreal_is_posreal"
                ("px" "(a!1 ^ 2) ^ n!1" "py" "factorial(2 * n!1)"))
               (assert))
              ("2" (assert))))
            ("2"
             (hide-all-but (1 3))
             (lemma "pos_times_lt" ("x" "a!1" "y" "a!1"))
             (grind))))))
        ("2"
         (hide-all-but 1)
         (case "forall (n:nat): (-1)^(2*n) = 1")
         (("1"
           (split)
           (("1"
             (flatten)
             (lemma "even_or_odd")
             (inst - "n!1")
             (assert)
             (hide 1)
             (expand "even?")
             (skosimp)
             (inst - "j!1")
             (("1" (assert)) ("2" (assert))))
            ("2"
             (flatten)
             (expand "odd?")
             (skosimp)
             (replace -1)
             (rewrite "expt_plus" 1)
             (rewrite "expt_x1" 1)
             (inst - "j!1")
             (("1" (assert)) ("2" (assert))))))
          ("2"
           (hide 2)
           (skosimp)
           (rewrite "expt_times")
           (expand "^" 1 1)
           (expand "expt")
           (expand "expt")
           (expand "expt")
           (rewrite "expt_1i"))))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "cos_term")
   (lemma "exp_tends_to_0" ("n0a" "n0x!1"))
   (expand "exp_term")
   (expand "tends_to_0?")
   (skosimp*)
   (inst - "epsilon!1")
   (skosimp)
   (inst + "2*n!1")
   (skosimp)
   (inst - "2*i!1")
   (assert)
   (case-replace "i!1=0")
   (("1" (assert))
    ("2"
     (assert)
     (rewrite "abs_div")
     (rewrite "abs_div")
     (rewrite "abs_mult")
     (case-replace "abs((-1) ^ i!1) = 1")
     (("1" (assert))
      ("2"
       (hide-all-but 1)
       (case "(-1)^2 = 1")
       (("1"
         (case "even?(i!1)")
         (("1"
           (expand "even?")
           (skosimp)
           (replace -1)
           (rewrite "expt_times")
           (replace -2)
           (rewrite "expt_1i")
           (expand "abs")
           (propax))
          ("2"
           (rewrite "even_or_odd")
           (expand "odd?")
           (skosimp)
           (replace -1)
           (rewrite "expt_plus")
           (rewrite "expt_times")
           (replace -2)
           (rewrite "expt_x1")
           (rewrite "expt_1i")
           (expand "abs")
           (propax))))
        ("2" (assert) (hide 2) (grind))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "sin_approx")
   (expand "sin_term")
   (expand "^" 1 2)
   (expand "expt")
   (induct "n")
   (("1" (expand "sigma") (assert))
    ("2" (skosimp*) (expand "sigma" 1) (assert))
    ("3" (skosimp*) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "sin_approx")
   (induct "n")
   (("1"
     (expand "sigma")
     (expand "sin_term")
     (skosimp)
     (rewrite "expt_x1")
     (rewrite "expt_x1")
     (assert))
    ("2"
     (skosimp*)
     (expand "sigma" 1)
     (inst - "a!1")
     (replace -1)
     (assert)
     (hide -1)
     (expand "sin_term")
     (assert)
     (case-replace "(-a!1) ^ (3 + 2 * j!1) = - a!1 ^ (3 + 2 * j!1)")
     (("1" (assert))
      ("2"
       (hide 2)
       (lemma "expt_plus" ("i" "1" "j" "2*j!1+2"))
       (case-replace "a!1=0")
       (("1" (expand "^" 1) (expand "expt" 1) (assert))
        ("2"
         (inst-cp - "-a!1")
         (("1"
           (inst - "a!1")
           (("1"
             (rewrite "expt_x1")
             (rewrite "expt_x1")
             (replace -1)
             (replace -2)
             (hide -1 -2)
             (lemma "expt_times" ("i" "2" "j" "1+j!1"))
             (inst-cp - "a!1")
             (("1"
               (inst - "-a!1")
               (("1"
                 (replace -1)
                 (replace -2)
                 (case-replace "(-a!1) ^ 2 = a!1 ^ 2")
                 (("1" (assert))
                  ("2"
                   (hide-all-but (1 2))
                   (expand "^")
                   (expand "expt")
                   (expand "expt")
                   (expand "expt")
                   (assert))))
                ("2" (assert))))
              ("2" (assert))))
            ("2" (assert))))
          ("2" (assert))))))))
    ("3" (skosimp*) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "sin_approx")
   (expand "sigma" 1 1)
   (expand "sigma" 1 1)
   (expand "sin_term")
   (expand "^")
   (expand "expt" 1 1)
   (name-replace "S" "expt((-1), 1 + n!1)")
   (expand "expt" 1 1)
   (expand "expt" 1 1)
   (name-replace "AA" "expt(a!1, 3 + 2 * n!1)")
   (rewrite "div_times")
   (assert)
   (expand "factorial" 1 1)
   (expand "factorial" 1 2)
   (expand "factorial" 1 1)
   (name-replace "DRL100"
    "(20 * factorial(3 + 2 * n!1) +
                18 * (factorial(3 + 2 * n!1) * n!1)
                + 4 * (factorial(3 + 2 * n!1) * n!1 * n!1))")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "sin_approx_next" ("a" "a!1" "n" "n!1"))
   (replace -2)
   (lemma "div_simp" ("n0x" "(2 * n!1 + 5) * (2 * n!1 + 4)"))
   (replace -1)
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "sin_series" ("x" "a!1" "n" "n!1"))
   (expand "sin_term")
   (case "forall (n:nat): sin_series_n(a!1, n) = sin_approx(a!1, n)")
   (("1"
     (inst - "n!1")
     (replace -1 -2)
     (hide -1)
     (rewrite "abs_div")
     (rewrite "abs_mult")
     (expand "abs" 1 4)
     (case-replace "abs((-1) ^ (1 + n!1)) = 1")
     (("1" (assert))
      ("2"
       (hide-all-but 1)
       (case "(-1)^2 =1")
       (("1"
         (case "even?(1+n!1)")
         (("1"
           (expand "even?")
           (skosimp)
           (replace -1)
           (rewrite "expt_times")
           (replace -2)
           (rewrite "expt_1i")
           (expand "abs")
           (propax))
          ("2"
           (rewrite "even_or_odd")
           (expand "odd?")
           (skosimp)
           (replace -1)
           (rewrite "expt_plus")
           (rewrite "expt_times")
           (replace -2)
           (rewrite "expt_1i")
           (rewrite "expt_x1")
           (expand "abs")
           (assert))))
        ("2"
         (hide 2)
         (expand "^")
         (expand "expt")
         (expand "expt")
         (expand "expt")
         (assert))))))
    ("2"
     (hide-all-but 1)
     (expand "sin_series_n")
     (expand "sin_approx")
     (expand "sin_term")
     (expand "sin_series_term")
     (induct "n")
     (("1" (expand "sigma") (expand "sigma") (propax))
      ("2"
       (skosimp*)
       (expand "sigma" 1)
       (replace -1 1 rl)
       (hide -1)
       (lemma "sigma_eq"
        ("low"
         "0"
         "high"
         "j!1"
         "F"
         "LAMBDA (i: nat):
                       IF i > 1 + j!1 THEN 0
                       ELSE ((-1) ^ i * a!1 ^ (1 + 2 * i)) / factorial(1 + 2 * i)
                       ENDIF"
         "G"
         "LAMBDA (i: nat):
                        IF i > j!1 THEN 0
                        ELSE ((-1) ^ i * a!1 ^ (1 + 2 * i)) / factorial(1 + 2 * i)
                        ENDIF"))
       (assert))
      ("3" (skosimp*) (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "cos_approx")
   (expand "cos_term")
   (induct "n")
   (("1" (expand "sigma") (expand "sigma") (propax))
    ("2"
     (skosimp*)
     (expand "sigma" 1)
     (expand "^" 1 4)
     (expand "expt")
     (assert))
    ("3" (skosimp*) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "cos_approx")
   (induct "n")
   (("1"
     (expand "sigma")
     (expand "cos_term")
     (skosimp*)
     (expand "sigma")
     (propax))
    ("2"
     (skosimp*)
     (expand "sigma" 1)
     (inst - "a!1")
     (replace -1)
     (assert)
     (hide -1)
     (expand "cos_term")
     (case-replace "a!1=0")
     (("1" (assert))
      ("2"
       (lemma "expt_times" ("i" "2" "j" "1+j!1"))
       (inst-cp - "a!1")
       (inst - "-a!1")
       (case-replace "(-a!1) ^ 2 = a!1 ^ 2")
       (("1" (assert)) ("2" (hide-all-but (1 2)) (grind))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "cos_series" ("x" "a!1" "n" "n!1"))
   (expand "cos_term")
   (rewrite "abs_div")
   (expand "abs" 1 3)
   (rewrite "abs_mult")
   (case-replace "abs((-1)^(1+n!1))=1")
   (("1"
     (case "forall (n:nat): cos_series_n(a!1, n) = cos_approx(a!1, n)")
     (("1" (inst - "n!1") (assert))
      ("2"
       (hide-all-but 1)
       (expand "cos_approx")
       (expand "cos_series_n")
       (expand "cos_series_term")
       (expand "cos_term")
       (induct "n")
       (("1" (expand "sigma") (expand "sigma") (propax))
        ("2"
         (skosimp*)
         (expand "sigma" 1)
         (replace -1 1 rl)
         (hide -1)
         (lemma "sigma_eq"
          ("low"
           "0"
           "high"
           "j!1"
           "F"
           "LAMBDA (i: nat):
                         IF i > 1 + j!1 THEN 0
                         ELSE IF i = 0 THEN 1
                              ELSE (-1) ^ i * a!1 ^ (2 * i) / factorial(2 * i)
                              ENDIF
                         ENDIF"
           "G"
           "LAMBDA (i: nat):
                          IF i > j!1 THEN 0
                          ELSE IF i = 0 THEN 1
                               ELSE (-1) ^ i * a!1 ^ (2 * i) / factorial(2 * i)
                               ENDIF
                          ENDIF"))
         (assert))
        ("3" (skosimp*) (assert))))))
    ("2"
     (hide-all-but 1)
     (case "(-1)^2=1")
     (("1"
       (case "even?(1+n!1)")
       (("1"
         (expand "even?")
         (skosimp)
         (replace -1)
         (rewrite "expt_times")
         (replace -2)
         (rewrite "expt_1i")
         (expand "abs")
         (propax))
        ("2"
         (rewrite "even_or_odd")
         (expand "odd?")
         (skosimp*)
         (replace -1)
         (rewrite "expt_plus")
         (rewrite "expt_times")
         (rewrite "expt_x1")
         (replace -2)
         (rewrite "expt_1i")
         (expand "abs")
         (assert))))
      ("2"
       (hide 2)
       (expand "^")
       (expand "expt")
       (expand "expt")
       (expand "expt")
       (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "cos_approx")
   (expand "sigma" 1 1)
   (expand "sigma" 1 1)
   (expand "cos_term")
   (expand "^")
   (expand "expt" 1 1)
   (name-replace "S" "expt((-1), 1 + n!1)")
   (expand "expt" 1 1)
   (expand "expt" 1 1)
   (name-replace "AA" "expt(a!1, 2 + 2 * n!1)")
   (expand "factorial" 1 1)
   (expand "factorial" 1 2)
   (expand "factorial" 1 1)
   (rewrite "div_times")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "cos_approx_next" ("a" "a!1" "n" "n!1"))
   (replace -2 -1)
   (lemma "div_simp" ("n0x" "(2 * n!1 + 4) * (2 * n!1 + 3)"))
   (replace -1)
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "sin_lb")
   (expand "sin_ub")
   (skosimp)
   (lemma "trichotomy" ("x" "a!1"))
   (split -1)
   (("1" (assert) (rewrite "sin_approx_neg"))
    ("2"
     (replace -1)
     (assert)
     (rewrite "sin_approx_a0")
     (rewrite "sin_approx_a0")
     (assert))
    ("3" (assert) (rewrite "sin_approx_neg"))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "sin_lb")
   (expand "sin_ub")
   (lift-if)
   (case-replace "n0x!1 < 0")
   (("1"
     (expand "sin_approx")
     (expand "sigma" 1 2)
     (lemma "sin_term_gt0" ("a" "n0x!1" "n" "1+2*n!1"))
     (assert))
    ("2"
     (assert)
     (expand "sin_approx")
     (expand "sigma" 2 1)
     (lemma "sin_term_lt0" ("a" "n0x!1" "n" "1+2*n!1"))
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (case "FORALL (n: nat, px: posreal):
                 px * px < (4 * n + 7) * (4 * n + 6) =>
                  sin_lb(px, n) < sin_lb(px, n + 1)")
   (("1"
     (induct "pm" 1)
     (("1" (assert)) ("2" (assert))
      ("3"
       (skosimp*)
       (case-replace "j!1=0")
       (("1" (inst - "n!1" "px!1") (assert))
        ("2"
         (inst - "n!1" "px!1")
         (assert)
         (inst - "1+n!1" "px!1")
         (assert))))))
    ("2"
     (hide 2)
     (skosimp)
     (expand "sin_lb")
     (lemma "sin_approx_next" ("a" "px!1" "n" "1+2*n!1"))
     (lemma "div_mult_pos_lt1"
      ("z" "px!1 * px!1" "py" "(4 * n!1 + 7) * (4 * n!1 + 6)" "x" "1"))
     (replace -1 -3 rl)
     (hide -1)
     (name-replace "TT" "px!1 * px!1 / ((4 * n!1 + 7) * (4 * n!1 + 6))")
     (lemma "sin_term_gt0" ("a" "px!1" "n" "2*(1+n!1)"))
     (assert)
     (name-replace "ST" "sin_term(px!1)(2 + 2 * n!1)")
     (lemma "both_sides_times_pos_lt1" ("pz" "ST" "x" "0" "y" "1-TT"))
     (("1" (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (case "FORALL (n: nat, px: posreal):
                        px * px < (4 * n + 5) * (4 * n + 4) =>
                         sin_ub(px, n + 1) < sin_ub(px, n)")
   (("1"
     (induct "pm")
     (("1" (assert)) ("2" (assert))
      ("3"
       (skosimp*)
       (case-replace "j!1=0")
       (("1" (inst - "n!1" "px!1") (assert))
        ("2"
         (inst - "n!1" "px!1")
         (assert)
         (inst - "n!1+1" "px!1")
         (assert))))))
    ("2"
     (hide 2)
     (skosimp)
     (expand "sin_ub")
     (lemma "sin_approx_next" ("a" "px!1" "n" "2*n!1"))
     (lemma "div_mult_pos_lt1"
      ("z" "px!1 * px!1" "py" "(4 * n!1 + 5) * (4 * n!1 + 4)" "x" "1"))
     (name-replace "TT" "px!1 * px!1 / ((4 * n!1 + 5) * (4 * n!1 + 4))")
     (assert)
     (hide -3)
     (lemma "sin_term_lt0" ("a" "px!1" "n" "1+2*n!1"))
     (assert)
     (name-replace "ST" "sin_term(px!1)(1 + 2 * n!1)")
     (lemma "both_sides_times_neg_lt1" ("nz" "ST" "y" "0" "x" "1-TT"))
     (("1" (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (name "EPS" "sin_ub(px!1,n!1+1) - sin_lb(px!1,n!1)")
   (case "sin_term(px!1)(2*(n!1+1)) = EPS")
   (("1"
     (lemma "sin_term_gt0" ("a" "px!1" "n" "2*(n!1+1)"))
     (replace -2)
     (simplify -1)
     (lemma "sin_approx_sin" ("a" "px!1"))
     (expand "sin_lb")
     (expand "sin_ub")
     (name-replace "SN" "sin_approx(px!1, 1 + 2 * n!1)")
     (inst - "2*(n!1+1)")
     (name-replace "SN2" "sin_approx(px!1, 2 * (n!1 + 1))")
     (rewrite "sin_term_next" -1)
     (replace -3)
     (name-replace "M" "(4 * n!1 + 7) * (4 * n!1 + 6)")
     (rewrite "abs_div")
     (rewrite "abs_mult")
     (rewrite "abs_mult")
     (rewrite "abs_mult")
     (expand "abs" -1)
     (assert)
     (lemma "div_mult_pos_lt1" ("z" "px!1*px!1" "py" "M" "x" "1"))
     (assert)
     (lemma "both_sides_times_pos_lt1"
      ("pz" "EPS" "x" "px!1 * px!1 / M" "y" "1"))
     (assert))
    ("2"
     (hide 2 -2)
     (expand "sin_ub")
     (expand "sin_lb")
     (expand "sin_approx")
     (expand "sigma" -1 1)
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "sin_ub_dec" ("px" "px!1" "n" "n!1" "pm" "1"))
   (replace -2)
   (lemma "sin_lb_ub" ("n0x" "px!1" "n" "n!1+1"))
   (expand "sin_lb")
   (lemma "sin_approx_sin" ("a" "px!1" "n" "3+2*n!1"))
   (lemma "sin_term_neg" ("a" "px!1" "n" "3+2*n!1"))
   (simplify -1)
   (name-replace "S" "sin(px!1)")
   (case "sin_ub(px!1, 1 + n!1) - sin_approx(px!1, 3 + 2 * n!1) = -sin_term(px!1)(3+2*n!1)")
   (("1"
     (name-replace "SN" "sin_ub(px!1, n!1)")
     (name-replace "SN1" "sin_ub(px!1, n!1+1)")
     (name-replace "SN3" "sin_approx(px!1, 2*n!1+3)")
     (rewrite "sin_term_next" -3)
     (name-replace "ST" "sin_term(px!1)(3 + 2 * n!1)")
     (rewrite "abs_div")
     (rewrite "abs_mult")
     (rewrite "abs_mult")
     (rewrite "abs_mult")
     (expand "abs" -3)
     (assert)
     (lemma "div_mult_pos_lt1"
      ("z"
       "px!1*px!1"
       "py"
       "72 + 36 * n!1 + (16 * (n!1 * n!1) + 32 * n!1)"
       "x"
       "1"))
     (lemma "both_sides_times_pos_lt1"
      ("pz"
       "-ST"
       "x"
       "px!1 * px!1 / (72 + 36 * n!1 + (16 * (n!1 * n!1) + 32 * n!1))"
       "y"
       "1"))
     (assert))
    ("2"
     (hide-all-but 1)
     (expand "sin_ub")
     (expand "sin_approx")
     (expand "sigma" 1 2)
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (induct "n")
   (("1"
     (skosimp)
     (expand "sin_lb")
     (expand "sin_approx")
     (expand "sigma")
     (expand "sin_term")
     (expand "sigma")
     (rewrite "expt_x0")
     (rewrite "expt_x1")
     (rewrite "expt_x1")
     (expand "factorial")
     (expand "factorial")
     (expand "factorial")
     (expand "factorial")
     (assert)
     (case "px!1<=6")
     (("1"
       (lemma "le_times_le_pos"
        ("nnx" "px!1" "y" "6" "nnz" "px!1" "w" "6"))
       (assert))
      ("2"
       (case "6<px!1")
       (("1"
         (hide 1)
         (case "1-px!1*px!1/6 < -6")
         (("1"
           (lemma "both_sides_times_pos_lt1"
            ("pz" "px!1" "x" "1 - px!1 * px!1 / 6" "y" "-6"))
           (assert)
           (expand "^")
           (expand "expt")
           (expand "expt")
           (expand "expt")
           (expand "expt")
           (assert)
           (expand "sigma")
           (assert))
          ("2"
           (hide 2)
           (lemma "both_sides_div_pos_lt1"
            ("pz" "6" "x" "42" "y" "px!1*px!1"))
           (assert))))
        ("2" (assert))))))
    ("2"
     (skosimp*)
     (inst - "px!1")
     (assert)
     (expand "sin_lb")
     (lemma "sin_approx_next" ("a" "px!1" "n" "1+2*j!1"))
     (lemma "div_mult_pos_gt1"
      ("z"
       "px!1*px!1"
       "py"
       "110 + 44 * j!1 + (16 * (j!1 * j!1) + 40 * j!1)"
       "x"
       "1"))
     (assert)
     (name-replace "SN" "sin_approx(px!1, 1 + 2 * j!1)")
     (name-replace "SN2" "sin_approx(px!1, 3 + 2 * j!1)")
     (lemma "sin_term_gt0" ("a" "px!1" "n" "2*(1+j!1)"))
     (assert)
     (name-replace "ST" "sin_term(px!1)(2 + 2 * j!1)")
     (case "1-px!1 * px!1 / (42 + 28 * j!1 + (16 * (j!1 * j!1) + 24 * j!1))<0")
     (("1"
       (lemma "both_sides_times_pos_lt1"
        ("pz"
         "ST"
         "x"
         "1 - px!1 * px!1 / (42 + 28 * j!1 + (16 * (j!1 * j!1) + 24 * j!1))"
         "y"
         "0"))
       (("1"
         (assert)
         (assert)
         (name-replace "TT"
          "(px!1 * px!1 / (42 + 16 * (j!1 * j!1) + 52 * j!1))")
         (assert))
        ("2" (assert))))
      ("2"
       (hide 2 -1 -3 -4)
       (hide -1)
       (lemma "div_mult_pos_gt1"
        ("z"
         "px!1*px!1"
         "py"
         "(42 + 28 * j!1 + (16 * (j!1 * j!1) + 24 * j!1))"
         "x"
         "1"))
       (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (induct "n")
   (("1"
     (skosimp)
     (expand "sin_ub")
     (expand "sin_approx")
     (expand "sigma")
     (expand "sin_term")
     (rewrite "expt_x0")
     (rewrite "expt_x1")
     (expand "factorial")
     (expand "factorial")
     (case "px!1<=4")
     (("1"
       (lemma "le_times_le_pos"
        ("nnx" "px!1" "y" "4" "nnz" "px!1" "w" "4"))
       (assert))
      ("2" (assert))))
    ("2"
     (skosimp*)
     (inst - "px!1")
     (assert)
     (expand "sin_ub")
     (lemma "sin_approx_next" ("a" "px!1" "n" "2*j!1"))
     (name-replace "SN" "sin_approx(px!1, 2 * j!1)")
     (name-replace "SN2" "sin_approx(px!1, 2 * j!1+2)")
     (lemma "sin_term_lt0" ("a" "px!1" "n" "1+2*j!1"))
     (simplify -1)
     (name-replace "ST" "sin_term(px!1)(1 + 2 * j!1)")
     (lemma "negreal_times_negreal_is_posreal"
      ("nx"
       "ST"
       "ny"
       "1 - px!1 * px!1 / ((2 * (2 * j!1) + 5) * (2 * (2 * j!1) + 4))"))
     (("1" (assert))
      ("2"
       (hide -1 -2 -3 2)
       (lemma "div_mult_pos_gt1"
        ("z"
         "px!1*px!1"
         "py"
         "20 + 20 * j!1 + (16 * (j!1 * j!1) + 16 * j!1)"
         "x"
         "1"))
       (assert))
      ("3" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "trichotomy" ("x" "n0x!1"))
   (split -1)
   (("1"
     (lemma "trich_lt" ("x" "n0x!1*n0x!1" "y" "(4*n!1+7)*(4*n!1+6)"))
     (split -1)
     (("1"
       (lemma "sin_lb_lt" ("px" "n0x!1" "n" "n!1"))
       (("1" (assert)) ("2" (assert))))
      ("2"
       (case-replace "sin_lb(n0x!1,n!1)=sin_lb(n0x!1,n!1+1)")
       (("1"
         (lemma "sin_lb_lt" ("px" "n0x!1" "n" "n!1+1"))
         (("1" (assert)) ("2" (assert))))
        ("2"
         (hide 2)
         (expand "sin_lb")
         (assert)
         (lemma "sin_approx_eq" ("a" "n0x!1" "n" "1+2*n!1"))
         (assert))))
      ("3"
       (lemma "sin_lb_gt" ("px" "n0x!1" "n" "n!1"))
       (("1" (typepred "sin(n0x!1)") (assert)) ("2" (assert))))))
    ("2" (assert))
    ("3"
     (lemma "sin_neg" ("a" "n0x!1"))
     (lemma "both_sides_times_neg_lt1"
      ("nz" "-1" "y" "sin_lb(n0x!1, n!1)" "x" "sin(n0x!1)"))
     (replace -1 1 rl)
     (replace -2 1 rl)
     (lemma "sin_ub_neg" ("a" "n0x!1" "n" "n!1"))
     (replace -1 1 rl)
     (hide -1 -2 -3)
     (lemma "trich_lt" ("x" "-n0x!1*-n0x!1" "y" "(4*n!1+5)*(4*n!1+4)"))
     (split -1)
     (("1"
       (lemma "sin_ub_lt" ("px" "-n0x!1" "n" "n!1"))
       (("1" (assert)) ("2" (assert))))
      ("2"
       (lemma "sin_ub_lt" ("px" "-n0x!1" "n" "n!1+1"))
       (("1"
         (assert)
         (case-replace "sin_ub(-n0x!1, 1 + n!1) = sin_ub(-n0x!1, n!1)")
         (hide -1 2)
         (expand "sin_ub")
         (lemma "sin_approx_eq" ("a" "-n0x!1" "n" "2*n!1"))
         (assert))
        ("2" (assert))))
      ("3"
       (lemma "sin_ub_gt" ("px" "-n0x!1" "n" "n!1"))
       (("1" (assert)) ("2" (assert))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "trichotomy" ("x" "n0x!1"))
   (split -1)
   (("1"
     (lemma "sin_lb" ("n0x" "-n0x!1" "n" "n!1"))
     (rewrite "sin_lb_neg")
     (rewrite "sin_neg")
     (lemma "both_sides_times_neg_lt1"
      ("nz" "-1" "y" "sin(n0x!1)" "x" "sin_ub(n0x!1, n!1)"))
     (assert))
    ("2" (assert))
    ("3"
     (lemma "sin_lb" ("n0x" "-n0x!1" "n" "n!1"))
     (rewrite "sin_neg")
     (rewrite "sin_lb_neg")
     (lemma "both_sides_times_neg_lt1"
      ("nz" "-1" "y" "sin(n0x!1)" "x" "sin_ub(n0x!1, n!1)"))
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (case-replace "a!1=0")
   (("1"
     (rewrite "sin_0")
     (expand "sin_lb")
     (expand "sin_ub")
     (rewrite "sin_approx_a0")
     (rewrite "sin_approx_a0")
     (assert))
    ("2"
     (lemma "sin_lb" ("n0x" "a!1" "n" "n!1"))
     (("1" (lemma "sin_ub" ("n0x" "a!1" "n" "n!1")) (assert))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (case "sin_lb(px!1,0) > 0")
   (("1"
     (case-replace "n!1=0")
     (lemma "sin_lb_inc" ("px" "px!1" "n" "0" "pm" "n!1"))
     (("1" (assert)) ("2" (assert))))
    ("2"
     (hide 2)
     (expand "sin_lb")
     (expand "sin_approx")
     (expand "sigma")
     (expand "sigma")
     (expand "sin_term")
     (expand "^")
     (expand "expt")
     (expand "expt")
     (expand "expt")
     (expand "expt")
     (expand "factorial")
     (expand "factorial")
     (expand "factorial")
     (expand "factorial")
     (lemma "posreal_times_posreal_is_posreal"
      ("px" "px!1/6" "py" "6-px!1*px!1"))
     (("1" (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "cos_lb")
   (expand "cos_ub")
   (expand "cos_approx")
   (expand "sigma" 1 1)
   (lemma "cos_term_lt0" ("a" "n0x!1" "n" "1+2*n!1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (case "FORALL (n: nat, n0x: nzreal):
                               n0x * n0x < (4 * n + 6) * (4 * n + 5) =>
                                cos_lb(n0x, n) < cos_lb(n0x, n + 1)")
   (("1"
     (induct "pm")
     (("1" (assert)) ("2" (assert))
      ("3"
       (skosimp*)
       (inst - "n!1" "n0x!1")
       (replace -3)
       (case-replace "j!1=0")
       (("1" (assert))
        ("2" (assert) (inst - "n!1+1" "n0x!1") (assert))))))
    ("2"
     (hide 2)
     (skosimp)
     (expand "cos_lb")
     (lemma "cos_approx_next" ("a" "n0x!1" "n" "1+2*n!1"))
     (lemma "cos_term_gt0" ("a" "n0x!1" "n" "2*(1+n!1)"))
     (simplify -1)
     (name-replace "CT" "cos_term(n0x!1)(2 + 2 * n!1)")
     (name-replace "CN" "cos_approx(n0x!1, 1 + 2 * n!1)")
     (name-replace "CN2" "cos_approx(n0x!1, 3 + 2 * n!1)")
     (lemma "div_mult_pos_lt1"
      ("z" "n0x!1*n0x!1" "py" "(4 * n!1 + 6) * (4 * n!1 + 5)" "x" "1"))
     (name-replace "TT"
      "n0x!1 * n0x!1 / ((4 * n!1 + 6) * (4 * n!1 + 5))")
     (assert)
     (lemma "posreal_times_posreal_is_posreal" ("px" "CT" "py" "1-TT"))
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (case "FORALL (n: nat, n0x: nzreal):
                        n0x * n0x < (4 * n + 4) * (4 * n + 3) =>
                         cos_ub(n0x, n + 1) < cos_ub(n0x, n)")
   (("1"
     (induct "pm")
     (("1" (assert)) ("2" (assert))
      ("3"
       (skosimp*)
       (inst - "n!1" "n0x!1")
       (case-replace "j!1=0")
       (("1" (assert))
        ("2" (assert) (inst - "n!1+1" "n0x!1") (assert))))))
    ("2"
     (hide 2)
     (skosimp)
     (expand "cos_ub")
     (lemma "cos_approx_next" ("a" "n0x!1" "n" "2*n!1"))
     (lemma "div_mult_pos_lt1"
      ("z" "n0x!1 * n0x!1" "py" "(4 * n!1 + 4) * (4 * n!1 + 3)" "x" "1"))
     (lemma "cos_term_lt0" ("a" "n0x!1" "n" "1+2*n!1"))
     (name-replace "TT"
      "n0x!1 * n0x!1 / ((4 * n!1 + 4) * (4 * n!1 + 3))")
     (name-replace "CT" "cos_term(n0x!1)(1 + 2 * n!1)")
     (assert)
     (lemma "both_sides_times_pos_lt1" ("pz" "1-TT" "x" "CT" "y" "0"))
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "cos_lb_inc" ("n0x" "n0x!1" "n" "n!1" "pm" "1"))
   (replace -2 -1)
   (lemma "cos_lb_ub" ("n0x" "n0x!1" "n" "n!1+1"))
   (expand "cos_lb")
   (expand "cos_ub")
   (lemma "cos_approx_next" ("a" "n0x!1" "n" "1 + 2 * n!1"))
   (lemma "cos_term_gt0" ("a" "n0x!1" "n" "2*(1+n!1)"))
   (simplify -1)
   (lemma "cos_approx_cos" ("a" "n0x!1" "n" "2*(1+n!1)"))
   (name-replace "CC" "cos(n0x!1)")
   (rewrite "cos_term_next" -1)
   (case "cos_approx(n0x!1, 2 + 2 * n!1) - cos_approx(n0x!1, 3 + 2 * n!1) = -cos_term(n0x!1)(3 + 2 * n!1)")
   (("1"
     (name-replace "CN1" "cos_approx(n0x!1, 1 + 2 * n!1)")
     (name-replace "CN2" "cos_approx(n0x!1, 2 + 2 * n!1)")
     (name-replace "CN3" "cos_approx(n0x!1, 3 + 2 * n!1)")
     (rewrite "cos_term_next" -1)
     (name-replace "CT" "cos_term(n0x!1)(2 + 2 * n!1)")
     (lemma "div_mult_pos_lt1"
      ("z" "n0x!1 * n0x!1" "py" "(4 * n!1 + 6) * (4 * n!1 + 5)" "x" "1"))
     (replace -8 -1)
     (simplify -1)
     (name-replace "M" "(4 * n!1 + 6) * (4 * n!1 + 5)")
     (case-replace
      "-1 * (CT * n0x!1 * n0x!1) / M = -CT*((n0x!1 * n0x!1) / M)")
     (("1"
       (lemma "posreal_div_posreal_is_posreal"
        ("px" "n0x!1*n0x!1" "py" "M"))
       (name-replace "TT" "n0x!1 * n0x!1 / M")
       (rewrite "abs_mult" -5)
       (expand "abs" -5)
       (case-replace "CC - CN2 < 0")
       (("1" (assert)) ("2" (assert))))
      ("2" (assert))))
    ("2"
     (hide-all-but 1)
     (expand "cos_approx")
     (expand "sigma" 1 2)
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "cos_ub_dec" ("n0x" "n0x!1" "n" "n!1" "pm" "1"))
   (replace -2 -1)
   (lemma "cos_lb_ub" ("n0x" "n0x!1" "n" "n!1+1"))
   (case "cos_ub(n0x!1, n!1 + 1) - cos_lb(n0x!1, n!1+1) = -cos_term(n0x!1)(3+2*n!1)")
   (("1"
     (lemma "cos_approx_cos" ("a" "n0x!1" "n" "2*n!1+3"))
     (expand "cos_lb")
     (name-replace "CC" "cos(n0x!1)")
     (name-replace "CN3" "cos_approx(n0x!1, 2 * n!1 + 3)")
     (rewrite "cos_term_next" -1)
     (lemma "cos_term_neg" ("a" "n0x!1" "n" "3+2*n!1"))
     (simplify -1)
     (name-replace "CT" "cos_term(n0x!1)(3 + 2 * n!1)")
     (lemma "div_mult_pos_lt1"
      ("z"
       "n0x!1 * n0x!1"
       "py"
       "(56 + 32 * n!1 + (16 * (n!1 * n!1) + 28 * n!1))"
       "x"
       "1"))
     (assert)
     (lemma "posreal_div_posreal_is_posreal"
      ("px" "n0x!1 * n0x!1" "py" "(56 + 16 * (n!1 * n!1) + 60 * n!1)"))
     (case-replace
      "(-1 * (CT * n0x!1 * n0x!1) /
                  (56 + 32 * n!1 + (16 * (n!1 * n!1) + 28 * n!1))) = -CT*((n0x!1 * n0x!1) /
                  (56 + 32 * n!1 + (16 * (n!1 * n!1) + 28 * n!1)))")
     (("1"
       (name-replace "TT"
        "((n0x!1 * n0x!1) / (56 + 32 * n!1 + (16 * (n!1 * n!1) + 28 * n!1)))")
       (hide -1)
       (rewrite "abs_mult" -4)
       (expand "abs" -4)
       (assert)
       (lemma "both_sides_times_pos_lt1" ("pz" "-CT" "x" "TT" "y" "1"))
       (assert))
      ("2" (assert))))
    ("2"
     (hide-all-but 1)
     (expand "cos_ub")
     (expand "cos_lb")
     (expand "cos_approx")
     (expand "sigma" 1 2)
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (induct "n")
   (("1"
     (skosimp)
     (expand "cos_lb")
     (expand "cos_approx")
     (expand "sigma")
     (expand "sigma")
     (expand "cos_term")
     (rewrite "expt_x1")
     (expand "factorial")
     (expand "factorial")
     (expand "factorial")
     (expand "^")
     (expand "expt")
     (expand "expt")
     (expand "expt")
     (assert)
     (expand "sigma")
     (assert))
    ("2"
     (skosimp*)
     (expand "cos_lb")
     (inst - "n0x!1")
     (lemma "cos_approx_next" ("a" "n0x!1" "n" "1+2*j!1"))
     (name-replace "CN1" "cos_approx(n0x!1, 1 + 2 * j!1)")
     (name-replace "CN3" "cos_approx(n0x!1, 3 + 2 * j!1)")
     (lemma "cos_term_gt0" ("a" "n0x!1" "n" "2*(1+j!1)"))
     (simplify -1)
     (name-replace "CT" "cos_term(n0x!1)(1 + 2 * j!1 + 1)")
     (assert)
     (lemma "div_mult_pos_gt1"
      ("z"
       "n0x!1*n0x!1"
       "py"
       "(30 + 24 * j!1 + (16 * (j!1 * j!1) + 20 * j!1))"
       "x"
       "1"))
     (assert)
     (name-replace "TT"
      "n0x!1 * n0x!1 / (30 + 16 * (j!1 * j!1) + 44 * j!1)")
     (lemma "both_sides_times_pos_lt1" ("pz" "CT" "x" "1-TT" "y" "0"))
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (case "FORALL (n: nat, px: posreal):
                                             px * px > (4 * n + 4) * (4 * n + 3) & n >= 1 => cos_ub(px, n) > 1")
   (("1"
     (skosimp)
     (lemma "trichotomy" ("x" "n0x!1"))
     (split -1)
     (("1" (inst - "n!1" "n0x!1") (("1" (assert)) ("2" (assert))))
      ("2" (assert))
      ("3"
       (inst - "n!1" "-n0x!1")
       (("1" (assert) (expand "cos_ub") (rewrite "cos_approx_neg"))
        ("2" (assert))))))
    ("2"
     (hide 2)
     (induct "n")
     (("1" (skosimp) (assert))
      ("2"
       (skosimp*)
       (case-replace "j!1=0")
       (("1"
         (assert)
         (hide -1 -2 -4)
         (expand "cos_ub")
         (expand "cos_approx")
         (expand "sigma")
         (expand "sigma")
         (expand "sigma")
         (expand "cos_term")
         (expand "factorial")
         (expand "factorial")
         (expand "factorial")
         (expand "factorial")
         (expand "factorial")
         (rewrite "expt_x1")
         (lemma "expt_times" ("n0x" "px!1" "i" "2" "j" "2"))
         (case-replace "px!1^2=px!1*px!1")
         (("1"
           (replace -2)
           (name-replace "X" "px!1 * px!1")
           (hide -1 -2)
           (expand "^")
           (expand "expt")
           (expand "expt")
           (expand "expt")
           (lemma "posreal_times_posreal_is_posreal"
            ("px" "X" "py" "X/24-1/2"))
           (("1" (assert) (expand "sigma") (assert))
            ("2"
             (hide 2)
             (lemma "both_sides_times_pos_lt1"
              ("pz" "24" "x" "0" "y" "X / 24 - 1 / 2"))
             (assert))))
          ("2" (hide-all-but 1) (grind))))
        ("2"
         (inst - "px!1")
         (expand "cos_ub")
         (lemma "cos_approx_next" ("a" "px!1" "n" "2*j!1"))
         (lemma "cos_term_lt0" ("a" "px!1" "n" "2*j!1+1"))
         (simplify -1)
         (name-replace "CT" "cos_term(px!1)(1 + 2 * j!1)")
         (lemma "div_mult_pos_gt1"
          ("z" "px!1*px!1" "py" "(4*j!1+4)*(4*j!1+3)" "x" "1"))
         (name-replace "TT"
          "px!1 * px!1 / ((4 * j!1 + 4) * (4 * j!1 + 3))")
         (assert)
         (lemma "negreal_times_negreal_is_posreal"
          ("nx" "CT" "ny" "1-TT"))
         (assert))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "trich_lt" ("x" "n0x!1*n0x!1" "y" "(4*n!1+6)*(4*n!1+5)"))
   (split -1)
   (("1" (lemma "cos_lb_lt" ("n0x" "n0x!1" "n" "n!1")) (assert))
    ("2"
     (lemma "cos_lb_lt" ("n0x" "n0x!1" "n" "n!1+1"))
     (case-replace "cos_lb(n0x!1, n!1 + 1) = cos_lb(n0x!1, n!1)")
     (("1" (assert))
      ("2"
       (hide 2 -1)
       (expand "cos_lb")
       (lemma "cos_approx_eq" ("a" "n0x!1" "n" "1+2*n!1"))
       (assert))))
    ("3" (lemma "cos_lb_gt" ("n0x" "n0x!1" "n" "n!1")) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "trich_lt" ("x" "n0x!1*n0x!1" "y" "(4*pm!1+4)*(4*pm!1+3)"))
   (split -1)
   (("1" (lemma "cos_ub_lt" ("n0x" "n0x!1" "n" "pm!1")) (assert))
    ("2"
     (lemma "cos_ub_lt" ("n0x" "n0x!1" "n" "pm!1+1"))
     (case-replace "cos_ub(n0x!1, pm!1 + 1) = cos_ub(n0x!1, pm!1)")
     (("1" (assert))
      ("2"
       (hide -1 2)
       (expand "cos_ub")
       (lemma "cos_approx_eq" ("a" "n0x!1" "n" "2*pm!1"))
       (assert))))
    ("3"
     (lemma "cos_ub_gt" ("n0x" "n0x!1" "n" "pm!1"))
     (typepred "cos(n0x!1)")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (case-replace "a!1=0")
   (("1"
     (rewrite "cos_0")
     (expand "cos_lb")
     (expand "cos_ub")
     (rewrite "cos_approx_a0")
     (rewrite "cos_approx_a0")
     (assert))
    ("2"
     (lemma "cos_lb" ("n0x" "a!1" "n" "n!1"))
     (("1"
       (assert)
       (hide -1)
       (case "n!1=0")
       (("1"
         (expand "cos_ub")
         (expand "cos_approx")
         (replace -1)
         (expand "sigma")
         (expand "cos_term")
         (typepred "cos(a!1)")
         (expand "sigma")
         (propax))
        ("2"
         (lemma "cos_ub" ("n0x" "a!1" "pm" "n!1"))
         (("1" (assert)) ("2" (assert))))))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (expand "strict_decreasing?")
   (skosimp*)
   (typepred "x!1")
   (typepred "y!1")
   (expand ">=")
   (expand "<=" -3)
   (split -3)
   (("1"
     (lemma "cos_lb_deriv" ("n" "n!1"))
     (flatten)
     (lemma "restrict2_derivable[{x: posreal | x <= pi},real]"
      ("f" "LAMBDA a: cos_lb(a, n!1)"))
     (("1"
       (lemma "restrict2_deriv[{x: posreal | x <= pi},real]"
        ("f" "LAMBDA a: cos_lb(a, n!1)"))
       (expand "restrict2")
       (replace -4)
       (simplify -1)
       (lemma "negative_derivative[{x:posreal | x <= pi}]"
        ("g" "LAMBDA (a:{x:posreal | x <= pi}): cos_lb(a, n!1)"))
       (("1"
         (split -1)
         (("1"
           (expand "strict_decreasing?")
           (inst - "x!1" "y!1")
           (("1" (assert)) ("2" (assert)) ("3" (assert))))
          ("2"
           (skosimp)
           (inst - "x!2")
           (expand "deriv" -1)
           (replace -1 1 rl)
           (hide-all-but 1)
           (typepred "x!2")
           (lemma "sin_ub" ("n0x" "x!2" "n" "n!1"))
           (lemma "sin_ge_0" ("a" "x!2"))
           (assert))))
        ("2" (propax))))
      ("2" (propax)) ("3" (hide-all-but 1) (skosimp) (inst 1 "x!2"))
      ("4" (hide-all-but 1) (skosimp) (inst 1 "x!2+1") (assert))
      ("5"
       (hide-all-but 1)
       (skosimp)
       (typepred "x!2")
       (case-replace "x!2=pi")
       (("1" (inst + "pi/2") (assert)) ("2" (inst + "pi") (assert))))
      ("6" (hide-all-but 1) (skosimp*) (assert))))
    ("2"
     (replace -1 * rl)
     (lemma "cos_lb" ("n0x" "y!1" "n" "n!1"))
     (("1"
       (typepred "cos(y!1)")
       (expand "cos_lb")
       (rewrite "cos_approx_a0")
       (assert))
      ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "cos_lb_nn_strict_decreasing" ("n" "n!1"))
   (expand "strict_decreasing?")
   (expand "strict_increasing?")
   (skosimp)
   (inst - "-y!1" "-x!1")
   (assert)
   (rewrite "cos_lb_neg")
   (rewrite "cos_lb_neg"))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "sin_lb" ("n0x" "px!1" "n" "0"))
   (expand "sin_lb")
   (expand "sin_approx")
   (expand "sigma")
   (expand "sigma")
   (expand "sin_term")
   (expand "^")
   (expand "expt")
   (expand "expt")
   (expand "expt")
   (expand "expt")
   (expand "factorial")
   (expand "factorial")
   (expand "factorial")
   (expand "factorial")
   (case "1 - 1 / 1500000 < 1-px!1*px!1/6")
   (("1"
     (lemma "both_sides_times_pos_lt1"
      ("pz" "px!1" "x" "1 - 1 / 1500000" "y" "1 - px!1 * px!1 / 6"))
     (assert))
    ("2"
     (hide -1 2)
     (lemma "sq_lt" ("nna" "px!1" "nnb" "1/500"))
     (assert)
     (expand "sq")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (rewrite "sin_shift" :dir rl)
   (lemma "pi_lb_diff" ("n" "n!1"))
   (lemma "pi_lb_inc" ("n" "n!1" "m" "n!1+1"))
   (simplify -1)
   (lemma "pi_bounds" ("n" "n!1+1"))
   (flatten)
   (hide -2)
   (name "KK"
         "16 * (1 / 5) ^ (4 * n!1 + 5) *
                                                    (1 / (4 * n!1 + 5) - 1 / (25 * (4 * n!1 + 7)))
                                                    +
                                                    4 * (1 / 239) ^ (4 * n!1 + 3) *
                                                     (1 / (4 * n!1 + 3) - 1 / (57121 * (4 * n!1 + 5)))")
   (replace -1)
   (case "pi / 2 - pi_lbn(n!1) / 2 > KK / 2")
   (("1"
     (case "pi / 2 - pi_lbn(n!1) / 2 < 1/500")
     (("1"
       (lemma "sin_px" ("px" "pi / 2 - pi_lbn(n!1) / 2"))
       (("1"
         (split -1)
         (("1"
           (case "cos_term(pi_lbn(n!1) / 2)(2 * n!1 + 2) < KK/2 * (1 - 1 / 1500000)")
           (("1" (assert))
            ("2"
             (hide 2)
             (hide -1)
             (name "F"
                   "lambda (n:nat): 8 * (1 / 5) ^ (4 * n + 5) *
                                                                                                               (1 / (4 * n + 5) - 1 / (25 * (4 * n + 7)))
                                                                                                               +
                                                                                                               2 * (1 / 239) ^ (4 * n + 3) *
                                                                                                                (1 / (4 * n + 3) - 1 / (57121 * (4 * n + 5)))")
             (case-replace "KK/2=F(n!1)")
             (("1"
               (hide -1 -2 -5)
               (expand "cos_term")
               (case-replace "(-1) ^ (2 + 2 * n!1)=1")
               (("1"
                 (lemma "both_sides_expt_pos_lt"
                  ("px"
                   "pi_lbn(n!1) / 2"
                   "py"
                   "31415927/20000000"
                   "pm"
                   "4 + 4 * n!1"))
                 (assert)
                 (lemma "pi_ub")
                 (assert)
                 (name "G"
                       "lambda (n:nat): (31415927 / 20000000) ^ (4 + 4 * n)/factorial(4 + 4 * n)")
                 (case "(1 * (pi_lbn(n!1) / 2) ^ (4 + 4 * n!1)) / factorial(4 + 4 * n!1) <G(n!1)")
                 (("1"
                   (case "forall (m:nat): m>=5 => G(m)<F(m)*(1 - 1 / 1500000)")
                   (("1"
                     (inst - "n!1")
                     (assert)
                     (name-replace "DRL1"
                      "(1 * (pi_lbn(n!1) / 2) ^ (4 + 4 * n!1)) / factorial(4 + 4 * n!1)")
                     (assert))
                    ("2"
                     (hide-all-but 1)
                     (case "G(5) < F(5) * (1 - 1 / 1500000)")
                     (("1"
                       (case "FORALL (m: nat): m >= 5 & G(m) < F(m) * (1 - 1 / 1500000) => G(m+1) < F(m+1) * (1 - 1 / 1500000)")
                       (("1"
                         (induct "m")
                         (("1" (flatten) (assert))
                          ("2"
                           (skosimp*)
                           (case-replace "j!1=4")
                           (("1" (assert))
                            ("2" (inst - "j!1") (assert))))))
                        ("2"
                         (hide 2 -1)
                         (skosimp)
                         (name "LHS"
                               "(31415927 / 20000000) ^ 4/((5+4 * m!1)*(6+4 * m!1)*(7+4 * m!1)*(8+4 * m!1))")
                         (case-replace "G(m!1 + 1)=G(m!1)*LHS")
                         (("1"
                           (hide -1)
                           (case "LHS*F(m!1)<F(m!1 + 1)")
                           (("1"
                             (lemma "both_sides_times_pos_lt1"
                              ("pz"
                               "LHS"
                               "x"
                               "G(m!1)"
                               "y"
                               "F(m!1) * (1 - 1 / 1500000)"))
                             (assert))
                            ("2"
                             (hide -3 2)
                             (expand "F" 1)
                             (lemma "expt_plus"
                              ("n0x" "1/5" "i" "4" "j" "5+4*m!1"))
                             (replace -1)
                             (hide -1)
                             (name-replace "FIVE"
                              "(1 / 5) ^ (5 + 4 * m!1)")
                             (lemma "expt_plus"
                              ("n0x"
                               "1 / 239"
                               "i"
                               "4"
                               "j"
                               "3 + 4 * m!1"))
                             (replace -1)
                             (hide -1)
                             (name-replace "TWOTHREENINE"
                              "(1 / 239) ^ (3 + 4 * m!1)")
                             (case-replace
                              "(1 / 239) ^ 4 * TWOTHREENINE * (1 / (514089 + 228484 * m!1))= (1 / 239) ^ 6 * TWOTHREENINE * (1 / (9+4*m!1))")
                             (("1"
                               (hide -1)
                               (case-replace
                                "(TWOTHREENINE * (1 / (285605 + 228484 * m!1))) = (1/239)^2 * (TWOTHREENINE * (1 / (5 + 4 * m!1)))")
                               (("1"
                                 (hide -1)
                                 (case-replace
                                  "(FIVE * (1 / (175 + 100 * m!1))) = (1/5)^2*FIVE*(1/(7+4*m!1))")
                                 (("1"
                                   (hide -1)
                                   (case
                                    "-2 * ((1 / 239) ^ 2 * (TWOTHREENINE * (1 / (5 + 4 * m!1))) * LHS) -
                                                                                                                                                                                                                     8 * ((1 / 5) ^ 2 * FIVE * (1 / (7 + 4 * m!1)) * LHS)
                                                                                                                                                                                                                     + 8 * ((FIVE * (1 / (5 + 4 * m!1))) * LHS)
                                                                                                                                                                                                                     + 2 * ((TWOTHREENINE * (1 / (3 + 4 * m!1))) * LHS) < 8 * ((FIVE * (1 / (5 + 4 * m!1))) * LHS)")
                                   (("1"
                                     (case
                                      "8 * ((FIVE * (1 / (5 + 4 * m!1))) * LHS)<8 * ((1 / 5) ^ 4 * FIVE * (1 / (9 + 4 * m!1))) +
                                                                                                                                                                                                                                  2 * ((1 / 239) ^ 4 * TWOTHREENINE * (1 / (7 + 4 * m!1)))
                                                                                                                                                                                                                                  - 2 * ((1 / 239) ^ 6 * TWOTHREENINE * (1 / (9 + 4 * m!1)))
                                                                                                                                                                                                                                  - 8 * ((1 / 5) ^ 4 * FIVE * (1 / (275 + 100 * m!1)))")
                                     (("1" (assert))
                                      ("2"
                                       (hide 2 -1)
                                       (lemma
                                        "expt_plus"
                                        ("n0x" "1/239" "i" "2" "j" "4"))
                                       (replace -1)
                                       (hide -1)
                                       (lemma
                                        "both_sides_times_pos_lt1"
                                        ("pz"
                                         "2 * (1 / 239) ^ 4 * TWOTHREENINE"
                                         "y"
                                         "1 / (7 + 4 * m!1) -(1 / 239) ^ 2/ (9 + 4 * m!1)"
                                         "x"
                                         "0"))
                                       (flatten -1)
                                       (hide -1)
                                       (split -1)
                                       (("1"
                                         (case
                                          "8 * ((FIVE * (1 / (5 + 4 * m!1))) * LHS) <8 * ((1 / 5) ^ 4 * FIVE * (1 / (9 + 4 * m!1))) - 8 * ((1 / 5) ^ 4 * FIVE * (1 / (275 + 100 * m!1)))")
                                         (("1" (assert))
                                          ("2"
                                           (hide -1 2)
                                           (case-replace
                                            "1 / (275 + 100 * m!1) = (1/5)^2*1/(11+4*m!1)")
                                           (("1"
                                             (hide -1)
                                             (lemma
                                              "both_sides_times_pos_lt1"
                                              ("pz"
                                               "8*FIVE"
                                               "x"
                                               "LHS/(5 + 4 * m!1)"
                                               "y"
                                               "(1 / 5) ^ 4*(1 / (9 + 4 * m!1) - (1 / 5) ^ 2 / (11 + 4 * m!1))"))
                                             (replace -1 1)
                                             (hide -1)
                                             (case
                                              "(24/25)*(1 / (9 + 4 * m!1)) < (1 / (9 + 4 * m!1) - (1 / 5) ^ 2 / (11 + 4 * m!1))")
                                             (("1"
                                               (case
                                                "LHS / (5 + 4 * m!1) <(1 / 5) ^ 4 *(24 / 25) * (1 / (9 + 4 * m!1))")
                                               (("1"
                                                 (name-replace
                                                  "RHS"
                                                  "(1 / (9 + 4 * m!1) - (1 / 5) ^ 2 / (11 + 4 * m!1))")
                                                 (lemma
                                                  "both_sides_times_pos_lt1"
                                                  ("pz"
                                                   "(1/5)^4"
                                                   "x"
                                                   "(24 / 25) * (1 / (9 + 4 * m!1))"
                                                   "y"
                                                   "RHS"))
                                                 (assert))
                                                ("2"
                                                 (hide 2)
                                                 (hide -1)
                                                 (case
                                                  "(31415927 / 20000000) ^ 4 < 609/100")
                                                 (("1"
                                                   (lemma
                                                    "both_sides_div_pos_lt1"
                                                    ("pz"
                                                     "((5 + 4 * m!1) * (6 + 4 * m!1) * (7 + 4 * m!1) * (8 + 4 * m!1))"
                                                     "x"
                                                     "(31415927 / 20000000) ^ 4"
                                                     "y"
                                                     "609 / 100"))
                                                   (replace -3)
                                                   (replace -2)
                                                   (flatten -1)
                                                   (case
                                                    "LHS < (1 / 5) ^ 4 * (12/15)")
                                                   (("1"
                                                     (hide -2 -3 -4)
                                                     (lemma
                                                      "both_sides_div_pos_lt1"
                                                      ("pz"
                                                       "5 + 4 * m!1"
                                                       "x"
                                                       "LHS"
                                                       "y"
                                                       "(1 / 5) ^ 4 * (12 / 15)"))
                                                     (replace -2)
                                                     (flatten)
                                                     (lemma
                                                      "both_sides_times_pos_lt1"
                                                      ("pz"
                                                       "(1 / 5) ^ 4"
                                                       "x"
                                                       "(12 / 15) / (5 + 4 * m!1)"
                                                       "y"
                                                       "(24 / 25) * (1 / (9 + 4 * m!1))"))
                                                     (flatten)
                                                     (hide -1)
                                                     (split -1)
                                                     (("1" (assert))
                                                      ("2"
                                                       (hide -1 -2 2)
                                                       (lemma
                                                        "both_sides_times_pos_lt1"
                                                        ("pz"
                                                         "12/75"
                                                         "x"
                                                         "5/(5 + 4 * m!1)"
                                                         "y"
                                                         "6/(9 + 4 * m!1)"))
                                                       (replace -1 1)
                                                       (hide -1)
                                                       (lemma
                                                        "div_mult_pos_lt1"
                                                        ("py"
                                                         "5 + 4 * m!1"
                                                         "z"
                                                         "5"
                                                         "x"
                                                         "6 / (9 + 4 * m!1)"))
                                                       (replace -1)
                                                       (lemma
                                                        "div_mult_pos_lt2"
                                                        ("py"
                                                         "9 + 4 * m!1"
                                                         "z"
                                                         "6*(5 + 4 * m!1)"
                                                         "x"
                                                         "5"))
                                                       (replace -1 1)
                                                       (assert))))
                                                    ("2"
                                                     (hide 2)
                                                     (case-replace
                                                      "(1 / 5) ^ 4 * (12 / 15) = 12/9375")
                                                     (("1"
                                                       (hide -1)
                                                       (lemma
                                                        "both_sides_div_pos_le2"
                                                        ("pz"
                                                         "609/100"
                                                         "py"
                                                         "25*26*27*28"
                                                         "px"
                                                         "((5 + 4 * m!1) * (6 + 4 * m!1) * (7 + 4 * m!1) * (8 + 4 * m!1))"))
                                                       (flatten)
                                                       (hide -1)
                                                       (split)
                                                       (("1"
                                                         (name-replace
                                                          "LHS2"
                                                          "609 / 100 /
                                                                                                                                                                                                                                                                                                                                                          ((5 + 4 * m!1) * (6 + 4 * m!1) * (7 + 4 * m!1) * (8 + 4 * m!1))")
                                                         (assert))
                                                        ("2"
                                                         (hide-all-but
                                                          (1 -4))
                                                         (lemma
                                                          "le_times_le_pos"
                                                          ("nnx"
                                                           "25"
                                                           "y"
                                                           "5 + 4 * m!1"
                                                           "nnz"
                                                           "26 * 27 * 28"
                                                           "w"
                                                           "(6 + 4 * m!1) * (7 + 4 * m!1) * (8 + 4 * m!1)"))
                                                         (lemma
                                                          "le_times_le_pos"
                                                          ("nnx"
                                                           "26"
                                                           "y"
                                                           "6 + 4 * m!1"
                                                           "nnz"
                                                           "27 * 28"
                                                           "w"
                                                           "(7 + 4 * m!1) * (8 + 4 * m!1)"))
                                                         (lemma
                                                          "le_times_le_pos"
                                                          ("nnx"
                                                           "27"
                                                           "y"
                                                           "7 + 4 * m!1"
                                                           "nnz"
                                                           "28"
                                                           "w"
                                                           "(8 + 4 * m!1)"))
                                                         (assert))))
                                                      ("2"
                                                       (hide-all-but 1)
                                                       (grind))))))
                                                  ("2"
                                                   (hide-all-but 1)
                                                   (grind))))))
                                              ("2"
                                               (hide -1 2)
                                               (lemma
                                                "both_sides_times_pos_lt1"
                                                ("pz"
                                                 "9 + 4 * m!1"
                                                 "x"
                                                 "(24 / 25) * (1 / (9 + 4 * m!1))"
                                                 "y"
                                                 "(1 / (9 + 4 * m!1) - (1 / 5) ^ 2 / (11 + 4 * m!1))"))
                                               (replace -1 1 rl)
                                               (hide -1)
                                               (lemma
                                                "div_cancel2"
                                                ("x"
                                                 "1"
                                                 "n0z"
                                                 "9+4*m!1"))
                                               (lemma
                                                "associative_mult"
                                                ("x"
                                                 "24 / 25"
                                                 "y"
                                                 "1 / (9 + 4 * m!1)"
                                                 "z"
                                                 "9 + 4 * m!1"))
                                               (replace -2)
                                               (replace -1 1 rl)
                                               (hide -1 -2)
                                               (lemma
                                                "both_sides_div_pos_lt2"
                                                ("pz"
                                                 "1"
                                                 "py"
                                                 "9 + 4 * m!1"
                                                 "px"
                                                 "11 + 4 * m!1"))
                                               (simplify -1)
                                               (case-replace
                                                "(1 / (9 + 4 * m!1) - (1 / 5) ^ 2 / (11 + 4 * m!1)) * (9 + 4 * m!1) = 1- (1 / 5) ^ 2*(9 + 4 * m!1)/(11 + 4 * m!1)")
                                               (("1"
                                                 (hide -1)
                                                 (case
                                                  "(1 / 5) ^ 2 * (9 + 4 * m!1) / (11 + 4 * m!1) < 1/25")
                                                 (("1" (assert))
                                                  ("2"
                                                   (hide 2)
                                                   (case-replace
                                                    "(1 / 5) ^ 2=1/25")
                                                   (("1"
                                                     (rewrite
                                                      "div_mult_pos_lt1"
                                                      1))
                                                    ("2"
                                                     (hide-all-but 1)
                                                     (grind))))))
                                                ("2"
                                                 (hide 2)
                                                 (assert))))))
                                            ("2"
                                             (hide-all-but 1)
                                             (rewrite "cross_mult")
                                             (grind))))))
                                        ("2"
                                         (hide -1 2)
                                         (lemma
                                          "div_mult_pos_lt1"
                                          ("z"
                                           "(1 / 239) ^ 2"
                                           "py"
                                           "9 + 4 * m!1"
                                           "x"
                                           "1 / (7 + 4 * m!1)"))
                                         (flatten)
                                         (hide -1)
                                         (split -1)
                                         (("1"
                                           (assert)
                                           (name-replace
                                            "DRL1"
                                            "(1 / 239) ^ 2")
                                           (assert))
                                          ("2"
                                           (hide 2)
                                           (lemma
                                            "div_mult_pos_lt2"
                                            ("py"
                                             "7 + 4 * m!1"
                                             "z"
                                             "9 + 4 * m!1"
                                             "x"
                                             "(1 / 239) ^ 2"))
                                           (replace -1 1)
                                           (hide -1)
                                           (lemma
                                            "lt_times_lt_pos1"
                                            ("px"
                                             "(1 / 239) ^ 2"
                                             "y"
                                             "1"
                                             "nnz"
                                             "7 + 4 * m!1"
                                             "w"
                                             "9 + 4 * m!1"))
                                           (lemma
                                            "both_sides_expt_pos_lt"
                                            ("px"
                                             "1/239"
                                             "py"
                                             "1"
                                             "pm"
                                             "2"))
                                           (assert)
                                           (grind))))))))
                                    ("2"
                                     (hide 2)
                                     (case
                                      "(2*TWOTHREENINE)*(1 / (3 + 4 * m!1)-(1 / 239) ^ 2*(1 / (5 + 4 * m!1))) - 8*(1 / 5) ^ 2 * FIVE * (1 / (7 + 4 * m!1))<0")
                                     (("1"
                                       (lemma
                                        "both_sides_times_pos_lt1"
                                        ("pz"
                                         "LHS"
                                         "x"
                                         "(2 * TWOTHREENINE) *
                                                                                                                                                                                                                                                   (1 / (3 + 4 * m!1) - (1 / 239) ^ 2 * (1 / (5 + 4 * m!1)))
                                                                                                                                                                                                                                                   - 8 * (1 / 5) ^ 2 * FIVE * (1 / (7 + 4 * m!1))"
                                         "y"
                                         "0"))
                                       (replace -1 -2 rl)
                                       (hide -1)
                                       (assert))
                                      ("2"
                                       (hide 2)
                                       (hide -1)
                                       (case
                                        "2 * TWOTHREENINE/(3 + 4 * m!1) < 8 * (1 / 5) ^ 2 * FIVE * (1 / (7 + 4 * m!1))")
                                       (("1"
                                         (name-replace
                                          "RHS"
                                          "8 * (1 / 5) ^ 2 * FIVE * (1 / (7 + 4 * m!1))")
                                         (lemma
                                          "both_sides_times_pos_lt1"
                                          ("y"
                                           "1/(3 + 4 * m!1)"
                                           "x"
                                           "(1 / (3 + 4 * m!1) - (1 / 239) ^ 2 * (1 / (5 + 4 * m!1)))"
                                           "pz"
                                           "2 * TWOTHREENINE"))
                                         (assert))
                                        ("2"
                                         (hide 2)
                                         (rewrite "times_div1")
                                         (lemma
                                          "div_mult_pos_lt1"
                                          ("py"
                                           "3 + 4 * m!1"
                                           "z"
                                           "2 * TWOTHREENINE"
                                           "x"
                                           "(8 * ((1 / 5) ^ 2 * FIVE))/(7 + 4 * m!1)"))
                                         (replace -1 1)
                                         (hide -1)
                                         (lemma
                                          "div_mult_pos_lt2"
                                          ("py"
                                           "7 + 4 * m!1"
                                           "z"
                                           "(8 * ((1 / 5) ^ 2 * FIVE))*(3 + 4 * m!1)"
                                           "x"
                                           "2 * TWOTHREENINE"))
                                         (replace -1)
                                         (hide -1)
                                         (expand "FIVE")
                                         (expand "TWOTHREENINE")
                                         (case
                                          "forall (m:nat): m>=5 => 14 * (1 / 239) ^ (3 + 4 * m) +
                                                                                                                                                                                                                                                         8 * ((1 / 239) ^ (3 + 4 * m) * m)
                                                                                                                                                                                                                                                         <
                                                                                                                                                                                                                                                         24 * ((1 / 5) ^ 2 * (1 / 5) ^ (5 + 4 * m)) +
                                                                                                                                                                                                                                                          32 * ((1 / 5) ^ 2 * (1 / 5) ^ (5 + 4 * m) * m)")
                                         (("1" (inst - "m!1") (assert))
                                          ("2"
                                           (hide-all-but 1)
                                           (induct "m")
                                           (("1" (assert))
                                            ("2"
                                             (skosimp)
                                             (case-replace "j!1=4")
                                             (("1" (grind))
                                              ("2"
                                               (assert)
                                               (lemma
                                                "lt_times_lt_pos1"
                                                ("px"
                                                 "14 * (1 / 239) ^ (3 + 4 * j!1) +
                                                                                                                                                                                                                                                                                                   8 * ((1 / 239) ^ (3 + 4 * j!1) * j!1)"
                                                 "y"
                                                 "24 * ((1 / 5) ^ 2 * (1 / 5) ^ (5 + 4 * j!1)) +
                                                                                                                                                                                                                                                                                                    32 * ((1 / 5) ^ 2 * (1 / 5) ^ (5 + 4 * j!1) * j!1)"
                                                 "nnz"
                                                 "(1 / 239) ^ 4"
                                                 "w"
                                                 "(1/5)^4"))
                                               (split -1)
                                               (("1"
                                                 (case
                                                  "8*(1 / 239) ^ (7 + 4 * j!1)<32*((1 / 5) ^ 2 * (1 / 5) ^ (9 + 4 * j!1))")
                                                 (("1"
                                                   (lemma
                                                    "expt_plus"
                                                    ("n0x"
                                                     "1/5"
                                                     "i"
                                                     "4"
                                                     "j"
                                                     "5+4*j!1"))
                                                   (replace -1)
                                                   (lemma
                                                    "expt_plus"
                                                    ("n0x"
                                                     "1/239"
                                                     "i"
                                                     "4"
                                                     "j"
                                                     "3+4*j!1"))
                                                   (replace -1)
                                                   (assert))
                                                  ("2"
                                                   (hide -1 -2 3)
                                                   (lemma
                                                    "expt_plus"
                                                    ("n0x"
                                                     "1/5"
                                                     "i"
                                                     "2"
                                                     "j"
                                                     "7+4*j!1"))
                                                   (replace -1)
                                                   (hide -1)
                                                   (case
                                                    "forall (m:nat): m>=27 => 8 * (1 / 239) ^ m <
                                                                                                                                                                                                                                                                                                                     32 * ((1 / 5) ^ 2 * ((1 / 5) ^ 2 * (1 / 5) ^ m))")
                                                   (("1"
                                                     (inst
                                                      -
                                                      "7 + 4 * j!1")
                                                     (assert))
                                                    ("2"
                                                     (hide-all-but 1)
                                                     (induct "m")
                                                     (("1" (grind))
                                                      ("2"
                                                       (skosimp)
                                                       (case-replace
                                                        "j!2=26")
                                                       (("1" (grind))
                                                        ("2"
                                                         (assert)
                                                         (lemma
                                                          "lt_times_lt_pos1"
                                                          ("px"
                                                           "1/239"
                                                           "y"
                                                           "1/5"
                                                           "nnz"
                                                           "8 * (1 / 239) ^ j!2"
                                                           "w"
                                                           "32 * ((1 / 5) ^ 2 * ((1 / 5) ^ 2 * (1 / 5) ^ j!2))"))
                                                         (expand "^")
                                                         (expand
                                                          "expt"
                                                          2
                                                          (1 4))
                                                         (assert))))))))))
                                                ("2" (assert))
                                                ("3"
                                                 (hide-all-but 1)
                                                 (lemma
                                                  "both_sides_expt_pos_lt"
                                                  ("px"
                                                   "1/239"
                                                   "py"
                                                   "1/5"
                                                   "pm"
                                                   "4"))
                                                 (assert))))))))))))))))
                                  ("2"
                                   (hide 2 -1)
                                   (rewrite "times_div1")
                                   (rewrite "times_div1")
                                   (rewrite "cross_mult")
                                   (grind))))
                                ("2"
                                 (hide -1 2)
                                 (rewrite "times_div1")
                                 (rewrite "times_div1")
                                 (rewrite "times_div1")
                                 (rewrite "cross_mult")
                                 (rewrite "expt_x2")
                                 (assert))))
                              ("2"
                               (hide 2)
                               (rewrite "times_div1")
                               (rewrite "times_div1")
                               (rewrite "cross_mult")
                               (expand "^" 1)
                               (expand "expt" 1 (3 4))
                               (expand "expt" 1 (3 4))
                               (propax))))))
                          ("2"
                           (hide -3 2 -2)
                           (expand "G")
                           (hide -1)
                           (lemma "expt_plus"
                            ("n0x"
                             "31415927 / 20000000"
                             "i"
                             "4"
                             "j"
                             "4 + 4 * m!1"))
                           (replace -1 1)
                           (hide -1)
                           (expand "LHS")
                           (name-replace "DRL11"
                            "(31415927 / 20000000) ^ 4")
                           (name-replace "DRL12"
                            "(31415927 / 20000000) ^ (4 + 4 * m!1)")
                           (expand "factorial" 1 1)
                           (expand "factorial" 1 (1 2))
                           (expand "factorial" 1 (1 2 3))
                           (expand "factorial" 1 (1 2 3 4))
                           (assert)
                           (name-replace "FACTORIAL"
                            "factorial(4 + 4 * m!1)")
                           (assert)
                           (rewrite "div_times")
                           (assert))))))
                      ("2"
                       (hide 2)
                       (expand "F")
                       (expand "G")
                       (grind))))))
                  ("2"
                   (hide 2)
                   (expand "G" 1)
                   (assert)
                   (lemma "both_sides_div_pos_lt1"
                    ("pz"
                     "factorial(4 + 4 * n!1)"
                     "x"
                     "(pi_lbn(n!1) / 2) ^ (4 + 4 * n!1)"
                     "y"
                     "(31415927 / 20000000) ^ (4 + 4 * n!1)"))
                   (assert))))
                ("2" (hide-all-but 1) (rewrite "even_m1_pow"))))
              ("2" (expand "F" 1) (expand "KK" 1) (assert))))))
          ("2" (assert))))
        ("2" (assert))))
      ("2"
       (hide -1 -2 2)
       (lemma "pi_lb_pi" ("n" "n!1"))
       (case "16 * ((1 / 5) ^ (4 * n!1 + 5) / (4 * n!1 + 5)) <= 16*(1/5)^25/25")
       (("1"
         (case "4 * ((1 / 239) ^ (4 * n!1 + 3) / (4 * n!1 + 3)) <= 4*(1/239)^23/23")
         (("1"
           (case "16 * (1 / 5) ^ 25 / 25< 1/1000000")
           (("1"
             (case "4 * (1 / 239) ^ 23 / 23< 1 / 1000000")
             (("1" (assert)) ("2" (hide-all-but 1) (grind))))
            ("2" (hide-all-but 1) (grind))))
          ("2"
           (hide-all-but (-6 1))
           (lemma "both_sides_expt_lt1_le"
            ("lt1x" "1/239" "j" "23" "i" "4*n!1+3"))
           (assert)
           (lemma "both_sides_div_pos_le2"
            ("pz" "4" "px" "3+4*n!1" "py" "23"))
           (assert)
           (lemma "le_times_le_pos"
            ("nnx"
             "4 / (3 + 4 * n!1)"
             "y"
             "4 / 23"
             "nnz"
             "(1 / 239) ^ (3 + 4 * n!1)"
             "w"
             "(1 / 239) ^ 23"))
           (assert))))
        ("2"
         (hide-all-but (-5 1))
         (lemma "both_sides_div_pos_le2"
          ("pz" "16" "px" "5+4*n!1" "py" "25"))
         (assert)
         (lemma "both_sides_expt_lt1_le"
          ("lt1x" "1/5" "j" "25" "i" "4*n!1+5"))
         (lemma "le_times_le_pos"
          ("nnx"
           "16 / (5 + 4 * n!1)"
           "y"
           "16 / 25"
           "nnz"
           "(1 / 5) ^ (4 * n!1 + 5)"
           "w"
           "(1 / 5) ^ 25"))
         (assert))))))
    ("2"
     (hide -1 2)
     (lemma "both_sides_div_pos_lt1"
      ("pz" "2" "y" "pi-pi_lbn(n!1)" "x" "KK"))
     (expand ">" 1)
     (replace -1 1)
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "cos_approx_cos" ("a" "pi / 2 - px!1" "n" "1+2*n!1"))
   (lemma "cos_bounds" ("a" "pi / 2 - px!1" "n" "n!1"))
   (flatten)
   (hide -2)
   (expand "cos_lb")
   (expand "abs" -2 1)
   (assert)
   (name-replace "COS_APPROX" "cos_approx(pi / 2 - px!1, 1 + 2 * n!1)")
   (rewrite "cos_shift")
   (lemma "sin_gt_0" ("a" "px!1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "cos_lb")
   (expand "cos_approx")
   (replace -1)
   (expand "sigma")
   (expand "sigma")
   (expand "cos_term")
   (expand "pi_lbn")
   (expand "atan_pos_le1_lb")
   (expand "atan_pos_le1_ub")
   (expand "atan_series_n")
   (expand "sigma")
   (expand "sigma")
   (expand "atan_series_term")
   (expand "atan_series_coef")
   (grind))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "cos_lb_pi2_eps" ("n" "n!1" "px" "pi/2-pi_lbn(n!1) / 2"))
   (("1"
     (assert)
     (hide 2)
     (lemma "pi_bounds" ("n" "n!1"))
     (flatten)
     (assert)
     (lemma "pi_bounds0")
     (flatten)
     (lemma "pi_lb_inc" ("n" "0" "m" "n!1"))
     (assert)
     (rewrite "sin_shift" 1)
     (lemma "cos_term_pi_lb" ("n" "n!1"))
     (assert)
     (name "TERM" "cos_term(pi_lbn(n!1) / 2)(2 + 2 * n!1)")
     (replace -1)
     (expand "cos_term")
     (lemma "expt_times" ("n0x" "-1" "i" "2" "j" "1+n!1"))
     (expand "^" -1 2)
     (expand "expt" -1)
     (expand "expt" -1)
     (expand "expt" -1)
     (rewrite "sq_rew")
     (rewrite "sq_neg")
     (rewrite "expt_1i")
     (replace -1)
     (hide -1)
     (typepred "factorial(4 + 4 * n!1)")
     (lemma "expt_pos" ("px" "pi_lbn(n!1) / 2" "i" "4 + 4 * n!1"))
     (expand "abs" 1)
     (assert))
    ("2" (hide 2) (lemma "pi_bounds" ("n" "n!1")) (flatten) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_degree
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "sind")
   (expand "toRad")
   (case "sin(a * pi / 180) >= sin(a*pi_lb/180)")
   (("1"
     (case "sin(a * pi_lb / 180)>= sin_lb(a * pi_lb / 180,n)")
     (("1" (ground))
      ("2"
       (hide 2)
       (lemma "sin_bounds")
       (inst -1 "a * pi_lb / 180" "n")
       (ground))))
    ("2"
     (hide 2)
     (case "a=0")
     (("1" (replace -1 :hide? t) (ground))
      ("2"
       (case "a > 0")
       (("1"
         (hide 1)
         (lemma "sin_increasing")
         (inst -1 " a * pi / 180" "a * pi_lb / 180")
         (ground)
         (("1" (hide 2 3) (cross-mult 1) (cancel-by 1 "a*180"))
          ("2" (cross-mult) (hide 2) (cancel-by 1 "2*pi"))
          ("3" (cross-mult) (hide 2) (cancel-by 1 "2*pi"))
          ("4" (hide 2) (cross-mult 1) (cancel-by 1 "2") (grind-reals))
          ("5"
           (hide 2)
           (cross-mult)
           (cancel-by 1 "2")
           (typepred "pi")
           (grind))))
        ("2" (assert))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_degree
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "cosd")
   (expand "toRad")
   (case "cos(a * pi / 180) <= cos(a*pi_lb/180)")
   (("1"
     (case "cos(a * pi_lb / 180) <= cos_ub(a * pi_lb / 180,n)")
     (("1" (ground))
      ("2"
       (hide 2)
       (lemma "cos_bounds")
       (inst -1 "a * pi_lb / 180" "n")
       (ground))))
    ("2"
     (hide 2)
     (lemma "cos_decreasing")
     (inst -1 "a * pi / 180" "a * pi_lb / 180")
     (ground)
     (("1"
       (hide 2 3)
       (cross-mult 1)
       (case "a=0")
       (("1" (replace -1) (ground)) ("2" (cancel-by 2 "180*a"))))
      ("2" (hide 2) (cross-mult 1) (cancel-by 1 "pi"))
      ("3" (hide 2) (cross-mult 1) (typepred "pi") (grind-reals))
      ("4"
       (hide 2)
       (cross-mult)
       (typepred "pi")
       (swap-rel -3)
       (mult-ineq -3 -6)
       (assert)
       (mult-ineq -4 -8)
       (assert))
      ("5" (hide 2) (cross-mult 1) (grind))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: law_cosines
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "dist")
   (expand "sq_dist")
   (lemma "sq_times")
   (inst-cp - "pz!1" "x0!1-x1!1")
   (inst - "pz!1" "y0!1-y1!1")
   (lemma "sqrt_times")
   (inst - "sq(pz!1)" "sq(x0!1 - x1!1) + sq(y0!1 - y1!1)")
   (rewrite "sqrt_sq")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: law_cosines
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "dist")
   (expand "sq_dist")
   (name "KX" "x0!1 - x1!1")
   (name "KY" "y0!1 - y1!1")
   (case "(cos(ac!1) * x0!1 + sin(ac!1) * y1!1 - cos(ac!1) * x1!1 -
                         sin(ac!1) * y0!1) = cos(ac!1)*KX - sin(ac!1)*KY")
   (("1"
     (replace -1)
     (case "(cos(ac!1) * y0!1 + sin(ac!1) * x0!1 - cos(ac!1) * y1!1 -
                            sin(ac!1) * x1!1) = sin(ac!1)*KX +cos(ac!1)*KY")
     (("1"
       (replace -1)
       (replace -3)
       (replace -4)
       (hide-all-but 1)
       (lemma "sin2_cos2" ("a" "ac!1"))
       (name-replace "SIN" "sin(ac!1)")
       (name-replace "COS" "cos(ac!1)")
       (expand "sq")
       (assert))
      ("2" (hide 2 -1) (expand "KX") (expand "KY") (propax))))
    ("2" (expand "KY") (expand "KX") (propax))))


proof_type: f_proof
decl_type: formula
library: trig
theory: law_cosines
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "dist")
   (expand "sq_dist")
   (ground)
   (expand "sq")
   (ground)
   (skosimp*)
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: law_cosines
signature: nil
run_date: Unknown date
run_time: ----
status: unchecked
description: nil
script:
  (""
   (case "FORALL (x,y:real): dist(0,0,0,1) <= dist(x,y,0,1) + dist(x,y,0,0)")
   (("1"
     (case "FORALL (x,y:real,pz:posreal): dist(0, 0, 0, pz) <= dist(x, y, 0, pz) + dist(x, y, 0, 0)")
     (("1"
       (hide -2)
       (case "FORALL (x,y,a,b:real): dist(0, 0, a,b) <= dist(x, y, a,b) + dist(x, y, 0, 0)")
       (("1"
         (hide -2)
         (skosimp*)
         (lemma "distance_trans" ("x2" "-x0!1" "y2" "-y0!1"))
         (inst-cp - "x0!1" "x1!1" "y0!1" "y1!1")
         (inst-cp - "x2!1" "x1!1" "y2!1" "y1!1")
         (inst - "x2!1" "x0!1" "y2!1" "y0!1")
         (inst - "x2!1-x0!1" "y2!1-y0!1" "x1!1-x0!1" "y1!1-y0!1")
         (assert))
        ("2"
         (hide 2)
         (skosimp*)
         (case "a!1=0")
         (("1"
           (replace -1)
           (lemma "trichotomy" ("x" "b!1"))
           (split -1)
           (("1" (inst - "x!1" "y!1" "b!1") (assert))
            ("2"
             (replace -1)
             (expand "dist")
             (expand "sq_dist")
             (rewrite "sq_0")
             (rewrite "sqrt_0")
             (assert))
            ("3"
             (inst - "x!1" "-y!1" "-b!1")
             (("1"
               (expand "dist")
               (expand "sq_dist")
               (rewrite "sq_neg")
               (lemma "sq_neg" ("a" "y!1-b!1"))
               (replace -1)
               (assert)
               (lemma "sq_neg" ("a" "-1*b!1"))
               (assert))
              ("2" (assert))))))
          ("2"
           (name "theta" "atan2(b!1,a!1)")
           (("1"
             (lemma "distance_rot" ("ac" "theta"))
             (lemma "sin_atan2" ("x" "b!1" "y" "a!1"))
             (lemma "cos_atan2" ("x" "b!1" "y" "a!1"))
             (assert)
             (replace -4)
             (inst-cp - "0" "a!1" "0" "b!1")
             (simplify -4)
             (case "cos(theta) * a!1 - sin(theta) * b!1 = 0")
             (("1"
               (case "cos(theta) * b!1 + sin(theta) * a!1 = sqrt(sq(a!1)+sq(b!1))")
               (("1"
                 (inst-cp - "x!1" "0" "y!1" "0")
                 (inst - "x!1" "a!1" "y!1" "b!1")
                 (replace -1)
                 (replace -2)
                 (replace -5)
                 (replace -6)
                 (replace -7)
                 (simplify 2)
                 (inst - "cos(theta) * x!1 - sin(theta) * y!1"
                  "cos(theta) * y!1 + sin(theta) * x!1"
                  "sqrt(sq(a!1) + sq(b!1))")
                 (hide -3 -4 -5 -6 -7 -8 3)
                 (lemma "sqrt_pos" ("px" "sq(a!1) + sq(b!1)"))
                 (("1" (propax))
                  ("2"
                   (hide -1 -2 2)
                   (lemma "sq_nz_pos" ("nz" "a!1"))
                   (assert))))
                ("2"
                 (hide -1 -4 -5 -6 -7 3)
                 (case "b!1=0")
                 (("1"
                   (replace -1)
                   (rewrite "sq_0")
                   (simplify 1)
                   (case "a!1>0")
                   (("1" (rewrite "sqrt_sq") (assert))
                    ("2"
                     (lemma "sq_neg" ("a" "a!1"))
                     (replace -1 2 rl)
                     (rewrite "sqrt_sq")
                     (assert))))
                  ("2"
                   (assert)
                   (case "1 + sq(a!1 / b!1) = (sq(a!1)+sq(b!1))/sq(b!1)")
                   (("1"
                     (replace -1)
                     (rewrite "sqrt_div")
                     (("1"
                       (case "b!1>0")
                       (("1"
                         (assert)
                         (rewrite "sqrt_sq")
                         (rewrite "div_div1")
                         (rewrite "div_div1")
                         (lemma "div_cancel2" ("x" "a!1" "n0z" "b!1"))
                         (replace -1 -5)
                         (replace -4)
                         (replace -5)
                         (lemma "div_cancel3"
                          ("x"
                           "b!1*b!1+a!1*a!1"
                           "n0z"
                           "sqrt(sq(a!1) + sq(b!1))"
                           "y"
                           "sqrt(sq(a!1) + sq(b!1))"))
                         (replace -1 2)
                         (rewrite "sq_rew" 2)
                         (rewrite "sq_rew" 2)
                         (rewrite "sq_rew" 2)
                         (rewrite "sq_sqrt")
                         (assert))
                        ("2"
                         (assert)
                         (rewrite "div_div1")
                         (rewrite "div_div1")
                         (lemma "sq_neg" ("a" "b!1"))
                         (replace -1 * rl)
                         (rewrite "sqrt_sq")
                         (case "-((a!1 / b!1 * -b!1) / sqrt((sq(a!1) + sq(-b!1)))) = a!1/ sqrt((sq(a!1) + sq(-b!1)))")
                         (("1"
                           (replace -1)
                           (case "-1*-b!1=b!1")
                           (("1"
                             (replace -1)
                             (hide -1 -2 -4)
                             (replace -2)
                             (replace -3)
                             (replace -1)
                             (hide (-1 -2 -3))
                             (lemma "div_cancel3")
                             (inst - "sqrt(sq(a!1) + sq(b!1))"
                              "b!1*b!1+a!1*a!1"
                              "sqrt(sq(a!1) + sq(b!1))")
                             (replace -1 3)
                             (rewrite "sq_rew")
                             (rewrite "sq_rew")
                             (rewrite "sq_rew")
                             (rewrite "sq_sqrt")
                             (assert))
                            ("2" (assert))))
                          ("2" (hide 4 -3 -4) (assert))
                          ("3" (assert))))))
                      ("2" (lemma "sq_nz_pos" ("nz" "b!1")) (assert))))
                    ("2" (rewrite "sq_div") (assert))
                    ("3" (lemma "sq_nz_pos" ("nz" "b!1")) (assert))))))))
              ("2"
               (hide -3 -4 -5 -6 3)
               (case "b!1=0")
               (("1" (assert))
                ("2" (case "b!1>0") (("1" (assert)) ("2" (assert))))))))
            ("2" (case "b!1=0") (("1" (assert)) ("2" (assert))))))))))
      ("2"
       (hide 2)
       (skosimp*)
       (lemma "distance_scale" ("pz" "pz!1"))
       (inst-cp - "0" "0" "0" "1")
       (inst-cp - "x!1/pz!1" "0" "y!1/pz!1" "1")
       (inst - "x!1/pz!1" "0" "y!1/pz!1" "0")
       (inst - "x!1/pz!1" "y!1/pz!1")
       (lemma "both_sides_times_pos_le1"
        ("x"
         "dist(0, 0, 0, 1)"
         "y"
         "dist(x!1/pz!1, y!1/pz!1, 0, 1) + dist(x!1/pz!1, y!1/pz!1, 0, 0)"
         "pz"
         "pz!1"))
       (assert))))
    ("2"
     (hide 2)
     (skosimp*)
     (expand "dist")
     (expand "sq_dist")
     (rewrite "sq_neg")
     (rewrite "sq_0")
     (rewrite "sq_1")
     (rewrite "sqrt_1")
     (name-replace "K1" "sq(x!1)")
     (rewrite "sq_le" :dir rl)
     (rewrite "sq_1")
     (rewrite "sq_plus")
     (rewrite "sq_sqrt")
     (rewrite "sq_sqrt")
     (rewrite "sq_minus")
     (rewrite "sq_1")
     (lemma "trichotomy" ("x" "y!1"))
     (split -1)
     (("1"
       (case "sq(y!1) - 2 * y!1 + K1 + (sq(y!1) + K1) >=0")
       (("1" (assert))
        ("2"
         (case "y!1-sq(y!1)-K1 <= (sqrt(1 + sq(y!1) - 2 * y!1 + K1) * sqrt(sq(y!1) + K1))")
         (("1" (assert))
          ("2"
           (hide 3)
           (rewrite "sqrt_times" :dir rl)
           (rewrite "sq_le" :dir rl)
           (rewrite "sq_sqrt")
           (expand "sq" 1)
           (assert))
          ("3" (assert))))))
      ("2" (replace -1) (rewrite "sq_0") (assert)) ("3" (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: tan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand* "tan_lb_ub" "tan_ub_ub")
   (rewrite "sin_lb_neg")
   (rewrite "cos_ub_neg")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: tan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand* "tan_ub_lb" "tan_lb_lb")
   (rewrite "sin_ub_neg")
   (rewrite "cos_lb_neg")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: tan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand* "tan_lb_lb" "tan_ub_lb")
   (rewrite "sin_lb_neg")
   (rewrite "cos_lb_neg")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: tan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand* "tan_ub_ub" "tan_lb_ub")
   (rewrite "sin_ub_neg")
   (rewrite "cos_ub_neg")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: tan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "tan")
   (expand "tan_lb_ub")
   (expand "tan_ub_lb")
   (case "cos(a) > 0")
   (("1"
     (case "sin(a) >= 0")
     (("1"
       (lemma "sin_bounds")
       (inst?)
       (assert)
       (flatten)
       (lemma "cos_bounds")
       (inst?)
       (assert)
       (flatten)
       (split)
       (("1"
         (cross-mult 1)
         (case "sin_lb(a, n) * cos(a) <= sin(a) * cos(a)"
           "sin(a) * cos(a) <= sin(a) * cos_ub(a, n)")
         (("1" (assert)) ("2" (hide -1 2) (cancel-by 1 "sin(a)"))
          ("3" (hide 2) (cancel-by 1 "cos(a)"))))
        ("2"
         (cross-mult 1)
         (case "sin(a) * cos_lb(a, n) <= sin(a) * cos(a)"
           "sin(a) * cos(a) <= sin_ub(a, n) * cos(a)")
         (("1" (assert)) ("2" (hide -1 2) (cancel-by 1 "cos(a)"))
          ("3" (hide 2) (cancel-by 1 "sin(a)"))))))
      ("2" (rewrite "sin_ge_0"))))
    ("2" (rewrite "cos_gt_0"))))


proof_type: f_proof
decl_type: formula
library: trig
theory: tan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (lemma "tan_bounds_0_pi2")
   (inst -1 "-a" "n")
   (assert)
   (rewrite "cos_lb_neg")
   (assert)
   (flatten)
   (lemma "cos_bounds")
   (inst?)
   (assert)
   (flatten)
   (rewrite "tan_neg")
   (("1" (rewrite "tan_lb_ub_neg") (rewrite "tan_ub_lb_neg") (assert))
    ("2" (expand "Tan?") (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: tan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (expand "tan")
   (expand "tan_ub_ub")
   (expand "tan_lb_lb")
   (case "cos(a) < 0")
   (("1"
     (case "sin(a) >= 0")
     (("1"
       (lemma "cos_bounds")
       (inst?)
       (assert)
       (flatten)
       (lemma "sin_bounds")
       (inst?)
       (assert)
       (flatten)
       (split)
       (("1"
         (cross-mult 1)
         (case "sin_ub(a, n) * cos(a) <= sin(a) * cos(a)"
           "sin(a) * cos(a) <= sin(a) * cos_ub(a, n)")
         (("1" (assert)) ("2" (hide -1 2) (cancel-by 1 "sin(a)"))
          ("3" (hide 2) (cancel-by 1 "cos(a)"))))
        ("2"
         (cross-mult 1)
         (case "sin(a) * cos_lb(a, n) <= sin(a) * cos(a)"
           "sin(a) * cos(a) <= sin_lb(a, n) * cos(a)")
         (("1" (assert)) ("2" (hide -1 2) (cancel-by 1 "cos(a)"))
          ("3" (hide 2) (cancel-by 1 "sin(a)"))))))
      ("2" (rewrite "sin_ge_0"))))
    ("2" (rewrite "cos_lt_0"))))


proof_type: f_proof
decl_type: formula
library: trig
theory: tan_approx
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (lemma "tan_bounds_pi2_pi")
   (inst -1 "-a" "n")
   (assert)
   (rewrite "cos_ub_neg")
   (assert)
   (rewrite "tan_neg")
   (("1"
     (rewrite "tan_ub_ub_neg")
     (rewrite "tan_lb_lb_neg")
     (("1" (flatten) (assert))
      ("2"
       (hide -1 2)
       (lemma "cos_bounds")
       (inst?)
       (assert)
       (flatten)
       (assert))))
    ("2"
     (hide -1 2)
     (expand "Tan?")
     (lemma "cos_bounds")
     (inst?)
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "sin_plus" ("a" "(a!1+b!1)/2" "b" "(a!1-b!1)/2"))
   (lemma "sin_minus" ("a" "(a!1+b!1)/2" "b" "(a!1-b!1)/2"))
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "cos_plus" ("a" "(a!1+b!1)/2" "b" "(a!1-b!1)/2"))
   (lemma "cos_minus" ("a" "(a!1+b!1)/2" "b" "(a!1-b!1)/2"))
   (assert)
   (replace -1)
   (replace -2)
   (assert)
   (name-replace "K1" "cos((a!1 + b!1) / 2)")
   (name-replace "K2" "cos((a!1 - b!1) / 2)")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "cos_plus" ("a" "(a!1+b!1)/2" "b" "(a!1-b!1)/2"))
   (lemma "cos_minus" ("a" "(a!1+b!1)/2" "b" "(a!1-b!1)/2"))
   (replace -1)
   (replace -2)
   (assert)
   (name-replace "K1" "sin((a!1 + b!1) / 2)")
   (name-replace "K2" "sin((a!1 - b!1) / 2)")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "tan")
   (case "(sin(a!1) / cos(a!1) - sin(b!1) / cos(b!1) = sin(a!1 - b!1)
                                                             /
                                                             (cos(a!1)
                                                              *
                                                              cos(b!1))) = (sin(a!1 - b!1)
                                                                            /
                                                                            (cos(a!1)
                                                                             *
                                                                             cos
                                                                             (b!1)) = sin(a!1)
                                                                                      /
                                                                                      cos(a!1)
                                                                                      -
                                                                                      sin(b!1)
                                                                                      /
                                                                                      cos(b!1))")
   (("1"
     (replace -1 1 :hide? t)
     (rewrite "div_cancel3" 1)
     (("1"
       (rewrite "times_div1" 1)
       (("1"
         (case-replace
          "(cos(a!1) * cos(b!1) * sin(a!1)) / cos(a!1) = cos(b!1) * sin(a!1)")
         (("1"
           (case-replace
            "cos(a!1) * cos(b!1) * (sin(b!1) / cos(b!1)) = cos(a!1) * sin(b!1)")
           (("1" (hide -1 -2) (rewrite "sin_minus") (assert))
            ("2" (assert))))
          ("2" (assert))))
        ("2" (expand "Tan?") (propax))))
      ("2" (expand "Tan?") (propax)) ("3" (expand "Tan?") (propax))
      ("4" (flatten) (expand "Tan?") (flatten) (mult-cases -1))))
    ("2" (assert) (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "sin2_cos2")
   (inst -1 "a!1")
   (replace -1 * rl)
   (hide -1)
   (lemma "cos_plus")
   (inst -1 "a!1" "a!1")
   (replace -1 * lr)
   (hide -1)
   (expand "sq")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (prop)
   (("1"
     (lemma "sq_sin")
     (inst -1 "a!1/2")
     (replace -2 * lr)
     (expand "sq")
     (assert))
    ("2"
     (lemma "sq_sin")
     (inst -1 "a!1/2")
     (replace -2 * lr)
     (assert)
     (lemma "sq_eq_0")
     (inst -1 "sin(a!1/2)")
     (assert)
     (replace -1)
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (prop)
   (("1"
     (lemma "sq_cos")
     (inst -1 "a!1/2")
     (replace -2 * lr)
     (expand "sq")
     (assert))
    ("2"
     (lemma "sq_cos")
     (inst -1 "a!1/2")
     (replace -2 * lr)
     (lemma "sq_eq_0")
     (inst -1 "cos(a!1/2)")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "tan")
   (rewrite "sq_div")
   (("1" (rewrite "sq_sin") (rewrite "sq_cos") (grind-reals))
    ("2"
     (hide 3)
     (lemma "sq_cos")
     (inst -1 "a!1")
     (prop)
     (replace -2 * lr)
     (expand "sq")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "cos_2a_sin")
   (inst -1 "a!1/2")
   (case-replace "2 * (a!1 / 2) = a!1")
   (("1"
     (hide -1)
     (replace -1)
     (hide -1)
     (case-replace
      "(2 * (sin(a!1 / 2) * sin(a!1 / 2)) / 2) = sq(sin(a!1/2))")
     (("1"
       (hide -1)
       (prop)
       (("1" (rewrite "sqrt_sq") (hide 2) (rewrite "sin_ge_0"))
        ("2"
         (rewrite "sqrt_sq_abs")
         (expand "abs")
         (lift-if)
         (ground)
         (lemma "sin_le_0")
         (inst -1 "a!1/2")
         (assert))))
      ("2" (hide 2) (expand "sq") (assert))))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "cos_2a_sin")
   (inst -1 "a!1/2")
   (case-replace "2 * (a!1 / 2) = a!1")
   (("1"
     (hide -1)
     (replace -1)
     (hide -1)
     (assert)
     (case-replace "sin(a!1 / 2) * sin(a!1 / 2) = sq(sin(a!1/2))")
     (("1"
       (case-replace
        "(2 - 2 * sq(sin(a!1 / 2))) / 2 = (1 - sq(sin(a!1 / 2)))")
       (("1"
         (hide -1)
         (rewrite "cos2" :dir rl)
         (ground)
         (("1"
           (case-replace "cos(a!1/2) >= 0")
           (("1" (rewrite "sqrt_sq"))
            ("2" (hide 2) (rewrite "cos_ge_0"))))
          ("2"
           (case "cos(a!1/2) <= 0")
           (("1"
             (rewrite "sqrt_sq_abs")
             (expand "abs")
             (lift-if)
             (assert))
            ("2" (hide 2) (rewrite "cos_le_0"))))
          ("3"
           (case "cos(a!1/2) >= 0")
           (("1" (rewrite "sqrt_sq"))
            ("2" (hide 2) (rewrite "cos_ge_0_3pi2"))))))
        ("2" (hide 2) (assert))))
      ("2" (hide 2) (expand "sq") (propax))))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "tan")
   (lemma "sin_plus")
   (inst -1 "a!1/2" "a!1/2")
   (replace -1 * lr)
   (hide -1)
   (lemma "sq_cos")
   (inst -1 "a!1/2")
   (rewrite "div_cancel1")
   (lemma "div_cancel1")
   (inst -1 "2" "1+cos(a!1)")
   (replace -2 * rl)
   (replace -1 * rl)
   (hide -2 -1)
   (expand "sq")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (name "BB" "a!1/2")
   (replace -1)
   (case-replace "a!1 = 2*BB")
   (("1"
     (hide -1 -2)
     (rewrite "sin_2a")
     (rewrite "cos_2a_sin")
     (assert)
     (expand "tan")
     (assert))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "sin_plus")
   (inst -1 "a!1" "2*a!1")
   (rewrite "sin_2a")
   (rewrite "cos_2a")
   (assert)
   (replace -1)
   (assert)
   (hide -1)
   (expand "expt")
   (expand "expt")
   (expand "expt")
   (expand "expt")
   (assert)
   (lemma "sin_plus")
   (inst -1 "a!1" "2*a!1")
   (rewrite "sin_2a")
   (rewrite "cos_2a")
   (assert)
   (lemma "cos2")
   (inst?)
   (expand "sq")
   (replace -1)
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "cos_plus")
   (inst -1 "a!1" "2*a!1")
   (rewrite "sin_2a")
   (assert)
   (replace -1)
   (hide -1)
   (expand "expt")
   (expand "expt")
   (expand "expt")
   (expand "expt")
   (lemma "cos2")
   (inst?)
   (expand "sq")
   (replace -1)
   (rewrite "cos_2a")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (prop)
   (("1"
     (case "sin(a!1) - sin(b!1) = 0")
     (("1"
       (hide -2)
       (rewrite "sin_diff")
       (rewrite "zero_times3")
       (rewrite "zero_times3")
       (prop)
       (("1"
         (rewrite "cos_eq_0")
         (skosimp*)
         (inst + "i!1")
         (assert)
         (flatten)
         (ground))
        ("2"
         (rewrite "sin_eq_0")
         (skosimp*)
         (lemma "both_sides_times1")
         (inst -1 "2" "(a!1 - b!1) / 2" "i!1 * pi")
         (replace -1 -2 rl t)
         (rewrite "div_cancel2" -1)
         (inst + "i!1")
         (flatten)
         (assert))))
      ("2" (assert))))
    ("2"
     (skosimp*)
     (prop)
     (("1"
       (replace -1)
       (hide -1)
       (rewrite "sin_plus")
       (assert)
       (lemma "sin_k_pi")
       (inst -1 "2*k!1")
       (replace -1)
       (hide -1)
       (lemma "cos_2k_pi")
       (inst -1 "k!1")
       (replace -1)
       (assert))
      ("2"
       (replace -1)
       (hide -1)
       (lemma "sin_minus")
       (inst -1 "pi + 2*k!1*pi" "b!1")
       (replace -1)
       (hide -1)
       (lemma "sin_k_pi")
       (inst -1 "2*k!1+1")
       (assert)
       (replace -1)
       (hide -1)
       (assert)
       (rewrite "cos_plus")
       (assert)
       (lemma "cos_2k_pi")
       (inst -1 "k!1")
       (replace -1)
       (hide -1)
       (lemma "sin_k_pi")
       (inst -1 "2*k!1")
       (replace -1)
       (assert)
       (rewrite "cos_pi")
       (assert))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (prop)
   (("1"
     (case-replace "cos(a!1)-cos(b!1) = 0")
     (("1"
       (hide -2)
       (rewrite "cos_diff")
       (rewrite "zero_times3")
       (rewrite "zero_times3")
       (prop)
       (("1" (rewrite "sin_eq_0") (skosimp*) (inst + "i!1") (ground))
        ("2"
         (rewrite "sin_eq_0")
         (skosimp*)
         (inst + "i!1")
         (flatten)
         (ground))))
      ("2" (assert))))
    ("2"
     (skosimp*)
     (prop)
     (("1"
       (replace -1)
       (hide -1)
       (rewrite "cos_plus")
       (lemma "cos_2k_pi")
       (inst -1 "k!1")
       (replace -1)
       (hide -1)
       (lemma "sin_k_pi")
       (inst -1 "2*k!1")
       (replace -1)
       (hide -1)
       (assert))
      ("2"
       (replace -1)
       (hide -1)
       (rewrite "cos_plus")
       (lemma "sin_k_pi")
       (inst -1 "2*k!1")
       (replace -1)
       (assert)
       (hide -1)
       (lemma "cos_2k_pi")
       (inst -1 "k!1")
       (replace -1)
       (assert)
       (hide -1)
       (rewrite "cos_neg"))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (prop)
   (("1"
     (case-replace "tan(a!1) - tan(b!1) = 0")
     (("1"
       (hide -2)
       (rewrite "tan_diff")
       (rewrite "div_eq_zero")
       (("1" (rewrite "sin_eq_0") (skosimp*) (inst + "i!1") (assert))
        ("2"
         (hide -1 2)
         (expand "Tan?")
         (lemma "zero_times3")
         (inst?)
         (assert))))
      ("2" (assert))))
    ("2"
     (skosimp*)
     (replace -1)
     (hide -1)
     (expand "tan")
     (expand "Tan?")
     (rewrite "sin_plus")
     (rewrite "cos_plus")
     (rewrite "sin_k_pi")
     (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "sin_eq_sin")
   (inst?)
   (assert)
   (lemma "cos_eq_cos")
   (inst?)
   (assert)
   (skosimp*)
   (case-replace "k!1 = 0")
   (("1" (assert))
    ("2"
     (case-replace "k!2 = 0")
     (("1"
       (assert)
       (case-replace "k!1 <= -1")
       (("1"
         (mult-by -1 "2*pi")
         (case-replace "k!1 >= 1")
         (("1" (mult-by -1 "2*pi") (ground)) ("2" (assert))))
        ("2"
         (assert)
         (case-replace "k!1 >= 1")
         (("1" (mult-by -1 "2*pi") (assert)) ("2" (assert))))))
      ("2"
       (case-replace "k!1 >= 1")
       (("1"
         (mult-by -1 "2*pi")
         (assert)
         (case-replace "k!1 <= -1")
         (("1" (mult-by -1 "2*pi") (assert))
          ("2"
           (assert)
           (ground)
           (("1"
             (case-replace "k!2 >= 1")
             (("1" (mult-by 1 "pi") (mult-by -1 "2*pi") (assert))
              ("2"
               (assert)
               (case-replace "k!2 <= -1")
               (("1" (mult-by -1 "2*pi") (assert)) ("2" (assert))))))
            ("2"
             (hide-all-but (-1 -3))
             (replace -1)
             (hide -1)
             (case-replace "(2*k!2+1) * pi   =  2 * (k!1 * pi)")
             (("1"
               (hide -2)
               (div-by -1 "pi")
               (assert)
               (case-replace "2 * (k!1 * pi) / pi = 2*k!1")
               (("1" (assert)) ("2" (assert) (cross-mult 1))))
              ("2" (assert))))))))
        ("2"
         (case-replace "k!1 <= -1")
         (("1" (mult-by -1 "2*pi") (assert)) ("2" (assert))))))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skeep)
   (lemma "cos_plus")
   (inst - "a" "pi/4")
   (rewrite "cos_pi4")
   (rewrite "sin_pi4")
   (replace -2)
   (assert)
   (lemma "cos_eq_0")
   (inst?)
   (assert)
   (skosimp*)
   (inst + "i!1")
   (assert))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (ground)
   (("1"
     (lemma "sin_k_pi2")
     (inst -1 "i!1")
     (replace -1 * rl)
     (hide -1)
     (rewrite "sin_eq_sin")
     (skosimp*)
     (prop)
     (("1" (inst + "k!1") (assert)) ("2" (inst + "k!1-i!1") (assert))))
    ("2"
     (skosimp*)
     (lemma "sin_k_pi2")
     (inst -1 "2*j!1+i!1")
     (replace -2 * rl)
     (hide -2)
     (replace -1)
     (hide -1)
     (lemma "expt_plus")
     (inst -1 "2*j!1" "i!1" "-1")
     (replace -1)
     (hide -1)
     (case "(-1) ^ (2 * j!1) = 1")
     (("1" (assert)) ("2" (hide 2) (rewrite "even_m1_pow"))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (ground)
   (("1"
     (lemma "cos_k_pi")
     (inst -1 "i!1")
     (replace -1 * rl)
     (hide -1)
     (rewrite "cos_eq_cos")
     (skosimp*)
     (prop)
     (("1" (inst + "k!1") (assert)) ("2" (inst + "k!1-i!1") (assert))))
    ("2"
     (skosimp*)
     (lemma "cos_k_pi")
     (inst -1 "2*j!1+i!1")
     (replace -2 * rl)
     (hide -2)
     (replace -1)
     (hide -1)
     (lemma "expt_plus")
     (inst -1 "2*j!1" "i!1" "-1")
     (replace -1)
     (hide -1)
     (case "(-1) ^ (2 * j!1) = 1")
     (("1" (assert)) ("2" (hide 2) (rewrite "even_m1_pow"))))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (hide -1)
   (expand "tan")
   (cross-mult -1)
   (invoke (case "sq(%1) = sq(%2)") (? -1 "%1 = %2"))
   (("1"
     (rewrite "sq_times")
     (rewrite "sq_times")
     (lemma "sin2_cos2")
     (inst?)
     (hide -3)
     (prop)
     (("1"
       (move-terms -1 l 1)
       (replace -1)
       (hide -1)
       (assert)
       (move-terms -1 r 2)
       (factor -1)
       (replace -2 - rl)
       (div-by -1 "sq(C!1)")
       (rewrite "sq_div"))
      ("2"
       (move-terms -1 l 2)
       (replace -1)
       (hide -1)
       (assert)
       (move-terms -1 l 2)
       (factor -1)
       (replace -2 - rl)
       (hide -2)
       (div-by -1 "sq(C!1)")
       (rewrite "sq_div")
       (assert))))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (rewrite "sin_plus")
   (rewrite "sin_atan2")
   (rewrite "cos_atan2")
   (lift-if)
   (assert)
   (split +)
   (("1" (flatten) (replace -1) (assert) (assert))
    ("2"
     (flatten)
     (case-replace
      "sqrt(1 + sq(y!1 / x!1)) = sqrt(sq(x!1)+sq(y!1))/sqrt(sq(x!1))")
     (("1" (assert))
      ("2"
       (hide 3)
       (lemma "sqrt_div")
       (inst - "sq(x!1) + sq(y!1)" "sq(x!1)")
       (split)
       (("1"
         (replace -1 :dir RL)
         (invoke (case "%1=%2") (! 1 l 1) (! 1 r 1))
         (("1" (assert))
          ("2" (hide -1 2 3) (cross-mult 1) (expand "sq") (assert))))
        ("2" (use "sq_gt_0") (assert))))
      ("3"
       (hide 3)
       (rewrite "sqrt_sq_abs")
       (expand "abs")
       (lift-if)
       (assert))
      ("4" (assert))))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "Tan?")
   (skosimp*)
   (lemma "sin_shift" ("a" "a!1-3*pi/2"))
   (lemma "sin_period" ("a" "-a!1" "j" "1"))
   (rewrite "sin_neg" -1)
   (assert))


proof_type: t_proof
decl_type: tcc
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "tan")
   (lemma "div_eq_zero")
   (inst -1 "cos(a!1)" "sin(a!1)")
   (("1" (replace -1 * lr) (propax)) ("2" (assert))))


proof_type: t_proof
decl_type: tcc
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("a"))
   (flatten)
   (expand "Tan?")
   (lemma "cos_neg" ("a" "a-pi/2"))
   (lemma "cos_shift" ("a" "a"))
   (replace -1)
   (assert))


proof_type: t_proof
decl_type: tcc
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "Tan?")
   (lemma "cos_sin" ("a" "3*pi/2-a!1"))
   (lemma "sin_period" ("a" "-a!1" "j" "1"))
   (replace -1 -2 rl)
   (rewrite "sin_neg" -2)
   (assert))


proof_type: t_proof
decl_type: tcc
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "Tan?")
   (lemma "neg_cos" ("a" "-a!1"))
   (rewrite "cos_neg" -1)
   (assert))


proof_type: t_proof
decl_type: tcc
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "Tan?")
   (lemma "sin_cos" ("a" "-a!1"))
   (rewrite "sin_neg" -1)
   (assert))


proof_type: t_proof
decl_type: tcc
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "Tan?")
   (lemma "cos_2a")
   (inst -1 "a!1/2")
   (replace -1 * lr)
   (hide -1)
   (prop)
   (replace -1 * lr)
   (assert)
   (lemma "sin2")
   (inst -1 "a!1/2")
   (expand "sq")
   (replace -1 * lr)
   (hide -1)
   (assert))


proof_type: t_proof
decl_type: tcc
library: trig
theory: trig_extra
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "Tan?")
   (lemma "sin_2a")
   (inst -1 "a!1/2")
   (replace -1 * lr)
   (hide -1)
   (prop)
   (replace -1 * lr)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: real_fun_supinf
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "sup")
   (use "adherence_sup")
   (auto-rewrite "Im")
   (apply (then (reduce :if-match nil) (inst?) (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: real_fun_supinf
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (expand "sup")
   (rewrite "lub_is_lub")
   (grind :if-match nil)
   (("1" (inst?) (inst?)) ("2" (inst?))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: real_fun_supinf
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "inf")
   (use "adherence_inf")
   (auto-rewrite "Im")
   (apply (then (reduce :if-match nil) (inst?) (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: real_fun_supinf
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (expand "inf")
   (rewrite "glb_is_glb")
   (grind :if-match nil)
   (("1" (inst?) (inst?)) ("2" (inst?))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: real_fun_supinf
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (auto-rewrite "supfun_neg_TCC1" "-")
   (use "supfun_is_sup2")
   (use "inffun_is_inf2" ("a" "- sup(- h!1)"))
   (ground)
   (case-replace "sup(-h!1) <= -inf(h!1)")
   (("1" (assert))
    ("2"
     (lemma "supfun_is_sup2")
     (inst - "-inf(h!1)" "-h!1")
     (assert)
     (skosimp*)
     (inst?)
     (inst?)
     (assert)
     (use "inffun_is_bound")
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: real_fun_supinf
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (auto-rewrite "inffun_neg_TCC1" "-")
   (use "inffun_is_inf2")
   (use "supfun_is_sup2" ("a" "- inf(- g!1)"))
   (ground)
   (case "inf(-g!1) >= -sup(g!1)")
   (("1" (assert))
    ("2"
     (hide 2)
     (hide -1)
     (lemma "inffun_is_inf2")
     (inst - "-sup(g!1)" "-g!1")
     (assert)
     (skosimp*)
     (inst?)
     (inst?)
     (assert)
     (use "supfun_is_bound")
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: real_fun_supinf
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (split)
   (("1"
     (flatten)
     (forward-chain "max_bounded[T]")
     (assert)
     (use "supfun_is_bound")
     (expand "is_maximum?")
     (use "supfun_is_sup2" ("g" "f!1"))
     (ground))
    ("2"
     (flatten)
     (assert)
     (expand "is_maximum?")
     (replace -2 + rl)
     (lemma "supfun_is_bound" ("g" "f!1"))
     (propax))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: real_fun_supinf
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (split)
   (("1"
     (flatten)
     (forward-chain "min_bounded[T]")
     (assert)
     (use "inffun_is_bound")
     (expand "is_minimum?")
     (use "inffun_is_inf2" ("h" "f!1"))
     (ground))
    ("2"
     (flatten)
     (assert)
     (expand "is_minimum?")
     (replace -2 + rl)
     (lemma "inffun_is_bound" ("h" "f!1"))
     (propax))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (expand "increasing?")
   (prop)
   (("1" (skolem!) (inst?) (assert))
    ("2"
     (induct "y")
     (("1" (skosimp) (assert))
      ("2" (skosimp*) (inst -1 "x!1") (inst -3 "j!1") (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (expand "decreasing?")
   (prop)
   (("1" (skolem!) (inst?) (assert))
    ("2"
     (induct "y")
     (("1" (skosimp) (assert))
      ("2" (skosimp*) (inst -1 "x!1") (inst -3 "j!1") (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (expand "strict_increasing?")
   (prop)
   (("1" (skolem!) (inst?) (assert))
    ("2"
     (induct "y")
     (("1" (skosimp) (assert))
      ("2" (skosimp*) (inst -1 "x!1") (inst -3 "j!1") (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (expand "strict_decreasing?")
   (prop)
   (("1" (skolem!) (inst?) (assert))
    ("2"
     (induct "y")
     (("1" (skosimp) (assert))
      ("2" (skosimp*) (inst -1 "x!1") (inst -3 "j!1") (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("f!1" _))
   (induct "i")
   (("1" (assert))
    ("2"
     (skosimp)
     (use "extract_incr1" ("i" "j!1" "j" "j!1+1"))
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (use "unbounded_extract1" ("f" "f!1"))
   (skolem!)
   (inst 1 "j!1+1")
   (use "extract_incr1" ("i" "j!1" "j" "j!1+1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "subseq")
   (skosimp*)
   (inst 1 "f!2 o f!1")
   (("1" (grind)) ("2" (rewrite "extract_composition"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "bijective?")
   (typepred "f!1")
   (expand "strict_increasing?")
   (split)
   (("1"
     (expand "injective?")
     (skosimp)
     (lemma "trich_lt" ("x" "x1!1" "y" "x2!1"))
     (split -1)
     (("1" (inst - "x1!1" "x2!1") (assert)) ("2" (propax))
      ("3" (inst - "x2!1" "x1!1") (assert))))
    ("2"
     (expand "surjective?")
     (skosimp*)
     (typepred "y!1")
     (expand "fullset")
     (expand "image")
     (skosimp)
     (inst + "x!1")
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :if-match nil)
   (inst-cp -5 "x!1")
   (inst -5 "y!1")
   (replace*)
   (inst? -4)
   (assert)
   (inst -3 "x!1" "y!1")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :if-match nil)
   (inst-cp -5 "x!1")
   (inst -5 "y!1")
   (inst -3 "x!1" "y!1")
   (inst -4 "f!1(x!1)" "f!1(y!1)")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: sequence_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "bounded?")
   (skosimp)
   (forward-chain "bounded_above_subseq")
   (forward-chain "bounded_below_subseq")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem + (_ "u!1"))
   (induct "n")
   (("1" (reduce))
    ("2"
     (skosimp*)
     (inst + "IF u!1(i!1) <= u!1(j!1+1) THEN i!1 ELSE j!1+1 ENDIF")
     (skosimp)
     (inst - "j!2")
     (smash))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :if-match nil)
   (use "minimum_prefix" ("n" "n!1"))
   (skolem!)
   (inst + "IF u!1(i!2) <= u!1(i!1) THEN i!2 ELSE i!1 ENDIF")
   (skolem!)
   (inst - "j!1")
   (inst - "j!1")
   (smash))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (name-replace "m" "mini(v!1, n!1)" :hide? nil)
   (expand "mini")
   (use "epsilon_ax[nat]")
   (replace -2)
   (delete -2)
   (split)
   (("1" (propax))
    ("2" (typepred "v!1") (inst?) (expand "has_minimum") (propax))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (rewrite "strict_incr_condition")
   (skolem!)
   (expand "h" 1 2)
   (use "min_prop1")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (expand* "hseq" "subseq")
   (inst + "h(v!1)")
   (("1" (assert)) ("2" (rewrite "h_increasing"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (rewrite "incr_condition")
   (skolem!)
   (expand "hseq")
   (name-replace "k" "h(v!1)(i!1)" :hide? nil)
   (expand "h" -1)
   (smash)
   (("1" (use "min_prop2" ("i" "h(v!1)(1 + i!1)")) (assert))
    ("2"
     (use "min_prop2" ("i" "h(v!1)(1 + i!1)"))
     (assert)
     (use "h_increasing")
     (expand "strict_increasing?")
     (inst - "i!1 - 1" "1 + i!1")
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (name-replace "k" "pick(w!1, n!1)" :hide? nil)
   (expand "pick")
   (lemma "epsilon_ax"
    ("p" "LAMBDA (i : nat) : n!1 <= i AND w!1(i) < w!1(n!1)"))
   (replace -2)
   (assert)
   (split)
   (("1" (propax))
    ("2"
     (delete -1 2)
     (use "no_minimum" ("n" "n!1"))
     (expand "has_minimum")
     (inst?)
     (assert)
     (skosimp)
     (inst?)
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (rewrite "strict_incr_condition")
   (skolem!)
   (expand "g" 1 2)
   (rewrite "pick_prop1"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (expand* "subseq" "gseq")
   (inst + "g(w!1)")
   (("1" (assert)) ("2" (rewrite "g_increasing"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (rewrite "strict_decr_condition")
   (skolem!)
   (expand "gseq")
   (expand "g" 1 1)
   (rewrite "pick_prop2"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :if-match nil)
   (inst + "LAMBDA i : i+n!1")
   (("1" (assert)) ("2" (skosimp) (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :if-match nil)
   (("1"
     (inst? +)
     (assert)
     (skosimp)
     (inst - "j!1 - n!1")
     (("1" (assert)) ("2" (assert))))
    ("2" (inst + "i!1 - n!1") (skosimp) (inst?) (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: monotone_subsequence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (auto-rewrite "strict_decr_to_decr[nat]" "gseq_decreasing")
   (case "FORALL n : has_minimum(u!1, n)")
   (("1"
     (assert)
     (inst + "hseq(u!1)")
     (ground)
     (("1" (rewrite "hseq_extraction"))
      ("2" (rewrite "hseq_increasing"))))
    ("2"
     (skolem!)
     (rewrite "suffix_hasmin" :dir rl)
     (assert)
     (inst + "gseq(suffix(u!1, n!1))")
     (ground)
     (use "gseq_extraction")
     (use "suffix_subseq")
     (forward-chain "transitive_subseq"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "convergence")
   (rewrite "abs_diff_0")
   (name "eps" "abs(l1!1 - l2!1)/3")
   (assert)
   (inst -2 "eps")
   (inst -3 "eps")
   (skolem!)
   (skolem!)
   (inst -2 "n!1+n!2")
   (inst -3 "n!1+n!2")
   (assert)
   (lemma "triangle2")
   (inst -1 "eps" "eps" "l1!1" "u!1(n!1+n!2)" "l2!1")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem-typepred)
   (name-replace "ll" "limit(v!1)" :hide? nil)
   (expand "limit")
   (expand "convergent?")
   (lemma "epsilon_ax" ("p" "LAMBDA (l: real): convergence(v!1, l)"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :defs nil :rewrites ("subseq" "convergence") :if-match nil)
   (delete -1 -2 -3 -4)
   (inst -1 "epsilon!1")
   (skolem!)
   (inst 1 "n!1")
   (skosimp)
   (inst? -2)
   (replace -2)
   (inst?)
   (assert)
   (use "extract_incr3")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :defs nil :rewrites ("convergence" "accumulation") :if-match
    nil)
   (inst?)
   (skolem!)
   (inst -5 "n!1+n!2")
   (inst 1 "n!1+n!2")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "accumulation")
   (name-replace "y" "g(u!1, a!1)(n!1 + 1)" :hide? nil)
   (expand "g" -1)
   (assert)
   (lemma "epsilon_ax"
    ("p"
     "LAMBDA (i: nat): g(u!1, a!1)(n!1) < i AND abs(u!1(i) - a!1) < 1 / (1 + n!1)"))
   (replace -2)
   (split -1)
   (("1" (assert))
    ("2"
     (inst -2 "1/(1+n!1)" "g(u!1, a!1)(n!1) + 1")
     (skosimp)
     (inst 1 "i!1")
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (rewrite "strict_incr_condition")
   (skolem!)
   (forward-chain "g_prop")
   (inst?)
   (ground))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (prop)
   (("1"
     (inst 1 "LAMBDA (i : nat) : u!1(g(u!1, a!1)(i))")
     (split)
     (("1"
       (forward-chain "g_increasing")
       (expand "subseq")
       (inst 1 "g(u!1, a!1)")
       (skolem!))
      ("2"
       (forward-chain "g_convergence")
       (expand "convergence")
       (skolem!)
       (lemma "archimedean2" ("x" "epsilon!1"))
       (skolem!)
       (inst 1 "a!2")
       (skosimp)
       (assert)
       (inst -2 "i!1 - 1")
       (assert)
       (case "1/i!1 <= 1/a!2")
       (("1" (assert)) ("2" (rewrite "both_sides_div_pos_le2"))))))
    ("2"
     (grind :defs nil :rewrites ("subseq" "convergence" "accumulation")
      :if-match nil)
     (inst? -6)
     (skolem!)
     (inst -5 "n!1 + n!2")
     (inst -6 "n!1+n!2")
     (inst?)
     (assert)
     (assert)
     (use "extract_incr3")
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :defs nil :rewrites ("cauchy" "accumulation" "convergence")
    :if-match nil)
   (inst -4 "epsilon!1/2")
   (skolem!)
   (inst -5 "epsilon!1/2" "n!1")
   (skosimp)
   (inst 1 "i!1")
   (skosimp)
   (inst -4 "i!1" "i!2")
   (assert)
   (lemma "triangle2")
   (assert)
   (inst -1 "epsilon!1/2" "epsilon!1/2" "u!1(i!2)" "u!1(i!1)" "a!1")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (rewrite "cauchy_accumulation" 1)
   (rewrite "accumulation_subsequence")
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (grind :defs nil :if-match nil :rewrites
    ("increasing?" "convergence"))
   (use "supfun_is_sup[nat]")
   (skolem!)
   (inst 1 "x!1")
   (skosimp)
   (inst -4 "x!1" "i!1")
   (assert)
   (use "supfun_is_bound" ("x" "i!1"))
   (assert)
   (expand "abs")
   (lift-if)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (grind :defs nil :if-match nil :rewrites
    ("decreasing?" "convergence"))
   (use "inffun_is_inf[nat]")
   (skolem!)
   (inst 1 "x!1")
   (skosimp)
   (inst -4 "x!1" "i!1")
   (assert)
   (use "inffun_is_bound" ("x" "i!1"))
   (assert)
   (expand "abs")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (use "monotone_subsequence")
   (skosimp)
   (use* "bounded_above_subseq" "bounded_below_subseq")
   (assert)
   (expand "subseq")
   (skolem!)
   (auto-rewrite "supfun_is_sup2[nat]" "inffun_is_inf2[nat]"
                 "supfun_is_bound[nat]" "inffun_is_bound[nat]"
                 "accumulation_subsequence")
   (ground)
   (("1"
     (forward-chain "increasing_bounded_convergence")
     (inst? +)
     (ground)
     (("1"
       (inst - "0")
       (use "supfun_is_bound" ("g" "s!1"))
       (use "inffun_is_bound" ("h" "w!1"))
       (assert))
      ("2" (skolem!) (inst?) (replace*) (assert))
      ("3" (inst?) (assert))))
    ("2"
     (forward-chain "decreasing_bounded_convergence")
     (inst? +)
     (ground)
     (("1" (skolem!) (inst?) (replace -5) (assert))
      ("2"
       (inst - "0")
       (use "inffun_is_bound" ("h" "s!1"))
       (use "supfun_is_bound" ("g" "w!1"))
       (assert))
      ("3" (inst?) (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (use "bolzano_weierstrass1")
   (skosimp)
   (rewrite "accumulation_subsequence")
   (skosimp)
   (inst?)
   (assert)
   (expand "convergent?")
   (inst?))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (case "bounded_above?(u!1) AND bounded_below?(u!1)")
   (("1"
     (ground)
     (case "a!1 <= inf(u!1) AND sup(u!1) <= b!1")
     (("1"
       (ground)
       (use "bolzano_weierstrass1")
       (skosimp)
       (inst + "a!2")
       (assert))
      ("2"
       (ground)
       (("1" (rewrite "inffun_is_inf2[nat]") (skolem!) (inst?) (assert))
        ("2"
         (rewrite "supfun_is_sup2[nat]")
         (skolem!)
         (inst?)
         (assert))))))
    ("2"
     (delete 2)
     (grind :if-match nil)
     (("1" (inst + "a!1") (skolem!) (inst?) (assert))
      ("2" (inst + "b!1") (skolem!) (inst?) (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 (_ "u!1"))
   (induct "n")
   (("1" (inst 1 "u!1(0)") (skosimp) (assert))
    ("2"
     (skosimp*)
     (inst 1 "max(a!1, u!1(j!1+1))")
     (skosimp)
     (inst?)
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 (_ "u!1"))
   (induct "n")
   (("1" (inst 1 "u!1(0)") (skosimp) (assert))
    ("2"
     (skosimp*)
     (inst 1 "min(a!1, u!1(j!1+1))")
     (skosimp)
     (inst -1 "i!1")
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "cauchy")
   (inst - "1")
   (skolem!)
   (inst - "n!1" _)
   (auto-rewrite "bounded_above?" "bounded_below?" "abs")
   (ground)
   (("1"
     (use "prefix_bounded1" ("n" "n!1"))
     (skolem!)
     (inst + "a!1 + 1")
     (skolem!)
     (inst-cp - "n!1")
     (inst - "x!1")
     (inst - "x!1")
     (assert))
    ("2"
     (use "prefix_bounded2" ("n" "n!1"))
     (skolem!)
     (inst + "a!1 - 1")
     (skolem!)
     (inst-cp - "n!1")
     (inst - "x!1")
     (inst - "x!1")
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :defs nil :rewrites ("convergent?" "convergence" "cauchy")
    :if-match nil)
   (delete -1 -2 -3)
   (inst -1 "epsilon!1/2")
   (skolem!)
   (inst? 1)
   (skosimp)
   (inst-cp -1 "i!1")
   (inst -1 "j!1")
   (assert)
   (rewrite "abs_diff_commute" -1)
   (rewrite "abs_diff_commute" -2)
   (lemma "triangle2")
   (inst -1 "epsilon!1/2" "epsilon!1/2" "u!1(j!1)" "l!1" "u!1(i!1)")
   (assert)
   (rewrite "abs_diff_commute" +)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (use "bolzano_weierstrass2")
   (("1"
     (skolem!)
     (expand "convergent?")
     (inst?)
     (rewrite "cauchy_accumulation"))
    ("2" (rewrite "cauchy_bounded"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_sequences
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (prop)
   (("1" (rewrite "convergence_cauchy1"))
    ("2" (rewrite "convergence_cauchy2"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: epsilon_lemmas
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "triangle")
   (inst -1 "(x1!1 - y1!1) * x2!1" "(x2!1 - y2!1) * y1!1")
   (auto-rewrite "abs_mult")
   (do-rewrite)
   (assert)
   (case "abs(x2!1 - y2!1) * abs(y1!1) <= e2!1 * abs(y1!1)")
   (("1"
     (case "abs(x1!1 - y1!1) * abs(x2!1) < e1!1 * (abs(y2!1) + e2!1)")
     (("1" (assert))
      ("2"
       (delete -1 -2 2)
       (rewrite "lt_times_lt_pos1" 1)
       (lemma "abs_diff")
       (inst -1 "x2!1" "y2!1")
       (assert))))
    ("2" (delete -1 2) (rewrite "le_times_le_pos" 1))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: epsilon_lemmas
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (case "EXISTS (u, v, w : posreal) :
                          u * v <= e!1/3 and abs(y1!1) * v < e!1/3 and abs(y2!1) * w < e!1/3")
   (("1"
     (skosimp)
     (inst 1 "min(u!1, w!1)" "v!1")
     (case "min(u!1, w!1) * v!1 <= u!1 * v!1 and abs(y2!1) * min(u!1, w!1) <= abs(y2!1) * w!1")
     (("1" (flatten) (assert))
      ("2"
       (delete -1 -2 -3 2)
       (split)
       (("1" (rewrite "both_sides_times_pos_le1") (assert))
        ("2" (rewrite "le_times_le_pos"))))))
    ("2"
     (delete 2)
     (name "f" "e!1/3")
     (replace -1)
     (case "FORALL (x : nonneg_real) : x * (f / (x+1)) < f")
     (("1"
       (inst-cp -1 "abs(y1!1)")
       (inst -1 "abs(y2!1)")
       (inst 1 "abs(y1!1) + 1" "f / (abs(y1!1) + 1)"
        "f / (abs(y2!1) + 1)")
       (split)
       (("1" (rewrite "div_cancel1") (assert)) ("2" (propax))
        ("3" (propax))))
      ("2"
       (delete -1 2)
       (skolem!)
       (rewrite "times_div1")
       (rewrite "div_mult_pos_lt1"))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: epsilon_lemmas
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (lemma "abs_eq_0" ("x" "x1!1"))
   (replace 1)
   (ground)
   (auto-rewrite "zero_times3")
   (case "abs(1 / x1!1 - 1 / y1!1) = abs(x1!1 - y1!1) / (abs(y1!1) * abs(x1!1))")
   (("1"
     (lemma "lt_div_lt_pos2")
     (inst - "abs(x1!1 - y1!1)" "abs(y1!1) * (abs(y1!1) - e1!1)"
      "abs(y1!1) * abs(x1!1)" "e1!1")
     (("1"
       (split)
       (("1" (assert) (replace -2) (propax)) ("2" (propax))
        ("3"
         (delete -1 5)
         (rewrite "both_sides_times_pos_le2")
         (use "abs_diff" ("x" "y1!1" "y" "x1!1"))
         (rewrite "abs_diff_commute" -2)
         (assert))))
      ("2"
       (delete -1 5)
       (case "abs(y1!1) * (abs(y1!1) - e1!1) > 0")
       (("1" (assert)) ("2" (delete 2) (rewrite "pos_times_gt"))))))
    ("2"
     (delete 5 -1)
     (auto-rewrite "minus_div1" "abs_div" "abs_mult")
     (assert)
     (rewrite "abs_diff_commute" 1)
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: epsilon_lemmas
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "abs_eq_0" ("x" "y1!1"))
   (assert)
   (case "EXISTS (c : posreal) : c < e!1 / (1 + e!1)")
   (("1"
     (skolem!)
     (inst 3 "abs(y1!1) * c!1")
     (("1"
       (split)
       (("1"
         (lemma "both_sides_times_pos_lt2"
          ("pz" "abs(y1!1)" "x" "c!1" "y" "1"))
         (assert)
         (case "e!1 / (1 + e!1) < (1 + e!1) / (1 + e!1)")
         (("1" (rewrite "div_simp") (assert))
          ("2" (rewrite "both_sides_div_pos_lt1"))))
        ("2"
         (lemma "both_sides_times_pos_lt2")
         (inst -1 "abs(y1!1)" "c!1" "e!1 * (1 - c!1)")
         (assert)
         (delete 2)
         (rewrite "div_mult_pos_lt2"))))
      ("2" (rewrite "pos_times_gt"))))
    ("2"
     (delete 2 3 4)
     (inst 1 "e!1 / (2 + e!1)")
     (rewrite "both_sides_div_pos_lt2"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: epsilon_lemmas
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "abs_eq_0" ("x" "y1!1"))
   (assert)
   (lemma "inv_epsilon1" ("y1" "y1!1" "e" "e!1 * abs(y1!1)"))
   (("1"
     (assert)
     (skosimp)
     (inst 3 "e1!1")
     (assert)
     (rewrite "div_mult_pos_lt1")
     (delete -2 4)
     (lemma "posreal_mult_closed"
      ("x" "abs(y1!1)" "y" "abs(y1!1) - e1!1"))
     (assert))
    ("2" (rewrite "posreal_mult_closed"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: epsilon_lemmas
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1" (grind))
    ("2"
     (flatten)
     (lemma "archimedean" ("px" "x!1-y!1"))
     (("1" (skosimp) (inst - "1/n!1") (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "convergence")
   (skosimp*)
   (inst -1 "epsilon!1/2")
   (inst -2 "epsilon!1/2")
   (skolem!)
   (skolem!)
   (inst 1 "n!1 + n!2")
   (skosimp)
   (inst -1 "i!1")
   (inst -2 "i!1")
   (assert)
   (expand "+")
   (lemma "triangle" ("x" "s1!1(i!1) - l1!1" "y" "s2!1(i!1) - l2!1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "convergence")
   (skosimp*)
   (inst -1 "epsilon!1")
   (expand "-")
   (skolem!)
   (inst? 1)
   (skosimp)
   (inst?)
   (assert)
   (lemma "abs_neg" ("x" "s1!1(i!1) - l1!1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (rewrite "diff_function")
   (lemma "cnv_seq_sum"
    ("s1" "s1!1" "s2" "- s2!1" "l1" "l1!1" "l2" "-l2!1"))
   (assert)
   (rewrite "cnv_seq_neg"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "convergence")
   (skosimp*)
   (lemma "prod_epsilon")
   (inst -1 "epsilon!1" "l1!1" "l2!1")
   (skolem!)
   (inst -2 "e1!1")
   (inst -3 "e2!1")
   (skolem!)
   (skolem!)
   (inst 1 "n!1 + n!2")
   (skosimp)
   (inst -2 "i!1")
   (inst -3 "i!1")
   (assert)
   (expand "*" 1 1)
   (lemma "prod_bound")
   (inst -1 "e1!1" "e2!1" "s1!1(i!1)" "s2!1(i!1)" "l1!1" "l2!1")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "convergence")
   (skosimp*)
   (assert)
   (lemma "inv_epsilon" ("y1" "l2!1" "e" "epsilon!1"))
   (assert)
   (skosimp)
   (inst -3 "e1!1")
   (skolem!)
   (inst 2 "n!1")
   (skosimp)
   (inst -3 "i!1")
   (assert)
   (expand "/")
   (assert)
   (lemma "inv_bound")
   (inst -1 "e1!1" "s3!1(i!1)" "l2!1")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (rewrite "div_function")
   (use "cnv_seq_prod" ("l2" "1/l2!1"))
   (assert)
   (rewrite "cnv_seq_inv"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "convergence")
   (skosimp*)
   (inst -1 "epsilon!1")
   (skolem!)
   (inst 1 "n!1")
   (skosimp)
   (inst -1 "i!1")
   (assert)
   (expand "abs" 1 2)
   (expand "abs" 1 1)
   (lift-if)
   (lemma "abs_diff" ("x" "s1!1(i!1)" "y" "l1!1"))
   (lemma "abs_diff" ("x" "l1!1" "y" "s1!1(i!1)"))
   (rewrite "abs_diff_commute" -1)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "convergence")
   (case "l2!1 < l1!1")
   (("1"
     (name "eps" "(l1!1 - l2!1) / 2")
     (assert)
     (inst -3 "eps")
     (inst -4 "eps")
     (skolem!)
     (skolem!)
     (inst -3 "n!1+n!2")
     (inst -4 "n!1+n!2")
     (inst -5 "n!1+n!2")
     (assert)
     (expand "abs")
     (lift-if)
     (ground))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (prop)
   (("1"
     (expand "convergence")
     (skosimp*)
     (inst - "epsilon!1")
     (skosimp*)
     (inst + "n!1")
     (skosimp*)
     (inst - "i!1 + m!1")
     (assert))
    ("2"
     (expand "convergence")
     (skosimp*)
     (inst - "epsilon!1")
     (skosimp*)
     (inst + "n!1+m!1")
     (skosimp*)
     (inst - "i!1-m!1")
     (("1" (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "convergence")
   (skosimp*)
   (inst -1 "epsilon!1")
   (inst -2 "epsilon!1")
   (skolem!)
   (skolem!)
   (inst 1 "N!1 + n!1 + n!2")
   (skosimp)
   (inst -1 "i!1")
   (inst -2 "i!1")
   (inst -3 "i!1")
   (assert)
   (flatten)
   (expand "abs")
   (lift-if)
   (split 1)
   (("1" (flatten) (assert)) ("2" (flatten) (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (auto-rewrite "cnv_seq_const" "const_fun")
   (lemma "squeezing_variant")
   (inst -1 "N!1" "l!1" "s!1" "const_fun(l!1)" "s1!1")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (auto-rewrite "cnv_seq_const" "const_fun")
   (lemma "squeezing_variant")
   (inst -1 "N!1" "l!1" "s!1" "s1!1" "const_fun(l!1)")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (use "squeezing_variant"
        ("s1" "s1!1" "s2" "s2!1" "s" "s!1" "N" "N!1"))
   (assert)
   (skosimp*)
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (prop)
   (("1" (forward-chain "cnv_seq_abs") (expand "abs" -1 2) (propax))
    ("2"
     (forward-chain "cnv_seq_neg")
     (assert)
     (lemma "squeezing"
      ("s1" "- abs(s!1)" "s2" "abs(s!1)" "s" "s!1" "l" "0"))
     (assert)
     (skolem!)
     (delete -1 -2 2)
     (expand "-")
     (expand "abs")
     (expand "abs")
     (lift-if)
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :exclude "convergence" :rewrites ("cnv_seq_sum") :if-match nil)
   (inst + "l!1 + l!2")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (expand "convergent?")
   (skolem!)
   (use "cnv_seq_inv")
   (assert)
   (rewrite "limit_def" -2 :dir rl)
   (assert)
   (inst?))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (expand "convergent?")
   (skosimp*)
   (use "cnv_seq_div")
   (assert)
   (rewrite "limit_def" -3 :dir rl)
   (assert)
   (inst?))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (rewrite "abs_convergence" +)
   (lemma "squeezing")
   (assert)
   (inst - "0" "abs(s!1)" "const_fun(0)" "abs(s1!1)")
   (assert)
   (split +)
   (("1" (rewrite "cnv_seq_const"))
    ("2" (lemma "abs_convergence") (inst - "s1!1") (assert))
    ("3"
     (skosimp*)
     (expand "const_fun")
     (assert)
     (inst - "n!1")
     (assert)
     (expand "abs" 1)
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (rewrite "abs_convergence" +)
   (lemma "squeezing_gen")
   (assert)
   (inst - "N!1" "0" "abs(s!1)" "const_fun(0)" "abs(s1!1)")
   (assert)
   (split +)
   (("1" (rewrite "cnv_seq_const"))
    ("2" (lemma "abs_convergence") (inst - "s1!1") (assert))
    ("3"
     (skosimp*)
     (expand "const_fun")
     (assert)
     (inst - "n!1")
     (assert)
     (expand "abs" 1)
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "limit_def" "limit_lemma" "convergent_nz?")
   (skolem-typepred)
   (assert)
   (rewrite "cnv_seq_inv"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "limit_def" "limit_lemma" "convergent_nz?")
   (skolem-typepred)
   (assert)
   (rewrite "cnv_seq_div"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (ground)
   (("1" (grind :exclude ("convergence")))
    ("2" (rewrite "limit_def") (expand "convergent?") (inst?))
    ("3" (rewrite "limit_def"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "convergence")
   (case "l2!1<l1!1")
   (("1"
     (name "eps" "(l1!1 - l2!1) / 2")
     (inst - "eps")
     (("1"
       (inst - "eps")
       (("1"
         (skosimp*)
         (inst - "n!1+n!2")
         (inst - "n!1+n!2")
         (inst - "n!1+n!2")
         (assert)
         (expand "abs")
         (grind))
        ("2" (assert))))
      ("2" (assert))))
    ("2" (assert))))


proof_type: j_proof
decl_type: tcc
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "convergent_const")
   (skosimp*)
   (expand "K_conversion")
   (expand "const_fun")
   (inst?))


proof_type: j_proof
decl_type: tcc
library: analysis
theory: convergence_ops
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (use "cnv_seq_const")
   (case-replace
    "K_conversion[nzreal, nat](b!1) = K_conversion[real, nat](b!1)")
   (("1"
     (assert)
     (auto-rewrite "limit_def" "convergent_nz?")
     (assert)
     (use "unique_limit" ("l2" "0"))
     (assert)
     (expand "const_fun")
     (propax))
    ("2" (expand "K_conversion") (propax))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :if-match nil :defs nil :rewrites ("subset?" "member" "adh"))
   (inst? -5)
   (skosimp)
   (inst? -4)
   (inst? 1)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (use "adherence_prop1" ("e" "min(e1!1, e2!1)" "E" "E!1"))
   (skosimp)
   (inst?)
   (ground))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :exclude ("abs" "adh") :if-match nil)
   (delete -1 -2 -3 -4)
   (rewrite "abs_diff_0")
   (name "eps" "abs(l1!1 - l2!1)")
   (assert)
   (inst -2 "eps/2")
   (inst -3 "eps/2")
   (skosimp*)
   (lemma "adherence_prop2"
    ("E" "E!1" "e1" "delta!1" "e2" "delta!2" "a" "a!1"))
   (skosimp)
   (inst?)
   (inst?)
   (assert)
   (delete -2 -3 1)
   (use "triangle2" ("y" "l2!1" "b" "eps/2"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :exclude ("abs" "adh") :if-match nil)
   (inst? -7)
   (skolem!)
   (inst 1 "delta!1")
   (skosimp)
   (inst? -5)
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :exclude ("abs" "adh") :if-match nil)
   (rewrite "abs_diff_0")
   (inst -5 "abs(l!1 - f!1(x!1))")
   (("1"
     (skolem!)
     (inst?)
     (assert)
     (rewrite "abs_diff_commute" -)
     (grind))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :exclude ("abs" "adh") :if-match nil)
   (delete -1 -2 -3 -4 -5 -6)
   (inst -1 "epsilon!1/2")
   (inst -2 "epsilon!1/2")
   (skosimp*)
   (inst 1 "min(delta!1, delta!2)")
   (skosimp)
   (inst?)
   (inst?)
   (assert)
   (lemma "triangle" ("x" "f1!1(x!1) - l1!1" "y" "f2!1(x!1) - l2!1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :if-match nil :exclude ("abs" "adh"))
   (delete -1 -2 -3 -4 -5)
   (inst -1 "epsilon!1")
   (skolem!)
   (inst 1 "delta!1")
   (skosimp)
   (inst?)
   (assert)
   (lemma "abs_neg" ("x" "f1!1(x!1) - l1!1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (rewrite "diff_function")
   (use "convergence_sum" ("f2" "-f2!1" "l2" "-l2!1"))
   (assert)
   (rewrite "convergence_neg"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :exclude ("abs" "adh") :if-match nil)
   (delete -1 -2 -3 -4 -5 -6)
   (lemma "prod_epsilon" ("y1" "l1!1" "y2" "l2!1" "e" "epsilon!1"))
   (skolem!)
   (inst -2 "e1!1")
   (inst -3 "e2!1")
   (skosimp*)
   (inst 1 "min(delta!1, delta!2)")
   (skosimp)
   (inst?)
   (inst?)
   (assert)
   (lemma "prod_bound")
   (inst -1 "e1!1" "e2!1" "f1!1(x!1)" "f2!1(x!1)" "l1!1" "l2!1")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (rewrite "scal_function")
   (rewrite "convergence_prod")
   (rewrite "convergence_const")
   (expand "convergence" -)
   (propax))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :if-match nil :exclude ("abs" "adh"))
   (delete -1 -2 -3 -4 -5)
   (lemma "inv_epsilon" ("y1" "l1!1" "e" "epsilon!1"))
   (assert)
   (skosimp)
   (inst? -3)
   (skolem!)
   (inst 2 "delta!1")
   (skosimp)
   (inst?)
   (assert)
   (lemma "inv_bound" ("e1" "e1!1" "x1" "g!1(x!1)" "y1" "l1!1"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (rewrite "div_function")
   (assert)
   (use "convergence_prod" ("l2" "1/l2!1"))
   (assert)
   (rewrite "convergence_inv"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :exclude ("abs" "adh") :if-match nil)
   (delete -1 -2 -3 -4)
   (case "l2!1 < l1!1")
   (("1"
     (name "eps" "(l1!1 - l2!1)/2")
     (assert)
     (inst -3 "eps")
     (inst -4 "eps")
     (skosimp*)
     (lemma "adherence_prop2"
      ("e1" "delta!1" "e2" "delta!2" "E" "E!1" "a" "a!1"))
     (skosimp)
     (inst?)
     (inst?)
     (inst?)
     (assert)
     (delete -2 -3)
     (grind))
    ("2" (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (use "convergence_const" ("b" "b!1"))
   (("1"
     (use "convergence_order" ("f2" "f!1"))
     (auto-rewrite "const_fun")
     (assert))
    ("2" (assert) (expand "convergence") (propax))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (use "convergence_const" ("b" "b!1"))
   (("1"
     (use "convergence_order" ("f1" "f!1"))
     (auto-rewrite "const_fun")
     (assert))
    ("2" (assert) (expand "convergence") (propax))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :if-match nil :exclude ("abs" "adh"))
   (inst 1 "epsilon!1")
   (skosimp)
   (inst?)
   (assert)
   (expand "abs")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: convergence_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :exclude ("abs" "adh") :if-match nil)
   (delete -1 -2 -3 -4 -5)
   (inst -1 "epsilon!1/2")
   (inst -2 "epsilon!1/2")
   (skosimp*)
   (inst 1 "min(delta!1, delta!2)")
   (skosimp)
   (inst?)
   (inst?)
   (inst?)
   (ground)
   (delete -6)
   (grind))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "convergence")
   (use "convergence_in_domain[T]")
   (expand "fullset")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "convergence")
   (skosimp*)
   (expand "restrict")
   (expand "convergence")
   (skosimp*)
   (expand "fullset")
   (inst + "epsilon!1")
   (skosimp*)
   (grind))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (prop)
   (("1"
     (expand "convergence")
     (expand "fullset")
     (expand "convergence")
     (flatten)
     (assert)
     (skosimp*)
     (inst -2 "epsilon!1")
     (skosimp*)
     (inst + "delta!1")
     (skosimp*)
     (inst?)
     (assert)
     (grind))
    ("2"
     (expand "convergence")
     (expand "fullset")
     (expand "convergence")
     (flatten)
     (assert)
     (skosimp*)
     (inst -2 "epsilon!1")
     (skosimp*)
     (inst + "delta!1")
     (skosimp*)
     (inst?)
     (assert)
     (grind))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (name-replace "ll" "lim(f!1, x0!1)" :hide? nil)
   (expand "lim" -)
   (lemma "epsilon_ax"
    ("p" "LAMBDA (l: real): convergence(f!1, x0!1, l)"))
   (assert)
   (typepred "x0!1")
   (expand "convergent?")
   (propax))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (use "lim_fun_lemma")
   (ground)
   (use "cv_unique" ("l2" "lim(f!1, x0!1)"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (rewrite "lim_fun_def")
   (expand "convergence")
   (expand "fullset")
   (expand "convergence")
   (typepred "l!1")
   (split +)
   (("1" (flatten))
    ("2"
     (flatten)
     (split +)
     (("1"
       (expand "adh")
       (skosimp*)
       (assert)
       (expand "convergent?")
       (skosimp*)
       (expand "convergence")
       (expand "convergence")
       (flatten)
       (expand "adh")
       (inst -3 "e!1")
       (skosimp*)
       (inst + "x!1"))
      ("2" (propax))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (prop)
   (("1" (expand "convergent?") (inst?))
    ("2" (rewrite "lim_fun_def") (expand "convergent?") (inst?))
    ("3" (rewrite "lim_fun_def"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (rewrite "lim_fun_def")
   (expand "convergent?")
   (skosimp)
   (assert)
   (inst 2 "1/l!1")
   (rewrite "cv_inv"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (rewrite "lim_fun_def")
   (expand "convergent?")
   (skosimp*)
   (assert)
   (inst 2 "l!1 / l!2")
   (rewrite "cv_div"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "lim_fun_lemma" "lim_fun_def" "sum_fun_convergent"
                 ("cv_sum"))
   (skosimp)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "lim_fun_lemma" "lim_fun_def" "neg_fun_convergent"
                 ("cv_neg"))
   (skosimp)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "lim_fun_lemma" "lim_fun_def" "diff_fun_convergent"
                 ("cv_diff"))
   (skosimp)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "lim_fun_lemma" "lim_fun_def" "prod_fun_convergent"
                 ("cv_prod"))
   (skosimp)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "lim_fun_lemma" "lim_fun_def" "const_fun_convergent"
                 ("cv_const"))
   (skosimp)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "lim_fun_lemma" "lim_fun_def" "scal_fun_convergent"
                 "cv_scal")
   (skosimp)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (delete 1)
   (auto-rewrite "lim_fun_def" "lim_fun_lemma" "inv_fun_convergent"
                 ("cv_inv"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (delete 1)
   (auto-rewrite "lim_fun_def" "lim_fun_lemma" "div_fun_convergent"
                 "cv_div")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "lim_fun_lemma" "lim_fun_def" "convergent_identity"
                 "cv_identity")
   (skolem!)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (name-replace "ll" "lim(f!1, a!1)" :hide? nil)
   (rewrite "lim_fun_def")
   (expand "convergence")
   (use "convergence_upper_bound[T]")
   (ground)
   (delete -1 -2 2)
   (grind))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (name-replace "ll" "lim(f!1, a!1)" :hide? nil)
   (rewrite "lim_fun_def")
   (expand "convergence")
   (use "convergence_lower_bound[T]" ("b" "b!1"))
   (ground)
   (delete -1 -2 2)
   (grind :if-match nil)
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (name-replace "ll1" "lim(f1!1, a!1)" :hide? nil)
   (name-replace "ll2" "lim(f2!1, a!1)" :hide? nil)
   (rewrite "lim_fun_def")
   (rewrite "lim_fun_def")
   (expand "convergence")
   (use "convergence_order[T]" ("l1" "ll1" "l2" "ll2"))
   (ground)
   (expand "fullset" +)
   (propax))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (name-replace "ll" "lim(f!1, a!1)" :hide? nil)
   (rewrite "lim_fun_def")
   (expand "convergence")
   (use "subset_convergence2[T]" ("E1" "E!1"))
   (ground)
   (("1" (delete -2 -3) (use "convergence_upper_bound[T]") (assert))
    ("2" (rewrite "subset_fullset"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (name-replace "ll" "lim(f!1, a!1)" :hide? nil)
   (rewrite "lim_fun_def")
   (expand "convergence")
   (use "subset_convergence2[T]" ("E1" "E!1"))
   (ground)
   (("1"
     (delete -2 -3)
     (use "convergence_lower_bound[T]" ("b" "b!1"))
     (ground)
     (delete -1 -2 2)
     (skosimp)
     (inst?)
     (assert))
    ("2" (rewrite "subset_fullset"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (name-replace "ll1" "lim(f1!1, a!1)" :hide? nil)
   (name-replace "ll2" "lim(f2!1, a!1)" :hide? nil)
   (rewrite "lim_fun_def")
   (rewrite "lim_fun_def")
   (expand "convergence")
   (use "subset_convergence2[T]" ("E1" "E!1"))
   (use "subset_convergence2[T]" ("E1" "E!1" "f" "f1!1"))
   (rewrite "subset_fullset")
   (ground)
   (delete -3 -4 -5 -6)
   (forward-chain "convergence_order[T]"))


proof_type: t_proof
decl_type: tcc
library: analysis
theory: lim_of_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (inst +
    "(LAMBDA (d: [f: [T -> real], {a | convergent?(f, a)}]):
                   choose(LAMBDA l : convergence(d`1, d`2, l)))")
   (skosimp*)
   (expand "nonempty?")
   (expand "empty?")
   (expand "member")
   (expand "convergence")
   (typepred "d!1`2")
   (expand "convergent?")
   (skosimp*)
   (inst - "l!1")
   (expand "convergence" -1)
   (propax))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuous_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite ("adherence_fullset[T]"
                  "convergence_def[T]"
                  "continuous?"))
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuous_functions
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "continuous_on?")
   (expand "convergence")
   (split +)
   (("1"
     (flatten)
     (skosimp*)
     (split +)
     (("1"
       (hide -1)
       (expand "adh")
       (expand "extend")
       (skosimp*)
       (typepred "y!1")
       (inst + "y!1")
       (assert))
      ("2"
       (skosimp*)
       (inst? -)
       (inst - "epsilon!1")
       (skosimp*)
       (inst + delta!1)
       (skosimp*)
       (inst?)
       (("1" (assert)) ("2" (expand "extend") (propax))))))
    ("2"
     (flatten)
     (skosimp*)
     (inst?)
     (flatten)
     (hide -1)
     (inst - "epsilon!1")
     (skosimp*)
     (inst + delta!1)
     (skosimp*)
     (inst?)
     (expand "extend")
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "continuous?")
   (expand "convergence")
   (skosimp*)
   (expand "o ")
   (inst -2 "epsilon!1")
   (skosimp*)
   (inst -1 "delta!1")
   (skosimp*)
   (inst 1 "n!1")
   (skosimp)
   (inst?)
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "accumulation")
   (expand "o ")
   (skosimp*)
   (expand "continuous?")
   (inst -2 "epsilon!1")
   (skosimp*)
   (inst - "delta!1" "n!1")
   (skosimp)
   (inst - "u!1(i!1)")
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (lemma "bolzano_weierstrass4")
   (inst -1 "a" "b" "u!1")
   (prop)
   (("1" (skosimp) (inst?) (assert)) ("2" (delete 2) (grind))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "bounded_above?")
   (inst 2 "lambda (n : nat) : epsilon! (x : J) : f!1(x) > n")
   (skosimp)
   (assert)
   (use "epsilon_ax[J]")
   (ground)
   (inst? 2)
   (delete 3)
   (skolem!)
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (use "unbounded_sequence")
   (assert)
   (skolem!)
   (use "bolz_weier")
   (skolem!)
   (expand "continuous?")
   (inst? -3)
   (forward-chain "continuity_accumulation[J]")
   (delete -2 -4 1)
   (expand "accumulation")
   (expand "o")
   (case "EXISTS (m : nat) : f!1(c!1) + 1 < m")
   (("1" (skolem!) (inst -2 "1" "m!1") (skosimp) (inst?) (grind))
    ("2"
     (delete -)
     (use "axiom_of_archimedes")
     (skolem!)
     (inst 1 "IF i!1 < 0 THEN 0 ELSE i!1 ENDIF")
     (("1" (lift-if) (assert)) ("2" (ground))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "bounded_from_above" ("f" "-f!1"))
   (rewrite "bounded_above_neg[J]")
   (assert)
   (rewrite "neg_fun_continuous [J]"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (forward-chain "bounded_from_above")
   (assert)
   (inst 1
    "LAMBDA (n : nat) : epsilon! (x : J) : sup(f!1) - f!1(x) < 1 / (1 + n)")
   (skolem!)
   (lemma "epsilon_ax"
    ("p" "LAMBDA (x: J): sup(f!1) - f!1(x) < 1 / (1 + n!1)"))
   (assert)
   (delete 2)
   (lemma "supfun_is_sup[J]" ("g" "f!1" "epsilon" "1/(1+n!1)"))
   (skolem!)
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (forward-chain "bounded_from_above")
   (assert)
   (forward-chain "max_extraction")
   (skolem!)
   (use "bolz_weier")
   (skolem!)
   (expand "continuous?")
   (inst? -4)
   (forward-chain "continuity_accumulation[J]")
   (delete -2 -4 -5)
   (inst? 1)
   (expand "accumulation")
   (expand "o")
   (use "supfun_is_bound[J]")
   (name "eps" "sup(f!1) - f!1(c!1)")
   (assert)
   (use "archimedean2" ("x" "eps/2"))
   (skolem!)
   (inst -4 "eps/2" "a!1")
   (skosimp)
   (inst -6 "i!1")
   (case "1 / (1 + i!1) < 1 / a!1")
   (("1" (expand "abs") (lift-if) (ground))
    ("2" (rewrite "both_sides_div_pos_lt2" 1) (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (forward-chain "sup_is_reached")
   (skolem!)
   (inst?)
   (rewrite "max_upper_bound[J]")
   (assert)
   (rewrite "bounded_from_above"))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (use "sup_is_reached" ("f" "-f!1"))
   (split)
   (("1"
     (skolem!)
     (rewrite "supfun_neg[J]")
     (("1" (expand "-") (inst?) (assert))
      ("2" (rewrite "bounded_from_below"))))
    ("2" (rewrite "neg_fun_continuous [J]"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (use "maximum_exists" ("f" "-f!1"))
   (split)
   (("1" (skolem!) (rewrite "max_neg[J]") (inst?))
    ("2" (rewrite "neg_fun_continuous [J]"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (name "E" "{y:real| a <= y AND y <= b AND f!1(y) < x!1}")
   (("1"
     (case "nonempty?(E) AND bounded_above?(E)")
     (("1"
       (assert)
       (ground)
       (case "a <= lub(E) AND lub(E) <= b")
       (("1"
         (assert)
         (ground)
         (hide -1 -2 -3 -4)
         (expand "continuous?")
         (inst - "lub(E)")
         (inst + "lub(E)")
         (auto-rewrite "abs" "subset_fullset[real]")
         (case "x!1 < f!1(lub(E))")
         (("1"
           (assert)
           (expand "continuous?")
           (inst - "f!1(lub(E)) - x!1")
           (skolem!)
           (use "adherence_sup" ("epsilon" "delta!1"))
           (skolem-typepred)
           (replace -4 -1 rl)
           (assert)
           (use "lub_is_bound" ("U" "E" "x" "x!2"))
           (ground)
           (inst - "x!2")
           (assert))
          ("2"
           (name "F" "{y:real | lub(E) < y AND y <= b}")
           (rewrite "continuity_def[J]")
           (lemma "subset_convergence2[J]" ("E1" "F"))
           (inst - "fullset[real]" "f!1" "lub(E)" "f!1(lub(E))")
           (("1"
             (ground)
             (("1"
               (delete -4)
               (lemma "convergence_lower_bound[J]" ("b" "x!1"))
               (inst - "F" "f!1" "lub(E)" "f!1(lub(E))")
               (assert)
               (skosimp)
               (replace -3 -1 rl)
               (assert)
               (use "lub_is_bound" ("U" "E" "x" "x!2"))
               (("1" (assert)) ("2" (replace -4 + rl) (assert))))
              ("2"
               (hide -1 -2 -4 -5 2 3)
               (expand "convergence")
               (expand "convergence")
               (propax))))
            ("2"
             (replace -1 + rl)
             (expand "adh")
             (skosimp)
             (case "b < lub(E) + e!1")
             (("1" (assert) (inst + "b") (assert))
              ("2" (assert) (inst + "lub(E) + e!1/2") (assert))))))))
        ("2"
         (delete -1 -2 -4 -5 -6 2)
         (ground)
         (("1" (rewrite "lub_is_bound") (replace -1 + rl) (assert))
          ("2"
           (rewrite "lub_is_lub")
           (skolem-typepred)
           (replace -2 - rl)
           (assert)
           (assert))))))
      ("2"
       (replace -1 + rl)
       (delete -1 -2 2)
       (grind :if-match nil)
       (("1" (inst + "b") (skolem!) (assert))
        ("2" (inst - "a") (assert))))))
    ("2" (skosimp) (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (use "intermediate_value1")
   (assert)
   (split)
   (("1" (propax)) ("2" (inst 2 "a") (assert))
    ("3" (inst 2 "b") (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "intermediate_value1" ("f" "-f!1" "x" "-x!1"))
   (auto-rewrite "neg_fun_continuous [J]" "-")
   (assert)
   (skolem!)
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (use "intermediate_value3")
   (assert)
   (split)
   (("1" (propax)) ("2" (inst 2 "b") (assert))
    ("3" (inst 2 "a") (assert))))


proof_type: t_proof
decl_type: tcc
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (inst +
    "(LAMBDA (f: {f | continuous?[J](f)}): choose({xj: J | is_maximum[J](xj, f)}))")
   (skosimp*)
   (lemma "maximum_exists")
   (inst?)
   (assert)
   (skosimp*)
   (expand "nonempty?")
   (expand "empty?")
   (inst?)
   (expand "member")
   (propax))


proof_type: t_proof
decl_type: tcc
library: analysis
theory: continuity_interval
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (inst +
    "(LAMBDA (f: {f | continuous?[J](f)}): choose({xj: J | is_minimum[J](xj, f)}))")
   (skosimp*)
   (lemma "minimum_exists")
   (inst?)
   (assert)
   (skosimp*)
   (expand "nonempty?")
   (expand "empty?")
   (inst?)
   (expand "member")
   (propax))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuous_functions_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp :preds? t)
   (auto-rewrite "sub_interval")
   (expand "continuous?")
   (skolem!)
   (inst -3 "x0!1")
   (expand "continuous?")
   (skosimp*)
   (inst -3 "epsilon!1")
   (skolem!)
   (inst 1 "delta!1")
   (skosimp)
   (inst -3 "x!1")
   (expand "R")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "deriv_domain")
   (expand "adh")
   (expand "deriv_domain?")
   (expand "fullset")
   (skosimp*)
   (inst - "e!1" "x!1")
   (skosimp*)
   (inst?)
   (expand "A")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "deriv_domain")
   (expand "deriv_domain?")
   (expand "adh")
   (skosimp*)
   (inst?)
   (inst - "x!1")
   (skosimp*)
   (inst + "y!1")
   (("1" (expand "fullset") (propax)) ("2" (expand "A") (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :exclude ("abs" "adh") :rewrites
    ("deriv_TCC" "adherence_fullset[T]") :if-match nil)
   (("1"
     (inst? -4)
     (skolem!)
     (inst + "delta!1")
     (skosimp)
     (inst - "x!2 - x!1")
     (("1" (assert)) ("2" (delete -5) (grind))))
    ("2"
     (inst? -4)
     (skolem!)
     (inst + "delta!1")
     (skosimp :preds? t)
     (assert)
     (inst?)
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (rewrite "continuous_lim" :dir rl)
   (case-replace
    "(LAMBDA (h: (A(x!1))): f!1(h + x!1)) =
               const_fun(f!1(x!1)) + I[(A(x!1))] * NQ(f!1, x!1)")
   (("1"
     (delete -1)
     (auto-rewrite-theory "lim_of_functions[(A(x!1))]" :exclude
                          ("convergence"
                           "convergence_def"
                           "convergent?"
                           "lim"
                           "lim_fun_lemma"
                           "lim_fun_def")
                          :always? t)
     (auto-rewrite "deriv_TCC")
     (grind :defs nil))
    ("2"
     (delete -1 2)
     (apply-extensionality :hide? t)
     (("1" (grind)) ("2" (grind))))
    ("3" (delete -1 2) (grind))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "deriv_TCC")
   (skosimp)
   (name "F" "LAMBDA (h : (A(x!1))) : f1!1(x!1 + h)")
   (("1"
     (case-replace
      "NQ(f1!1 * f2!1, x!1) = f2!1(x!1) * NQ(f1!1, x!1) + F * NQ(f2!1, x!1)")
     (("1"
       (auto-rewrite-theory "lim_of_functions[(A(x!1))]" :exclude
                            ("convergence"
                             "convergence_def"
                             "convergent?"
                             "lim"
                             "lim_fun_def"
                             "lim_e_del")
                            :always? t)
       (forward-chain "deriv_continuous" -3)
       (use "continuous_lim")
       (replace*)
       (grind :defs nil))
      ("2"
       (replace -1 + rl)
       (delete -1 -2 -3 2)
       (apply-extensionality :hide? t)
       (("1" (grind)) ("2" (delete 2) (grind))))))
    ("2" (delete -1 -2 2) (grind))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (auto-rewrite "deriv_TCC")
   (skosimp)
   (name "F" "LAMBDA (h : (A(x!1))) : g!1(x!1 + h)")
   (("1"
     (case-replace "NQ(1/g!1, x!1) = - NQ(g!1, x!1) / (g!1(x!1) * F)")
     (("1"
       (rewrite "cv_div[(A(x!1))]")
       (("1" (rewrite "cv_neg[(A(x!1))]"))
        ("2"
         (rewrite "cv_scal[(A(x!1))]")
         (use "continuous_lim" ("f" "g!1"))
         (ground)
         (forward-chain "deriv_continuous"))))
      ("2"
       (replace -1 + rl)
       (delete -1 -2 2)
       (apply-extensionality :hide? t)
       (("1" (grind)) ("2" (delete 2) (grind :rewrites "zero_times3"))))
      ("3"
       (replace -1 + rl)
       (delete -1 -2 2)
       (grind :rewrites "zero_times3"))))
    ("2" (delete -1 2) (grind))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (prop)
   (("1" (expand "derivable?") (expand "convergent?") (inst + "l!1"))
    ("2"
     (expand "deriv")
     (rewrite "lim_fun_def")
     (hide 2)
     (expand "convergent?")
     (inst + "l!1"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (case "derivable?(f!1)")
   (("1"
     (assert)
     (apply-extensionality 1 :hide? t)
     (lemma "deriv_def")
     (inst?)
     (expand "deriv" 1)
     (inst - "fp!1(x!1)" "x!1")
     (assert)
     (inst?))
    ("2"
     (expand "derivable?")
     (skosimp*)
     (expand "derivable?")
     (expand "convergent?")
     (inst -1 "x!1")
     (expand "convergence")
     (inst + "fp!1(x!1)"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_alt
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem!)
   (rewrite "convergence_equiv[(A[T](x!1))]")
   (expand "derivable?")
   (expand "deriv")
   (propax))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_alt
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (grind :exclude ("abs" "adh") :rewrites
    ("deriv_TCC[T]" "adherence_fullset[T]") :if-match nil)
   (("1"
     (inst 1
      "LAMBDA y : IF y=x!1 THEN 0 ELSE NQ(f!1, x!1)(y - x!1) - D!1 ENDIF")
     (("1"
       (split)
       (("1"
         (assert)
         (skolem!)
         (inst -3 "epsilon!1")
         (skolem!)
         (inst 1 "delta!1")
         (skosimp)
         (lift-if)
         (ground)
         (inst -4 "x!2 - x!1")
         (assert))
        ("2"
         (delete -)
         (grind)
         (auto-rewrite "times_div2" "div_distributes_minus")
         (assert)
         (use "div_cancel3" ("y" "f!1(y!1) - f!1(x!1)"))
         (ground))))
      ("2" (skosimp) (assert))))
    ("2"
     (inst? -5)
     (skolem!)
     (inst 1 "delta!1")
     (skosimp :preds? t)
     (assert)
     (inst -7 "x!1 + x2!1")
     (inst -8 "x!1+x2!1")
     (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_alt
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("D" "f" "x"))
   (lemma "derivative_equivalence1" ("f" "f" "D" "D" "x" "x"))
   (replace -1 1)
   (hide -1)
   (lemma "derivative_equivalence2" ("f" "f" "D" "D" "x" "x"))
   (replace -1 1)
   (hide -1)
   (split)
   (("1"
     (flatten)
     (skolem!)
     (flatten -1)
     (inst + "LAMBDA (z:T): D+phi!1(z)")
     (split 1)
     (("1"
       (expand "convergence")
       (expand "fullset")
       (expand "convergence")
       (propax))
      ("2" (propax))))
    ("2"
     (skosimp*)
     (inst + "LAMBDA (z:T): psi!1(z) - D")
     (split 1)
     (("1" (expand "convergence") (expand "convergence") (propax))
      ("2" (skosimp*) (inst - "y!1") (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_alt
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (prop)
   (("1"
     (inst - "abs(x!1)/2")
     (("1" (assert))
      ("2"
       (assert)
       (mult-by 1 "2")
       (assert)
       (lemma "abs_eq_0")
       (inst?)
       (assert))))
    ("2" (replace -1) (skosimp*) (grind))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_alt
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (case "adh[(A[T](x!1))](fullset[real])(0)")
   (("1"
     (prop)
     (("1"
       (case "convergence[(A(x!1))](const_fun(fp!1(x!1)),0,fp!1(x!1))")
       (("1"
         (lemma "cv_diff[(A(x!1))]")
         (hide -2)
         (inst?)
         (reveal -2)
         (inst?)
         (assert)
         (hide -1 -3)
         (expand "const_fun")
         (assert)
         (inst?)
         (assert)
         (expand "-")
         (propax))
        ("2"
         (hide 2)
         (expand "convergence")
         (rewrite "convergence_const[(A(x!1))]"))))
      ("2"
       (skosimp*)
       (replace -2)
       (hide -2)
       (lemma "cv_sum[(A(x!1))]")
       (inst?)
       (inst - "const_fun(fp!1(x!1))" "fp!1(x!1)")
       (assert)
       (lemma "cv_const[(A(x!1))]")
       (inst?)
       (assert)
       (hide -1 -3)
       (expand "const_fun")
       (expand "+")
       (assert)
       (case-replace
        "(LAMBDA (x_1: ((A(x!1)))): NQ(f!1, x!1)(x_1)) = NQ(f!1, x!1)")
       (apply-extensionality 1 :hide? t))))
    ("2" (hide-all-but 1) (rewrite "adh_A_lem"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_alt
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (prop)
   (("1"
     (lemma "derivative_squeeze")
     (inst?)
     (replace -2)
     (flatten)
     (skosimp*)
     (inst + "abs(HH!1)")
     (assert)
     (rewrite "conv_0_0_abs")
     (assert)
     (replace -2)
     (assert)
     (inst + "1")
     (skosimp*)
     (expand "abs" 1 2)
     (assert))
    ("2"
     (skosimp*)
     (lemma "derivative_squeeze")
     (inst?)
     (assert)
     (inst + "(LAMBDA (h: (A(x!1))): (NQ(f!1, x!1)(h) - fp!1(x!1)))")
     (hide 2)
     (expand "convergence")
     (expand "convergence")
     (flatten)
     (assert)
     (skosimp*)
     (inst -2 "epsilon!1")
     (skosimp*)
     (inst + "min(delta!1,delta!2)")
     (skosimp*)
     (inst -5 "x!2")
     (inst -4 "x!2")
     (assert)
     (hide -1 -2 -3)
     (name-replace "DD" "NQ(f!1, x!1)(x!2) - fp!1(x!1)")
     (grind))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivatives_alt
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (auto-rewrite "deriv_TCC[T]" "A[T]")
   (expand "convergence")
   (lemma "convergence_locally_constant"
    ("f"
     "NQ(f!1, c!1)"
     "E"
     "{x:real| abs(x) < min(c!1 - a!1, b!1 - c!1)}"
     "b"
     "0"
     "a"
     "0"))
   (("1"
     (ground)
     (("1"
       (grind :exclude ("min" "abs" "NQ" "adh") :if-match nil)
       (inst? -4)
       (skolem!)
       (inst 1 "min(delta!1, min(c!1 - a!1, b!1 - c!1))")
       (("1" (skosimp) (inst? -4) (assert))
        ("2" (delete -3 -4 -7) (expand "min") (smash))))
      ("2"
       (delete 2)
       (skosimp :preds? t)
       (assert)
       (inst -5 "c!1 + x!1")
       (grind))))
    ("2"
     (delete -3 2)
     (lemma "deriv_TCC[T]" ("x" "c!1"))
     (grind :exclude ("abs" "min") :if-match nil)
     (inst -3 "min(e!1, min(c!1 - a!1, b!1 - c!1))")
     (("1" (skosimp) (inst?) (assert)) ("2" (delete 2) (grind))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivative_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "convergence")
   (expand "fullset")
   (expand "NQ")
   (prop)
   (("1"
     (expand "convergence")
     (flatten)
     (prop)
     (("1"
       (hide -2)
       (expand "adh")
       (skosimp*)
       (inst -1 "e!1")
       (skosimp*)
       (typepred "x!2")
       (expand "A")
       (inst + "x!1+x!2")
       (grind))
      ("2"
       (skosimp*)
       (inst - "epsilon!1")
       (skosimp*)
       (inst + "delta!1")
       (skosimp*)
       (inst -3 "x!2-x!1")
       (("1" (assert)) ("2" (hide 2) (expand "A") (propax))))))
    ("2"
     (expand "convergence")
     (prop)
     (("1"
       (expand "adh")
       (skosimp*)
       (hide -2)
       (inst -1 "e!1")
       (skosimp*)
       (typepred "x!2")
       (typepred "x!1")
       (inst + "x!2-x!1")
       (expand "A")
       (propax))
      ("2"
       (skosimp*)
       (inst - "epsilon!1")
       (skosimp*)
       (inst + "delta!1")
       (skosimp*)
       (inst -3 "x!1+x!2")
       (("1" (assert))
        ("2"
         (hide -1 2)
         (typepred "x!1")
         (typepred "x!2")
         (expand "A")
         (propax))))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: derivative_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "derivative_alt")
   (lemma "derivative_equivalence1[T]")
   (("1"
     (split +)
     (("1"
       (flatten)
       (skosimp*)
       (inst - "gg!1(x!1)" "ff!1" "x!1")
       (inst - "gg!1(x!1)" "ff!1" "x!1")
       (assert)
       (hide 1)
       (assert)
       (expand "derivable?" -1)
       (inst?)
       (assert)
       (replace -2 * rl)
       (expand "deriv" 1 2)
       (propax))
      ("2"
       (skosimp*)
       (case "derivable?(ff!1)")
       (("1"
         (assert)
         (apply-extensionality 1 :hide? t)
         (inst - "gg!1(x!1)" "ff!1" "x!1")
         (inst - "gg!1(x!1)" "ff!1" "x!1")
         (assert)
         (inst?)
         (expand "deriv" 1)
         (assert))
        ("2"
         (hide 2)
         (expand "derivable?" 1)
         (skosimp*)
         (inst - "gg!1(x!1)" "ff!1" "x!1")
         (assert)
         (inst - "gg!1(x!1)" "ff!1" "x!1")
         (assert)
         (hide 1 2)
         (inst?))))))
    ("2" (hide 2) (skosimp*) (hide -1) (lemma "not_one_element") (inst?))
    ("3" (hide -1 2) (skosimp*) (lemma "deriv_domain") (inst?))))


proof_type: t_proof
decl_type: tcc
library: analysis
theory: derivative_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (lemma "connected_domain")
   (lemma not_one_element)
   (lemma "connected_deriv_domain[T]")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: unif_cont_fun
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (inst 1
    "(LAMBDA (j: posnat): choose({xy: [real,real] | P3!1(xy`1,xy`2,j)})`1)"
    "(LAMBDA (j: posnat): choose({xy: [real,real] |  P3!1(xy`1,xy`2,j)})`2)")
   (("1" (skosimp*) (inst -1 "k!1") (assert))
    ("2"
     (skosimp*)
     (expand "nonempty?")
     (expand "empty?")
     (expand "member")
     (inst -2 "j!1")
     (skosimp*)
     (inst -1 "(x!1,y!1)"))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: unif_cont_fun
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: FIX
script:
  (""
   (skosimp*)
   (assert)
   (flatten)
   (expand "uniformly_continuous?")
   (skosimp*)
   (case "EXISTS (N: posnat): FORALL (x, y: ({xx: T | a!1 <= xx AND xx <= b!1})):
                                 abs(x - y) < 1/N IMPLIES abs(f!1(x) - f!1(y)) < epsi!1")
   (("1" (skosimp*) (inst + "1/N!1"))
    ("2"
     (hide 2)
     (case "EXISTS (eps: posreal): FORALL (N: posnat):
                                     EXISTS (x, y: ({xx: T | a!1 <= xx AND xx <= b!1})):
                                       abs(x - y) < 1 / N AND abs(f!1(x) - f!1(y)) >= eps")
     (("1"
       (skosimp*)
       (hide 1)
       (lemma "getem_scaf4")
       (inst -1
        "(LAMBDA (x,y: real,n:posnat): abs(x - y) < 1 / n AND a!1 <= x AND x <= b!1 AND a!1 <= y AND y <= b!1 AND abs(f!1(x) - f!1(y)) >= eps!1)")
       (("1"
         (split -1)
         (("1"
           (hide -2)
           (skosimp*)
           (name "A"
                 "(LAMBDA (kk: posnat): {xx: real | EXISTS (j: posnat): j >= kk AND xx = XX!1(j)})")
           (name "alpha" "(LAMBDA (kk: posnat): lub(A(kk)))")
           (("1"
             (name "CC"
                   "glb({alphs: real | EXISTS (jj: posnat): alphs = alpha(jj)})")
             (("1"
               (case "a!1 <= CC AND CC <= b!1")
               (("1"
                 (flatten)
                 (rewrite "continuous_on_def")
                 (inst -8 "CC")
                 (("1"
                   (expand "convergence")
                   (flatten)
                   (inst -9 "eps!1/2")
                   (skosimp*)
                   (expand "extend")
                   (case "EXISTS (kk: posnat): CC <= alpha(kk) AND alpha(kk) < CC + delta!1/2 AND 1/kk < delta!1/2")
                   (("1"
                     (skosimp*)
                     (case "EXISTS (nn: posnat): alpha(kk!1) - delta!1/2 < XX!1(nn) AND XX!1(nn) <= alpha(kk!1) AND nn >= kk!1")
                     (("1"
                       (skosimp*)
                       (inst -12 "nn!1")
                       (flatten)
                       (case "1/nn!1 < delta!1/2")
                       (("1"
                         (case "CC - delta!1/2 <= XX!1(nn!1) AND XX!1(nn!1) <= CC + delta!1/2")
                         (("1"
                           (case "CC - delta!1 < YY!1(nn!1) AND YY!1(nn!1) < CC + delta!1")
                           (("1"
                             (flatten)
                             (lemma "triangle")
                             (inst -1 "f!1(XX!1(nn!1)) -f!1(CC)"
                              "f!1(CC) - f!1(YY!1(nn!1))")
                             (("1"
                               (assert)
                               (inst-cp -26 "XX!1(nn!1)")
                               (inst -26 "YY!1(nn!1)")
                               (split -26)
                               (("1"
                                 (split -27)
                                 (("1"
                                   (hide -4 -5 -7 -8 -9 -11)
                                   (case-replace
                                    "abs(f!1(CC) - f!1(YY!1(nn!1))) = abs(f!1(YY!1(nn!1))-f!1(CC))")
                                   (("1" (assert))
                                    ("2" (hide-all-but 1) (grind))))
                                  ("2" (propax))
                                  ("3" (propax))
                                  ("4"
                                   (hide-all-but (-5 -6 1))
                                   (name-replace "xxnn" "XX!1(nn!1)")
                                   (grind))))
                                ("2" (propax)) ("3" (propax))
                                ("4"
                                 (hide-all-but (-2 -3 1))
                                 (name-replace "yynn" "YY!1(nn!1)")
                                 (grind))))
                              ("2"
                               (lemma "connected_domain")
                               (expand "connected?")
                               (inst - "a!1" "b!1" "CC")
                               (assert))))
                            ("2"
                             (hide-all-but (-1 -2 -14 1))
                             (flatten)
                             (grind))))
                          ("2"
                           (assert)
                           (hide-all-but (-1 -2 -3 -5 -6 -7 -8 -9 1))
                           (name-replace "xxnn" "XX!1(nn!1)")
                           (assert))))
                        ("2"
                         (assert)
                         (assert)
                         (hide-all-but (-3 -6 1))
                         (case "1/nn!1 <= 1/kk!1")
                         (("1" (assert))
                          ("2" (hide -2 2) (cross-mult 1))))))
                      ("2"
                       (hide -9 -11 -12)
                       (typepred "lub(A(kk!1))")
                       (("1"
                         (expand "least_upper_bound?")
                         (flatten)
                         (inst -2 "alpha(kk!1)- delta!1 / 2")
                         (split -2)
                         (("1" (assert) (replace -9 -1 rl) (assert))
                          ("2"
                           (expand "upper_bound?")
                           (skosimp*)
                           (typepred "s!1")
                           (replace -10 -1 rl)
                           (assert)
                           (skosimp*)
                           (inst + "j!1")
                           (assert)
                           (replace -2)
                           (hide -2)
                           (case "CC <= XX!1(j!1)")
                           (("1"
                             (assert)
                             (replace -10 * rl)
                             (assert)
                             (inst - "XX!1(j!1)"))
                            ("2" (inst - "XX!1(j!1)") (assert))))))
                        ("2"
                         (hide 2)
                         (prop)
                         (("1"
                           (expand "nonempty?")
                           (expand "empty?")
                           (expand "member")
                           (replace -9 -1 rl)
                           (assert)
                           (inst -1 "XX!1(kk!1)")
                           (inst + "kk!1")
                           (assert))
                          ("2"
                           (expand "bounded_above?")
                           (inst + "b!1")
                           (expand "upper_bound?")
                           (skosimp*)
                           (typepred "s!1")
                           (replace -9 -1 rl)
                           (assert)
                           (skosimp*)
                           (reveal -1)
                           (inst -1 "j!1")
                           (assert))))))))
                    ("2"
                     (typepred
                      "glb({alphs: real | EXISTS (jj: posnat): alphs = alpha(jj)})")
                     (expand "greatest_lower_bound?")
                     (flatten)
                     (expand "lower_bound?")
                     (replace -5 -)
                     (inst -2 "CC+delta!1/2")
                     (assert)
                     (skosimp*)
                     (typepred "s!1")
                     (skosimp*)
                     (case "FORALL (ii: posnat): ii >= jj!1 IMPLIES alpha(ii) <= alpha(jj!1)")
                     (("1"
                       (case "(EXISTS (jk: posnat): jk >= jj!1 AND 1/jk < delta!1/2)")
                       (("1"
                         (skosimp*)
                         (inst 2 "jk!1")
                         (assert)
                         (inst -3 "jk!1")
                         (assert)
                         (inst -5 "alpha(jk!1)")
                         (assert)
                         (inst + "jk!1"))
                        ("2"
                         (hide-all-but 1)
                         (lemma "archimedean")
                         (inst -1 "delta!1/2")
                         (skosimp*)
                         (inst + "max(jj!1,n!1)")
                         (expand "max")
                         (lift-if)
                         (ground)
                         (case "1/jj!1 <= 1/n!1")
                         (("1" (assert)) ("2" (cross-mult 1))))))
                      ("2"
                       (hide -1 -2 -3 -4 -5 -10 -11 2 3)
                       (skosimp*)
                       (replace -2 * rl)
                       (assert)
                       (replace -3 * rl)
                       (hide -2 -3)
                       (assert)
                       (case "(FORALL (A,B: (bounded_above?)): subset?(A,B) IMPLIES
                                                                                                                                                                                                                                                                                                                                lub(A) <= lub(B))")
                       (("1"
                         (inst?)
                         (("1"
                           (assert)
                           (hide 2)
                           (expand "subset?")
                           (expand "member")
                           (skosimp*)
                           (inst + "j!1")
                           (assert))
                          ("2"
                           (hide 2)
                           (prop)
                           (("1"
                             (expand "nonempty?")
                             (expand "empty?")
                             (expand "member")
                             (inst -1 "XX!1(jj!1)")
                             (inst + "jj!1")
                             (assert))
                            ("2"
                             (expand "bounded_above?")
                             (inst + "b!1")
                             (expand "upper_bound?")
                             (skosimp*)
                             (typepred "s!2")
                             (skosimp*)
                             (inst -4 "j!1")
                             (assert))))
                          ("3"
                           (hide 2)
                           (prop)
                           (("1"
                             (expand "nonempty?")
                             (expand "empty?")
                             (expand "member")
                             (inst -1 "XX!1(ii!1)")
                             (inst + "ii!1")
                             (assert))
                            ("2"
                             (expand "bounded_above?")
                             (expand "upper_bound?")
                             (inst + "b!1")
                             (skosimp*)
                             (typepred "s!2")
                             (skosimp*)
                             (inst -4 "j!1")
                             (assert))))))
                        ("2"
                         (hide 2)
                         (skosimp*)
                         (hide -2 -3 -4)
                         (typepred "lub(A!1)")
                         (typepred "lub(B!1)")
                         (expand "least_upper_bound?")
                         (flatten)
                         (inst -4 "lub(B!1)")
                         (assert)
                         (hide 2)
                         (expand "upper_bound?")
                         (skosimp*)
                         (typepred "s!2")
                         (expand "subset?")
                         (expand "member")
                         (inst -5 "s!2")
                         (inst -2 "s!2")
                         (assert))))))))
                  ("2"
                   (ground)
                   (lemma "connected_domain")
                   (assert)
                   (expand "connected?")
                   (inst -1 "a!1" "b!1" "CC")
                   (assert))))
                ("2"
                 (assert)
                 (hide -6)
                 (typepred
                  "glb({alphs: real | EXISTS (jj: posnat): alphs = alpha(jj)})")
                 (expand "greatest_lower_bound?")
                 (flatten)
                 (expand "lower_bound?")
                 (inst -1 "alpha(1)")
                 (("1"
                   (replace -3)
                   (case "alpha(1) <= b!1")
                   (("1"
                     (assert)
                     (inst -3 "a!1")
                     (assert)
                     (skosimp*)
                     (typepred "s!1")
                     (skosimp*)
                     (replace -5 * rl)
                     (assert)
                     (hide -5)
                     (replace -5 * rl)
                     (hide -5)
                     (assert)
                     (hide -2 -3 -4)
                     (typepred
                      "lub({xx: real | EXISTS (j: posnat): j >= jj!1 AND xx = XX!1(j)})")
                     (("1"
                       (expand "least_upper_bound?")
                       (flatten)
                       (expand "upper_bound?")
                       (inst -1 "XX!1(jj!1)")
                       (("1" (assert) (inst -4 "jj!1") (assert))
                        ("2" (inst + "jj!1") (assert))))
                      ("2"
                       (prop)
                       (("1"
                         (expand "nonempty?")
                         (expand "empty?")
                         (expand "member")
                         (inst -1 "XX!1(jj!1)")
                         (inst + "jj!1")
                         (assert))
                        ("2"
                         (expand "bounded_above?")
                         (expand "upper_bound?")
                         (inst 1 "b!1")
                         (skosimp*)
                         (typepred "s!2")
                         (skosimp*)
                         (inst -4 "j!1")
                         (assert))))))
                    ("2"
                     (replace -4 * rl)
                     (assert)
                     (typepred "lub(A(1))")
                     (expand "least_upper_bound?")
                     (flatten)
                     (inst -2 "b!1")
                     (assert)
                     (expand "upper_bound?")
                     (skosimp*)
                     (typepred "s!1")
                     (hide -4 -5 -6)
                     (replace -4 - rl)
                     (assert)
                     (skosimp*)
                     (inst -5 "j!1")
                     (assert))))
                  ("2" (inst + "1"))))))
              ("2"
               (prop)
               (("1"
                 (expand "nonempty?")
                 (expand "empty?")
                 (expand "member")
                 (inst -1 "alpha(1)")
                 (assert)
                 (inst + "1"))
                ("2"
                 (expand "bounded_below?")
                 (expand "lower_bound?")
                 (inst 1 "a!1")
                 (skosimp*)
                 (typepred "s!1")
                 (skosimp*)
                 (replace -2 -1 rl)
                 (assert)
                 (hide -2)
                 (replace -2 -1 rl)
                 (hide -2)
                 (assert)
                 (typepred
                  "lub({xx: real | EXISTS (j: posnat): j >= jj!1 AND xx = XX!1(j)})")
                 (("1"
                   (expand "least_upper_bound?")
                   (flatten)
                   (replace -3 * rl)
                   (hide -3)
                   (expand "upper_bound?")
                   (assert)
                   (inst -1 "XX!1(jj!1)")
                   (("1" (inst -3 "jj!1") (assert))
                    ("2" (inst + "jj!1") (assert))))
                  ("2"
                   (prop)
                   (("1"
                     (expand "nonempty?")
                     (expand "empty?")
                     (expand "member")
                     (inst -1 "XX!1(jj!1)")
                     (inst + "jj!1")
                     (assert))
                    ("2"
                     (expand "bounded_above?")
                     (expand "upper_bound?")
                     (inst + "b!1")
                     (skosimp*)
                     (typepred "s!2")
                     (skosimp*)
                     (inst -4 "j!1")
                     (assert))))))))))
            ("2"
             (skosimp*)
             (prop)
             (("1"
               (expand "nonempty?")
               (expand "empty?")
               (expand "member")
               (replace -2 -1 rl)
               (assert)
               (inst -1 "XX!1(kk!1)")
               (assert)
               (inst + "kk!1")
               (assert))
              ("2"
               (expand "bounded_above?")
               (expand "upper_bound?")
               (inst + "b!1")
               (skosimp*)
               (typepred "s!1")
               (replace -2 -1 rl)
               (hide -2)
               (assert)
               (skosimp*)
               (inst -3 "j!1")
               (assert))))))
          ("2"
           (skosimp*)
           (inst -1 "n!1")
           (skosimp*)
           (inst + "x!1" "y!1")
           (assert))))
        ("2"
         (skosimp*)
         (lemma "connected_domain")
         (assert)
         (expand "connected?")
         (inst -1 "a!1" "b!1" "y!1")
         (assert))
        ("3"
         (skosimp*)
         (lemma "connected_domain")
         (assert)
         (expand "connected?")
         (inst -1 "a!1" "b!1" "x!1")
         (assert))))
      ("2"
       (inst + "epsi!1")
       (skosimp*)
       (inst 2 "N!1")
       (skosimp*)
       (inst + "x!1" "y!1")
       (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: continuous_functions_more
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "convergence" 1)
   (skosimp*)
   (rewrite "continuity_def")
   (expand "convergence" -2)
   (expand "fullset")
   (expand "convergence" -2)
   (flatten)
   (inst -3 "epsilon!1")
   (skosimp*)
   (expand "convergence")
   (inst - "delta!1")
   (skosimp*)
   (inst + "n!1")
   (skosimp*)
   (inst -3 "cn!1(i!1)")
   (inst?)
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp*)
   (assert)
   (expand "width")
   (typepred
    "max({l: real |
                     EXISTS (ii: below(length(P!1) - 1)):
                       l = seq(P!1)(1 + ii) - seq(P!1)(ii)})")
   (("1"
     (skosimp*)
     (inst -2 "P!1`seq(1 + ii!1) - P!1`seq(ii!1)")
     (assert)
     (hide -1 2)
     (inst?))
    ("2"
     (hide 2)
     (lemma "width_TCC3")
     (inst -1 "a!1" "b!1" "P!1" "seq(P!1)")
     (assert)
     (inst?))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (case "FORALL (n: posnat): ii!1 + n < length(P!1) IMPLIES                      seq(P!1)(ii!1) < seq(P!1)(ii!1+n)")
   (("1" (inst -1 "jj!1-ii!1") (("1" (assert)) ("2" (assert))))
    ("2"
     (hide -1 2)
     (induct "n")
     (("1" (assert)) ("2" (assert))
      ("3"
       (skosimp*)
       (assert)
       (ground)
       (("1" (typepred "P!1") (inst -4 "ii!1+j!1") (assert))
        ("2"
         (assert)
         (case-replace "j!1 = 0")
         (("1" (assert) (typepred "P!1") (inst -4 "ii!1"))
          ("2" (assert))))))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (case "ii!1 < jj!1")
   (("1"
     (case-replace "seq(P!1)(ii!1+1) < seq(P!1)(jj!1)")
     (("1" (assert))
      ("2"
       (case "ii!1 + 1 = jj!1")
       (("1" (replace -1) (assert))
        ("2" (lemma "parts_order") (inst?) (assert))))))
    ("2"
     (case-replace "seq(P!1)(jj!1+1) < seq(P!1)(ii!1)")
     (("1" (assert))
      ("2"
       (case "jj!1 + 1 = ii!1")
       (("1" (replace -1) (assert))
        ("2"
         (lemma "parts_order")
         (inst -1 "a!1" "b!1" "P!1" "jj!1+1" "ii!1")
         (assert))))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skolem 1 ("a!1" "b!1" "x!1" "_"))
   (measure-induct+ "length(P)" ("P"))
   (inst-cp 1 "length(x!2) - 2")
   (inst 1 "length(x!2) - 3")
   (("1"
     (ground)
     (inst -1
      "(# length := length(x!2) - 1,
                             seq    := (LAMBDA (iii: below(length(x!2) - 1)):
                                         IF iii <= length(x!2) -3 THEN seq(x!2)(iii)
                                         ELSE seq(x!2)(iii+1)
                                         ENDIF) #)")
     (("1"
       (assert)
       (skosimp*)
       (ground)
       (reveal 1)
       (inst + "ii!1")
       (assert))
      ("2"
       (skosimp*)
       (ground)
       (lift-if)
       (ground)
       (("1" (typepred "x!2") (inst?))
        ("2" (assert) (lemma "parts_order") (inst?) (assert))))))
    ("2"
     (typepred "x!2")
     (case "length(x!2) = 2")
     (("1" (assert)) ("2" (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (lemma "parts_order")
   (inst - "a!1" "b!1" "P!1" "ii!1+1" "jj!1")
   (assert)
   (lemma "parts_order")
   (inst - "a!1" "b!1" "P!1" "jj!1" "ii!1")
   (assert))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (assert)
   (skosimp*)
   (case "(FORALL (n: below(length(P!1)-1)): (FORALL (ii: below(n + 1)): seq(P!1)(ii) <= x!1 AND x!1 <= seq(P!1)(1 + ii) IMPLIES Prop!1(x!1))                 IMPLIES  Prop!1(x!1) OR x!1 > seq(P!1)(1+n))")
   (("1" (inst -1 "length(P!1)-2") (assert) (skosimp*) (inst?) (assert))
    ("2"
     (hide -1 2)
     (induct "n" 1 "below_induction[length(P!1) - 1]")
     (("1" (assert) (skosimp*) (inst?) (assert))
      ("2"
       (skosimp*)
       (split -2)
       (("1" (propax)) ("2" (inst - "jb!1+1") (assert))
        ("3" (skosimp*) (inst?) (assert))))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (expand "Rie_sum")
   (assert)
   (expand "Rie_sum_alt")
   (expand "Rie_sec")
   (assert)
   (case "FORALL (NN: below(length(P!1)-1)):  sigma[below(length(P!1) - 1)]
                                 (0, NN,
                                  LAMBDA (n: below(length(P!1) - 1)):
                                    P!1`seq(1 + n) * f!1(xis!1(n)) -
                                     P!1`seq(n) * f!1(xis!1(n)))
                              =
                              sigma[upto(length(P!1) - 1)]
                                  (1, NN+1,
                                   LAMBDA (n: upto(length(P!1) - 1)):
                                     IF n = 0 THEN 0
                                     ELSE P!1`seq(n) * f!1(xis!1(n - 1)) -
                                           P!1`seq(n - 1) * f!1(xis!1(n - 1))
                                     ENDIF)")
   (("1" (inst?) (assert))
    ("2"
     (hide 2)
     (induct "NN" 1 "below_induction[length(P!1)-1]")
     (("1" (assert) (expand "sigma") (expand "sigma") (propax))
      ("2" (skosimp*) (expand "sigma" 1) (assert))
      ("3" (hide 2) (skosimp*) (assert)) ("4" (skosimp*) (assert))))
    ("3" (hide 2) (skosimp*) (assert))
    ("4" (hide 2) (skosimp*) (assert))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp*)
   (name-replace "PP" "eq_partition(a!1, b!1, N!1)")
   (typepred "width(a!1, b!1, PP)")
   (("1"
     (expand "width")
     (typepred
      "max({l: real |
                   EXISTS (ii: below(length(PP) - 1)):
                     l = seq(PP)(1 + ii) - seq(PP)(ii)})")
     (("1"
       (skosimp*)
       (replace -1)
       (reveal -1)
       (expand "eq_partition")
       (replace -1 + rl)
       (assert))
      ("2"
       (lemma "width_TCC3")
       (inst -1 "a!1" "b!1" "PP" "seq(PP)")
       (inst?)
       (assert))))
    ("2" (propax))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp*)
   (assert)
   (case "(b!1 - a!1) / delta!1 > 0")
   (("1"
     (lemma "width_eq_part")
     (inst?)
     (("1"
       (assert)
       (name-replace "EP"
        "eq_partition(a!1, b!1, 2 + floor((b!1 - a!1) / delta!1))")
       (typepred "floor((b!1 - a!1) / delta!1)")
       (name-replace "FL" "floor((b!1 - a!1) / delta!1)")
       (replace -3)
       (hide -3)
       (cross-mult -1)
       (cross-mult -2)
       (cross-mult 1)
       (assert))
      ("2" (assert))))
    ("2" (hide 2) (cross-mult 1))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp*)
   (expand "integral?")
   (case-replace "(FORALL (EPS: posreal): abs(A1!1 - A2!1) < 2*EPS)")
   (("1"
     (hide -3 -4)
     (case "A1!1 > A2!1")
     (("1" (inst -2 "(A1!1 - A2!1)/2") (("1" (grind)) ("2" (assert))))
      ("2" (inst -1 "(A2!1 - A1!1)/2") (("1" (grind)) ("2" (assert))))))
    ("2"
     (hide 2)
     (skosimp*)
     (inst -2 "EPS!1")
     (inst - "EPS!1")
     (skosimp*)
     (name "DELTA" "real_defs.min(delta!1,delta!2)")
     (case "2 + floor((b!1 - a!1) / DELTA) > 1")
     (("1"
       (name "NN" "2 + floor((b!1 - a!1) / DELTA)")
       (replace -1)
       (inst - "eq_partition(a!1,b!1,NN)")
       (inst - "eq_partition(a!1,b!1,NN)")
       (split -5)
       (("1"
         (split -6)
         (("1"
           (name "S"
                 "Rie_sum(a!1, b!1, eq_partition(a!1, b!1,NN ),
                                           gen_xis(a!1,b!1,eq_partition(a!1, b!1,NN )),    f!1)")
           (("1"
             (inst - "S")
             (("1"
               (inst - "S")
               (("1" (hide-all-but (-2 -3 1)) (grind))
                ("2"
                 (hide 2)
                 (lemma "Riemann?_Rie")
                 (inst - "a!1" "b!1" "f!1")
                 (split -1)
                 (("1" (inst?) (assert)) ("2" (propax))))))
              ("2"
               (hide 2)
               (lemma "Riemann?_Rie")
               (inst - "a!1" "b!1" "f!1")
               (split -1)
               (("1" (inst?) (assert)) ("2" (propax))))))
            ("2" (propax)) ("3" (propax))))
          ("2"
           (hide 2)
           (hide -1)
           (rewrite "width_eq_part")
           (case "DELTA <= delta!2")
           (("1"
             (hide -4)
             (case "(b!1 - a!1) / DELTA < NN-1")
             (("1"
               (hide -3)
               (mult-by -1 "DELTA")
               (mult-by 1 "NN-1")
               (("1" (mult-by -2 "NN-1") (assert))
                ("2" (hide -1 2) (assert))))
              ("2" (hide -1 2) (grind))))
            ("2" (hide -5 2) (grind))))))
        ("2"
         (hide -5 2)
         (rewrite "width_eq_part")
         (case "DELTA <= delta!1")
         (("1"
           (hide -4)
           (case "(b!1 - a!1) / DELTA < NN-1")
           (("1"
             (hide -3)
             (mult-by -1 "DELTA")
             (mult-by 1 "NN-1")
             (("1" (mult-by -2 "NN-1") (assert))
              ("2" (hide -1 2) (assert))))
            ("2" (hide -1 2) (grind))))
          ("2" (grind))))))
      ("2"
       (hide -3 -4 2)
       (mult-by 1 "DELTA")
       (assert)
       (move-terms 1 l 1)
       (auto-rewrite-theory "real_props")
       (assert)
       (lemma "pos_div_ge")
       (inst?)
       (assert))))))


proof_type: f_proof
decl_type: formula
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp*)
   (expand "integrable?")
   (typepred "integral(a!1, b!1, f!1)")
   (("1"
     (ground)
     (("1"
       (lemma "integral_unique")
       (inst?)
       (inst -1 "integral(a!1, b!1, f!1)")
       (("1" (assert) (inst + "s!1"))
        ("2" (hide 2) (expand "integrable?") (inst?))))
      ("2"
       (lemma "integral_unique")
       (inst?)
       (inst -1 "integral(a!1, b!1, f!1)")
       (("1" (assert)) ("2" (expand "integrable?") (inst + "s!1"))))))
    ("2" (expand "integrable?") (inst?) (assert) (flatten) (assert))
    ("3" (propax))))


proof_type: t_proof
decl_type: tcc
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (prop)
   (("1"
     (lemma "is_finite_surj")
     (inst?)
     (("1"
       (assert)
       (hide 2)
       (inst + "N!1-1"
        "(LAMBDA (ii: below(N!1-1)): xx!1(ii + 1) - xx!1(ii)) ")
       (("1"
         (expand "surjective?")
         (skosimp*)
         (replace -1)
         (typepred "y!1")
         (skosimp*)
         (inst + "ii!1")
         (assert))
        ("2" (skosimp*) (inst?))))
      ("2" (hide 2) (skosimp*) (grind))
      ("3" (hide 2) (skosimp*) (grind))))
    ("2"
     (expand "empty?")
     (expand "member")
     (inst -1 "xx!1(1) - xx!1(0)")
     (inst + "0")
     (("1" (assert)) ("2" (assert))))))


proof_type: t_proof
decl_type: tcc
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: fix
script:
  (""
   (skosimp*)
   (typepred
    "max[real, <=]
                ({l: real |
                    EXISTS (ii: below(N!1 - 1)): l = xx!1(ii + 1) - xx!1(ii)})")
   (("1"
     (skosimp*)
     (replace -1)
     (assert)
     (hide -1 -2)
     (typepred "P!1")
     (inst -4 "ii!1")
     (assert))
    ("2" (hide 2) (lemma "width_TCC3") (inst?) (assert) (inst?) (assert))
    ("3" (hide 2) (grind)) ("4" (hide 2) (grind))))


proof_type: t_proof
decl_type: tcc
library: analysis
theory: integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp*)
   (case-replace "a!1 <= (b!1 * ii!1 - a!1 * ii!1) / (N!1 - 1) + a!1")
   (("1"
     (case-replace "(b!1 * ii!1 - a!1 * ii!1) / (N!1 - 1) + a!1 <= b!1")
     (("1"
       (assert)
       (lemma "connected_domain")
       (expand "connected?")
       (inst -1 "a!1" "b!1" "a!1 + ii!1 * (b!1 - a!1) / (N!1 - 1)")
       (assert))
      ("2"
       (hide -1 2)
       (move-terms 1 l 2)
       (mult-by * "N!1-1")
       (factor 1 l)
       (typepred "ii!1")
       (name-replace "bma" "b!1-a!1")
       (div-by 1 "bma")
       (("1" (assert)) ("2" (reveal -2) (assert))))))
    ("2"
     (hide 2)
     (move-terms 1 r 2)
     (assert)
     (mult-by * "N!1-1")
     (assert)
     (factor 1 r)
     (typepred "ii!1")
     (lemma "pos_times_ge")
     (inst?)
     (assert))))


