# Proofs

proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral_scal" ("c" "-1" "f" "f!1"))
   (assert)
   (expand "*" -1)
   (assert)
   (expand "-")
   (assert))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral_opp" ("f" "f2!1"))
   (lemma "integral_add" ("f1" "f1!1" "f2" "-f2!1"))
   (expand "-" -1 1)
   (expand "+" -1 1)
   (expand "-" 1)
   (assert))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "nn_integrable_is_nn_integrable" ("f" "f!1"))
   (assert)
   (split -1)
   (("1" (rewrite "integral_nn") (assert)) ("2" (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral_nonneg" ("f" "abs(f!1)-f!1"))
   (split -1)
   (("1"
     (rewrite "integral_diff")
     (lemma "integral_nonneg" ("f" "f!1+abs(f!1)"))
     (split -1)
     (("1"
       (rewrite "integral_add")
       (name-replace "INTF" "integral(f!1)")
       (name-replace "INTA" "integral(abs(f!1))")
       (grind))
      ("2" (hide-all-but 1) (grind))))
    ("2" (hide-all-but 1) (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1"
     (flatten)
     (assert)
     (lemma "integrable_plus" ("f" "f0!1"))
     (lemma "integrable_minus" ("f" "f0!1"))
     (assert))
    ("2"
     (flatten)
     (lemma "integrable_diff" ("f1" "plus(f0!1)" "f2" "minus(f0!1)"))
     (("1" (rewrite "plus_minus_def" -1 :dir rl)) ("2" (propax))
      ("3" (propax))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral_diff" ("f1" "plus(f!1)" "f2" "minus(f!1)"))
   (replace -1 1 rl)
   (hide-all-but 1)
   (case-replace "plus(f!1) - minus(f!1)=f!1")
   (hide 2)
   (apply-extensionality :hide? t)
   (grind))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1"
     (flatten)
     (rewrite "integrable_pm_def" +)
     (lemma "plus_measurable" ("g" "h!1"))
     (lemma "minus_measurable" ("g" "h!1"))
     (case-replace "abs(h!1)=plus[T](h!1)+minus[T](h!1)")
     (("1"
       (replace -1 -4 rl)
       (lemma "nn_integrable_le" ("g" "plus[T](h!1)" "f" "abs(h!1)"))
       (("1"
         (lemma "nn_integrable_le" ("g" "minus[T](h!1)" "f" "abs(h!1)"))
         (split -1)
         (("1"
           (flatten)
           (split)
           (("1"
             (flatten)
             (assert)
             (lemma "nn_integrable_is_integrable")
             (inst-cp - "plus[T](h!1)")
             (inst - "minus[T](h!1)")
             (assert))
            ("2" (hide-all-but 1) (grind))))
          ("2" (hide-all-but 1) (grind))))
        ("2"
         (lemma "nn_integrable_is_nn_integrable" ("f" "abs[T](h!1)"))
         (("1"
           (split -1)
           (("1" (propax)) ("2" (hide-all-but 1) (grind))))
          ("2" (propax))))))
      ("2"
       (hide-all-but 1)
       (apply-extensionality :hide? t)
       (("1" (grind)) ("2" (grind))))))
    ("2" (flatten) (rewrite "integrable_abs"))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (case "FORALL (epsilon: posreal, f: nn_integrable):
                  measurable_set?({x | f(x) > epsilon}) AND
                    mu_fin?({x | f(x) > epsilon})")
   (("1"
     (skosimp)
     (inst - "epsilon!1/2" "abs(f!1)")
     (("1"
       (expand "abs" -1)
       (flatten)
       (split)
       (("1"
         (typepred "f!1")
         (lemma "measurable_ge" ("f" "abs(f!1)"))
         (assert)
         (lemma "integrable_abs_def" ("h" "f!1"))
         (lemma "integrable_is_measurable")
         (inst - "abs(f!1)")
         (assert)
         (inst - "epsilon!1")
         (expand "measurable_set?")
         (expand "abs" -3)
         (propax))
        ("2"
         (lemma "m_monotone"
          ("a"
           "{x | abs(f!1(x)) >= epsilon!1}"
           "b"
           "{x | abs(f!1(x)) > epsilon!1 / 2}"))
         (("1"
           (split -1)
           (("1" (expand "x_le") (expand "mu_fin?") (assert))
            ("2"
             (hide-all-but 1)
             (expand "subset?")
             (expand "member")
             (skosimp)
             (assert))))
          ("2" (propax))
          ("3"
           (hide-all-but 1)
           (lemma "measurable_ge" ("f" "abs(f!1)"))
           (lemma "integrable_is_measurable" ("x" "abs(f!1)"))
           (assert)
           (expand "abs" -2)
           (inst - "epsilon!1")
           (expand "measurable_set?")
           (propax))))))
      ("2"
       (hide 2)
       (lemma "nn_integrable_is_nn_integrable" ("f" "abs(f!1)"))
       (assert)
       (hide 2)
       (expand "abs")
       (skosimp)
       (assert))))
    ("2"
     (hide 2)
     (skosimp)
     (typepred "f!1")
     (case-replace "measurable_set?({x | f!1(x) > epsilon!1})")
     (("1"
       (expand "nn_integrable?")
       (skosimp)
       (typepred "u!1")
       (expand "increasing_nn_isf?")
       (name "EN" "lambda n: {x | u!1(n)(x) > epsilon!1}")
       (hide -1)
       (case "forall n: measurable_set?(EN(n))")
       (("1"
         (case "forall n: mu_fin?(EN(n))")
         (("1"
           (case "increasing?(EN)")
           (("1"
             (lemma "m_increasing_convergence" ("E" "EN"))
             (assert)
             (expand "convergent?")
             (skolem - "M")
             (case "M>=0")
             (("1"
               (case "increasing?(isf_integral o u!1)")
               (("1"
                 (case "forall n: isf_integral(u!1(n)) <= M")
                 (("1"
                   (case "forall n: mu(EN(n))<=M/epsilon!1")
                   (("1"
                     (case "mu_fin?(IUnion(EN))")
                     (("1"
                       (case-replace
                        "{x | f!1(x) > epsilon!1}=IUnion(EN)")
                       (apply-extensionality 1 :hide? t)
                       (hide-all-but (-12 1 -10))
                       (expand "IUnion")
                       (expand "pointwise_convergence?")
                       (expand "pointwise_increasing?")
                       (inst - "x!1")
                       (inst - "x!1")
                       (rewrite "metric_convergence_def")
                       (expand "metric_converges_to")
                       (expand "ball")
                       (expand "member")
                       (expand "increasing?")
                       (expand "EN")
                       (case-replace "f!1(x!1) > epsilon!1")
                       (("1"
                         (inst -3 "f!1(x!1)-epsilon!1")
                         (("1"
                           (skosimp)
                           (inst -3 "n!1")
                           (assert)
                           (inst + "n!1")
                           (assert))
                          ("2" (assert))))
                        ("2"
                         (assert)
                         (skosimp)
                         (inst -3 "u!1(i!1)(x!1) - epsilon!1")
                         (("1"
                           (skosimp)
                           (inst - "i!1+n!1")
                           (expand "abs")
                           (inst - "i!1" "i!1+n!1")
                           (assert))
                          ("2" (assert))))))
                      ("2"
                       (hide 2)
                       (expand "x_converges?")
                       (expand "mu_fin?")
                       (replace 1 -5)
                       (expand "o ")
                       (replace -7 -5)
                       (prop)
                       (hide 2)
                       (lemma "bounded_above_is_convergent"
                        ("u" "LAMBDA (i:nat): m(EN(i))`2"))
                       (("1"
                         (split -1)
                         (("1"
                           (expand "convergent_upto?")
                           (skosimp)
                           (expand "converges_upto?")
                           (flatten)
                           (name-replace "DRL1"
                            "LAMBDA (i: nat): m(EN(i))`2")
                           (hide-all-but (-1 1))
                           (rewrite "metric_convergence_def")
                           (expand "metric_converges_to")
                           (expand "ball")
                           (expand "convergent?")
                           (expand "convergence")
                           (expand "member")
                           (inst + "x!1")
                           (skosimp)
                           (inst - "epsilon!2")
                           (skosimp)
                           (inst + "n!1")
                           (skosimp)
                           (inst - "i!1")
                           (grind))
                          ("2"
                           (hide-all-but (-1 1))
                           (expand "mu")
                           (expand "bounded_above?")
                           (inst + "M / epsilon!1"))
                          ("3"
                           (hide 2 -1 -2 -3)
                           (expand "increasing?")
                           (skolem + ("i!1" "j!1"))
                           (inst - "i!1" "j!1")
                           (flatten)
                           (assert)
                           (lemma "m_monotone"
                            ("a" "EN(i!1)" "b" "EN(j!1)"))
                           (("1" (assert) (expand "x_le") (inst - "j!1"))
                            ("2" (inst -5 "j!1"))
                            ("3" (inst -5 "i!1"))))))
                        ("2"
                         (skosimp)
                         (inst -7 "i!1")
                         (expand "measurable_set?")
                         (propax))))
                      ("3" (rewrite "measurable_IUnion"))))
                    ("2"
                     (hide 2)
                     (skosimp)
                     (inst - "n!1")
                     (lemma "isf_integral_le"
                      ("i1" "epsilon!1*phi(EN(n!1))" "i2" "u!1(n!1)"))
                     (("1"
                       (split -1)
                       (("1"
                         (inst -7 "n!1")
                         (inst -8 "n!1")
                         (lemma "isf_phi" ("E" "EN(n!1)"))
                         (lemma "isf_scal"
                          ("c" "epsilon!1" "i" "phi[T, S](EN(n!1))"))
                         (("1"
                           (rewrite "isf_integral_scal")
                           (rewrite "isf_integral_phi")
                           (lemma "div_mult_pos_le2"
                            ("x" "mu(EN(n!1))" "z" "M" "py" "epsilon!1"))
                           (assert))
                          ("2" (propax))))
                        ("2"
                         (skosimp)
                         (expand "*")
                         (expand "phi")
                         (expand "EN")
                         (expand "member")
                         (case-replace "u!1(n!1)(x!1) > epsilon!1")
                         (("1" (assert))
                          ("2"
                           (assert)
                           (typepred "u!1(n!1)")
                           (expand "nn_isf?")
                           (inst - "x!1")
                           (assert))))))
                      ("2"
                       (inst -6 "n!1")
                       (inst - "n!1")
                       (rewrite "isf_scal")
                       (rewrite "isf_phi"))))
                    ("3"
                     (skosimp)
                     (inst - "n!1")
                     (inst - "n!1")
                     (inst - "n!1")
                     (expand "measurable_set?")
                     (assert))))
                  ("2"
                   (hide-all-but (1 -1 -10))
                   (skosimp)
                   (expand "o ")
                   (expand "increasing?")
                   (rewrite "metric_convergence_def")
                   (expand "metric_converges_to")
                   (inst - "isf_integral(u!1(n!1))-M")
                   (("1"
                     (skosimp)
                     (expand "ball")
                     (expand "member")
                     (inst - "n!1+n!2")
                     (inst - "n!1" "n!1+n!2")
                     (assert)
                     (expand "abs")
                     (assert))
                    ("2" (assert))))))
                ("2"
                 (hide-all-but (1 -6))
                 (expand "o ")
                 (expand "pointwise_increasing?")
                 (expand "increasing?")
                 (skolem + ("i!1" "j!1"))
                 (flatten)
                 (lemma "isf_integral_le"
                  ("i1" "u!1(i!1)" "i2" "u!1(j!1)"))
                 (split -1)
                 (("1" (propax))
                  ("2"
                   (skosimp)
                   (inst - "x!1")
                   (inst - "i!1" "j!1")
                   (assert))))))
              ("2"
               (hide-all-but (1 -5 -8))
               (rewrite "metric_convergence_def")
               (expand "metric_converges_to")
               (expand "o ")
               (expand "ball")
               (expand "member")
               (typepred "u!1(0)")
               (expand "nn_isf?")
               (lemma "isf_integral_pos" ("i" "u!1(0)"))
               (replace -3)
               (inst -5 "isf_integral(u!1(0))-M")
               (("1"
                 (skosimp)
                 (inst -5 "n!1")
                 (assert)
                 (expand "pointwise_increasing?")
                 (expand "increasing?")
                 (typepred "u!1(n!1)")
                 (expand "nn_isf?")
                 (lemma "isf_integral_pos" ("i" "u!1(n!1)"))
                 (replace -3)
                 (expand "abs")
                 (assert)
                 (lemma "isf_integral_le"
                  ("i1" "u!1(0)" "i2" "u!1(n!1)"))
                 (split -1)
                 (("1" (assert))
                  ("2"
                   (skosimp)
                   (inst -7 "x!1")
                   (inst -7 "0" "n!1")
                   (assert))))
                ("2" (assert))))))
            ("2"
             (hide-all-but (-3 1))
             (expand "pointwise_increasing?")
             (expand "increasing?")
             (skolem + ("i!1" "j!1"))
             (flatten)
             (expand "subset?")
             (expand "EN")
             (expand "member")
             (skosimp)
             (inst - "x!1")
             (inst - "i!1" "j!1")
             (assert))))
          ("2"
           (hide-all-but (-1 1))
           (skosimp)
           (inst - "n!1")
           (lemma "m_monotone"
            ("a" "EN(n!1)" "b" "nonzero_set?(u!1(n!1))"))
           (("1"
             (split -1)
             (("1"
               (typepred "u!1(n!1)")
               (expand "isf?")
               (flatten)
               (expand "x_le")
               (expand "mu_fin?")
               (assert))
              ("2"
               (hide-all-but 1)
               (expand "nonzero_set?")
               (expand "EN")
               (expand "subset?")
               (expand "member")
               (skosimp)
               (assert))))
            ("2" (rewrite "nonzero_measurable"))))
          ("3" (propax))))
        ("2"
         (skosimp)
         (hide-all-but 1)
         (expand "EN")
         (expand "measurable_set?")
         (typepred "u!1(n!1)")
         (lemma "isf_is_simple" ("x" "u!1(n!1)"))
         (expand "simple?")
         (flatten)
         (rewrite "measurable_gt")
         (inst - "epsilon!1"))))
      ("2"
       (hide 2)
       (lemma "nn_integrable_is_measurable")
       (inst - "f!1")
       (rewrite "measurable_gt")
       (inst - "epsilon!1")
       (expand "measurable_set?")
       (propax))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (rewrite "integral_pm")
   (lemma "integrable_pm_def" ("f0" "i!1"))
   (assert)
   (rewrite "isf_is_integrable")
   (flatten)
   (rewrite "integral_nn")
   (("1"
     (rewrite "integral_nn")
     (("1"
       (rewrite "nn_integral_isf")
       (("1"
         (rewrite "nn_integral_isf")
         (("1"
           (lemma "isf_integral_diff"
            ("i1" "plus(i!1)" "i2" "minus(i!1)"))
           (rewrite "plus_minus_def" -1 :dir rl)
           (assert))
          ("2" (expand "nn_isf?") (hide-all-but 1) (grind))))
        ("2" (expand "nn_isf?") (hide-all-but 1) (grind))))
      ("2"
       (lemma "nn_integrable_is_nn_integrable" ("f" "minus[T](i!1)"))
       (split -1)
       (("1" (propax)) ("2" (hide-all-but 1) (grind))))))
    ("2"
     (lemma "nn_integrable_is_nn_integrable" ("f" "plus[T](i!1)"))
     (split -1)
     (("1" (propax)) ("2" (hide-all-but 1) (grind))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (name "H" "abs(h!1-f!1)")
   (case "measurable_function?(H)")
   (("1"
     (case "forall x: 0 <= H(x)")
     (("1"
       (case "ae_0?(H)")
       (("1"
         (lemma "nn_measurable_def" ("f" "H"))
         (replace -3 -1)
         (replace -4 -1)
         (assert)
         (skosimp)
         (typepred "w!1")
         (case "forall (n:nat): ae_0?(w!1(n))")
         (("1"
           (case "forall (n:nat): isf_integral(w!1(n)) = 0")
           (("1"
             (case "pointwise_convergence?(w!1,H) AND convergence?(isf_integral o w!1,0)")
             (("1"
               (flatten)
               (case "nn_integrable?(H)")
               (("1"
                 (lemma "integrable_abs_def" ("h" "h!1 - f!1"))
                 (replace -12)
                 (lemma "nn_integrable_is_integrable")
                 (inst - "H")
                 (assert)
                 (lemma "integrable_add" ("f1" "h!1 - f!1" "f2" "f!1"))
                 (case-replace "(+[T])(h!1 - f!1, f!1)=h!1")
                 (("1"
                   (assert)
                   (case "nn_integral(H)=0")
                   (("1"
                     (replace -16 -1 rl)
                     (lemma "integral_nn" ("g" "abs(h!1 - f!1)"))
                     (replace -2)
                     (hide -2)
                     (lemma "integral_abs" ("f" "h!1-f!1"))
                     (replace -2)
                     (case-replace "integral(h!1 - f!1)=0")
                     (("1" (rewrite "integral_diff") (assert))
                      ("2"
                       (typepred "abs(integral(h!1 - f!1))")
                       (assert))))
                    ("2"
                     (hide 2)
                     (expand "nn_integral")
                     (hide -1 -2 -3 -4 -15 -16 -17)
                     (case "nonempty?[increasing_nn_isf[T, S, m]]
                                     ({u: increasing_nn_isf[T, S, m] |
                                         pointwise_convergence?[T](u, H)})")
                     (("1"
                       (lemma "choose_member"
                        ("a"
                         "{u: increasing_nn_isf[T, S, m] |
                                               pointwise_convergence?(u, H)}"))
                       (split -1)
                       (("1"
                         (name-replace "CU"
                          "choose({u: increasing_nn_isf[T, S, m] |
                                                 pointwise_convergence?(u, H)})")
                         (expand "member")
                         (hide -2)
                         (lemma "nn_convergence"
                          ("u1" "w!1" "f" "H" "u2" "CU"))
                         (("1"
                           (replace -2)
                           (replace -4)
                           (split -1)
                           (("1"
                             (flatten)
                             (replace -2 1 rl)
                             (rewrite "limit_def" 1))
                            ("2"
                             (hide 2)
                             (expand "convergent?")
                             (inst + "0"))))
                          ("2"
                           (hide -1 -3 -4 2 -8 -9 -10)
                           (split)
                           (("1"
                             (skolem + ("n!1"))
                             (expand "nn_isf?")
                             (expand "isf?")
                             (hide -1 -2)
                             (inst - "n!1")
                             (expand "increasing_nn_simple?")
                             (flatten)
                             (inst - "n!1")
                             (expand "nn_simple?")
                             (flatten)
                             (assert)
                             (split)
                             (("1"
                               (expand "ae_0?")
                               (expand "restrict")
                               (expand "pointwise_ae?")
                               (expand "ae?")
                               (expand "fullset")
                               (expand "ae_in?")
                               (skosimp)
                               (typepred "E!1")
                               (expand "negligible_set?")
                               (skosimp)
                               (expand "null_set?")
                               (flatten)
                               (lemma "m_monotone"
                                ("a" "nonzero_set?(w!1(n!1))" "b" "X!1"))
                               (split -1)
                               (("1"
                                 (expand "mu_fin?")
                                 (expand "x_le")
                                 (assert))
                                ("2"
                                 (hide 2 -1 -2 -3 -7 -8 -9)
                                 (expand "nonzero_set?")
                                 (expand "subset?")
                                 (expand "member")
                                 (skosimp)
                                 (inst - "x!1")
                                 (inst - "x!1")
                                 (assert))))
                              ("2" (skosimp) (inst - "x!1") (assert))))
                            ("2"
                             (expand "increasing_nn_simple?")
                             (expand "increasing_nn_isf?")
                             (flatten))))))
                        ("2" (expand "nonempty?") (propax))))
                      ("2"
                       (hide 2)
                       (expand "nonempty?")
                       (expand "empty?")
                       (expand "member")
                       (inst - "w!1")
                       (split)
                       (("1"
                         (skolem + ("n!1"))
                         (expand "nn_isf?")
                         (expand "isf?")
                         (expand "increasing_nn_simple?")
                         (flatten)
                         (inst -6 "n!1")
                         (expand "nn_simple?")
                         (flatten)
                         (assert)
                         (split)
                         (("1"
                           (inst -5 "n!1")
                           (hide -1 -2 -3 -4)
                           (expand "ae_0?" -1)
                           (expand "restrict")
                           (expand "pointwise_ae?")
                           (expand "ae?")
                           (expand "fullset")
                           (expand "ae_in?")
                           (skosimp)
                           (typepred "E!1")
                           (expand "negligible_set?")
                           (skosimp)
                           (expand "null_set?")
                           (flatten)
                           (lemma "m_monotone"
                            ("a" "nonzero_set?(w!1(n!1))" "b" "X!1"))
                           (split -1)
                           (("1"
                             (expand "x_le")
                             (expand "mu_fin?")
                             (assert))
                            ("2"
                             (hide -1 -2 -3 -10 2)
                             (expand "nonzero_set?")
                             (expand "subset?")
                             (expand "member")
                             (skosimp)
                             (inst - "x!1")
                             (inst - "x!1")
                             (assert))))
                          ("2" (skosimp) (inst -6 "x!1") (assert))))
                        ("2"
                         (expand "increasing_nn_isf?")
                         (expand "pointwise_converges_upto?")
                         (propax))))))))
                  ("2"
                   (hide-all-but 1)
                   (grind)
                   (apply-extensionality :hide? t))))
                ("2"
                 (expand "nn_integrable?")
                 (inst + "w!1")
                 (("1" (assert) (expand "convergent?") (inst + "0"))
                  ("2"
                   (expand "increasing_nn_isf?")
                   (expand "nn_isf?")
                   (expand "increasing_nn_simple?")
                   (flatten)
                   (assert)
                   (hide-all-but (-4 -5 1))
                   (skolem + ("n!1"))
                   (expand "isf?")
                   (inst - "n!1")
                   (inst - "n!1")
                   (expand "nn_simple?")
                   (flatten)
                   (assert)
                   (split)
                   (("1"
                     (hide -3)
                     (expand "ae_0?")
                     (expand "restrict")
                     (expand "pointwise_ae?")
                     (expand "nonzero_set?")
                     (expand "ae?")
                     (expand "fullset")
                     (expand "ae_in?")
                     (skosimp)
                     (typepred "E!1")
                     (expand "negligible_set?")
                     (skosimp)
                     (expand "null_set?")
                     (flatten)
                     (lemma "m_monotone"
                      ("a" "nonzero_set?(w!1(n!1))" "b" "X!1"))
                     (("1"
                       (split -1)
                       (("1"
                         (expand "x_le")
                         (expand "mu_fin?")
                         (assert)
                         (expand "nonzero_set?")
                         (propax))
                        ("2"
                         (hide -1 -2 -3 2)
                         (expand "nonzero_set?")
                         (expand "subset?")
                         (expand "member")
                         (skosimp)
                         (inst - "x!1")
                         (inst - "x!1")
                         (assert))))
                      ("2"
                       (typepred "w!1(n!1)")
                       (rewrite "nonzero_measurable"))))
                    ("2" (skosimp) (inst - "x!1") (assert))))))))
              ("2"
               (hide 2)
               (expand "pointwise_converges_upto?")
               (flatten)
               (assert)
               (case-replace "isf_integral o w!1 = lambda (n:nat): 0")
               (("1"
                 (expand "convergence?")
                 (skosimp)
                 (inst + "0")
                 (skosimp))
                ("2"
                 (hide-all-but (-1 1))
                 (apply-extensionality :hide? t)
                 (inst - "x!1")
                 (expand "o ")
                 (propax))))
              ("3"
               (skosimp)
               (hide-all-but (1 -3 -4))
               (skolem + ("n!1"))
               (expand "increasing_nn_simple?")
               (flatten)
               (inst - "n!1")
               (inst - "n!1")
               (expand "isf?")
               (expand "nn_simple?")
               (flatten)
               (assert)
               (hide -3 -4)
               (expand "ae_0?")
               (expand "restrict")
               (expand "pointwise_ae?")
               (expand "ae?")
               (expand "fullset")
               (expand "ae_in?")
               (skosimp)
               (typepred "E!1")
               (expand "negligible_set?")
               (skosimp)
               (expand "null_set?")
               (flatten)
               (lemma "m_monotone"
                ("a" "nonzero_set?(w!1(n!1))" "b" "X!1"))
               (split -1)
               (("1" (expand "x_le") (expand "mu_fin?") (assert))
                ("2"
                 (hide -1 -2 -3 2)
                 (expand "nonzero_set?")
                 (expand "subset?")
                 (expand "member")
                 (skosimp)
                 (inst - "x!1")
                 (inst - "x!1")
                 (assert))))))
            ("2"
             (skosimp)
             (inst - "n!1")
             (hide 2 -8)
             (lemma "isf_ae_0" ("f" "w!1(n!1)"))
             (replace -2)
             (expand "increasing_nn_simple?")
             (flatten -3)
             (expand "nn_simple?")
             (inst - "n!1")
             (flatten -3)
             (replace -4)
             (flatten)
             (lemma "isf_integral_abs" ("i" "w!1(n!1)"))
             (replace -3)
             (typepred "abs(isf_integral(w!1(n!1)))")
             (assert))
            ("3"
             (expand "increasing_nn_simple?")
             (flatten)
             (skosimp)
             (inst - "n!1")
             (inst - "n!1")
             (expand "isf?")
             (expand "nn_simple?")
             (flatten)
             (assert)
             (hide 2 -9 -10 -11)
             (expand "ae_0?" -1)
             (expand "restrict")
             (expand "pointwise_ae?")
             (expand "ae?")
             (expand "fullset")
             (expand "ae_in?")
             (skosimp)
             (typepred "E!1")
             (expand "negligible_set?")
             (skosimp)
             (expand "null_set?")
             (flatten)
             (lemma "m_monotone"
              ("a" "nonzero_set?(w!1(n!1))" "b" "X!1"))
             (split -1)
             (("1" (expand "x_le") (expand "mu_fin?") (assert))
              ("2"
               (hide 2)
               (expand "nonzero_set?")
               (expand "subset?")
               (expand "member")
               (skosimp)
               (inst -5 "x!1")
               (assert)
               (inst - "x!1")
               (assert))))))
          ("2"
           (hide 2 -7)
           (skosimp)
           (expand "pointwise_converges_upto?")
           (flatten)
           (case "FORALL x: w!1(n!1)(x) <= H(x)")
           (("1"
             (hide -2 -3 -4 -8 -9)
             (expand "ae_0?")
             (expand "restrict")
             (expand "pointwise_ae?")
             (expand "ae?")
             (expand "fullset")
             (expand "ae_in?")
             (skosimp*)
             (inst + "E!1")
             (skosimp)
             (inst -2 "x!1")
             (assert)
             (inst - "x!1")
             (inst - "x!1")
             (assert)
             (typepred "w!1")
             (expand "increasing_nn_simple?")
             (expand "nn_simple?")
             (flatten)
             (inst - "n!1")
             (flatten)
             (inst - "x!1")
             (assert))
            ("2"
             (expand "pointwise_convergence?")
             (hide-all-but (-2 -3 1 -5))
             (skosimp)
             (case "H(x!1)<w!1(n!1)(x!1)")
             (("1"
               (hide 1)
               (inst - "x!1")
               (rewrite "metric_convergence_def" *)
               (expand "metric_converges_to")
               (inst - "w!1(n!1)(x!1)-H(x!1)")
               (("1"
                 (skosimp)
                 (expand "ball")
                 (expand "member")
                 (inst - "n!1+n!2")
                 (assert)
                 (expand "pointwise_increasing?")
                 (inst - "x!1")
                 (inst - "x!1")
                 (expand "increasing?")
                 (inst - "n!1" "n!1+n!2")
                 (assert))
                ("2" (assert))))
              ("2" (assert))))))))
        ("2"
         (hide-all-but (-5 1))
         (expand "ae_0?")
         (expand "ae_eq?")
         (expand "H")
         (expand "abs")
         (expand "restrict")
         (expand "pointwise_ae?")
         (expand "ae?")
         (expand "fullset")
         (expand "ae_in?")
         (skosimp)
         (inst + "E!1")
         (skosimp)
         (inst - "x!1")
         (assert)
         (grind))))
      ("2" (hide-all-but 1) (grind))))
    ("2" (hide -1 -3 2) (expand "H") (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "ae_le?")
   (expand "pointwise_ae?")
   (expand "ae?")
   (expand "fullset")
   (expand "ae_in?")
   (skosimp)
   (typepred "E!1")
   (expand "negligible_set?")
   (skosimp)
   (lemma "measurable_complement" ("a" "X!1"))
   (("1"
     (case "measurable_function?(phi(complement[T](X!1)))")
     (("1"
       (case "forall x: (phi(complement[T](X!1))*abs(f!1 * h!1))(x) <= (phi(complement[T](X!1))* (nnc!1*abs(f!1)))(x) & (phi(complement[T](X!1))* (nnc!1*abs(f!1)))(x) <= (nnc!1*abs(f!1))(x)")
       (("1"
         (lemma "nn_integrable_le"
          ("f"
           "nnc!1 * abs(f!1)"
           "g"
           "phi(complement[T](X!1)) * abs(f!1 * h!1)"))
         (("1"
           (split -)
           (("1"
             (flatten)
             (hide -3)
             (lemma "nn_integrable_is_integrable")
             (inst - "phi(complement[T](X!1)) * abs(f!1 * h!1)")
             (lemma "integral_ae_eq"
              ("f"
               "phi(complement[T](X!1)) * abs(f!1 * h!1)"
               "h"
               "abs(f!1 * h!1)"))
             (("1"
               (split -1)
               (("1"
                 (flatten)
                 (lemma "integrable_abs_def" ("h" "f!1*h!1"))
                 (assert)
                 (name-replace "I_0" "integral(abs(f!1 * h!1))")
                 (rewrite "integral_nn" * :dir rl)
                 (replace -3)
                 (rewrite "integral_nn" * :dir rl)
                 (rewrite "integral_scal" -))
                ("2"
                 (hide-all-but (-5 -6 -7 -8 1))
                 (expand "ae_eq?")
                 (expand "restrict")
                 (expand "pointwise_ae?")
                 (expand "ae?")
                 (expand "fullset")
                 (expand "ae_in?")
                 (inst + "X!1")
                 (("1"
                   (skosimp)
                   (expand "*")
                   (expand "abs")
                   (expand "complement")
                   (expand "phi")
                   (expand "member")
                   (assert))
                  ("2"
                   (expand "negligible_set?")
                   (inst + "X!1")
                   (assert)
                   (expand "subset?")
                   (skosimp))))))
              ("2" (propax))))
            ("2"
             (skosimp)
             (inst - "x!1")
             (flatten)
             (assert)
             (hide-all-but 1)
             (expand "*")
             (expand "abs")
             (expand "complement")
             (expand "phi")
             (expand "member")
             (case-replace "X!1(x!1)")
             (("1" (assert))
              ("2" (typepred "abs(f!1(x!1) * h!1(x!1))") (assert))))))
          ("2" (hide 2) (rewrite "prod_measurable"))
          ("3"
           (split)
           (("1"
             (hide-all-but 1)
             (skolem + ("x!1"))
             (expand "*")
             (case-replace "nnc!1=0")
             (("1" (assert))
              ("2"
               (lemma "both_sides_times_pos_le1"
                ("pz" "nnc!1" "x" "0" "y" "abs[T](f!1)(x!1)"))
               (("1" (expand "abs") (assert)) ("2" (assert))))))
            ("2"
             (lemma "integrable_abs" ("f" "f!1"))
             (lemma "integrable_scal" ("f" "abs[T](f!1)" "c" "nnc!1"))
             (lemma "nn_integrable_is_nn_integrable"
              ("f" "*[T](nnc!1, abs[T](f!1))"))
             (assert)
             (hide-all-but 1)
             (skosimp)
             (expand "*")
             (expand "abs")
             (case-replace "nnc!1=0")
             (("1" (assert))
              ("2"
               (lemma "both_sides_times_pos_le1"
                ("pz" "nnc!1" "x" "0" "y" "abs(f!1(x!1))"))
               (("1" (assert)) ("2" (assert))))))))))
        ("2"
         (hide 2)
         (skosimp)
         (split)
         (("1"
           (expand "*")
           (expand "abs")
           (expand "complement")
           (expand "phi")
           (expand "member")
           (case-replace "X!1(x!1)")
           (("1" (assert))
            ("2"
             (assert)
             (inst - "x!1")
             (expand "subset?")
             (inst - "x!1")
             (assert)
             (rewrite "abs_mult" 2)
             (case-replace "abs(f!1(x!1))=0")
             (("1" (assert))
              ("2"
               (lemma "both_sides_times_pos_le1"
                ("pz" "abs(f!1(x!1))" "x" "abs(h!1(x!1))" "y" "nnc!1"))
               (assert))))))
          ("2"
           (expand "*")
           (expand "complement")
           (expand "phi")
           (expand "member")
           (case-replace "X!1(x!1)")
           (("1" (assert)) ("2" (assert))))))))
      ("2"
       (hide-all-but (-1 1))
       (lemma "phi_is_simple" ("X" "complement[T](X!1)"))
       (("1"
         (lemma "simple_is_measurable")
         (inst - "phi(complement[T](X!1))"))
        ("2" (expand "measurable_set?") (propax))))))
    ("2" (expand "null_set?") (flatten))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral_prod" ("h" "phi(E!1)" "nnc" "1" "f" "f!1"))
   (("1"
     (case-replace "f!1 * phi(E!1)=phi(E!1) * f!1")
     (("1"
       (hide -1)
       (assert)
       (hide 2)
       (expand "phi")
       (expand "abs")
       (expand "member")
       (expand "abs")
       (expand "ae_le?")
       (expand "pointwise_ae?")
       (expand "ae?")
       (expand "fullset")
       (expand "ae_in?")
       (inst + "emptyset[T]")
       (skosimp)
       (hide 1)
       (grind))
      ("2"
       (hide-all-but 1)
       (apply-extensionality :hide? t)
       (expand "*")
       (assert))))
    ("2"
     (lemma "phi_is_simple" ("X" "E!1"))
     (("1" (expand "simple?") (flatten))
      ("2" (typepred "E!1") (expand "measurable_set?") (propax))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (expand "ae_le?")
   (expand "pointwise_ae?")
   (expand "ae?")
   (expand "fullset")
   (expand "ae_in?")
   (skosimp)
   (typepred "E!1")
   (expand "negligible_set?")
   (skosimp)
   (expand "null_set?")
   (flatten)
   (lemma "integral_ae_eq" ("f" "f1!1" "h" "phi(complement(X!1))*f1!1"))
   (("1"
     (lemma "integral_ae_eq"
      ("f" "f2!1" "h" "phi(complement(X!1))*f2!1"))
     (("1"
       (split)
       (("1"
         (split)
         (("1"
           (flatten)
           (replace -2)
           (replace -4)
           (hide -2 -4)
           (lemma "integrable_diff"
            ("f1"
             "phi(complement(X!1)) * f2!1"
             "f2"
             "phi(complement(X!1)) * f1!1"))
           (lemma "integral_diff"
            ("f1"
             "phi(complement(X!1)) * f2!1"
             "f2"
             "phi(complement(X!1)) * f1!1"))
           (lemma "integral_nonneg"
            ("f"
             "phi(complement(X!1)) * f2!1 - phi(complement(X!1)) * f1!1"))
           (split -1)
           (("1" (assert))
            ("2"
             (hide-all-but (-8 -9 1))
             (skosimp)
             (expand "subset?")
             (inst - "x!1")
             (inst - "x!1")
             (expand "member")
             (assert)
             (grind))))
          ("2"
           (hide -1 2)
           (expand "ae_eq?")
           (expand "restrict")
           (expand "pointwise_ae?")
           (expand "*")
           (expand "ae?")
           (expand "fullset")
           (expand "ae_in?")
           (inst + "X!1")
           (("1"
             (skosimp)
             (expand "complement")
             (expand "phi")
             (expand "member")
             (assert))
            ("2"
             (expand "negligible_set?")
             (inst + "X!1")
             (expand "null_set?")
             (assert)
             (expand "subset?")
             (expand "member")
             (skosimp))))))
        ("2"
         (hide -1 2)
         (expand "ae_eq?")
         (expand "restrict")
         (expand "pointwise_ae?")
         (expand "ae?")
         (expand "fullset")
         (expand "ae_in?")
         (inst + "X!1")
         (("1"
           (skosimp)
           (expand "complement")
           (expand "phi")
           (expand "member")
           (expand "*")
           (assert))
          ("2"
           (expand "negligible_set?")
           (inst + "X!1")
           (expand "null_set?")
           (assert)
           (expand "subset?")
           (skosimp))))))
      ("2"
       (rewrite "prod_measurable")
       (lemma "phi_is_simple" ("X" "complement[T](X!1)"))
       (("1" (rewrite "simple_is_measurable"))
        ("2"
         (lemma "measurable_complement" ("a" "X!1"))
         (expand "measurable_set?")
         (propax))))))
    ("2"
     (lemma "measurable_complement" ("a" "X!1"))
     (rewrite "prod_measurable")
     (lemma "phi_is_simple" ("X" "complement[T](X!1)"))
     (("1" (rewrite "simple_is_measurable"))
      ("2" (expand "measurable_set?") (propax))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integrable_abs" ("f" "f!1"))
   (copy -2)
   (expand "ae_le?" -1)
   (expand "pointwise_ae?")
   (expand "ae?")
   (expand "fullset")
   (expand "ae_in?")
   (skosimp)
   (typepred "E!1")
   (expand "negligible_set?")
   (skosimp)
   (case " measurable_set?[T, S](complement[T](X!1))")
   (("1"
     (lemma "indefinite_integrable"
      ("f" "abs(f!1)" "E" "complement(X!1)"))
     (("1"
       (lemma "nn_integrable_le"
        ("g"
         "phi(complement(X!1))*abs(h!1)"
         "f"
         "phi(complement(X!1)) * abs(f!1)"))
       (("1"
         (split -1)
         (("1"
           (flatten)
           (lemma "nn_integrable_is_integrable")
           (inst - "phi(complement(X!1)) * abs(h!1)")
           (rewrite "integral_nn" * :dir rl)
           (rewrite "integral_nn" * :dir rl)
           (lemma "integrable_abs_def"
            ("h" "phi(complement(X!1)) * h!1"))
           (("1"
             (case-replace
              "abs(phi(complement(X!1)) * h!1)=phi(complement(X!1)) * abs(h!1)")
             (("1"
               (assert)
               (hide -1)
               (lemma "integral_ae_eq"
                ("f" "phi(complement(X!1)) * h!1" "h" "h!1"))
               (split -1)
               (("1"
                 (flatten)
                 (assert)
                 (lemma "integral_abs"
                  ("f" "phi(complement(X!1)) * h!1"))
                 (replace -3)
                 (case-replace
                  "phi(complement(X!1)) * abs(h!1)=abs(phi(complement(X!1)) * h!1)")
                 (("1"
                   (hide -1)
                   (name-replace "I_0" "abs(integral(h!1))")
                   (name-replace "I_1"
                    "integral(abs(phi(complement(X!1)) * h!1))")
                   (lemma "integral_ae_eq"
                    ("f"
                     "abs(f!1)"
                     "h"
                     "phi(complement(X!1)) * abs(f!1)"))
                   (("1"
                     (split -1)
                     (("1" (flatten) (assert))
                      ("2"
                       (expand "ae_eq?")
                       (expand "restrict")
                       (expand "pointwise_ae?")
                       (expand "ae?")
                       (expand "fullset")
                       (expand "ae_in?")
                       (inst + "X!1")
                       (("1"
                         (skosimp)
                         (expand "*")
                         (expand "complement")
                         (expand "member")
                         (expand "phi")
                         (expand "member")
                         (assert))
                        ("2"
                         (expand "negligible_set?")
                         (inst + "X!1")
                         (assert)
                         (expand "subset?")
                         (skosimp))))))
                    ("2"
                     (hide-all-but (-9 1 -13))
                     (rewrite "prod_measurable")
                     (lemma "simple_is_measurable")
                     (inst - "phi[T, S](complement[T](X!1))")
                     (rewrite "phi_is_simple")
                     (expand "measurable_set?")
                     (propax))))
                  ("2"
                   (hide-all-but 1)
                   (apply-extensionality :hide? t))))
                ("2"
                 (hide 2)
                 (expand "ae_eq?")
                 (expand "restrict")
                 (expand "pointwise_ae?")
                 (expand "ae?")
                 (expand "fullset")
                 (expand "ae_in?")
                 (inst + "X!1")
                 (("1"
                   (skosimp)
                   (expand "*")
                   (expand "complement")
                   (expand "member")
                   (expand "phi")
                   (expand "member")
                   (assert))
                  ("2"
                   (expand "negligible_set?")
                   (inst + "X!1")
                   (assert)
                   (expand "subset?")
                   (skosimp))))))
              ("2"
               (hide-all-but 1)
               (apply-extensionality :hide? t)
               (("1" (grind)) ("2" (grind))))))
            ("2"
             (rewrite "prod_measurable")
             (hide-all-but (1 -5))
             (lemma "simple_is_measurable")
             (inst - "phi[T, S](complement[T](X!1))")
             (rewrite "phi_is_simple")
             (expand "measurable_set?")
             (propax))))
          ("2"
           (hide-all-but (1 -4 -5))
           (skosimp)
           (expand "subset?")
           (inst - "x!1")
           (inst - "x!1")
           (grind))))
        ("2"
         (rewrite "prod_measurable")
         (lemma "phi_is_simple" ("X" "complement[T](X!1)"))
         (("1"
           (lemma "simple_is_measurable")
           (inst - "phi(complement[T](X!1))"))
          ("2" (expand "measurable_set?") (propax))))
        ("3"
         (hide 2)
         (split)
         (("1" (hide-all-but 1) (grind))
          ("2"
           (lemma "nn_integrable_is_nn_integrable"
            ("f" "phi(complement(X!1)) * abs(f!1)"))
           (("1"
             (split -1)
             (("1" (propax)) ("2" (hide-all-but 1) (grind))))
            ("2" (propax))))))))
      ("2" (propax))))
    ("2"
     (expand "null_set?")
     (flatten)
     (rewrite "measurable_complement"))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "sup_norm_prop" ("f" "phi(F!1) * h!1"))
   (("1"
     (flatten)
     (name-replace "K" "sup_norm(phi(F!1) * h!1)")
     (case "nonempty?(fullset[T])")
     (("1"
       (case "K>=0")
       (("1"
         (lemma "isf_is_integrable")
         (inst - "K*phi(F!1)")
         (lemma "integral_ae_abs"
          ("h" "phi(F!1) * h!1" "f" "K * phi(F!1)"))
         (case-replace "abs(K * phi(F!1))=K*phi(F!1)")
         (("1"
           (hide -1)
           (rewrite "integral_scal" -1)
           (rewrite "integral_phi" -1)
           (assert)
           (split -1)
           (("1" (flatten) (assert))
            ("2"
             (hide 2 -1)
             (expand "ae_le?")
             (expand "pointwise_ae?")
             (expand "ae?")
             (expand "fullset")
             (expand "ae_in?")
             (inst + "emptyset[T]")
             (skosimp)
             (expand "*")
             (inst - "x!1")
             (expand "abs" (-2 2))
             (expand "phi")
             (expand "member")
             (case-replace "F!1(x!1)")
             (("1" (assert))
              ("2"
               (assert)
               (rewrite "abs_mult")
               (expand "abs" 3 1)
               (assert))))))
          ("2"
           (hide-all-but (-3 1))
           (apply-extensionality :hide? t)
           (("1" (grind)) ("2" (grind))))))
        ("2"
         (hide-all-but (-1 -2 1))
         (expand "fullset")
         (expand "nonempty?")
         (expand "empty?")
         (skosimp)
         (expand "member")
         (inst - "x!1")
         (assert))))
      ("2"
       (expand "nonempty?")
       (case-replace "F!1=emptyset[T]")
       (("1"
         (hide -3 -4 -5)
         (case-replace "phi(emptyset[T]) * h!1 = lambda x: 0")
         (("1"
           (rewrite "integral_zero")
           (expand "mu")
           (typepred "m")
           (expand "measure?")
           (flatten)
           (expand "measure_empty?")
           (replace -1)
           (expand "abs")
           (lemma "nn_integrable_zero")
           (rewrite "nn_integrable_is_integrable"))
          ("2"
           (hide 2)
           (apply-extensionality :hide? t)
           (expand "*")
           (expand "phi")
           (expand "member")
           (expand "emptyset")
           (assert))))
        ("2"
         (hide 2 -3 -4 -2)
         (apply-extensionality :hide? t)
         (expand "emptyset")
         (expand "fullset")
         (expand "empty?")
         (inst - "x!1")
         (expand "member")
         (propax))))))
    ("2" (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "nn_integrable_is_nn_integrable" ("f" "abs(f!1)"))
   (split -1)
   (("1"
     (expand "nn_integrable?")
     (skosimp)
     (typepred "u!1")
     (case "forall (n:nat): ae_0?(u!1(n))")
     (("1"
       (expand "pointwise_convergence?")
       (expand "convergent?")
       (skosimp)
       (lemma "ae_eq_convergence"
        ("F" "u!1" "G" "lambda (n:nat): lambda x: 0" "f" "abs(f!1)"))
       (split)
       (("1"
         (hide-all-but (-1 1))
         (expand "ae_convergence?")
         (expand "ae_0?")
         (expand "restrict")
         (expand "pointwise_ae?")
         (expand "ae?")
         (expand "fullset")
         (expand "ae_convergence_in?")
         (expand "ae_in?")
         (skosimp)
         (typepred "E!1")
         (expand "negligible_set?")
         (skosimp)
         (inst + "X!1")
         (("1"
           (skosimp)
           (expand "subset?")
           (inst - "x!1")
           (assert)
           (inst - "x!1")
           (assert)
           (lemma "hausdorff_convergence.unique_limit"
            ("l1" "abs(f!1)(x!1)" "l2" "0" "u" "LAMBDA (n:nat): 0"))
           (assert)
           (split -1)
           (("1" (expand "abs") (hide-all-but (-1 3)) (grind))
            ("2"
             (hide-all-but 1)
             (expand "convergence?")
             (skosimp)
             (inst + "0")
             (skosimp))))
          ("2"
           (assert)
           (expand "negligible_set?")
           (inst + "X!1")
           (assert)
           (expand "subset?")
           (skosimp))))
        ("2"
         (hide-all-but (-3 1))
         (expand "ae_convergence?")
         (expand "fullset")
         (expand "ae_convergence_in?")
         (expand "ae_in?")
         (inst + "emptyset[T]")
         (expand "emptyset")
         (skosimp)
         (expand "member")
         (inst - "x!1"))
        ("3"
         (hide-all-but (-1 1))
         (skosimp)
         (inst - "n!1")
         (expand "ae_0?")
         (expand "restrict")
         (expand "pointwise_ae?")
         (expand "ae_eq?")
         (expand "restrict")
         (expand "pointwise_ae?")
         (propax))))
      ("2"
       (skosimp)
       (hide 2)
       (lemma "isf_ae_ge_0" ("i" "u!1(n!1)"))
       (assert)
       (hide 2)
       (split)
       (("1"
         (expand "ae_nonneg?")
         (expand "pointwise_ae?")
         (expand "ae?")
         (expand "fullset")
         (expand "ae_in?")
         (inst + "emptyset[T]")
         (skosimp)
         (assert)
         (expand "increasing_nn_isf?")
         (typepred "u!1(n!1)")
         (expand "nn_isf?")
         (inst - "x!1")
         (assert))
        ("2"
         (lemma "integral_nn" ("g" "abs(f!1)"))
         (("1"
           (replace -1)
           (hide -1)
           (expand "nn_integral")
           (rewrite "limit_def")
           (("1"
             (lemma "nn_convergence"
              ("u1"
               "u!1"
               "f"
               "abs(f!1)"
               "u2"
               "choose({u: increasing_nn_isf[T, S, m] |
                                             pointwise_convergence?(u, abs(f!1))})"))
             (("1"
               (assert)
               (flatten)
               (hide -1)
               (lemma "hausdorff_convergence.limit_def"
                ("v"
                 "(isf_integral o
                              choose({u: increasing_nn_isf[T, S, m] |
                                        pointwise_convergence?(u, abs(f!1))}))"
                 "l"
                 "0"))
               (replace -1 -6 rl)
               (replace -6)
               (hide -1 -6)
               (rewrite "limit_def" -1)
               (hide -4)
               (rewrite "metric_convergence_def" -)
               (expand "metric_converges_to")
               (lemma "isf_integral_pos" ("i" "u!1(n!1)"))
               (split -1)
               (("1"
                 (case "isf_integral(u!1(n!1)) > 0")
                 (("1"
                   (hide -2 1)
                   (inst - "isf_integral(u!1(n!1))")
                   (("1"
                     (skosimp)
                     (inst - "n!1+n!2")
                     (assert)
                     (expand "ball")
                     (expand "o ")
                     (expand "increasing_nn_isf?")
                     (expand "pointwise_increasing?")
                     (lemma "isf_integral_le"
                      ("i1" "u!1(n!1)" "i2" "u!1(n!1+n!2)"))
                     (split -1)
                     (("1"
                       (name-replace "I_0" "isf_integral(u!1(n!1))")
                       (name-replace "I_1" "isf_integral(u!1(n!1+n!2))")
                       (hide -4 -5)
                       (grind))
                      ("2"
                       (skosimp)
                       (inst - "x!1")
                       (expand "increasing?")
                       (inst - "n!1" "n!1+n!2")
                       (assert))))
                    ("2" (assert))))
                  ("2" (assert))))
                ("2"
                 (skosimp)
                 (expand "increasing_nn_isf?")
                 (expand "pointwise_increasing?")
                 (typepred "u!1(n!1)")
                 (expand "nn_isf?")
                 (inst - "x!1"))))
              ("2"
               (expand "nonempty?")
               (expand "empty?")
               (expand "member")
               (inst - "u!1"))))
            ("2"
             (expand "nonempty?")
             (expand "empty?")
             (inst - "u!1")
             (expand "member")
             (propax))))
          ("2"
           (lemma "nn_integrable_is_nn_integrable" ("f" "abs(f!1)"))
           (split -1)
           (("1" (propax)) ("2" (hide-all-but 1) (grind))))))))))
    ("2" (hide-all-but 1) (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral_ae_eq" ("f" "lambda x: 0" "h" "h!1"))
   (("1"
     (split -1)
     (("1" (flatten) (rewrite "integral_zero") (assert))
      ("2"
       (hide 2)
       (expand "ae_0?")
       (expand "ae_eq?")
       (expand "restrict")
       (expand "pointwise_ae?")
       (expand "ae?")
       (expand "fullset")
       (expand "ae_in?")
       (skosimp)
       (inst + "E!1")
       (skosimp)
       (inst - "x!1")
       (assert))))
    ("2" (rewrite "integrable_zero"))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral_ae_eq" ("f" "f!1" "h" "abs(f!1)"))
   (split -1)
   (("1" (flatten) (lemma "integral_abs_0" ("f" "f!1")) (assert))
    ("2"
     (hide -2 2)
     (expand "ae_nonneg?")
     (expand "ae_eq?")
     (expand "restrict")
     (expand "pointwise_ae?")
     (expand "ae?")
     (expand "fullset")
     (expand "ae_in?")
     (skosimp)
     (inst + "E!1")
     (skosimp)
     (inst - "x!1")
     (assert)
     (expand "abs")
     (expand "abs")
     (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1"
     (flatten)
     (rewrite "indefinite_integrable")
     (rewrite "indefinite_integrable"))
    ("2"
     (flatten)
     (lemma "integrable_add"
      ("f1" "phi(E!1) * h!1" "f2" "phi(complement(E!1)) * h!1"))
     (("1"
       (expand "*")
       (expand "+")
       (expand "phi")
       (expand "complement")
       (expand "member")
       (case-replace
        "(LAMBDA (x_1: T):
                            IF NOT E!1(x_1) THEN 1 ELSE 0 ENDIF * h!1(x_1) +
                             IF E!1(x_1) THEN 1 ELSE 0 ENDIF * h!1(x_1))=h!1")
       (apply-extensionality :hide? t)
       (case-replace "E!1(x!1)")
       (("1" (assert)) ("2" (assert))))
      ("2" (propax)) ("3" (propax))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral_add"
    ("f1" "phi(E!1) * f!1" "f2" "phi(complement(E!1)) * f!1"))
   (replace -1 1 rl)
   (hide -1)
   (expand "phi")
   (expand "complement")
   (expand "member")
   (expand "+")
   (expand "*")
   (case-replace
    "(LAMBDA (x_1: T):
                      IF NOT E!1(x_1) THEN 1 ELSE 0 ENDIF * f!1(x_1) +
                       IF E!1(x_1) THEN 1 ELSE 0 ENDIF * f!1(x_1))=f!1")
   (apply-extensionality :hide? t)
   (case-replace "E!1(x!1)")
   (("1" (assert)) ("2" (assert))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (expand "integrable?")
   (lemma "nn_integrable_zero")
   (inst + "lambda x: 0" "lambda x: 0")
   (apply-extensionality 1 :hide? t)
   (expand "-")
   (propax))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (typepred "x!1")
   (expand "integrable?")
   (inst + "x!1" "lambda x: 0")
   (("1"
     (apply-extensionality :hide? t)
     (("1" (expand "-") (propax)) ("2" (skosimp) (expand "-") (assert))))
    ("2" (rewrite "nn_integrable_zero"))))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integrable?")
   (inst + "plus(x!1)" "minus(x!1)")
   (("1" (lemma "plus_minus_def" ("f" "x!1")) (propax))
    ("2"
     (lemma "isf_minus" ("i" "x!1"))
     (assert)
     (lemma "nn_isf_is_nn_integrable")
     (inst - "minus[T](x!1)")
     (("1" (flatten)) ("2" (expand "nn_isf?") (hide-all-but 1) (grind))))
    ("3"
     (lemma "isf_plus" ("i" "x!1"))
     (assert)
     (lemma "nn_isf_is_nn_integrable")
     (inst - "plus[T](x!1)")
     (("1" (flatten))
      ("2" (hide 2) (expand "nn_isf?") (hide -1) (grind))))))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "nn_integrable_is_measurable")
   (typepred "x!1")
   (expand "integrable?")
   (skosimp)
   (replace -1)
   (inst-cp - "g!1")
   (inst - "h!1")
   (rewrite "diff_measurable"))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f1!1")
   (typepred "f2!1")
   (expand "integrable?")
   (skosimp*)
   (inst + "g!1+g!2" "h!1+h!2")
   (apply-extensionality 1 :hide? t)
   (grind))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (expand "integrable?")
   (skosimp)
   (case "c!1>=0")
   (("1"
     (inst + "c!1*g!1" "c!1*h!1")
     (("1" (apply-extensionality :hide? t) (grind))
      ("2"
       (split)
       (("1"
         (skosimp)
         (expand "*")
         (lemma "le_times_le_pos"
          ("nnx" "0" "y" "c!1" "nnz" "0" "w" "h!1(x1!1)"))
         (assert))
        ("2"
         (typepred "h!1")
         (lemma "nn_integrable_scal" ("c" "c!1" "f" "h!1"))
         (("1" (flatten)) ("2" (propax))))))
      ("3"
       (split)
       (("1"
         (skosimp)
         (lemma "nn_integrable_scal" ("c" "c!1" "f" "g!1"))
         (("1" (flatten) (inst - "x1!1")) ("2" (propax))))
        ("2"
         (lemma "nn_integrable_scal" ("c" "c!1" "f" "g!1"))
         (("1" (flatten)) ("2" (propax))))))))
    ("2"
     (inst + "-c!1*h!1" "-c!1*g!1")
     (("1"
       (replace -1)
       (hide-all-but 2)
       (apply-extensionality :hide? t)
       (grind))
      ("2"
       (split)
       (("1"
         (hide -1)
         (skosimp)
         (grind)
         (lemma "both_sides_times_pos_le1"
          ("pz" "-c!1" "x" "0" "y" "g!1(x1!1)"))
         (assert))
        ("2"
         (lemma "nn_integrable_scal" ("c" "-c!1" "f" "g!1"))
         (("1" (flatten)) ("2" (assert))))))
      ("3"
       (split)
       (("1"
         (skosimp)
         (lemma "both_sides_times_pos_le1"
          ("pz" "-c!1" "x" "0" "y" "h!1(x1!1)"))
         (("1" (assert) (grind)) ("2" (assert))))
        ("2"
         (lemma "nn_integrable_scal" ("c" "-c!1" "f" "h!1"))
         (("1" (flatten)) ("2" (assert))))))))))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (lemma "integrable_scal" ("c" "-1" "f" "f!1"))
   (expand "*")
   (expand "-")
   (assert))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integrable_opp" ("f" "f2!1"))
   (lemma "integrable_add" ("f1" "f1!1" "f2" "-f2!1"))
   (case-replace "(+[T])(f1!1, -f2!1)=(-[T])(f1!1, f2!1)")
   (apply-extensionality 1 :hide? t)
   (expand "+")
   (expand "-")
   (assert))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (expand "integrable?")
   (skosimp)
   (typepred "g!1")
   (typepred "h!1")
   (lemma "abs_measurable" ("g" "f!1"))
   (case "forall x: abs(f!1)(x)<= (g!1+h!1)(x)")
   (("1"
     (lemma "nn_integrable_add" ("f1" "g!1" "f2" "h!1"))
     (flatten)
     (lemma "nn_integrable_le" ("f" "g!1+h!1" "g" "abs(f!1)"))
     (split -1)
     (("1"
       (flatten)
       (lemma "nn_integrable_is_integrable")
       (inst - "abs(f!1)")
       (expand "integrable?")
       (propax))
      ("2" (skosimp) (inst -3 "x!1") (assert))))
    ("2" (hide-all-but (-4 1)) (replace -1) (hide -1) (grind))))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f2!1")
   (typepred "f1!1")
   (lemma "integrable_opp" ("f" "f2!1"))
   (lemma "integrable_opp" ("f" "f1!1"))
   (expand "-")
   (lemma "integrable_max"
    ("f1" "LAMBDA (x: T): -f1!1(x)" "f2" "LAMBDA (x: T): -f2!1(x)"))
   (("1"
     (expand "max")
     (lemma "integrable_opp"
      ("f" "LAMBDA (x_1: T): max(-f1!1(x_1), -f2!1(x_1))"))
     (("1"
       (expand "-")
       (expand "min")
       (case-replace
        "(LAMBDA (x: T): -max(-f1!1(x), -f2!1(x)))=(LAMBDA (x: T): min(f1!1(x), f2!1(x)))")
       (apply-extensionality :hide? t)
       (hide-all-but 1)
       (grind))
      ("2" (propax))))
    ("2" (propax)) ("3" (propax))))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integrable_max" ("f1" "f!1" "f2" "lambda x: 0"))
   (("1" (expand "max") (expand "plus") (propax))
    ("2" (rewrite "integrable_zero"))))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integrable_min" ("f1" "f!1" "f2" "lambda x: 0"))
   (("1"
     (expand "min")
     (lemma "integrable_opp" ("f" "LAMBDA (x_1: T): min(f!1(x_1), 0)"))
     (("1" (expand "minus") (expand "-" -1) (propax)) ("2" (propax))))
    ("2" (rewrite "integrable_TCC1"))))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (induct "n")
   (("1" (skosimp) (assert) (expand "maximum") (propax))
    ("2"
     (skosimp*)
     (inst - "w!1")
     (expand "maximum" 1)
     (rewrite "integrable_max"))))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (induct "n")
   (("1" (skosimp) (expand "minimum") (propax))
    ("2"
     (skosimp*)
     (inst - "w!1")
     (expand "minimum" 1)
     (rewrite "integrable_min"))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral_convergence_scaf
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (case "FORALL (F: sequence[nn_integrable], f: [T -> nnreal]):
                 pointwise_converges_upto?(F, f)&bounded?(nn_integral o F) =>(nn_integrable?(f) AND converges_upto?((nn_integral o F), nn_integral(f)))")
   (("1"
     (skosimp)
     (inst - "lambda (n:nat): F!1(n)-F!1(0)" "f!1-F!1(0)")
     (("1"
       (split -1)
       (("1"
         (flatten)
         (lemma "nn_integrable_is_integrable")
         (inst - "f!1 - F!1(0)")
         (lemma "integrable_add" ("f1" "f!1 - F!1(0)" "f2" "F!1(0)"))
         (("1"
           (case-replace "((+[T])(f!1 - F!1(0), F!1(0)))=f!1")
           (("1"
             (hide -1)
             (replace -1)
             (expand "o ")
             (expand "converges_upto?")
             (flatten)
             (split)
             (("1"
               (rewrite "integral_nn" -4 :dir rl)
               (rewrite "integral_diff")
               (rewrite "metric_convergence_def")
               (rewrite "metric_convergence_def")
               (("1"
                 (expand "metric_converges_to")
                 (skosimp)
                 (inst - "r!1")
                 (skosimp)
                 (inst + "n!1")
                 (skosimp)
                 (inst - "i!1")
                 (assert)
                 (rewrite "integral_nn" -5 :dir rl)
                 (rewrite "integral_diff")
                 (assert)
                 (expand "ball")
                 (propax))
                ("2"
                 (hide 2)
                 (skolem + ("n!1"))
                 (lemma "integrable_diff"
                  ("f1" "F!1(n!1)" "f2" "F!1(0)"))
                 (lemma "nn_integrable_is_nn_integrable"
                  ("f" "(-[T])(F!1(n!1), F!1(0))"))
                 (case-replace
                  "(FORALL (x1: T): ((-[T])(F!1(n!1), F!1(0)))(x1) >= 0)")
                 (expand "pointwise_converges_upto?")
                 (flatten)
                 (hide-all-but (1 -9))
                 (skosimp)
                 (expand "-")
                 (expand "pointwise_increasing?")
                 (inst - "x1!1")
                 (expand "increasing?")
                 (inst - "0" "n!1")
                 (assert))))
              ("2"
               (expand "increasing?")
               (skolem + ("i!1" "j!1"))
               (flatten)
               (inst - "i!1" "j!1")
               (assert)
               (hide -5 -8 -3 -4)
               (rewrite "integral_nn" -3 :dir rl)
               (rewrite "integral_nn" -3 :dir rl)
               (rewrite "integral_diff")
               (rewrite "integral_diff")
               (assert))))
            ("2"
             (hide-all-but 1)
             (apply-extensionality :hide? t)
             (expand "+")
             (expand "-")
             (propax))))
          ("2" (propax))))
        ("2"
         (hide 2)
         (expand "pointwise_converges_upto?")
         (flatten)
         (split)
         (("1"
           (expand "pointwise_convergence?")
           (skosimp)
           (inst - "x!1")
           (rewrite "metric_convergence_def")
           (rewrite "metric_convergence_def")
           (expand "metric_converges_to")
           (skosimp)
           (inst - "r!1")
           (skosimp)
           (inst + "n!1")
           (skosimp)
           (inst - "i!1")
           (expand "ball")
           (assert)
           (expand "-")
           (propax))
          ("2"
           (expand "pointwise_increasing?")
           (skosimp)
           (inst - "x!1")
           (expand "increasing?")
           (skolem + ("i!1" "j!1"))
           (flatten)
           (inst - "i!1" "j!1")
           (expand "-")
           (assert))))
        ("3"
         (hide 2)
         (expand "o ")
         (expand "bounded?")
         (flatten)
         (split)
         (("1"
           (expand "bounded_above?")
           (skosimp)
           (expand "pointwise_converges_upto?")
           (flatten)
           (hide -1)
           (expand "bounded_below?")
           (skosimp)
           (inst + "a!1-a!2")
           (skolem + ("n!1"))
           (inst - "n!1")
           (inst - "0")
           (rewrite "integral_nn" 1 :dir rl)
           (rewrite "integral_diff")
           (assert))
          ("2"
           (expand "bounded_below?")
           (skosimp)
           (expand "bounded_above?")
           (expand "pointwise_converges_upto?")
           (flatten)
           (hide -1)
           (skosimp)
           (inst + "a!1-a!2")
           (skolem + ("n!1"))
           (inst - "0")
           (inst - "n!1")
           (rewrite "integral_nn" 1 :dir rl)
           (rewrite "integral_diff")
           (assert))))))
      ("2"
       (hide 2)
       (skosimp)
       (expand "-")
       (expand "pointwise_converges_upto?")
       (expand "pointwise_increasing?")
       (flatten)
       (inst - "x1!1")
       (hide -3)
       (expand "pointwise_convergence?")
       (inst - "x1!1")
       (rewrite "metric_convergence_def")
       (expand "metric_converges_to")
       (inst - "F!1(0)(x1!1)-f!1(x1!1)")
       (("1"
         (skosimp)
         (expand "ball")
         (expand "member")
         (inst - "n!1")
         (assert)
         (expand "increasing?")
         (inst - "0" "n!1")
         (assert))
        ("2" (assert))))
      ("3"
       (hide 2)
       (skosimp)
       (split)
       (("1"
         (skosimp)
         (expand "pointwise_converges_upto?")
         (flatten)
         (expand "pointwise_increasing?")
         (inst - "x1!1")
         (expand "increasing?")
         (inst - "0" "n!1")
         (expand "-")
         (assert))
        ("2"
         (lemma "integrable_diff" ("f1" "F!1(n!1)" "f2" "F!1(0)"))
         (expand "pointwise_converges_upto?")
         (flatten)
         (rewrite "nn_integrable_is_nn_integrable")
         (skosimp)
         (expand "pointwise_increasing?")
         (inst - "x!1")
         (expand "-")
         (expand "increasing?")
         (inst - "0" "n!1")
         (assert))))))
    ("2"
     (hide 2)
     (skosimp)
     (lemma "pointwise_measurable" ("u" "F!1" "f" "f!1"))
     (split -1)
     (("1"
       (name "ISF"
             "lambda (n:nat): choose({u:increasing_nn_isf | pointwise_convergence?(u,F!1(n))})")
       (("1"
         (hide -1)
         (case "forall (n:nat): increasing_nn_isf?(ISF(n))")
         (("1"
           (case "forall (n:nat): pointwise_convergence?(ISF(n), F!1(n))")
           (("1"
             (name "G"
                   "lambda (n:nat): maximum(lambda (i:nat): ISF(i)(n),n)")
             (case "forall (n:nat,x:T): G(n)(x)<=F!1(n)(x)")
             (("1"
               (case "forall (n:nat, x: T): F!1(n)(x)<=f!1(x)")
               (("1"
                 (case "forall (n:nat,x:T): 0 <= G(n)(x)")
                 (("1"
                   (case "pointwise_increasing?(G)")
                   (("1"
                     (case "nonempty?({nn:nn_isf | exists (n:nat): nn = G(n)})")
                     (("1"
                       (case "pointwise_bounded_above?(G)")
                       (("1"
                         (case "pointwise_converges_upto?(G, f!1)")
                         (("1"
                           (case-replace "nn_integrable?(f!1)")
                           (("1"
                             (expand "converges_upto?")
                             (case-replace
                              "increasing?(nn_integral o F!1)")
                             (("1"
                               (case "convergence?((nn_integral o G), nn_integral(f!1))")
                               (("1"
                                 (expand "pointwise_converges_upto?")
                                 (flatten)
                                 (rewrite "metric_convergence_def")
                                 (rewrite "metric_convergence_def")
                                 (case
                                  "forall (n:nat): (nn_integral o G)(n)<=(nn_integral o F!1)(n)")
                                 (("1"
                                   (case "increasing?(nn_integral o G)")
                                   (("1"
                                     (case
                                      "forall (n:nat): (nn_integral o F!1)(n)<=nn_integral(f!1)")
                                     (("1"
                                       (name-replace
                                        "LIMIT"
                                        "nn_integral(f!1)")
                                       (name-replace
                                        "INT_F"
                                        "nn_integral o F!1")
                                       (name-replace
                                        "INT_G"
                                        "nn_integral o G")
                                       (hide-all-but (-1 -2 -3 -4 -5 1))
                                       (expand "metric_converges_to")
                                       (skosimp)
                                       (inst -4 "r!1")
                                       (skosimp)
                                       (inst + "n!1")
                                       (skosimp)
                                       (inst -4 "i!1")
                                       (expand "ball")
                                       (assert)
                                       (inst - "i!1")
                                       (expand "abs")
                                       (inst - "i!1")
                                       (assert))
                                      ("2"
                                       (hide-all-but (1 -5 -12))
                                       (skosimp)
                                       (expand "o ")
                                       (lemma
                                        "nn_integrable_le"
                                        ("g" "F!1(n!1)" "f" "f!1"))
                                       (split -1)
                                       (("1" (flatten))
                                        ("2"
                                         (skosimp)
                                         (inst - "n!1" "x!1")
                                         (assert))))))
                                    ("2"
                                     (hide-all-but (1 -6 -10))
                                     (expand "pointwise_increasing?")
                                     (expand "increasing?")
                                     (expand "o ")
                                     (skolem + ("i!1" "j!1"))
                                     (flatten)
                                     (lemma
                                      "nn_integrable_le"
                                      ("g" "G(i!1)" "f" "G(j!1)"))
                                     (split -1)
                                     (("1" (flatten))
                                      ("2"
                                       (hide 2)
                                       (skosimp)
                                       (inst - "x!1")
                                       (inst - "i!1" "j!1")
                                       (inst - "i!1" "x!1")
                                       (assert))))))
                                  ("2"
                                   (hide-all-but (1 -9 -11))
                                   (skosimp)
                                   (expand "o ")
                                   (lemma
                                    "nn_integrable_le"
                                    ("g" "G(n!1)" "f" "F!1(n!1)"))
                                   (split -1)
                                   (("1" (flatten))
                                    ("2"
                                     (skosimp)
                                     (inst - "n!1" "x!1")
                                     (inst - "n!1" "x!1")
                                     (assert))))))
                                ("2"
                                 (hide 2)
                                 (expand "pointwise_converges_upto?")
                                 (flatten)
                                 (hide -1 -14 -15 -16 -17 -11)
                                 (copy -1)
                                 (expand "nn_integrable?" -1)
                                 (skosimp)
                                 (lemma
                                  "nn_convergence"
                                  ("u1"
                                   "u!1"
                                   "f"
                                   "f!1"
                                   "u2"
                                   "choose({u:increasing_nn_isf | pointwise_convergence?(u,f!1)})"))
                                 (("1"
                                   (replace -2)
                                   (replace -3)
                                   (split -1)
                                   (("1"
                                     (flatten)
                                     (expand "nn_integral" 1 2)
                                     (replace -2 1 rl)
                                     (hide -2)
                                     (hide -1)
                                     (lemma
                                      "nn_convergence"
                                      ("u1" "u!1" "f" "f!1" "u2" "G"))
                                     (("1"
                                       (replace -2)
                                       (replace -3)
                                       (replace -5)
                                       (flatten)
                                       (replace -2)
                                       (expand "o" 1 1)
                                       (case-replace
                                        "(LAMBDA (x: nat): nn_integral(G(x)))=isf_integral o G")
                                       (("1"
                                         (rewrite
                                          "hausdorff_convergence.limit_def"
                                          1
                                          :dir
                                          rl))
                                        ("2"
                                         (hide 2)
                                         (apply-extensionality :hide? t)
                                         (("1"
                                           (expand "o" 1)
                                           (rewrite "nn_integral_isf")
                                           (expand "nn_isf?")
                                           (skosimp)
                                           (inst -11 "x!1" "x!2")
                                           (assert))
                                          ("2"
                                           (expand "o")
                                           (skolem + "n!1")
                                           (lemma
                                            "isf_integral_pos"
                                            ("i" "G(n!1)"))
                                           (assert)
                                           (skosimp)
                                           (inst - "n!1" "x!1")
                                           (assert))
                                          ("3"
                                           (skolem + "n!1")
                                           (split)
                                           (("1"
                                             (skosimp)
                                             (inst - "n!1" "x1!1")
                                             (assert))
                                            ("2"
                                             (lemma
                                              "nn_isf_is_nn_integrable"
                                              ("x" "G(n!1)"))
                                             (("1" (assert))
                                              ("2"
                                               (expand "nn_isf?")
                                               (skosimp)
                                               (inst - "n!1" "x!1")
                                               (assert))))))))))
                                      ("2"
                                       (hide 2)
                                       (split)
                                       (("1"
                                         (skolem + "n!1")
                                         (expand "nn_isf?")
                                         (skosimp)
                                         (inst - "n!1" "x!1")
                                         (assert))
                                        ("2"
                                         (expand "increasing_nn_isf?")
                                         (propax))))
                                      ("3" (propax))))
                                    ("2"
                                     (hide 2)
                                     (typepred
                                      "choose({u: increasing_nn_isf
                                                                           |
                                                                           pointwise_convergence?(u, f!1)})")
                                     (propax))))
                                  ("2"
                                   (hide-all-but (-1 -2 1))
                                   (expand "nonempty?")
                                   (expand "empty?")
                                   (inst - "u!1")
                                   (expand "member")
                                   (propax))))
                                ("3"
                                 (hide 2)
                                 (skolem + ("n!1"))
                                 (assert)
                                 (split)
                                 (("1"
                                   (skosimp)
                                   (inst - "n!1" "x2!1")
                                   (assert))
                                  ("2"
                                   (typepred "G(n!1)")
                                   (lemma
                                    "nn_isf_is_nn_integrable"
                                    ("x" "G(n!1)"))
                                   (("1" (assert))
                                    ("2"
                                     (expand "nn_isf?")
                                     (skosimp)
                                     (inst -8 "n!1" "x!1")
                                     (assert))))))))
                              ("2"
                               (hide 2)
                               (expand "pointwise_converges_upto?")
                               (flatten)
                               (hide-all-but (-15 1))
                               (expand "pointwise_increasing?")
                               (expand "increasing?")
                               (expand "o ")
                               (skolem + ("i!1" "j!1"))
                               (flatten)
                               (lemma "nn_integrable_le"
                                ("g" "F!1(i!1)" "f" "F!1(j!1)"))
                               (split -1)
                               (("1" (flatten))
                                ("2"
                                 (hide 2)
                                 (skosimp)
                                 (inst - "x!1")
                                 (inst - "i!1" "j!1")
                                 (assert)
                                 (assert))))))
                            ("2"
                             (hide 2)
                             (expand "nn_integrable?")
                             (inst + "G")
                             (("1"
                               (expand "pointwise_converges_upto?")
                               (flatten)
                               (assert)
                               (lemma "bounded_above_is_convergent"
                                ("u" "isf_integral o G"))
                               (split -1)
                               (("1"
                                 (expand "convergent_upto?")
                                 (skosimp)
                                 (expand "converges_upto?")
                                 (flatten)
                                 (expand "convergent?")
                                 (inst + "x!1"))
                                ("2"
                                 (hide-all-but (-15 1 -8 -2 -6))
                                 (expand "bounded?")
                                 (flatten)
                                 (expand "bounded_above?")
                                 (skosimp)
                                 (expand "o" -4)
                                 (inst + "a!1")
                                 (skosimp)
                                 (expand "o" +)
                                 (typepred "G(x!1)")
                                 (lemma "nn_integral_isf" ("i" "G(x!1)"))
                                 (("1"
                                   (replace -1 1 rl)
                                   (hide -1)
                                   (lemma
                                    "nn_integrable_le"
                                    ("g" "G(x!1)" "f" "F!1(x!1)"))
                                   (split -1)
                                   (("1"
                                     (flatten)
                                     (inst -7 "x!1")
                                     (assert))
                                    ("2"
                                     (skosimp)
                                     (inst -3 "x!1" "x!2")
                                     (assert)
                                     (inst -4 "x!1" "x!2"))))
                                  ("2"
                                   (expand "nn_isf?")
                                   (skosimp)
                                   (inst -3 "x!1" "x!2")
                                   (assert))))
                                ("3"
                                 (hide-all-but (-2 1))
                                 (expand "pointwise_increasing?")
                                 (expand "increasing?")
                                 (expand "o ")
                                 (skolem + ("i!1" "j!1"))
                                 (flatten)
                                 (lemma
                                  "isf_integral_le"
                                  ("i1" "G(i!1)" "i2" "G(j!1)"))
                                 (split -1)
                                 (("1" (propax))
                                  ("2"
                                   (skosimp)
                                   (inst - "x!1")
                                   (inst - "i!1" "j!1")
                                   (assert))))))
                              ("2"
                               (split)
                               (("1"
                                 (skosimp)
                                 (assert)
                                 (expand "nn_isf?")
                                 (skosimp)
                                 (inst -5 "x1!1" "x!1")
                                 (assert))
                                ("2"
                                 (expand "increasing_nn_isf?")
                                 (propax))))))))
                          ("2"
                           (hide 2)
                           (expand "pointwise_converges_upto?")
                           (assert)
                           (expand "pointwise_convergence?")
                           (skosimp)
                           (typepred
                            "sup(Im(LAMBDA (n:nat): G(n)(x!1)))")
                           (("1"
                             (name-replace "SUP"
                              "sup(Im(LAMBDA (n:nat): G(n)(x!1)))")
                             (expand "Im")
                             (case-replace "SUP=f!1(x!1)")
                             (("1"
                               (expand "least_upper_bound")
                               (flatten)
                               (hide-all-but (-2 -3 -6 1))
                               (name-replace "LIMIT" "f!1(x!1)")
                               (rewrite "metric_convergence_def")
                               (expand "metric_converges_to")
                               (skosimp)
                               (expand "ball")
                               (expand "member")
                               (inst - "LIMIT-r!1")
                               (assert)
                               (expand "upper_bound" 1)
                               (skosimp)
                               (typepred "z!1")
                               (skolem - ("n!1"))
                               (replace -1)
                               (inst + "n!1")
                               (skosimp)
                               (expand "pointwise_increasing?")
                               (inst - "x!1")
                               (expand "increasing?")
                               (inst - "n!1" "i!1")
                               (assert)
                               (expand "upper_bound")
                               (inst - "G(i!1)(x!1)")
                               (("1" (assert) (expand "abs") (assert))
                                ("2" (inst + "i!1"))))
                              ("2"
                               (hide 2)
                               (lemma "converges_upto_is_lub"
                                ("x"
                                 "SUP"
                                 "u"
                                 "lambda (n:nat): G(n)(x!1)"))
                               (case-replace
                                "least_upper_bound?(SUP,
                                                             image[nat, real]
                                                                 (LAMBDA (n:nat): G(n)(x!1), fullset[nat]))")
                               (("1"
                                 (hide -1)
                                 (expand "converges_upto?")
                                 (expand "pointwise_increasing?")
                                 (inst -5 "x!1")
                                 (replace -5)
                                 (expand "pointwise_bounded_above?")
                                 (expand "pointwise?")
                                 (inst -3 "x!1")
                                 (assert)
                                 (inst -13 "x!1")
                                 (inst -14 "x!1")
                                 (inst - "_" "x!1")
                                 (inst - "_" "x!1")
                                 (inst - "_" "x!1")
                                 (hide -9)
                                 (case-replace
                                  "convergence?(LAMBDA (n:nat): G(n)(x!1), f!1(x!1))")
                                 (("1"
                                   (lemma
                                    "hausdorff_convergence.unique_limit"
                                    ("u"
                                     "LAMBDA (n:nat): G(n)(x!1)"
                                     "l1"
                                     "SUP"
                                     "l2"
                                     "f!1(x!1)"))
                                   (assert))
                                  ("2"
                                   (hide 2 -1 -2 -3 -4)
                                   (rewrite "metric_convergence_def")
                                   (rewrite "metric_convergence_def")
                                   (case
                                    "forall (n:nat): metric_converges_to(LAMBDA (n_1: nat): ISF(n)(n_1)(x!1), F!1(n)(x!1))")
                                   (("1"
                                     (hide -6)
                                     (expand "metric_converges_to")
                                     (expand "ball")
                                     (expand "member")
                                     (skosimp)
                                     (inst -8 "r!1/2")
                                     (skosimp)
                                     (inst - "n!1")
                                     (inst - "r!1/2")
                                     (skosimp)
                                     (inst + "n!1+n!2")
                                     (skosimp)
                                     (inst - "i!1")
                                     (assert)
                                     (inst-cp -9 "n!1")
                                     (assert)
                                     (inst-cp -5 "n!1")
                                     (expand "abs" (1 -11))
                                     (assert)
                                     (inst-cp -7 "i!1")
                                     (assert)
                                     (inst-cp -5 "i!1")
                                     (assert)
                                     (case
                                      "forall (i:nat): ISF(n!1)(i)(x!1)<=F!1(n!1)(x!1)")
                                     (("1"
                                       (inst - "i!1")
                                       (expand "abs" -2)
                                       (assert)
                                       (case
                                        "ISF(n!1)(i!1)(x!1)<=G(i!1)(x!1)")
                                       (("1" (assert))
                                        ("2"
                                         (hide 2)
                                         (expand "G" 1)
                                         (hide-all-but (-3 1))
                                         (case
                                          "forall (j:nat): ISF(n!1)(i!1)(x!1) <= maximum(LAMBDA (i: nat): ISF(i)(i!1), n!1+j)(x!1)")
                                         (("1"
                                           (inst - "i!1-n!1")
                                           (assert))
                                          ("2"
                                           (hide 2)
                                           (induct "j")
                                           (("1"
                                             (case-replace "n!1=0")
                                             (("1"
                                               (expand "maximum")
                                               (assert))
                                              ("2"
                                               (expand "maximum")
                                               (assert)
                                               (expand "max")
                                               (grind))))
                                            ("2"
                                             (skosimp*)
                                             (expand "maximum" 1)
                                             (expand "max")
                                             (name-replace
                                              "DRL1"
                                              "maximum(LAMBDA (i: nat): ISF(i)(i!1), n!1 + j!1)(x!1)")
                                             (grind))))))))
                                      ("2"
                                       (hide 2)
                                       (skosimp)
                                       (expand "ISF" 1)
                                       (hide-all-but 1)
                                       (typepred
                                        "choose({u: increasing_nn_isf | pointwise_convergence?(u, F!1(n!1))})")
                                       (("1"
                                         (name-replace
                                          "DRL"
                                          "choose({u: increasing_nn_isf | pointwise_convergence?(u, F!1(n!1))})")
                                         (expand "increasing_nn_isf?")
                                         (expand "pointwise_increasing?")
                                         (expand
                                          "pointwise_convergence?")
                                         (inst - "x!1")
                                         (inst - "x!1")
                                         (rewrite
                                          "metric_convergence_def")
                                         (expand "metric_converges_to")
                                         (inst
                                          -
                                          "DRL(i!2)(x!1) - F!1(n!1)(x!1)")
                                         (("1"
                                           (skosimp)
                                           (expand "ball")
                                           (expand "member")
                                           (inst - "i!2+n!3")
                                           (assert)
                                           (expand "increasing?")
                                           (inst - "i!2" "i!2+n!3")
                                           (assert))
                                          ("2" (assert))))
                                        ("2"
                                         (hide 2)
                                         (expand "nonempty?")
                                         (expand "empty?")
                                         (expand "member")
                                         (typepred "F!1(n!1)")
                                         (expand "nn_integrable?")
                                         (skosimp)
                                         (inst - "u!1"))))))
                                    ("2"
                                     (hide-all-but (-5 1))
                                     (skosimp)
                                     (inst - "n!1")
                                     (inst - "x!1")
                                     (rewrite
                                      "metric_convergence_def"))))))
                                ("2"
                                 (hide-all-but (-2 1))
                                 (expand "fullset")
                                 (expand "image")
                                 (expand "least_upper_bound?")
                                 (expand "least_upper_bound")
                                 (flatten)
                                 (split)
                                 (("1"
                                   (hide -2)
                                   (expand "upper_bound")
                                   (expand "upper_bound?")
                                   (propax))
                                  ("2"
                                   (hide -1)
                                   (skosimp)
                                   (inst - "y!1")
                                   (split -2)
                                   (("1" (propax))
                                    ("2" (assert))
                                    ("3"
                                     (hide 2)
                                     (expand "upper_bound?")
                                     (expand "upper_bound")
                                     (propax))))))))))
                            ("2"
                             (hide-all-but (-1 1))
                             (expand "Im")
                             (expand "pointwise_bounded_above?")
                             (expand "pointwise?")
                             (inst - "x!1")
                             (expand "bounded_above?")
                             (expand "above_bounded")
                             (skosimp)
                             (expand "upper_bound")
                             (inst + "ceiling(a!1)")
                             (skosimp)
                             (typepred "z!1")
                             (skosimp)
                             (inst - "x!2")
                             (assert))))))
                        ("2"
                         (hide 2)
                         (expand "pointwise_bounded_above?")
                         (expand "pointwise?")
                         (skosimp)
                         (expand "bounded_above?")
                         (inst + "f!1(x!1)")
                         (skosimp)
                         (inst -5 "x!2" "x!1")
                         (inst -4 "x!2" "x!1")
                         (assert))))
                      ("2"
                       (hide 2)
                       (expand "nonempty?")
                       (expand "empty?")
                       (inst - "G(0)")
                       (("1" (expand "member") (inst + "0"))
                        ("2"
                         (expand "nn_isf?")
                         (skosimp)
                         (inst - "0" "x!1")
                         (assert))))))
                    ("2"
                     (hide 2 -9 -7 -4)
                     (expand "pointwise_increasing?")
                     (skosimp)
                     (expand "increasing?")
                     (expand "G")
                     (case "forall (i,j,k,n:nat): j<=k => maximum(LAMBDA (i: nat): ISF(i)(j), i)(x!1) <= maximum(LAMBDA (i: nat): ISF(i)(k), i+n)(x!1)")
                     (("1"
                       (skosimp)
                       (inst - "x!2" "x!2" "y!1" "y!1-x!2")
                       (("1" (assert)) ("2" (assert))))
                      ("2"
                       (hide 2 -1 -2 -3 -4 -6)
                       (induct "n")
                       (("1"
                         (induct "i")
                         (("1"
                           (skosimp)
                           (expand "maximum")
                           (inst - "0")
                           (expand "increasing_nn_isf?")
                           (expand "pointwise_increasing?")
                           (inst - "x!1")
                           (expand "increasing?")
                           (inst - "j!1" "k!1")
                           (assert))
                          ("2"
                           (skolem!)
                           (flatten)
                           (skosimp)
                           (expand "maximum" 1)
                           (expand "max")
                           (inst - "j!2" "k!1")
                           (assert)
                           (name-replace "DRL1"
                            "maximum(LAMBDA (i: nat): ISF(i)(j!2), j!1)(x!1)")
                           (name-replace "DRL2"
                            "maximum(LAMBDA (i: nat): ISF(i)(k!1), j!1)(x!1)")
                           (inst - "1+j!1")
                           (expand "increasing_nn_isf?")
                           (expand "pointwise_increasing?")
                           (inst - "x!1")
                           (expand "increasing?")
                           (inst - "j!2" "k!1")
                           (assert)
                           (grind))))
                        ("2"
                         (skolem!)
                         (flatten)
                         (induct "i")
                         (("1"
                           (skosimp)
                           (expand "maximum" 1)
                           (expand "max")
                           (inst - "0" "j!2" "k!1")
                           (assert)
                           (name-replace "DRL1"
                            "maximum(LAMBDA (i: nat): ISF(i)(k!1), j!1)(x!1)")
                           (expand "maximum")
                           (hide -3)
                           (grind))
                          ("2"
                           (skosimp*)
                           (expand "maximum" 1)
                           (expand "max")
                           (inst - "j!3" "k!1")
                           (assert)
                           (case "forall (n:nat): ISF(1 + j!2)(j!3)(x!1)<=maximum(LAMBDA (i: nat): ISF(i)(k!1), 1 + n + j!2)(x!1)")
                           (("1"
                             (inst - "j!1")
                             (name-replace "DRL1"
                              "maximum(LAMBDA (i: nat): ISF(i)(k!1), 1 + j!1 + j!2)(x!1)")
                             (name-replace "DRL2"
                              "maximum(LAMBDA (i: nat): ISF(i)(j!3), j!2)(x!1)")
                             (hide -4 -5 -3)
                             (grind))
                            ("2"
                             (hide -1 2 -3)
                             (induct "n")
                             (("1"
                               (expand "maximum")
                               (expand "max")
                               (inst - "1+j!2")
                               (expand "increasing_nn_isf?")
                               (expand "pointwise_increasing?")
                               (inst - "x!1")
                               (expand "increasing?")
                               (inst - "j!3" "k!1")
                               (assert))
                              ("2"
                               (skosimp*)
                               (expand "maximum" 1)
                               (expand "max")
                               (name-replace "DRL1"
                                "maximum(LAMBDA (i: nat): ISF(i)(k!1), 1 + j!4 + j!2)(x!1)")
                               (hide -3)
                               (grind))))))))))))))
                  ("2"
                   (hide 2)
                   (hide-all-but 1)
                   (expand "G")
                   (case "FORALL (n,j:nat,x:T): 0 <= maximum(LAMBDA (i: nat): ISF(i)(j), n)(x)")
                   (("1" (skosimp) (inst - "n!1" "n!1" "x!1"))
                    ("2"
                     (hide 2)
                     (skolem + ("_" "j!1" "x!1"))
                     (induct "n")
                     (("1"
                       (expand "maximum")
                       (typepred "ISF(0)(j!1)")
                       (expand "nn_isf?")
                       (inst - "x!1")
                       (assert))
                      ("2"
                       (skosimp*)
                       (expand "maximum" 1)
                       (expand "max")
                       (typepred "ISF(1+j!2)(j!1)")
                       (expand "nn_isf?")
                       (inst - "x!1")
                       (expand "max")
                       (case-replace
                        "ISF(1 + j!2)(j!1)(x!1) <
                                   maximum(LAMBDA (i: nat): ISF(i)(j!1), j!2)(x!1)")
                       (assert))))))))
                ("2"
                 (hide-all-but (-6 1))
                 (skosimp)
                 (expand "pointwise_converges_upto?")
                 (expand "pointwise_convergence?")
                 (expand "pointwise_increasing?")
                 (flatten)
                 (inst - "x!1")
                 (inst - "x!1")
                 (expand "increasing?")
                 (rewrite "metric_convergence_def")
                 (expand "metric_converges_to")
                 (inst - "F!1(n!1)(x!1)-f!1(x!1)")
                 (("1"
                   (skosimp)
                   (inst - "n!1+n!2")
                   (expand "ball")
                   (expand "member")
                   (inst - "n!1" "n!1+n!2")
                   (assert))
                  ("2" (assert))))))
              ("2"
               (expand "pointwise_converges_upto?")
               (flatten)
               (hide -1 -4 -5 -7 2)
               (expand "G")
               (case "forall (k,n:nat,x:T): maximum(LAMBDA (i: nat): ISF(i)(k), n)(x) <= F!1(n)(x)")
               (("1" (skosimp) (inst - "n!1" "n!1" "x!1"))
                ("2"
                 (hide 2)
                 (induct "n")
                 (("1"
                   (skosimp)
                   (expand "maximum")
                   (inst - "0")
                   (inst - "0")
                   (hide -3)
                   (expand "increasing_nn_isf?")
                   (expand "pointwise_convergence?")
                   (expand "pointwise_increasing?")
                   (inst - "x!1")
                   (inst - "x!1")
                   (rewrite "metric_convergence_def")
                   (expand "metric_converges_to")
                   (inst - "ISF(0)(k!1)(x!1) - F!1(0)(x!1)")
                   (("1"
                     (skosimp)
                     (expand "ball")
                     (expand "member")
                     (expand "abs")
                     (inst - "n!1+k!1")
                     (assert)
                     (expand "increasing?")
                     (inst - "k!1" "n!1+k!1")
                     (assert)
                     (assert))
                    ("2" (assert))))
                  ("2"
                   (skosimp*)
                   (expand "maximum" 1)
                   (expand "max")
                   (inst - "k!1" "x!1")
                   (name-replace "MAXI"
                    "maximum(LAMBDA (i: nat): ISF(i)(k!1), j!1)(x!1)")
                   (expand "pointwise_increasing?")
                   (inst -4 "x!1")
                   (expand "increasing?")
                   (inst -4 "j!1" "1+j!1")
                   (assert)
                   (case "ISF(1 + j!1)(k!1)(x!1)<=F!1(1 + j!1)(x!1)")
                   (("1"
                     (expand "max")
                     (case-replace "ISF(1 + j!1)(k!1)(x!1) < MAXI")
                     (("1" (assert)) ("2" (assert))))
                    ("2"
                     (hide -1 2 -4)
                     (inst - "1+j!1")
                     (inst - "1+j!1")
                     (expand "increasing_nn_isf?")
                     (expand "pointwise_convergence?")
                     (expand "pointwise_increasing?")
                     (inst - "x!1")
                     (inst - "x!1")
                     (rewrite "metric_convergence_def")
                     (expand "metric_converges_to")
                     (inst -
                      "ISF(1 + j!1)(k!1)(x!1) - F!1(1 + j!1)(x!1)")
                     (("1"
                       (skosimp)
                       (expand "ball")
                       (expand "member")
                       (inst - "n!1+k!1")
                       (expand "increasing?")
                       (inst - "k!1" "k!1+n!1")
                       (assert)
                       (assert))
                      ("2" (assert))))))))))))
            ("2"
             (hide 2 -2 -4)
             (skosimp)
             (typepred "ISF(n!1)")
             (propax))))
          ("2" (skosimp) (typepred "ISF(n!1)") (propax))))
        ("2"
         (hide 2)
         (skosimp)
         (expand "nonempty?")
         (hide -2 -3 -4)
         (typepred "F!1(n!1)")
         (expand "nn_integrable?")
         (skosimp)
         (expand "empty?")
         (inst - "u!1")
         (expand "member")
         (propax))))
      ("2" (expand "pointwise_converges_upto?") (flatten))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral_convergence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp*)
   (case-replace
    "(EXISTS f: ae_convergence?(F!1, f)) IFF bounded?(integral o F!1)")
   (("1"
     (assert)
     (skolem!)
     (flatten)
     (hide -2)
     (split -1)
     (("1"
       (expand "ae_increasing?")
       (expand "ae_convergence?")
       (expand "fullset")
       (expand "ae_convergence_in?")
       (expand "ae_in?")
       (skolem - "E1")
       (skolem - "E2")
       (typepred "union(E1,E2)")
       (expand "negligible_set?")
       (skosimp)
       (lemma "null_set_is_measurable")
       (inst - "X!1")
       (lemma "monotone_convergence_scaf"
        ("f"
         "phi(complement(X!1))*f!1"
         "F"
         "lambda n: phi(complement(X!1))*F!1(n)"))
       (("1"
         (case-replace
          "integral o (LAMBDA n: phi(complement(X!1)) * F!1(n))=integral o F!1")
         (("1"
           (hide -1)
           (replace -5)
           (case-replace
            "integral(phi(complement(X!1)) * f!1)=integral(f!1)")
           (("1"
             (split -2)
             (("1" (flatten))
              ("2"
               (hide 2)
               (expand "pointwise_converges_upto?")
               (case-replace
                "pointwise_increasing?(LAMBDA n: phi(complement(X!1)) * F!1(n))")
               (("1"
                 (expand "pointwise_convergence?")
                 (skosimp)
                 (inst -8 "x!1")
                 (expand "complement")
                 (expand "member")
                 (expand "phi")
                 (expand "member")
                 (hide -1 -2)
                 (expand "subset?")
                 (expand "union")
                 (expand "member")
                 (inst - "x!1")
                 (expand "*" 1)
                 (case-replace "E2(x!1)")
                 (("1"
                   (assert)
                   (hide-all-but 1)
                   (expand "convergence?")
                   (skosimp)
                   (inst + "0")
                   (skosimp)
                   (assert))
                  ("2"
                   (assert)
                   (case-replace "X!1(x!1)")
                   (("1"
                     (hide-all-but 2)
                     (expand "convergence?")
                     (skosimp)
                     (inst + "0")
                     (skosimp)
                     (assert))
                    ("2" (assert))))))
                ("2"
                 (hide 2)
                 (hide -1 -5 -7)
                 (expand "pointwise_increasing?")
                 (skosimp)
                 (expand "*")
                 (expand "complement")
                 (expand "phi")
                 (expand "member")
                 (inst - "x!1")
                 (expand "subset?")
                 (expand "union")
                 (expand "member")
                 (inst - "x!1")
                 (case-replace "X!1(x!1)")
                 (("1" (expand "increasing?") (propax))
                  ("2"
                   (assert)
                   (expand "increasing?")
                   (skosimp)
                   (assert)
                   (inst - "x!2" "y!1")
                   (assert))))))))
            ("2"
             (hide -1 2)
             (lemma "integral_ae_eq"
              ("f" "f!1" "h" "phi(complement(X!1)) * f!1"))
             (("1"
               (split -1)
               (("1" (flatten) (assert))
                ("2"
                 (hide 2)
                 (expand "ae_eq?")
                 (expand "restrict")
                 (expand "pointwise_ae?")
                 (expand "*")
                 (expand "complement")
                 (expand "phi")
                 (expand "member")
                 (expand "ae?")
                 (expand "fullset")
                 (expand "ae_in?")
                 (inst + "X!1")
                 (("1" (skosimp) (assert))
                  ("2"
                   (expand "negligible_set?")
                   (inst + "X!1")
                   (assert)
                   (hide-all-but 1)
                   (grind))))))
              ("2"
               (hide 2)
               (rewrite "integrable_is_measurable")
               (hide 2)
               (rewrite "indefinite_integrable")
               (hide 2)
               (rewrite "measurable_complement"))))
            ("3"
             (hide 2)
             (rewrite "indefinite_integrable")
             (rewrite "measurable_complement"))))
          ("2"
           (hide -1 2)
           (expand "o ")
           (apply-extensionality :hide? t)
           (("1"
             (lemma "integral_ae_eq"
              ("f" "F!1(x!1)" "h" "phi(complement(X!1)) * F!1(x!1)"))
             (("1"
               (split -1)
               (("1" (flatten) (assert))
                ("2"
                 (hide 2)
                 (expand "ae_eq?")
                 (expand "restrict")
                 (expand "pointwise_ae?")
                 (expand "*" 1)
                 (expand "complement")
                 (expand "phi")
                 (expand "member")
                 (expand "ae?")
                 (expand "fullset")
                 (expand "ae_in?")
                 (inst + "X!1")
                 (("1" (skosimp) (assert))
                  ("2"
                   (expand "negligible_set?")
                   (inst + "X!1")
                   (assert)
                   (hide-all-but 1)
                   (grind))))))
              ("2"
               (hide 2)
               (rewrite "integrable_is_measurable")
               (rewrite "indefinite_integrable")
               (rewrite "measurable_complement"))))
            ("2"
             (skosimp)
             (rewrite "indefinite_integrable")
             (rewrite "measurable_complement"))))))
        ("2"
         (skosimp)
         (rewrite "indefinite_integrable")
         (rewrite "measurable_complement"))))
      ("2" (inst + "f!1"))))
    ("2"
     (hide 2)
     (split)
     (("1"
       (skosimp*)
       (expand "bounded?")
       (split)
       (("1"
         (expand "bounded_above?")
         (inst + "integral(f!1)")
         (skolem + ("n!1"))
         (expand "o ")
         (expand "ae_convergence?")
         (expand "ae_increasing?")
         (expand "ae_convergence_in?")
         (expand "fullset")
         (expand "ae_in?")
         (skosimp*)
         (typepred "union(E!1,E!2)")
         (expand "negligible_set?")
         (skosimp)
         (lemma "integral_ae_le"
          ("f1"
           "phi(complement(X!1))*F!1(n!1)"
           "f2"
           "phi(complement(X!1))*f!1"))
         (("1"
           (split -1)
           (("1"
             (lemma "integral_ae_eq"
              ("f" "f!1" "h" "phi(complement(X!1)) * f!1"))
             (("1"
               (split -1)
               (("1"
                 (flatten)
                 (replace -2 * rl)
                 (lemma "integral_ae_eq"
                  ("f" "F!1(n!1)" "h" "phi(complement(X!1)) * F!1(n!1)"))
                 (("1"
                   (split -1)
                   (("1" (flatten) (assert))
                    ("2"
                     (hide-all-but (-4 -5 1))
                     (expand "ae_eq?")
                     (expand "restrict")
                     (expand "pointwise_ae?")
                     (expand "ae?")
                     (expand "*")
                     (expand "complement")
                     (expand "phi")
                     (expand "member")
                     (expand "fullset")
                     (expand "ae_in?")
                     (inst + "X!1")
                     (("1" (skosimp) (assert))
                      ("2" (rewrite "null_is_negligible"))))))
                  ("2" (rewrite "integrable_is_measurable"))))
                ("2"
                 (hide -1 -4 -5 2)
                 (expand "ae_eq?")
                 (expand "restrict")
                 (expand "pointwise_ae?")
                 (expand "complement")
                 (expand "phi")
                 (expand "member")
                 (expand "ae?")
                 (expand "fullset")
                 (expand "ae_in?")
                 (inst + "X!1")
                 (("1" (skosimp) (assert) (expand "*") (assert))
                  ("2" (rewrite "null_is_negligible"))))))
              ("2" (rewrite "integrable_is_measurable"))))
            ("2"
             (hide 2)
             (expand "ae_le?")
             (expand "*")
             (expand "pointwise_ae?")
             (expand "complement")
             (expand "phi")
             (expand "member")
             (expand "ae?")
             (expand "fullset")
             (expand "ae_in?")
             (inst + "X!1")
             (("1"
               (skosimp)
               (assert)
               (expand "union")
               (expand "subset?")
               (expand "member")
               (inst - "x!1")
               (inst - "x!1")
               (inst - "x!1")
               (case-replace "E!1(x!1)")
               (case-replace "E!2(x!1)")
               (assert)
               (hide 1 2 3 -1 -2)
               (rewrite "metric_convergence_def")
               (case "F!1(n!1)(x!1)-f!1(x!1)>0")
               (("1"
                 (expand "metric_converges_to")
                 (inst - "F!1(n!1)(x!1) - f!1(x!1)")
                 (hide 1)
                 (skosimp)
                 (inst - "n!1+n!2")
                 (assert)
                 (inst - "n!1" "n!1+n!2")
                 (expand "ball")
                 (assert))
                ("2" (assert))))
              ("2" (rewrite "null_is_negligible"))))))
          ("2"
           (rewrite "indefinite_integrable")
           (rewrite "measurable_complement")
           (expand "null_set?")
           (propax))
          ("3"
           (rewrite "indefinite_integrable")
           (rewrite "measurable_complement")
           (expand "null_set?")
           (propax))))
        ("2"
         (expand "bounded_below?")
         (inst + "integral(F!1(0))")
         (skolem + ("n!1"))
         (expand "o ")
         (expand "ae_increasing?")
         (skosimp)
         (lemma "integral_ae_le" ("f1" "F!1(0)" "f2" "F!1(n!1)"))
         (assert)
         (hide 2)
         (expand "ae_le?")
         (expand "pointwise_ae?")
         (expand "ae?")
         (expand "fullset")
         (expand "ae_in?")
         (inst + "E!1")
         (skosimp)
         (inst - "x!1")
         (assert)
         (inst - "0" "n!1")
         (assert))))
      ("2"
       (flatten)
       (expand "ae_increasing?")
       (skosimp)
       (typepred "E!1")
       (expand "negligible_set?")
       (skosimp)
       (case "forall (F:sequence[nn_integrable]): bounded?(integral o F)&pointwise_increasing?(F)=>EXISTS (f:nn_integrable): ae_convergence?(F, f)")
       (("1"
         (inst - "lambda n: phi(complement(X!1))*(F!1(n)-F!1(0))")
         (("1"
           (split -1)
           (("1"
             (skosimp)
             (typepred "f!1")
             (inst + "f!1+phi(complement(X!1)) *F!1(0)")
             (("1"
               (expand "ae_convergence?")
               (expand "fullset")
               (expand "ae_convergence_in?")
               (expand "ae_in?")
               (skosimp)
               (inst + "union(X!1,E!2)")
               (("1"
                 (skosimp)
                 (expand "union")
                 (expand "member")
                 (flatten)
                 (expand "+ ")
                 (expand "*")
                 (inst - "x!1")
                 (assert)
                 (expand "-")
                 (expand "complement")
                 (expand "phi")
                 (expand "member")
                 (hide-all-but (-2 3))
                 (rewrite "metric_convergence_def")
                 (rewrite "metric_convergence_def")
                 (expand "metric_converges_to")
                 (skosimp)
                 (inst - "r!1")
                 (skosimp)
                 (inst + "n!1")
                 (skosimp)
                 (inst - "i!1")
                 (expand "ball")
                 (expand "member")
                 (assert))
                ("2"
                 (rewrite "negligible_union")
                 (rewrite "null_is_negligible"))))
              ("2"
               (rewrite "integrable_add")
               (hide 2)
               (lemma "integral_ae_eq"
                ("f"
                 "F!1(0)"
                 "h"
                 "*[T](phi[T, S](complement[T](X!1)), F!1(0))"))
               (("1"
                 (split -1)
                 (("1" (flatten))
                  ("2"
                   (hide 2)
                   (expand "ae_eq?")
                   (expand "restrict")
                   (expand "pointwise_ae?")
                   (expand "ae?")
                   (expand "fullset")
                   (expand "ae_in?")
                   (inst + "X!1")
                   (("1"
                     (skosimp)
                     (expand "*")
                     (expand "complement")
                     (expand "phi")
                     (expand "member")
                     (assert))
                    ("2" (rewrite "null_is_negligible"))))))
                ("2"
                 (hide 2)
                 (lemma "phi_is_simple" ("X" "complement[T](X!1)"))
                 (("1"
                   (expand "simple?")
                   (flatten)
                   (rewrite "prod_measurable"))
                  ("2"
                   (expand "null_set?")
                   (flatten)
                   (lemma "measurable_complement" ("a" "X!1"))
                   (expand "measurable_set?")
                   (propax))))))))
            ("2"
             (hide 2)
             (expand "bounded?")
             (split)
             (("1"
               (flatten)
               (expand "bounded_above?")
               (skosimp)
               (hide -4)
               (inst + "a!1-integral(F!1(0))")
               (skolem + ("n!1"))
               (expand "o")
               (inst - "n!1")
               (lemma "integral_ae_eq"
                ("f"
                 "F!1(n!1) - F!1(0)"
                 "h"
                 "phi(complement(X!1)) * (F!1(n!1) - F!1(0))"))
               (("1"
                 (split -1)
                 (("1"
                   (flatten)
                   (replace -2 1 rl)
                   (rewrite "integral_diff")
                   (assert))
                  ("2"
                   (hide -3 2)
                   (expand "ae_eq?")
                   (expand "restrict")
                   (expand "pointwise_ae?")
                   (expand "ae?")
                   (expand "fullset")
                   (expand "ae_in?")
                   (inst + "X!1")
                   (("1"
                     (skosimp)
                     (expand "subset?")
                     (inst - "x!1")
                     (inst - "x!1")
                     (expand "complement")
                     (expand "phi")
                     (expand "member")
                     (expand "*")
                     (expand "-")
                     (assert))
                    ("2" (rewrite "null_is_negligible"))))))
                ("2"
                 (hide 2)
                 (lemma "integrable_diff"
                  ("f1" "F!1(n!1)" "f2" "F!1(0)"))
                 (lemma "integrable_is_measurable"
                  ("x" "(-[T])(F!1(n!1), F!1(0))"))
                 (lemma "phi_is_simple" ("X" "complement[T](X!1)"))
                 (("1"
                   (expand "simple?")
                   (flatten)
                   (rewrite "prod_measurable"))
                  ("2"
                   (expand "null_set?")
                   (flatten)
                   (lemma "measurable_complement" ("a" "X!1"))
                   (expand "measurable_set?")
                   (propax))))))
              ("2"
               (hide -3)
               (expand "bounded_below?")
               (inst + "0")
               (skolem + ("n!1"))
               (expand "o ")
               (lemma "integral_nonneg"
                ("f" "phi(complement(X!1)) * (F!1(n!1) - F!1(0))"))
               (split -1)
               (("1" (assert))
                ("2"
                 (hide 2)
                 (skosimp)
                 (expand "*")
                 (expand "-")
                 (inst - "x!1")
                 (expand "subset?")
                 (inst - "x!1")
                 (expand "complement")
                 (expand "phi")
                 (expand "member")
                 (case-replace "X!1(x!1)")
                 (("1" (assert))
                  ("2" (assert) (inst - "0" "n!1") (assert))))))))
            ("3"
             (hide 2)
             (expand "pointwise_increasing?")
             (skosimp)
             (inst - "x!1")
             (expand "subset?")
             (inst - "x!1")
             (expand "member")
             (expand "increasing?")
             (skolem + ("i!1" "j!1"))
             (flatten)
             (expand "*")
             (expand "-")
             (expand "complement")
             (expand "phi")
             (expand "member")
             (case-replace "X!1(x!1)")
             (("1" (assert))
              ("2" (assert) (inst - "i!1" "j!1") (assert))))))
          ("2"
           (hide 2)
           (skosimp)
           (split)
           (("1"
             (skolem + "x!1")
             (expand "*")
             (expand "complement")
             (expand "phi")
             (expand "member")
             (expand "subset?")
             (inst - "x!1")
             (expand "member")
             (inst - "x!1")
             (case-replace "X!1(x!1)")
             (("1" (assert))
              ("2" (assert) (expand "-") (inst - "0" "n!1") (assert))))
            ("2"
             (lemma "integrable_diff" ("f1" "F!1(n!1)" "f2" "F!1(0)"))
             (lemma "integral_ae_eq"
              ("f"
               "(-[T])(F!1(n!1), F!1(0))"
               "h"
               "*[T](phi[T, S](complement[T](X!1)), ((-[T])(F!1(n!1), F!1(0))))"))
             (("1"
               (split -1)
               (("1"
                 (flatten)
                 (rewrite "nn_integrable_is_nn_integrable")
                 (hide-all-but (-5 -7 1))
                 (skosimp)
                 (expand "*")
                 (expand "complement")
                 (expand "phi")
                 (expand "member")
                 (expand "-")
                 (inst - "x!1")
                 (expand "subset?")
                 (inst - "x!1")
                 (expand "member")
                 (case-replace "X!1(x!1)")
                 (("1" (assert))
                  ("2" (assert) (inst - "0" "n!1") (assert))))
                ("2"
                 (hide 2)
                 (expand "ae_eq?")
                 (expand "restrict")
                 (expand "pointwise_ae?")
                 (expand "ae?")
                 (expand "fullset")
                 (expand "ae_in?")
                 (inst + "X!1")
                 (("1"
                   (skosimp)
                   (expand "complement")
                   (expand "phi")
                   (expand "member")
                   (expand "*")
                   (expand "-")
                   (assert))
                  ("2" (rewrite "null_is_negligible"))))))
              ("2"
               (hide 2)
               (lemma "integrable_is_measurable"
                ("x" "(-[T])(F!1(n!1), F!1(0))"))
               (rewrite "prod_measurable")
               (lemma "phi_is_simple" ("X" "complement[T](X!1)"))
               (("1" (rewrite "simple_is_measurable"))
                ("2"
                 (expand "null_set?")
                 (flatten)
                 (lemma "measurable_complement" ("a" "X!1"))
                 (expand "measurable_set?")
                 (propax))))))))))
        ("2"
         (hide-all-but 1)
         (skosimp)
         (name "H" "LAMBDA n: LAMBDA (m: nat): {x | F!2(n)(x) >= m+1}")
         (name "HH" "LAMBDA (m: nat): IUnion(LAMBDA n: H(n)(m))")
         (hide -1 -2)
         (case "forall (n,m:nat): measurable_set?(H(n)(m))")
         (("1"
           (case "forall (m:nat): measurable_set?(HH(m))")
           (("1"
             (lemma "measurable_IIntersection" ("SS" "HH"))
             (("1"
               (case "FORALL x:
                             (NOT IIntersection[nat, T](HH)(x)) IFF
                              (EXISTS (k: posnat): FORALL n: F!2(n)(x) < k)")
               (("1"
                 (case "forall (n,m:nat): mu_fin?(H(n)(m))")
                 (("1"
                   (case "forall (n,m:nat,x:T): ((m+1)*phi(H(n)(m)))(x) <= F!2(n)(x)")
                   (("1"
                     (case "forall (n,m:nat): (m+1)*mu(H(n)(m)) <= nn_integral(F!2(n))")
                     (("1"
                       (expand "bounded?")
                       (flatten)
                       (hide -9)
                       (expand "bounded_above?")
                       (skolem - "M")
                       (expand "o ")
                       (case "forall (n,m:nat): subset?(H(n)(m),HH(m))")
                       (("1"
                         (case "forall (n,m:nat): mu(H(n)(m)) <= M/(1+m)")
                         (("1"
                           (name-replace "DIVERGENT"
                            "IIntersection[nat, T](HH)")
                           (case "null_set?(DIVERGENT)")
                           (("1"
                             (case "pointwise_bounded?(lambda n: phi(complement(DIVERGENT))*F!2(n))")
                             (("1"
                               (name "SUP"
                                     "lambda x: sup(Im(lambda n: (phi(complement(DIVERGENT)) * F!2(n))(x)))")
                               (("1"
                                 (case
                                  "forall x: least_upper_bound(<=)(SUP(x),Im(LAMBDA n: (phi(complement(DIVERGENT)) * F!2(n))(x)))")
                                 (("1"
                                   (lemma
                                    "monotone_convergence_scaf"
                                    ("F"
                                     "lambda n: phi(complement(DIVERGENT)) * F!2(n)"
                                     "f"
                                     "SUP"))
                                   (("1"
                                     (split -1)
                                     (("1"
                                       (flatten)
                                       (hide -2 -4)
                                       (lemma
                                        "nn_integrable_is_nn_integrable"
                                        ("f" "SUP"))
                                       (("1"
                                         (split -1)
                                         (("1"
                                           (inst + "SUP")
                                           (expand "ae_convergence?")
                                           (expand "fullset")
                                           (expand "ae_convergence_in?")
                                           (expand "ae_in?")
                                           (inst + "DIVERGENT")
                                           (("1"
                                             (skosimp)
                                             (inst - "x!1")
                                             (expand "*" -3)
                                             (expand "complement")
                                             (expand "phi" -3)
                                             (expand "member")
                                             (hide -4)
                                             (assert)
                                             (replace 1 -3)
                                             (hide-all-but (-3 -15 2))
                                             (expand
                                              "pointwise_increasing?")
                                             (inst - "x!1")
                                             (rewrite
                                              "metric_convergence_def")
                                             (expand
                                              "metric_converges_to")
                                             (skosimp)
                                             (expand "member")
                                             (expand "ball")
                                             (name-replace
                                              "LIMIT"
                                              "SUP(x!1)")
                                             (expand "Im")
                                             (expand "least_upper_bound")
                                             (flatten)
                                             (inst - "LIMIT-r!1")
                                             (assert)
                                             (expand "upper_bound")
                                             (skosimp)
                                             (typepred "z!1")
                                             (skolem - "n!1")
                                             (case "z!1>LIMIT-r!1")
                                             (("1"
                                               (hide 1)
                                               (inst + "n!1")
                                               (skosimp)
                                               (expand "increasing?")
                                               (inst - "n!1" "i!1")
                                               (assert)
                                               (inst - "F!2(i!1)(x!1)")
                                               (("1"
                                                 (expand "abs")
                                                 (assert))
                                                ("2"
                                                 (inst + "i!1")
                                                 (assert))))
                                              ("2" (assert))))
                                            ("2"
                                             (rewrite
                                              "null_is_negligible"))))
                                          ("2"
                                           (hide-all-but (-15 1 -2))
                                           (skosimp)
                                           (expand
                                            "pointwise_increasing?")
                                           (inst - "x!1")
                                           (inst - "x!1")
                                           (expand "least_upper_bound")
                                           (flatten)
                                           (hide -2)
                                           (expand "Im")
                                           (expand "upper_bound")
                                           (inst
                                            -
                                            "(phi(complement(DIVERGENT)) * F!2(0))(x!1)")
                                           (("1"
                                             (expand "*")
                                             (expand "phi")
                                             (hide -2)
                                             (grind))
                                            ("2" (inst + "0"))))))
                                        ("2" (propax))))
                                      ("2"
                                       (hide 2)
                                       (expand
                                        "pointwise_converges_upto?")
                                       (case-replace
                                        "pointwise_increasing?(LAMBDA n: phi(complement(DIVERGENT)) * F!2(n))")
                                       (("1"
                                         (expand
                                          "pointwise_convergence?")
                                         (skosimp)
                                         (hide -16)
                                         (expand "pointwise_increasing?")
                                         (inst - "x!1")
                                         (inst - "x!1")
                                         (name-replace
                                          "G"
                                          "LAMBDA (n_1: nat):
                                                               (phi(complement(DIVERGENT)) * F!2(n_1))(x!1)")
                                         (name-replace
                                          "LIMIT"
                                          "SUP(x!1)")
                                         (hide-all-but (-1 -2 1))
                                         (rewrite
                                          "metric_convergence_def")
                                         (expand "metric_converges_to")
                                         (skosimp)
                                         (expand "ball")
                                         (expand "member")
                                         (expand "least_upper_bound")
                                         (flatten)
                                         (inst - "LIMIT-r!1")
                                         (assert)
                                         (expand "upper_bound")
                                         (skosimp)
                                         (typepred "z!1")
                                         (case "z!1>LIMIT-r!1")
                                         (("1"
                                           (hide 2)
                                           (expand "Im")
                                           (skolem - "n!1")
                                           (inst + "n!1")
                                           (skosimp)
                                           (inst - "G(i!1)")
                                           (("1"
                                             (expand "abs")
                                             (expand "increasing?")
                                             (inst - "n!1" "i!1")
                                             (assert))
                                            ("2"
                                             (expand "Im")
                                             (inst + "i!1"))))
                                          ("2" (assert))))
                                        ("2"
                                         (hide-all-but (-15 1))
                                         (expand "pointwise_increasing?")
                                         (skosimp)
                                         (inst - "x!1")
                                         (expand "increasing?")
                                         (skolem + ("i!1" "j!1"))
                                         (inst - "i!1" "j!1")
                                         (flatten)
                                         (assert)
                                         (expand "*")
                                         (expand "phi")
                                         (grind))))
                                      ("3"
                                       (hide-all-but (1 -14 -15 -4 -11))
                                       (expand "bounded?")
                                       (split)
                                       (("1"
                                         (expand "bounded_above?")
                                         (inst + "M")
                                         (skolem + ("n!1"))
                                         (expand "o ")
                                         (inst - "n!1")
                                         (lemma
                                          "integral_ae_eq"
                                          ("f"
                                           "F!2(n!1)"
                                           "h"
                                           "phi(complement(DIVERGENT)) * F!2(n!1)"))
                                         (("1"
                                           (split -1)
                                           (("1"
                                             (flatten)
                                             (replace -2 * rl)
                                             (propax))
                                            ("2"
                                             (hide 2 -4 -3)
                                             (expand "ae_eq?")
                                             (expand "restrict")
                                             (expand "pointwise_ae?")
                                             (expand "ae?")
                                             (expand "fullset")
                                             (expand "ae_in?")
                                             (inst + "DIVERGENT")
                                             (("1"
                                               (skosimp)
                                               (expand "*")
                                               (expand "complement")
                                               (expand "phi")
                                               (expand "member")
                                               (assert))
                                              ("2"
                                               (rewrite
                                                "null_is_negligible"))))))
                                          ("2"
                                           (hide 2 -3 -4)
                                           (lemma
                                            "indefinite_integrable"
                                            ("E"
                                             "complement[T](DIVERGENT)"
                                             "f"
                                             "F!2(n!1)"))
                                           (("1"
                                             (rewrite
                                              "integrable_is_measurable"))
                                            ("2"
                                             (rewrite
                                              "measurable_complement"))))))
                                        ("2"
                                         (expand "bounded_below?")
                                         (inst + "0")
                                         (skolem + ("n!1"))
                                         (expand "o ")
                                         (hide -3 -4)
                                         (lemma
                                          "measurable_complement"
                                          ("a" "DIVERGENT"))
                                         (("1"
                                           (lemma
                                            "indefinite_integrable"
                                            ("E"
                                             "complement[T](DIVERGENT)"
                                             "f"
                                             "F!2(n!1)"))
                                           (("1"
                                             (lemma
                                              "integral_ae_eq"
                                              ("f"
                                               "F!2(n!1)"
                                               "h"
                                               "phi(complement[T](DIVERGENT)) * F!2(n!1)"))
                                             (("1"
                                               (split -1)
                                               (("1"
                                                 (flatten)
                                                 (replace -2 * rl)
                                                 (lemma
                                                  "integral_nonneg"
                                                  ("f" "F!2(n!1)"))
                                                 (split -1)
                                                 (("1" (assert))
                                                  ("2"
                                                   (skosimp)
                                                   (assert))))
                                                ("2"
                                                 (hide 2 -1)
                                                 (expand "ae_eq?")
                                                 (expand "restrict")
                                                 (expand "pointwise_ae?")
                                                 (expand "ae?")
                                                 (expand "fullset")
                                                 (expand "ae_in?")
                                                 (inst + "DIVERGENT")
                                                 (("1"
                                                   (skosimp)
                                                   (expand "*")
                                                   (expand "complement")
                                                   (expand "phi")
                                                   (expand "member")
                                                   (assert))
                                                  ("2"
                                                   (rewrite
                                                    "null_is_negligible"))))))
                                              ("2"
                                               (rewrite
                                                "integrable_is_measurable"))))
                                            ("2" (propax))))
                                          ("2" (propax))))))))
                                    ("2"
                                     (skosimp)
                                     (rewrite "indefinite_integrable" 1)
                                     (rewrite "measurable_complement"))))
                                  ("2"
                                   (hide 2)
                                   (skosimp)
                                   (replace -1 1 rl)
                                   (assert))))
                                ("2"
                                 (hide-all-but (1 -1 -13 -8))
                                 (skosimp)
                                 (expand "pointwise_bounded?")
                                 (expand "pointwise?")
                                 (inst - "x!1")
                                 (expand "bounded_seq?")
                                 (expand "fullset")
                                 (expand "image")
                                 (expand "Im")
                                 (expand "bounded?")
                                 (skosimp)
                                 (expand "subset?")
                                 (expand "member")
                                 (expand "above_bounded")
                                 (inst + "x!2+r!1")
                                 (expand "upper_bound")
                                 (skosimp)
                                 (typepred "z!1")
                                 (skosimp)
                                 (inst - "z!1")
                                 (split -2)
                                 (("1"
                                   (hide-all-but (-1 1))
                                   (expand "ball")
                                   (grind))
                                  ("2" (inst + "x!3"))))))
                              ("2"
                               (hide-all-but (-7 -12 1))
                               (expand "pointwise_bounded?")
                               (expand "pointwise_increasing?")
                               (expand "pointwise?")
                               (skosimp)
                               (inst - "x!1")
                               (inst - "x!1")
                               (expand "*")
                               (expand "complement")
                               (expand "phi")
                               (expand "member")
                               (case-replace "DIVERGENT(x!1)")
                               (("1"
                                 (expand "bounded_seq?")
                                 (expand "fullset")
                                 (expand "image")
                                 (expand "bounded?")
                                 (inst + "0" "1")
                                 (expand "subset?")
                                 (expand "member")
                                 (expand "ball")
                                 (expand "abs")
                                 (hide-all-but 1)
                                 (skosimp)
                                 (skosimp)
                                 (grind))
                                ("2"
                                 (assert)
                                 (skosimp)
                                 (expand "bounded_seq?")
                                 (expand "fullset")
                                 (expand "image")
                                 (expand "bounded?")
                                 (inst + "0" "k!1")
                                 (expand "subset?")
                                 (expand "member")
                                 (skosimp*)
                                 (replace -1)
                                 (hide -1)
                                 (expand "ball")
                                 (inst - "x!3")
                                 (hide -2 1)
                                 (grind))))))
                            ("2"
                             (hide 2)
                             (expand "null_set?")
                             (assert)
                             (case "FORALL (n, m,k: nat): n<=k=>subset?(H(n)(m), H(k)(m))")
                             (("1"
                               (hide -4 -5)
                               (lemma "m_decreasing_convergence"
                                ("E" "HH"))
                               (case-replace "decreasing?(HH)")
                               (("1"
                                 (case-replace "mu_fin?[T, S, m](HH(0))")
                                 (("1"
                                   (expand "x_converges?" -3)
                                   (expand "o" -3)
                                   (case-replace
                                    "(FORALL (i:nat): m(HH(i))`1)")
                                   (("1"
                                     (hide -9)
                                     (expand "DIVERGENT")
                                     (case-replace
                                      "m(IIntersection(HH))`1")
                                     (("1"
                                       (expand "mu_fin?")
                                       (assert)
                                       (name-replace
                                        "mH"
                                        "lambda n: m(HH(n))`2")
                                       (("1"
                                         (lemma
                                          "bounded_below_is_convergent"
                                          ("u" "mH"))
                                         (split -1)
                                         (("1"
                                           (case-replace
                                            "convergent(mH)")
                                           (("1"
                                             (case
                                              "forall n: mH(n) <= M / (1 + n)")
                                             (("1"
                                               (expand "mu" 1)
                                               (replace -8)
                                               (hide -4 -8 -13)
                                               (rewrite "limit_def" 1)
                                               (expand
                                                "convergent_downto?")
                                               (expand
                                                "converges_downto?")
                                               (skosimp)
                                               (hide-all-but (-1 -4 1))
                                               (expand "convergence")
                                               (skosimp)
                                               (inst-cp - "0")
                                               (expand "mH" -2)
                                               (case "0<=M")
                                               (("1"
                                                 (hide -3)
                                                 (expand "<=" -1)
                                                 (split -1)
                                                 (("1"
                                                   (lemma
                                                    "posreal_div_posreal_is_posreal"
                                                    ("px"
                                                     "epsilon!1"
                                                     "py"
                                                     "M"))
                                                   (("1"
                                                     (lemma
                                                      "archimedean"
                                                      ("px"
                                                       "epsilon!1 / M"))
                                                     (("1"
                                                       (skosimp)
                                                       (inst - "n!1-1")
                                                       (inst + "n!1-1")
                                                       (assert)
                                                       (skosimp)
                                                       (expand
                                                        "decreasing?")
                                                       (inst
                                                        -
                                                        "n!1-1"
                                                        "i!1")
                                                       (assert)
                                                       (expand "abs")
                                                       (assert)
                                                       (rewrite
                                                        "div_mult_pos_lt2"
                                                        -1))
                                                      ("2" (assert))))
                                                    ("2" (assert))))
                                                  ("2"
                                                   (replace -1 * rl)
                                                   (inst + "0")
                                                   (skosimp)
                                                   (expand "mH")
                                                   (expand "abs")
                                                   (assert)
                                                   (inst - "i!1")
                                                   (typepred
                                                    "m(HH(i!1))`2")
                                                   (assert))))
                                                ("2" (assert))))
                                              ("2"
                                               (hide 2 -3 -7 -12)
                                               (skosimp)
                                               (expand
                                                "convergent_downto?")
                                               (skosimp)
                                               (rewrite
                                                "converges_downto_def"
                                                -2)
                                               (flatten)
                                               (inst -9 "_" "n!1")
                                               (name-replace
                                                "RHS"
                                                "M / (1 + n!1)")
                                               (hide -15 -14)
                                               (lemma
                                                "m_increasing_convergence"
                                                ("E"
                                                 "lambda n: H(n)(n!1)"))
                                               (("1"
                                                 (case-replace
                                                  "increasing?(LAMBDA n: H(n)(n!1))")
                                                 (("1"
                                                   (expand "o ")
                                                   (expand
                                                    "x_converges?")
                                                   (inst -13 "_" "n!1")
                                                   (replace -13)
                                                   (case-replace
                                                    "convergent(LAMBDA i: m(H(i)(n!1))`2)")
                                                   (("1"
                                                     (flatten)
                                                     (expand "mH")
                                                     (expand "HH")
                                                     (replace -4)
                                                     (name-replace
                                                      "UU"
                                                      "LAMBDA (i:nat): m(H(i)(n!1))`2")
                                                     (("1"
                                                       (case
                                                        "increasing?(UU)")
                                                       (("1"
                                                         (case
                                                          "forall n: UU(n)<=RHS")
                                                         (("1"
                                                           (hide-all-but
                                                            (-1 -2 -3 1))
                                                           (lemma
                                                            "increasing_bounded_convergence"
                                                            ("v1" "UU"))
                                                           (("1"
                                                             (split)
                                                             (("1"
                                                               (rewrite
                                                                "limit_def"
                                                                -1
                                                                :dir
                                                                rl)
                                                               (replace
                                                                -1)
                                                               (hide
                                                                -1
                                                                -4)
                                                               (rewrite
                                                                "supfun_is_sup2"))
                                                              ("2"
                                                               (propax))))
                                                            ("2"
                                                             (hide 2 -3)
                                                             (expand
                                                              "bounded_above?")
                                                             (inst
                                                              +
                                                              "RHS"))))
                                                          ("2"
                                                           (skosimp)
                                                           (expand "UU")
                                                           (inst
                                                            -14
                                                            "n!2")
                                                           (expand "mu")
                                                           (propax))))
                                                        ("2"
                                                         (hide 2 -1)
                                                         (expand
                                                          "increasing?")
                                                         (skosimp)
                                                         (expand "UU")
                                                         (inst
                                                          -
                                                          "x!2"
                                                          "y!1")
                                                         (assert)
                                                         (inst-cp
                                                          -17
                                                          "x!2"
                                                          "n!1")
                                                         (inst
                                                          -17
                                                          "y!1"
                                                          "n!1")
                                                         (inst -15 "y!1")
                                                         (lemma
                                                          "m_monotone"
                                                          ("a"
                                                           "H(x!2)(n!1)"
                                                           "b"
                                                           "H(y!1)(n!1)"))
                                                         (("1"
                                                           (assert)
                                                           (expand
                                                            "x_le")
                                                           (propax))
                                                          ("2" (propax))
                                                          ("3"
                                                           (propax))))))
                                                      ("2"
                                                       (skosimp)
                                                       (inst
                                                        -17
                                                        "i!1"
                                                        "n!1")
                                                       (expand
                                                        "measurable_set?")
                                                       (propax))))
                                                    ("2"
                                                     (lemma
                                                      "bounded_above_is_convergent"
                                                      ("u"
                                                       "LAMBDA n: m(H(n)(n!1))`2"))
                                                     (("1"
                                                       (split -1)
                                                       (("1"
                                                         (hide-all-but
                                                          (-1 1))
                                                         (expand
                                                          "convergent_upto?")
                                                         (expand
                                                          "converges_upto?")
                                                         (skosimp)
                                                         (rewrite
                                                          "metric_convergence_def")
                                                         (hide -2)
                                                         (expand
                                                          "metric_converges_to")
                                                         (expand "ball")
                                                         (assert)
                                                         (expand
                                                          "convergent?")
                                                         (expand
                                                          "convergence")
                                                         (inst + "x!2")
                                                         (skosimp)
                                                         (inst
                                                          -
                                                          "epsilon!1")
                                                         (skosimp)
                                                         (inst + "n!2")
                                                         (skosimp)
                                                         (inst - "i!1")
                                                         (grind))
                                                        ("2"
                                                         (hide-all-but
                                                          (1 -11))
                                                         (expand
                                                          "bounded_above?")
                                                         (inst + "RHS")
                                                         (skosimp)
                                                         (inst - "x!2")
                                                         (expand "mu")
                                                         (propax))
                                                        ("3"
                                                         (hide-all-but
                                                          (-11
                                                           -13
                                                           -15
                                                           1
                                                           -1))
                                                         (expand
                                                          "increasing?")
                                                         (skolem
                                                          +
                                                          ("i!1" "j!1"))
                                                         (flatten)
                                                         (inst
                                                          -
                                                          "i!1"
                                                          "j!1")
                                                         (assert)
                                                         (inst-cp
                                                          -
                                                          "i!1"
                                                          "n!1")
                                                         (inst
                                                          -
                                                          "j!1"
                                                          "n!1")
                                                         (lemma
                                                          "m_monotone"
                                                          ("a"
                                                           "H(i!1)(n!1)"
                                                           "b"
                                                           "H(j!1)(n!1)"))
                                                         (("1"
                                                           (assert)
                                                           (expand
                                                            "x_le")
                                                           (inst
                                                            -4
                                                            "j!1"))
                                                          ("2" (propax))
                                                          ("3"
                                                           (propax))))))
                                                      ("2"
                                                       (skosimp)
                                                       (inst
                                                        -15
                                                        "n!2"
                                                        "n!1")
                                                       (expand
                                                        "measurable_set?")
                                                       (propax))))
                                                    ("3"
                                                     (skosimp)
                                                     (inst
                                                      -15
                                                      "i!1"
                                                      "n!1")
                                                     (expand
                                                      "measurable_set?")
                                                     (propax))))
                                                  ("2"
                                                   (hide-all-but (-9 1))
                                                   (expand "increasing?")
                                                   (skosimp)
                                                   (inst
                                                    -
                                                    "x!2"
                                                    "n!1"
                                                    "y!1")
                                                   (assert))))
                                                ("2"
                                                 (skosimp)
                                                 (inst
                                                  -13
                                                  "n!2"
                                                  "n!1"))))))
                                            ("2"
                                             (hide-all-but (-1 1))
                                             (expand
                                              "convergent_downto?")
                                             (skosimp)
                                             (expand "converges_downto?")
                                             (flatten)
                                             (rewrite
                                              "metric_convergence_def")
                                             (expand
                                              "metric_converges_to")
                                             (assert)
                                             (expand "ball")
                                             (hide -2)
                                             (expand "convergent?")
                                             (expand "convergence")
                                             (inst + "x!1")
                                             (skosimp)
                                             (inst - "epsilon!1")
                                             (skosimp)
                                             (inst + "n!1")
                                             (skosimp)
                                             (inst - "i!1")
                                             (grind))))
                                          ("2"
                                           (expand "bounded_below?")
                                           (inst + "0")
                                           (skosimp)
                                           (expand "mH")
                                           (assert))
                                          ("3"
                                           (hide -5 2)
                                           (expand "decreasing?")
                                           (skolem + ("i!1" "j!1"))
                                           (inst - "i!1" "j!1")
                                           (assert)
                                           (flatten)
                                           (assert)
                                           (hide-all-but (-3 -5 -11 1))
                                           (inst-cp - "i!1")
                                           (inst - "j!1")
                                           (inst-cp - "i!1")
                                           (inst - "j!1")
                                           (lemma
                                            "m_monotone"
                                            ("a"
                                             "HH(j!1)"
                                             "b"
                                             "HH(i!1)"))
                                           (("1"
                                             (assert)
                                             (expand "x_le")
                                             (expand "mH")
                                             (propax))
                                            ("2" (propax))
                                            ("3" (propax))))))
                                        ("2"
                                         (skosimp)
                                         (inst -11 "n!1")
                                         (expand "measurable_set?")
                                         (propax))))
                                      ("2"
                                       (hide 2 -4)
                                       (expand "mu_fin?")
                                       (lemma
                                        "m_monotone"
                                        ("a"
                                         "IIntersection(HH)"
                                         "b"
                                         "HH(0)"))
                                       (("1"
                                         (split -1)
                                         (("1" (expand "x_le") (assert))
                                          ("2"
                                           (hide-all-but 1)
                                           (expand "subset?")
                                           (expand "IIntersection")
                                           (expand "member")
                                           (skosimp)
                                           (inst - "0"))))
                                        ("2" (inst -9 "0"))
                                        ("3" (propax))))
                                      ("3"
                                       (expand "measurable_set?")
                                       (propax))))
                                    ("2"
                                     (skosimp)
                                     (expand "decreasing?")
                                     (inst - "0" "i!1")
                                     (assert)
                                     (lemma
                                      "m_monotone"
                                      ("a" "HH(i!1)" "b" "HH(0)"))
                                     (("1"
                                       (assert)
                                       (hide-all-but (-1 -2 1))
                                       (expand "mu_fin?")
                                       (expand "x_le")
                                       (propax))
                                      ("2" (inst -10 "i!1"))))
                                    ("3"
                                     (skosimp)
                                     (inst -10 "i!1")
                                     (expand "measurable_set?")
                                     (propax))))
                                  ("2"
                                   (hide 2)
                                   (hide -1 -2 -5)
                                   (expand "HH")
                                   (inst - "_" "0")
                                   (inst - "_" "0")
                                   (inst - "_" "0")
                                   (assert)
                                   (lemma
                                    "m_increasing_convergence"
                                    ("E" "LAMBDA n: H(n)(0)"))
                                   (("1"
                                     (case-replace
                                      "increasing?(LAMBDA n: H(n)(0))")
                                     (("1"
                                       (expand "o" -2)
                                       (expand "x_converges?")
                                       (expand "mu_fin?" (-5 1))
                                       (replace 1 -2)
                                       (replace -5)
                                       (prop)
                                       (hide 2)
                                       (name-replace
                                        "mH"
                                        "LAMBDA n: m(H(n)(0))`2")
                                       (("1"
                                         (case "increasing?(mH)")
                                         (("1"
                                           (case "forall n: mH(n)<=M")
                                           (("1"
                                             (hide-all-but (-1 -2 1))
                                             (lemma
                                              "bounded_above_is_convergent"
                                              ("u" "mH"))
                                             (assert)
                                             (split -1)
                                             (("1"
                                               (expand
                                                "convergent_upto?")
                                               (skosimp)
                                               (expand "converges_upto?")
                                               (rewrite
                                                "metric_convergence_def")
                                               (expand
                                                "metric_converges_to")
                                               (expand "ball")
                                               (expand "member")
                                               (assert)
                                               (hide -2 -3 -4)
                                               (expand "convergent?")
                                               (expand "convergence")
                                               (inst + "x!1")
                                               (skosimp)
                                               (inst - "epsilon!1")
                                               (skosimp)
                                               (inst + " n!1")
                                               (skosimp)
                                               (inst - "i!1")
                                               (grind))
                                              ("2"
                                               (hide 2)
                                               (expand "bounded_above?")
                                               (inst + "M"))))
                                            ("2"
                                             (skosimp)
                                             (inst -4 "n!1")
                                             (expand "mu")
                                             (expand "mH")
                                             (assert))))
                                          ("2"
                                           (hide 2 -10 -9 -5 -2 -3 -6 -7)
                                           (expand "increasing?")
                                           (skolem + ("i!1" "j!1"))
                                           (flatten)
                                           (inst - "i!1" "j!1")
                                           (assert)
                                           (expand "mH")
                                           (inst-cp - "i!1")
                                           (inst - "j!1")
                                           (inst-cp - "i!1")
                                           (inst - "j!1")
                                           (lemma
                                            "m_monotone"
                                            ("a"
                                             "H(i!1)(0)"
                                             "b"
                                             "H(j!1)(0)"))
                                           (("1"
                                             (assert)
                                             (expand "x_le")
                                             (propax))
                                            ("2" (propax))
                                            ("3" (propax))))))
                                        ("2"
                                         (skosimp)
                                         (inst -8 "n!1")
                                         (expand "measurable_set?")
                                         (propax))))
                                      ("2"
                                       (hide-all-but (-2 1))
                                       (expand "increasing?")
                                       (skolem + ("i!1" "j!1"))
                                       (flatten)
                                       (inst - "i!1" "0" "j!1")
                                       (assert))))
                                    ("2" (propax))))
                                  ("3" (inst -9 "0"))))
                                ("2"
                                 (hide-all-but (1 -11))
                                 (expand "decreasing?")
                                 (skolem + ("i!1" "j!1"))
                                 (flatten)
                                 (expand "subset?")
                                 (skosimp)
                                 (expand "pointwise_increasing?")
                                 (inst - "x!1")
                                 (assert)
                                 (expand "HH")
                                 (expand "IUnion")
                                 (skosimp)
                                 (expand "H")
                                 (expand "increasing?")
                                 (inst + "i!2")
                                 (assert))))
                              ("2"
                               (hide-all-but (-11 1))
                               (skosimp)
                               (expand "subset?")
                               (expand "member")
                               (expand "H")
                               (skosimp)
                               (expand "pointwise_increasing?")
                               (inst - "x!1")
                               (expand "increasing?")
                               (inst - "n!1" "k!1")
                               (assert))))))
                          ("2"
                           (hide-all-but (-2 -9 1))
                           (skosimp)
                           (inst - "n!1" "m!1")
                           (inst - "n!1")
                           (lemma "div_mult_pos_le2"
                            ("py"
                             "m!1 + 1"
                             "x"
                             "mu(H(n!1)(m!1))"
                             "z"
                             "M"))
                           (assert)
                           (assert)
                           (rewrite "integral_nn")
                           (assert))))
                        ("2"
                         (hide-all-but 1)
                         (expand "HH")
                         (expand "IUnion")
                         (expand "subset?")
                         (expand "member")
                         (skosimp*)
                         (inst + "n!1"))))
                      ("2"
                       (skosimp)
                       (inst - "n!1" "m!1" "_")
                       (hide 2)
                       (lemma "nn_integrable_le"
                        ("g"
                         "(m!1 + 1) * phi(H(n!1)(m!1))"
                         "f"
                         "F!2(n!1)"))
                       (("1"
                         (split -1)
                         (("1"
                           (flatten)
                           (lemma "isf_phi" ("E" "H(n!1)(m!1)"))
                           (("1"
                             (lemma "isf_scal"
                              ("c" "m!1+1" "i" "phi[T, S](H(n!1)(m!1))"))
                             (("1"
                               (name-replace "RHS"
                                "nn_integral(F!2(n!1))")
                               (rewrite "integral_nn" -4 :dir rl)
                               (rewrite "integral_scal" -4)
                               (("1"
                                 (rewrite "integral_phi" -4)
                                 (assert))
                                ("2"
                                 (hide-all-but (-2 1))
                                 (lemma "nn_isf_is_nn_integrable")
                                 (inst - "phi[T, S](H(n!1)(m!1))")
                                 (("1"
                                   (flatten)
                                   (lemma
                                    "nn_integrable_is_nn_integrable")
                                   (lemma "nn_integrable_is_integrable")
                                   (inst - "phi[T, S](H(n!1)(m!1))"))
                                  ("2"
                                   (expand "nn_isf?")
                                   (skosimp)
                                   (hide-all-but 1)
                                   (expand "phi")
                                   (expand "member")
                                   (case-replace "H(n!1)(m!1)(x!1)")
                                   (("1" (assert)) ("2" (assert))))))))
                              ("2" (propax))))
                            ("2" (inst -8 "n!1" "m!1"))))
                          ("2"
                           (skosimp)
                           (inst - "x!1")
                           (assert)
                           (hide-all-but 1)
                           (expand "*")
                           (expand "phi")
                           (expand "member")
                           (case-replace "H(n!1)(m!1)(x!1)")
                           (("1" (assert)) ("2" (assert))))))
                        ("2"
                         (rewrite "scal_measurable")
                         (lemma "phi_is_simple" ("X" "H(n!1)(m!1)"))
                         (rewrite "simple_is_measurable"))))
                      ("3"
                       (skosimp)
                       (inst -2 "n!1" "m!1")
                       (inst -6 "n!1" "m!1")
                       (expand "measurable_set?")
                       (assert))))
                    ("2"
                     (hide 2 -2 -1)
                     (skosimp)
                     (expand "phi")
                     (expand "H")
                     (expand "member")
                     (expand "*")
                     (case-replace "F!2(n!1)(x!1) >= 1 + m!1")
                     (("1" (assert)) ("2" (assert))))))
                  ("2"
                   (hide-all-but (1 -4))
                   (skosimp)
                   (expand "H")
                   (inst - "n!1" "m!1")
                   (lemma "integrable_nz_finite"
                    ("f" "F!2(n!1)" "epsilon" "m!1+1/2"))
                   (flatten)
                   (case-replace
                    "{x: T | abs(F!2(n!1)(x)) >= m!1 + 1 / 2}={x | F!2(n!1)(x) >= m!1 + 1 / 2}")
                   (("1"
                     (hide -1)
                     (lemma "m_monotone"
                      ("a"
                       "{x | F!2(n!1)(x) >= 1 + m!1}"
                       "b"
                       "{x | F!2(n!1)(x) >= m!1 + 1 / 2}"))
                     (("1"
                       (split -1)
                       (("1" (expand "x_le") (expand "mu_fin?") (assert))
                        ("2"
                         (hide-all-but 1)
                         (expand "subset?")
                         (expand "member")
                         (skosimp)
                         (assert))))
                      ("2" (assert)) ("3" (propax))))
                    ("2"
                     (apply-extensionality :hide? t)
                     (expand "abs")
                     (propax))))
                  ("3" (propax))))
                ("2"
                 (hide-all-but 1)
                 (skosimp)
                 (split)
                 (("1"
                   (flatten)
                   (expand "IIntersection")
                   (skosimp)
                   (expand "HH")
                   (expand "IUnion")
                   (expand "H")
                   (inst 2 "1+i!1")
                   (skosimp)
                   (inst + "n!1")
                   (assert))
                  ("2"
                   (skosimp*)
                   (expand "IIntersection")
                   (expand "HH")
                   (expand "IUnion")
                   (expand "H")
                   (typepred "k!1")
                   (inst -3 "k!1-1")
                   (skosimp)
                   (inst - "i!1")
                   (assert))))))
              ("2" (propax))))
            ("2"
             (hide-all-but (-1 1))
             (skosimp)
             (expand "HH")
             (rewrite "measurable_IUnion")
             (skosimp)
             (inst - "n!1" "m!1"))))
          ("2"
           (hide-all-but 1)
           (skosimp)
           (expand "measurable_set?")
           (expand "H")
           (typepred "F!2(n!1)")
           (lemma "nn_integrable_is_measurable")
           (inst - "F!2(n!1)")
           (rewrite "measurable_ge")
           (inst - "1+m!1"))))))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: integral_convergence
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (case "FORALL (F: sequence[integrable], f: integrable[T, S, m]):
                 (FORALL n,x: abs(F(n))(x) <= f(x)) AND pointwise_convergent?(F)  =>
                  (EXISTS f:
                     pointwise_convergence?(F, f) AND
                      convergence?(integral o F, integral(f)))")
   (("1"
     (skosimp)
     (case "exists E: forall x: not E(x) => FORALL n: abs(F!1(n))(x) <= f!1(x)")
     (("1"
       (case "EXISTS (E:negligible,f: [T -> real]):
                          FORALL (x: T): not E(x) => convergence?(LAMBDA n: F!1(n)(x), f(x))")
       (("1"
         (skosimp*)
         (typepred "union(E!1,E!2)")
         (expand "negligible_set?")
         (skosimp)
         (lemma "measurable_complement" ("a" "X!1"))
         (("1"
           (lemma "indefinite_integrable"
            ("f" "f!1" "E" "complement[T](X!1)"))
           (("1"
             (case "forall n: integrable?(phi(complement[T](X!1)) * F!1(n))")
             (("1"
               (inst -8 "lambda n: phi(complement[T](X!1)) * F!1(n)"
                "phi(complement[T](X!1)) * f!1")
               (split -8)
               (("1"
                 (skosimp)
                 (inst + "f!3")
                 (split 1)
                 (("1"
                   (hide-all-but (-1 -6 1))
                   (expand "pointwise_convergence?")
                   (expand "ae_convergence?")
                   (expand "fullset")
                   (expand "ae_convergence_in?")
                   (expand "ae_in?")
                   (inst + "X!1")
                   (("1"
                     (skosimp)
                     (inst - "x!1")
                     (expand "*")
                     (expand "complement")
                     (expand "phi")
                     (expand "member")
                     (assert))
                    ("2" (rewrite "null_is_negligible"))))
                  ("2"
                   (hide-all-but (-2 -6 1 -3 -4))
                   (case-replace
                    "integral o (LAMBDA n: phi(complement[T](X!1)) * F!1(n))=integral o F!1")
                   (apply-extensionality :hide? t)
                   (expand "o")
                   (hide -1 2)
                   (lemma "integral_ae_eq"
                    ("f"
                     "F!1(x!1)"
                     "h"
                     "phi(complement[T](X!1)) * F!1(x!1)"))
                   (("1"
                     (split -1)
                     (("1" (flatten) (assert))
                      ("2"
                       (hide 2 -1 -2)
                       (expand "ae_eq?")
                       (expand "restrict")
                       (expand "pointwise_ae?")
                       (expand "ae?")
                       (expand "fullset")
                       (expand "ae_in?")
                       (inst + "X!1")
                       (("1"
                         (skosimp)
                         (expand "*")
                         (expand "complement")
                         (expand "phi")
                         (expand "member")
                         (assert))
                        ("2" (rewrite "null_is_negligible"))))))
                    ("2" (rewrite "integrable_is_measurable"))))))
                ("2"
                 (hide-all-but (-4 -5 -7 1))
                 (skosimp)
                 (expand "*")
                 (expand "abs")
                 (inst - "x!1")
                 (expand "subset?")
                 (expand "union")
                 (expand "complement")
                 (expand "phi")
                 (expand "member")
                 (inst - "x!1")
                 (case-replace "X!1(x!1)")
                 (("1" (assert))
                  ("2"
                   (assert)
                   (flatten)
                   (assert)
                   (inst - "n!1")
                   (assert))))
                ("3"
                 (hide-all-but (-4 -5 -6 1))
                 (expand "pointwise_convergent?")
                 (inst + "phi(complement[T](X!1)) * f!2")
                 (expand "pointwise_convergence?")
                 (skosimp)
                 (inst - "x!1")
                 (expand "union")
                 (expand "subset?")
                 (expand "*")
                 (expand "complement")
                 (expand "phi")
                 (expand "member")
                 (inst - "x!1")
                 (case-replace "X!1(x!1)")
                 (("1"
                   (hide-all-but 1)
                   (rewrite "metric_convergence_def")
                   (expand "metric_converges_to")
                   (skosimp)
                   (inst + "0")
                   (skosimp)
                   (expand "ball")
                   (grind))
                  ("2" (assert) (flatten))))))
              ("2" (skosimp) (rewrite "indefinite_integrable"))))
            ("2" (propax))))
          ("2" (expand "null_set?") (flatten))))
        ("2"
         (hide-all-but (1 -4))
         (expand "ae_convergent?")
         (skosimp)
         (expand "ae_convergence?")
         (expand "fullset")
         (expand "ae_convergence_in?")
         (expand "ae_in?")
         (skosimp)
         (inst + "E!1" "f!2")
         (skosimp)
         (inst - "x!1")
         (assert))))
      ("2"
       (hide-all-but (-2 1))
       (expand "ae_le?")
       (expand "pointwise_ae?")
       (expand "ae?")
       (expand "fullset")
       (expand "ae_in?")
       (name "EN"
             "lambda n: choose({E| forall x: not E(x)=> abs(F!1(n))(x) <= f!1(x)})")
       (("1"
         (inst + "IUnion(EN)")
         (skosimp)
         (skosimp)
         (expand "IUnion")
         (inst - "n!1")
         (inst + "n!1")
         (expand "EN")
         (typepred
          "choose({E | FORALL x: NOT E(x) => abs(F!1(n!1))(x) <= f!1(x)})")
         (("1"
           (name-replace "CHOICE"
            "choose({E | FORALL x: NOT E(x) => abs(F!1(n!1))(x) <= f!1(x)})")
           (inst - "x!1")
           (assert))
          ("2"
           (hide-all-but (-2 1))
           (skosimp)
           (expand "nonempty?")
           (expand "empty?")
           (inst - "E!1")
           (expand "member")
           (propax))))
        ("2"
         (hide 2)
         (skosimp)
         (inst - "n!1")
         (skosimp)
         (expand "nonempty?")
         (expand "empty?")
         (inst - "E!1")
         (expand "member")
         (propax))))))
    ("2"
     (hide 2)
     (skosimp)
     (expand "pointwise_convergent?")
     (skosimp)
     (lemma "pointwise_measurable" ("u" "F!1" "f" "f!2"))
     (assert)
     (lemma "integral_ae_abs" ("h" "f!2" "f" "f!1"))
     (case "forall x: abs(f!2)(x) <= f!1(x)")
     (("1"
       (split -2)
       (("1"
         (flatten)
         (name-replace "FF" "f!2")
         (name-replace "GG" "f!1")
         (case "forall n: integrable?(F!1(n)-FF)")
         (("1"
           (case "forall n,x: abs(F!1(n)-FF)(x)<=2*GG(x)")
           (("1"
             (case "pointwise_convergence?(lambda n: abs(F!1(n) - FF), lambda x: 0)")
             (("1"
               (inst + "FF")
               (assert)
               (lemma "integrable_scal" ("c" "2" "f" "GG"))
               (case "pointwise_bounded_above?[T](LAMBDA n: abs[T]((-[T])(F!1(n), FF)))")
               (("1"
                 (name "H" "sup(lambda n: abs(F!1(n) - FF))")
                 (("1"
                   (case "forall n: measurable_function?(H(n))")
                   (("1"
                     (case "forall n,x: least_upper_bound(<=)
                                                  (H(n)(x),
                                                   {y: real |
                                                      EXISTS (i: ({m: nat | m >= n})):
                                                        y = abs(F!1(i) - FF)(x)})")
                     (("1"
                       (case "forall n,x: 0<=H(n)(x)&H(n)(x)<=2*GG(x)")
                       (("1"
                         (case "pointwise_decreasing?(H)")
                         (("1"
                           (case "forall n: integrable?(H(n))")
                           (("1"
                             (lemma "monotone_convergence" ("F" "-H"))
                             (("1"
                               (split -1)
                               (("1"
                                 (flatten)
                                 (hide -1 -2)
                                 (inst - "lambda (x:T): 0")
                                 (("1"
                                   (rewrite "integral_zero")
                                   (case
                                    "pointwise_bounded_above?[T](LAMBDA n: abs[T](F!1(n)))")
                                   (("1"
                                     (case
                                      "pointwise_convergence?(H, (lambda (x:T): 0))")
                                     (("1"
                                       (split -3)
                                       (("1"
                                         (expand "converges_upto?")
                                         (flatten)
                                         (case
                                          "forall n,x: FF(x)-H(n)(x)<= F!1(n)(x)& F!1(n)(x) <= FF(x)+H(n)(x)")
                                         (("1"
                                           (hide-all-but
                                            (-1 -6 -2 -8 -17 1))
                                           (rewrite
                                            "metric_convergence_def")
                                           (rewrite
                                            "metric_convergence_def")
                                           (expand "metric_converges_to")
                                           (skosimp)
                                           (inst -2 "r!1")
                                           (skosimp)
                                           (inst + "n!1")
                                           (skosimp)
                                           (inst -2 "i!1")
                                           (assert)
                                           (expand "ball")
                                           (rewrite "abs_mult")
                                           (expand "abs" -2)
                                           (expand "o")
                                           (expand "-" -2)
                                           (rewrite "integral_opp" -2)
                                           (("1"
                                             (rewrite "neg_neg")
                                             (("1"
                                               (inst - "i!1")
                                               (case
                                                "integral(H(i!1))<r!1")
                                               (("1"
                                                 (hide -3)
                                                 (lemma
                                                  "integral_nonneg"
                                                  ("f" "H(i!1)"))
                                                 (split -1)
                                                 (("1"
                                                   (lemma
                                                    "integral_ae_le"
                                                    ("f1"
                                                     "FF-H(i!1)"
                                                     "f2"
                                                     "F!1(i!1)"))
                                                   (("1"
                                                     (split -1)
                                                     (("1"
                                                       (rewrite
                                                        "integral_diff")
                                                       (lemma
                                                        "integral_ae_le"
                                                        ("f1"
                                                         "F!1(i!1)"
                                                         "f2"
                                                         "FF+H(i!1)"))
                                                       (("1"
                                                         (split -1)
                                                         (("1"
                                                           (rewrite
                                                            "integral_add")
                                                           (hide-all-but
                                                            (-1
                                                             -2
                                                             -3
                                                             -4
                                                             1))
                                                           (name-replace
                                                            "i_H"
                                                            "integral(H(i!1))")
                                                           (name-replace
                                                            "i_F"
                                                            "integral(F!1(i!1))")
                                                           (name-replace
                                                            "i_FF"
                                                            "integral(FF)")
                                                           (grind))
                                                          ("2"
                                                           (hide-all-but
                                                            (1 -4))
                                                           (expand
                                                            "ae_le?")
                                                           (expand
                                                            "pointwise_ae?")
                                                           (expand "ae?")
                                                           (expand
                                                            "fullset")
                                                           (expand
                                                            "ae_in?")
                                                           (inst
                                                            +
                                                            "emptyset[T]")
                                                           (skosimp)
                                                           (inst
                                                            -
                                                            "i!1"
                                                            "x!1")
                                                           (flatten)
                                                           (assert)
                                                           (expand "+")
                                                           (propax))))
                                                        ("2"
                                                         (rewrite
                                                          "integrable_add"))))
                                                      ("2"
                                                       (hide-all-but
                                                        (-3 1))
                                                       (expand "ae_le?")
                                                       (expand
                                                        "pointwise_ae?")
                                                       (expand "ae?")
                                                       (expand "fullset")
                                                       (expand "ae_in?")
                                                       (inst
                                                        +
                                                        "emptyset[T]")
                                                       (skosimp)
                                                       (hide 1)
                                                       (inst
                                                        -
                                                        "i!1"
                                                        "x!1")
                                                       (flatten)
                                                       (expand "-")
                                                       (assert))))
                                                    ("2"
                                                     (rewrite
                                                      "integrable_diff"))))
                                                  ("2"
                                                   (skosimp)
                                                   (inst -4 "i!1" "x!1")
                                                   (flatten)
                                                   (assert))))
                                                ("2"
                                                 (case-replace
                                                  "-integral((H(i!1))) < 0")
                                                 (("1" (assert))
                                                  ("2" (assert))))
                                                ("3" (propax))))
                                              ("2" (inst? -3))))
                                            ("2" (inst - "i!1"))))
                                          ("2"
                                           (hide-all-but
                                            (-8 -11 -3 1 -6 -7))
                                           (skosimp)
                                           (inst -4 "n!1" "x!1")
                                           (expand "least_upper_bound")
                                           (flatten)
                                           (split)
                                           (("1"
                                             (expand "upper_bound")
                                             (inst
                                              -4
                                              "abs(F!1(n!1)-FF)(x!1)")
                                             (("1"
                                               (expand "abs" -4)
                                               (expand "-")
                                               (lemma
                                                "triangle"
                                                ("x"
                                                 "F!1(n!1)(x!1) - FF(x!1)"
                                                 "y"
                                                 "FF(x!1)"))
                                               (assert))
                                              ("2" (inst + "n!1"))))
                                            ("2"
                                             (expand "upper_bound")
                                             (inst
                                              -
                                              "abs(F!1(n!1)-FF)(x!1)")
                                             (("1"
                                               (expand "abs" -4)
                                               (expand "-")
                                               (lemma
                                                "triangle"
                                                ("x"
                                                 "F!1(n!1)(x!1)"
                                                 "y"
                                                 "-FF(x!1)"))
                                               (rewrite "abs_neg")
                                               (expand "abs" -1 3)
                                               (assert))
                                              ("2" (inst + "n!1"))))))))
                                        ("2"
                                         (hide-all-but (-1 1))
                                         (expand "ae_convergence?")
                                         (expand "fullset")
                                         (expand "ae_convergence_in?")
                                         (expand "ae_in?")
                                         (inst + "emptyset[T]")
                                         (skosimp)
                                         (hide 1)
                                         (expand
                                          "pointwise_convergence?")
                                         (inst - "x!1")
                                         (expand "-")
                                         (expand "-")
                                         (rewrite
                                          "metric_convergence_def")
                                         (expand "metric_converges_to")
                                         (expand "ball")
                                         (assert)
                                         (rewrite
                                          "metric_convergence_def")
                                         (expand "metric_converges_to")
                                         (skosimp)
                                         (inst - "r!1")
                                         (skosimp)
                                         (inst + "n!1")
                                         (skosimp)
                                         (inst - "i!1")
                                         (assert)
                                         (expand "ball")
                                         (grind))))
                                      ("2"
                                       (hide 2)
                                       (hide-all-but
                                        (1 -4 -5 -6 -9 -11 1))
                                       (expand "pointwise_convergence?")
                                       (skosimp)
                                       (expand "pointwise_decreasing?")
                                       (inst - "x!1")
                                       (inst - "_" "x!1")
                                       (inst - "_" "x!1")
                                       (inst -5 "x!1")
                                       (rewrite "metric_convergence_def")
                                       (rewrite "metric_convergence_def")
                                       (lemma
                                        "converges_downto_is_glb"
                                        ("u"
                                         "LAMBDA n: H(n)(x!1)"
                                         "x"
                                         "0"))
                                       (replace -2)
                                       (expand "converges_downto?")
                                       (replace -2)
                                       (flatten)
                                       (hide -1)
                                       (split -1)
                                       (("1"
                                         (hide-all-but (-1 1))
                                         (rewrite
                                          "metric_convergence_def"))
                                        ("2"
                                         (hide-all-but (-2 1))
                                         (expand "bounded_below?")
                                         (inst + "0")
                                         (skosimp)
                                         (inst - "x!2")
                                         (flatten))
                                        ("3"
                                         (hide 2)
                                         (expand "fullset")
                                         (expand "image")
                                         (expand "greatest_lower_bound?")
                                         (split)
                                         (("1"
                                           (expand "lower_bound?")
                                           (skosimp)
                                           (typepred "s!1")
                                           (skosimp)
                                           (inst - "x!2")
                                           (flatten)
                                           (assert))
                                          ("2"
                                           (skosimp)
                                           (case "0<y!1")
                                           (("1"
                                             (expand "lower_bound?")
                                             (hide 1)
                                             (expand
                                              "metric_converges_to")
                                             (inst -7 "y!1/2")
                                             (("1"
                                               (expand "ball")
                                               (expand "member")
                                               (skosimp)
                                               (inst - "H(n!1)(x!1)")
                                               (("1"
                                                 (inst -5 "n!1")
                                                 (expand
                                                  "least_upper_bound")
                                                 (flatten)
                                                 (inst -6 "y!1/2")
                                                 (assert)
                                                 (expand "upper_bound" 1)
                                                 (skosimp)
                                                 (typepred "z!1")
                                                 (skosimp)
                                                 (typepred "i!1")
                                                 (inst -9 "i!1")
                                                 (assert)
                                                 (rewrite "abs_mult" -9)
                                                 (expand "abs" -9 1)
                                                 (expand "abs" -9 2)
                                                 (rewrite "abs_abs")
                                                 (expand "abs" -2)
                                                 (assert))
                                                ("2" (inst + "n!1"))))
                                              ("2" (assert))))
                                            ("2" (assert))))))))))
                                    ("2"
                                     (hide 2 -1 -2 -3 -4 -5 -6 -7)
                                     (expand "pointwise_bounded_above?")
                                     (hide -1)
                                     (expand "pointwise?" +)
                                     (skosimp)
                                     (expand "bounded_above?")
                                     (inst + "4*GG(x!1)+abs(FF(x!1))")
                                     (skosimp)
                                     (inst -3 "x!2" "x!1")
                                     (hide-all-but (-3 1))
                                     (expand "abs" -)
                                     (expand "abs" 1 1)
                                     (expand "-" -)
                                     (lemma
                                      "triangle"
                                      ("x"
                                       "F!1(x!2)(x!1) - FF(x!1)"
                                       "y"
                                       "FF(x!1)"))
                                     (assert))))
                                  ("2"
                                   (hide-all-but 1)
                                   (lemma "nn_integrable_zero")
                                   (rewrite
                                    "nn_integrable_is_integrable"))))
                                ("2"
                                 (hide-all-but (-2 1))
                                 (expand "ae_increasing?")
                                 (expand "pointwise_decreasing?")
                                 (inst + "emptyset[T]")
                                 (skosimp)
                                 (hide 1)
                                 (skosimp)
                                 (inst - "x!1")
                                 (expand "decreasing?")
                                 (inst - "i!1" "j!1")
                                 (expand "-")
                                 (expand "-")
                                 (assert))))
                              ("2"
                               (skosimp)
                               (inst - "x1!1")
                               (expand "-")
                               (rewrite "integrable_opp"))))
                            ("2"
                             (hide-all-but (-2 -4 -7 1))
                             (skosimp)
                             (inst - "n!1")
                             (inst - "n!1" "_")
                             (lemma "nn_integrable_le"
                              ("g" "H(n!1)" "f" "*[T](2, GG)"))
                             (("1"
                               (split -1)
                               (("1"
                                 (flatten)
                                 (rewrite "nn_integrable_is_integrable"))
                                ("2"
                                 (skosimp)
                                 (inst - "x!1")
                                 (expand "*")
                                 (propax))))
                              ("2" (propax))
                              ("3"
                               (split)
                               (("1"
                                 (skosimp)
                                 (inst - "x1!1")
                                 (expand "*")
                                 (assert)
                                 (flatten)
                                 (assert))
                                ("2"
                                 (rewrite
                                  "nn_integrable_is_nn_integrable")
                                 (skosimp)
                                 (inst - "x!1")
                                 (expand "*")
                                 (flatten)
                                 (assert))))))))
                          ("2"
                           (hide 2)
                           (expand "pointwise_decreasing?")
                           (skosimp)
                           (expand "decreasing?")
                           (skolem + ("i!1" "j!1"))
                           (flatten)
                           (inst-cp -3 "i!1" "x!1")
                           (inst -3 "j!1" "x!1")
                           (hide-all-but (-1 -3 -4 1))
                           (expand "least_upper_bound")
                           (flatten)
                           (expand "upper_bound")
                           (inst -3 "H(i!1)(x!1)")
                           (assert)
                           (skosimp)
                           (typepred "z!1")
                           (skosimp)
                           (typepred "i!2")
                           (inst -5 "abs(F!1(i!2) - FF)(x!1)")
                           (("1" (assert)) ("2" (inst + "i!2"))))))
                        ("2"
                         (hide-all-but (-1 1 -7))
                         (skosimp)
                         (inst - "n!1" "x!1")
                         (expand "least_upper_bound")
                         (flatten)
                         (split)
                         (("1"
                           (expand "upper_bound")
                           (inst - "abs(F!1(n!1) - FF)(x!1)")
                           (("1" (expand "abs" -1) (assert))
                            ("2" (inst + "n!1"))))
                          ("2"
                           (inst - "2*GG(x!1)")
                           (assert)
                           (expand "upper_bound")
                           (skosimp)
                           (typepred "z!1")
                           (skosimp)
                           (typepred "i!1")
                           (inst -4 "i!1" "x!1")
                           (assert))))))
                      ("2"
                       (hide 2)
                       (skosimp)
                       (hide -1 -2)
                       (expand "H")
                       (expand "sup")
                       (expand "image")
                       (typepred
                        "sup({y: real |
                                                       EXISTS (x: ({m:nat | m >= n!1})):
                                                         y = abs(F!1(x) - FF)(x!1)})")
                       (("1" (propax))
                        ("2"
                         (hide-all-but (-1 1))
                         (split)
                         (("1"
                           (expand "nonempty?")
                           (expand "empty?")
                           (inst - "abs[T]((-[T])(F!1(n!1), FF))(x!1)")
                           (expand "member")
                           (inst + "n!1"))
                          ("2"
                           (expand "pointwise_bounded_above?")
                           (expand "above_bounded")
                           (expand "bounded_above?")
                           (expand "pointwise?")
                           (inst - "x!1")
                           (skosimp)
                           (expand "upper_bound")
                           (inst + "ceiling(a!1)")
                           (skosimp)
                           (typepred "z!1")
                           (skosimp)
                           (inst - "x!2")
                           (assert))))))))
                    ("2"
                     (skosimp)
                     (expand "H")
                     (rewrite "sup_measurable")
                     (("1"
                       (hide 2 3 -1)
                       (expand "measurable_bounded_above?")
                       (propax))
                      ("2"
                       (skosimp)
                       (hide-all-but (-6 1))
                       (inst - "n!2")
                       (rewrite "integrable_is_measurable")
                       (hide 2)
                       (rewrite "integrable_abs"))))))
                  ("2" (propax))))
                ("2"
                 (hide-all-but (1 -3))
                 (expand "pointwise_bounded_above?")
                 (expand "bounded_above?")
                 (expand "pointwise?")
                 (skosimp)
                 (inst - "_" "x!1")
                 (inst + "2 * GG(x!1)"))))
              ("2"
               (hide 2)
               (expand "pointwise_convergence?")
               (skosimp)
               (inst -8 "x!1")
               (hide-all-but (-8 1))
               (rewrite "metric_convergence_def")
               (rewrite "metric_convergence_def")
               (expand "metric_converges_to")
               (skosimp)
               (inst - "r!1")
               (skosimp)
               (inst + "n!1")
               (skosimp)
               (inst - "i!1")
               (expand "ball")
               (grind))))
            ("2"
             (hide 2)
             (skosimp)
             (expand "abs" 1)
             (expand "-" 1)
             (lemma "triangle" ("x" "F!1(n!1)(x!1)" "y" "-FF(x!1)"))
             (rewrite "abs_neg" -1)
             (hide-all-but (-1 -5 -7 1))
             (inst - "x!1")
             (inst - "n!1" "x!1")
             (expand "abs" -2)
             (expand "abs" -3)
             (name-replace "LHS" "abs(F!1(n!1)(x!1) + -FF(x!1))")
             (assert))))
          ("2" (skosimp) (rewrite "integrable_diff"))))
        ("2"
         (hide -2 2)
         (expand "ae_le?")
         (expand "pointwise_ae?")
         (expand "ae?")
         (expand "fullset")
         (expand "ae_in?")
         (inst + "emptyset[T]")
         (skosimp)
         (hide 1)
         (inst - "x!1")
         (inst - "0" "x!1")
         (expand "abs")
         (typepred "abs(F!1(0)(x!1))")
         (expand "abs" 1 2)
         (assert)
         (hide -6)
         (grind))))
      ("2"
       (hide-all-but (-3 -4 1))
       (skosimp)
       (expand "pointwise_convergence?")
       (inst - "_" "x!1")
       (inst -2 "x!1")
       (rewrite "metric_convergence_def")
       (case "metric_converges_to(LAMBDA n: abs(F!1(n)(x!1)), abs(f!2(x!1)))")
       (("1"
         (hide -3)
         (expand "metric_converges_to")
         (inst - "abs(f!2)(x!1) - f!1(x!1)")
         (("1"
           (skosimp)
           (inst - "n!1")
           (inst - "n!1")
           (expand "ball")
           (expand "member")
           (expand "abs" -1 4)
           (expand "abs" 1)
           (name-replace "LIMIT" "abs(f!2(x!1))")
           (expand "abs" -2)
           (name-replace "DRL1" "abs(F!1(n!1)(x!1))")
           (expand "abs")
           (assert))
          ("2" (assert))))
        ("2"
         (hide 2 -1)
         (expand "metric_converges_to")
         (skosimp)
         (inst - "r!1")
         (skosimp)
         (inst + "n!1")
         (skosimp)
         (inst - "i!1")
         (assert)
         (expand "ball")
         (grind))))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_equality
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (case "FORALL (f: [T -> real], mu, nu: measure_type[T, S]):
                 (FORALL E: x_eq(mu(E), nu(E))) & isf?[T, S, mu](f) => isf?[T, S, nu](f)")
   (("1"
     (skosimp)
     (inst-cp - "f!1" "mu!1" "nu!1")
     (inst - "f!1" "nu!1" "mu!1")
     (replace -3)
     (split 1)
     (("1" (propax))
      ("2"
       (flatten)
       (assert)
       (hide-all-but (-3 2))
       (skosimp)
       (inst - "E!1")
       (expand "x_eq")
       (flatten)
       (assert)
       (flatten)
       (assert))))
    ("2"
     (hide 2)
     (skolem + ("_" "mu!1" "nu!1"))
     (case-replace "(FORALL E: x_eq(mu!1(E), nu!1(E)))")
     (("1"
       (case "forall (f:isf[T, S, mu!1]): isf?[T, S, nu!1](f)")
       (("1" (skosimp) (inst - "f!1"))
        ("2"
         (hide 2)
         (skosimp)
         (typepred "f!1")
         (lemma "isf_induction[T, S, mu!1]" ("P" "isf?[T, S, nu!1]"))
         (expand "restrict")
         (inst - "f!1")
         (assert)
         (hide 2)
         (rewrite "isf_zero[T,S,nu!1]")
         (skosimp)
         (typepred "E!1")
         (inst - "E!1")
         (("1"
           (rewrite "isf_add[T,S,nu!1]" 1)
           (hide 2)
           (rewrite "isf_scal[T,S,nu!1]" 1)
           (hide 2)
           (rewrite "isf_phi[T,S,nu!1]" 1)
           (hide 2)
           (expand "mu_fin?")
           (expand "x_eq")
           (flatten)
           (assert))
          ("2" (expand "measurable_set?") (propax))))))
      ("2" (assert) (replace 1 2) (hide 1) (skosimp))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_equality
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skolem + ("_" "mu!1" "nu!1"))
   (case-replace "FORALL E: x_eq(mu!1(E), nu!1(E))")
   (("1"
     (case "forall (f:isf[T, S, mu!1]): isf_integral[T, S, mu!1](f) = isf_integral[T, S, nu!1](f)")
     (("1"
       (skosimp)
       (split -3)
       (("1" (inst - "f!1"))
        ("2"
         (lemma "measure_eq_isf?" ("mu" "mu!1" "nu" "nu!1" "f" "f!1"))
         (assert)
         (split)
         (("1" (inst - "f!1")) ("2" (propax))))))
      ("2"
       (hide 2)
       (skosimp)
       (lemma "isf_induction[T,S,mu!1]"
        ("P"
         "lambda (f:isf[T, S, mu!1]): isf_integral[T, S, mu!1](f) = isf_integral[T, S, nu!1](f)"))
       (inst - "f!1")
       (assert)
       (hide 2)
       (rewrite "isf_integral_zero[T, S, mu!1]")
       (rewrite "isf_integral_zero[T, S, nu!1]")
       (skosimp)
       (rewrite "isf_integral_add[T, S, nu!1]")
       (("1"
         (rewrite "isf_integral_add[T, S, mu!1]")
         (("1"
           (replace -1)
           (assert)
           (hide -1)
           (rewrite "isf_integral_scal[T, S, mu!1]")
           (rewrite "isf_integral_scal[T, S, nu!1]")
           (("1"
             (rewrite "isf_integral_phi[T,S,mu!1]")
             (rewrite "isf_integral_phi[T,S,nu!1]")
             (("1"
               (inst - "E!1")
               (expand "x_eq")
               (expand "mu")
               (flatten)
               (typepred "E!1")
               (expand "mu_fin?")
               (assert))
              ("2"
               (typepred "E!1")
               (expand "mu_fin?")
               (inst - "E!1")
               (expand "x_eq")
               (flatten)
               (assert))))
            ("2"
             (rewrite "isf_phi[T, S, nu!1]")
             (typepred "E!1")
             (expand "mu_fin?")
             (inst - "E!1")
             (expand "x_eq")
             (flatten)
             (assert))))
          ("2" (rewrite "isf_scal[T, S, mu!1]"))))
        ("2"
         (rewrite "isf_scal[T, S, nu!1]")
         (rewrite "isf_phi[T, S, nu!1]")
         (typepred "E!1")
         (expand "mu_fin?")
         (inst - "E!1")
         (expand "x_eq")
         (flatten)
         (assert))))
      ("3"
       (skosimp)
       (lemma "measure_eq_isf?" ("mu" "mu!1" "nu" "nu!1" "f" "f!1"))
       (assert))))
    ("2" (replace 1 2) (hide 1) (skosimp))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_equality
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (case "FORALL (g: [T -> nnreal], mu, nu: measure_type[T, S]):
                 (FORALL E: x_eq(mu(E), nu(E)))&nn_integrable?[T, S, mu](g) => nn_integrable?[T, S, nu](g)")
   (("1"
     (skosimp)
     (split 1)
     (("1" (flatten) (inst - "g!1" "mu!1" "nu!1") (assert))
      ("2"
       (flatten)
       (inst - "g!1" "nu!1" "mu!1")
       (assert)
       (hide-all-but (-2 2))
       (skosimp)
       (inst - "E!1")
       (expand "x_eq")
       (flatten)
       (assert)
       (flatten)
       (assert))))
    ("2"
     (hide 2)
     (skosimp)
     (expand "nn_integrable?")
     (skosimp)
     (inst + "u!1")
     (("1"
       (assert)
       (expand "o ")
       (case-replace
        "(LAMBDA (n: nat): isf_integral[T,S,mu!1](u!1(n)))=LAMBDA (n: nat): isf_integral[T,S,nu!1](u!1(n))")
       (("1"
         (apply-extensionality :hide? t)
         (("1"
           (hide -3 2 -2)
           (typepred "u!1(x!1)")
           (lemma "measure_eq_isf"
            ("mu" "mu!1" "nu" "nu!1" "f" "u!1(x!1)"))
           (assert))
          ("2"
           (skosimp)
           (typepred "u!1(n!1)")
           (lemma "measure_eq_isf?"
            ("nu" "nu!1" "mu" "mu!1" "f" "u!1(n!1)"))
           (assert))))
        ("2"
         (skosimp)
         (lemma "measure_eq_isf?"
          ("nu" "nu!1" "mu" "mu!1" "f" "u!1(n!1)"))
         (assert))))
      ("2"
       (typepred "u!1")
       (expand "increasing_nn_isf?")
       (assert)
       (skolem + "n!1")
       (typepred "u!1(n!1)")
       (expand "nn_isf?")
       (assert)
       (split)
       (("1"
         (lemma "measure_eq_isf?"
          ("mu" "mu!1" "nu" "nu!1" "f" "u!1(n!1)"))
         (assert))
        ("2" (propax))))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_equality
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (case "FORALL (g: [T -> nnreal], mu, nu: measure_type[T, S]):
                 (FORALL E: x_eq(mu(E), nu(E))) AND
                  nn_integrable?[T, S, mu](g)
                  => (nn_integral[T, S, mu](g) = nn_integral[T, S, nu](g))")
   (("1"
     (skosimp)
     (split -3)
     (("1" (inst - "g!1" "mu!1" "nu!1") (assert))
      ("2"
       (lemma "measure_eq_nn_integrable?"
        ("mu" "mu!1" "nu" "nu!1" "g" "g!1"))
       (assert)
       (replace -4 -1)
       (inst - "g!1" "mu!1" "nu!1")
       (assert))))
    ("2"
     (hide 2)
     (skosimp)
     (lemma "measure_eq_nn_integrable?"
      ("mu" "mu!1" "nu" "nu!1" "g" "g!1"))
     (assert)
     (split)
     (("1"
       (lemma "nn_integral_def[T,S,nu!1]" ("f" "g!1"))
       (lemma "nn_integral_def[T,S,mu!1]" ("f" "g!1"))
       (skosimp*)
       (name-replace "LHS" "nn_integral[T, S, mu!1](g!1)")
       (name-replace "RHS" "nn_integral[T, S, nu!1](g!1)")
       (lemma "nn_convergence[T,S,mu!1]"
        ("u1" "u!1" "u2" "u!2" "f" "g!1"))
       (("1"
         (replace -2)
         (replace -4)
         (split -1)
         (("1"
           (flatten)
           (case-replace
            "isf_integral[T, S, nu!1] o u!2 = isf_integral[T, S, mu!1] o u!2")
           (("1"
             (hide -1)
             (lemma "hausdorff_convergence.limit_def"
              ("v" "isf_integral[T, S, mu!1] o u!2" "l" "RHS"))
             (assert)
             (replace -1)
             (lemma "hausdorff_convergence.limit_def"
              ("v" "isf_integral[T, S, mu!1] o u!1" "l" "LHS"))
             (assert))
            ("2"
             (apply-extensionality :hide? t)
             (hide 2)
             (expand "o ")
             (lemma "measure_eq_isf?"
              ("mu" "mu!1" "nu" "nu!1" "f" "u!2(x!1)"))
             (assert)
             (split)
             (("1"
               (lemma "measure_eq_isf"
                ("mu" "mu!1" "nu" "nu!1" "f" "u!2(x!1)"))
               (assert))
              ("2" (propax))))))
          ("2" (expand "convergent?") (inst + "LHS"))))
        ("2"
         (hide-all-but (-6 1))
         (typepred "u!2")
         (expand "increasing_nn_isf?")
         (replace -1)
         (skosimp)
         (typepred "u!2(x1!1)")
         (expand "nn_isf?")
         (replace -2)
         (lemma "measure_eq_isf?"
          ("mu" "mu!1" "nu" "nu!1" "f" "u!2(x1!1)"))
         (assert))))
      ("2" (propax))))
    ("3"
     (hide 2)
     (skosimp)
     (lemma "measure_eq_nn_integrable?"
      ("nu" "nu!1" "mu" "mu!1" "g" "g!1"))
     (assert))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_equality
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (rewrite "integrable_pm_def[T, S, mu!1]")
   (rewrite "integrable_pm_def[T, S, nu!1]")
   (lemma "measure_eq_nn_integrable?"
    ("nu" "nu!1" "mu" "mu!1" "g" "plus(f!1)"))
   (lemma "measure_eq_nn_integrable?"
    ("nu" "nu!1" "mu" "mu!1" "g" "minus(f!1)"))
   (replace -3)
   (assert)
   (split 1)
   (("1"
     (flatten)
     (assert)
     (lemma "nn_integrable_is_nn_integrable[T, S, mu!1]"
      ("f" "plus(f!1)"))
     (split -1)
     (("1"
       (assert)
       (lemma "nn_integrable_is_nn_integrable[T, S, mu!1]"
        ("f" "minus(f!1)"))
       (split)
       (("1"
         (assert)
         (hide-all-but (-5 -7 1))
         (lemma "nn_integrable_is_integrable[T,S,nu!1]")
         (inst-cp - "minus(f!1)")
         (inst - "plus(f!1)")
         (assert))
        ("2" (hide-all-but 1) (grind))))
      ("2" (hide-all-but 1) (grind))))
    ("2"
     (flatten)
     (lemma "nn_integrable_is_nn_integrable[T, S, nu!1]"
      ("f" "minus(f!1)"))
     (("1"
       (lemma "nn_integrable_is_nn_integrable[T, S, nu!1]"
        ("f" "plus(f!1)"))
       (("1"
         (split)
         (("1"
           (split)
           (("1"
             (assert)
             (lemma "nn_integrable_is_integrable[T,S,mu!1]")
             (inst-cp - "minus(f!1)")
             (inst - "plus(f!1)")
             (assert))
            ("2" (hide-all-but 1) (grind))))
          ("2" (hide-all-but 1) (grind))))
        ("2" (propax))))
      ("2" (propax))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_equality
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (case "FORALL (f: [T -> real], mu, nu: measure_type[T, S]):
                 (FORALL E: x_eq(mu(E), nu(E))) AND integrable?[T, S, mu](f)
                  => (integral[T, S, mu](f) = integral[T, S, nu](f))")
   (("1"
     (skosimp)
     (split -3)
     (("1" (inst - "f!1" "mu!1" "nu!1") (assert))
      ("2"
       (lemma "measure_eq_integrable?"
        ("mu" "mu!1" "nu" "nu!1" "f" "f!1"))
       (assert)
       (split -1)
       (("1" (inst - "f!1" "mu!1" "nu!1") (assert)) ("2" (propax))))))
    ("2"
     (hide 2)
     (skosimp)
     (rewrite "integral_pm[T, S, mu!1]")
     (rewrite "integral_pm[T, S, nu!1]")
     (lemma "measure_eq_integrable?" ("mu" "mu!1" "nu" "nu!1" "f" "f!1"))
     (assert)
     (replace -2)
     (rewrite "integrable_pm_def[T, S, nu!1]")
     (rewrite "integrable_pm_def[T, S, mu!1]")
     (flatten)
     (lemma "nn_integrable_is_nn_integrable[T,S,mu!1]")
     (inst-cp - "plus(f!1)")
     (inst - "minus(f!1)")
     (lemma "nn_integrable_is_nn_integrable[T,S,nu!1]")
     (inst-cp - "plus(f!1)")
     (inst - "minus(f!1)")
     (case-replace "FORALL (x: T): minus(f!1)(x) >= 0")
     (("1"
       (case-replace "FORALL (x: T): plus(f!1)(x) >= 0")
       (("1"
         (rewrite "integral_nn[T,S,mu!1]")
         (rewrite "integral_nn[T,S,mu!1]")
         (rewrite "integral_nn[T,S,nu!1]")
         (rewrite "integral_nn[T,S,nu!1]")
         (lemma "measure_eq_nn_integral"
          ("mu" "mu!1" "nu" "nu!1" "g" "plus(f!1)"))
         (lemma "measure_eq_nn_integral"
          ("mu" "mu!1" "nu" "nu!1" "g" "minus(f!1)"))
         (assert)
         (replace -11)
         (assert))
        ("2" (hide-all-but 1) (grind))))
      ("2" (hide-all-but 1) (grind))))
    ("3"
     (hide 2)
     (skosimp)
     (lemma "measure_eq_integrable?" ("mu" "mu!1" "nu" "nu!1" "f" "f!1"))
     (assert))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_equality
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (lemma "measure_eq_isf?" ("mu" "mu!1" "nu" "nu!1" "f" "f!1"))
   (assert))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_equality
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1" (propax))
    ("2"
     (lemma "measure_eq_nn_integrable?"
      ("mu" "mu!1" "nu" "nu!1" "g" "g!1"))
     (assert))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_equality
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (lemma "measure_eq_nn_integrable?"
    ("mu" "mu!1" "nu" "nu!1" "g" "g!1"))
   (assert))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_equality
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "measure_eq_integrable?" ("nu" "nu!1" "mu" "mu!1" "f" "f!1"))
   (assert)
   (split)
   (("1" (propax)) ("2" (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integral")
   (case-replace "phi(emptyset) * g!1=lambda x: 0")
   (("1" (rewrite "integral_zero"))
    ("2" (apply-extensionality :hide? t) (hide 2) (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integral" 1 1)
   (case-replace "phi(fullset) * f!1=f!1")
   (hide 2)
   (apply-extensionality :hide? t)
   (grind))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral_ae_ge_0" ("f" "phi(E!1) * f!1"))
   (replace -3)
   (split -1)
   (("1"
     (hide -3)
     (expand "ae_in?")
     (skosimp)
     (typepred "E!2")
     (expand "negligible_set?")
     (skosimp)
     (expand "ae_0?")
     (expand "restrict")
     (expand "pointwise_ae?")
     (expand "ae?")
     (expand "fullset")
     (expand "ae_in?")
     (skosimp)
     (typepred "E!3")
     (expand "negligible_set?")
     (skosimp)
     (name-replace "FF" "X!1")
     (case "forall x: difference(E!1,FF)(x) => f!1(x)>0")
     (("1"
       (hide -5 -7)
       (name-replace "GG" "X!2")
       (case "FORALL x: difference(E!1, GG)(x) => f!1(x) = 0")
       (("1"
         (hide -4 -6)
         (lemma "null_union" ("N1" "FF" "N2" "GG"))
         (("1"
           (lemma "m_monotone" ("a" "E!1" "b" "union(FF,GG)"))
           (("1"
             (split -1)
             (("1"
               (hide-all-but (-1 -2 1))
               (expand "null_set?")
               (expand "x_le")
               (expand "mu_fin?")
               (expand "mu")
               (flatten)
               (assert)
               (flatten)
               (assert))
              ("2"
               (hide -1 -4 -5 2)
               (expand "subset?")
               (skosimp)
               (expand "member")
               (inst - "x!1")
               (inst - "x!1")
               (expand "union")
               (flatten)
               (expand "member")
               (expand "difference")
               (expand "member")
               (assert))))
            ("2" (expand "null_set?") (flatten))))
          ("2" (propax)) ("3" (propax))))
        ("2"
         (hide -1 -4 2)
         (skosimp)
         (expand "difference")
         (expand "member")
         (flatten)
         (expand "subset?")
         (inst - "x!1")
         (expand "member")
         (assert)
         (inst - "x!1")
         (assert)
         (expand "*")
         (expand "phi")
         (expand "member")
         (assert))))
      ("2"
       (skosimp)
       (expand "difference")
       (expand "member")
       (flatten)
       (inst -7 "x!1")
       (expand "subset?")
       (inst -5 "x!1")
       (assert))))
    ("2"
     (hide -2 2)
     (expand "ae_nonneg?")
     (expand "pointwise_ae?")
     (expand "ae?")
     (expand "fullset")
     (expand "ae_in?")
     (skosimp)
     (typepred "E!2")
     (expand "*")
     (inst + "intersection(E!1,E!2)")
     (("1"
       (skosimp)
       (expand "intersection")
       (assert)
       (expand "phi")
       (assert)
       (case-replace "E!1(x!1)")
       (("1" (inst - "x!1") (assert)) ("2" (assert))))
      ("2"
       (lemma "negligible_subset"
        ("E" "E!2" "X" "intersection[T](E!1, E!2)"))
       (split -1)
       (("1" (propax))
        ("2"
         (hide-all-but 1)
         (expand "intersection")
         (expand "subset?")
         (expand "member")
         (skosimp*))))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integral")
   (name "H" "f1!1-f2!1")
   (lemma "integrable_diff" ("f1" "f1!1" "f2" "f2!1"))
   (replace -2)
   (lemma "integrable_is_measurable" ("x" "H"))
   (lemma "measurable_gt" ("f" "H"))
   (lemma "measurable_lt" ("f" "H"))
   (assert)
   (inst - "0")
   (inst - "0")
   (inst-cp - "{z: T | H(z) > 0}")
   (("1"
     (inst - "{z: T | H(z) < 0}")
     (("1"
       (lemma "indefinite_eq_0" ("E" "{z: T | H(z) > 0}" "f" "H"))
       (("1"
         (split -1)
         (("1"
           (lemma "indefinite_eq_0" ("E" "{z: T | H(z) < 0}" "f" "-H"))
           (("1"
             (split -1)
             (("1"
               (skosimp)
               (hide -10 -11 -8 -9)
               (lemma "m_disjoint_union"
                ("a" "{z: T | H(z) < 0}" "b" "{z: T | H(z) > 0}"))
               (split -1)
               (("1"
                 (expand "x_eq")
                 (expand "mu_fin?")
                 (expand "mu")
                 (assert)
                 (flatten)
                 (expand "x_add")
                 (assert)
                 (replace -4)
                 (replace -6)
                 (hide -3 -4 -5 -6)
                 (expand "ae_eq?")
                 (expand "restrict")
                 (expand "pointwise_ae?")
                 (expand "ae?")
                 (expand "fullset")
                 (expand "ae_in?")
                 (inst + "union({z: T | H(z) < 0}, {z: T | H(z) > 0})")
                 (("1"
                   (skosimp)
                   (expand "H")
                   (expand "union")
                   (expand "member")
                   (flatten)
                   (assert)
                   (expand "-")
                   (assert))
                  ("2"
                   (expand "negligible_set?")
                   (inst + "union({z: T | H(z) < 0}, {z: T | H(z) > 0})")
                   (split)
                   (("1"
                     (expand "null_set?")
                     (rewrite "measurable_union")
                     (expand "mu_fin?")
                     (expand "mu")
                     (propax))
                    ("2" (expand "subset?") (skosimp))))))
                ("2"
                 (hide-all-but 1)
                 (expand "disjoint?")
                 (expand "intersection")
                 (expand "empty?")
                 (skosimp)
                 (expand "member")
                 (flatten)
                 (assert))))
              ("2"
               (hide 2)
               (expand "ae_in?")
               (flatten)
               (inst + "{z: T | H(z) > 0}")
               (("1" (skosimp) (expand "-") (assert))
                ("2"
                 (expand "negligible_set?")
                 (inst + "{z: T | H(z) > 0}")
                 (split)
                 (("1"
                   (expand "null_set?")
                   (expand "measurable_set?")
                   (assert))
                  ("2" (expand "subset?") (skosimp))))))
              ("3"
               (hide-all-but (-5 -4 1 -7))
               (expand "H" 1 2)
               (case-replace
                "phi({z: T | H(z) < 0}) * -(f1!1 - f2!1) = phi({z: T | H(z) < 0}) * f2!1-phi({z: T | H(z) < 0}) * f1!1")
               (("1" (rewrite "integral_diff") (assert))
                ("2"
                 (hide-all-but 1)
                 (apply-extensionality :hide? t)
                 (grind))))))
            ("2"
             (expand "integrable?")
             (rewrite "indefinite_integrable")
             (expand "measurable_set?")
             (propax))
            ("3" (expand "measurable_set?") (propax))))
          ("2" (hide 2) (expand "ae_in?") (expand "member") (propax))
          ("3"
           (hide 2)
           (expand "H" 1 2)
           (expand "-" 1)
           (expand "*" 1)
           (lemma "integral_diff"
            ("f1"
             "phi({z: T | H(z) > 0}) * f1!1"
             "f2"
             "phi({z: T | H(z) > 0}) * f2!1"))
           (expand "-" -1)
           (expand "*" -1)
           (replace -1 1)
           (assert)
           (expand "*" -8)
           (assert))))
        ("2"
         (expand "integrable?")
         (rewrite "indefinite_integrable")
         (expand "measurable_set?")
         (propax))
        ("3" (expand "measurable_set?") (propax))))
      ("2" (expand "measurable_set?") (propax))))
    ("2" (expand "measurable_set?") (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integral")
   (lemma "integral_phi" ("F" "intersection(E!1, F!1)"))
   (case-replace "phi(intersection(E!1, F!1)) = phi(E!1) * phi(F!1)")
   (hide-all-but 1)
   (apply-extensionality :hide? t)
   (("1" (grind)) ("2" (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integral")
   (lemma "integral_add" ("f1" "phi(E!1) * f1!1" "f2" "phi(E!1) * f2!1"))
   (case-replace
    "phi(E!1) * (f1!1 + f2!1)=phi(E!1) * f1!1 + phi(E!1) * f2!1")
   (hide-all-but 1)
   (apply-extensionality :hide? t)
   (grind))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integral")
   (case-replace "phi(E!1) * (c!1 * f!1) = c!1*(phi(E!1)*f!1)")
   (("1" (rewrite "integral_scal"))
    ("2" (hide 2) (apply-extensionality :hide? t) (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "indefinite_scal" ("c" "-1" "f" "f!1" "E" "E!1"))
   (case-replace "-1 * f!1=-f!1")
   (("1" (assert))
    ("2" (apply-extensionality :hide? t) (hide-all-but 1) (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "indefinite_opp" ("f" "f2!1" "E" "E!1"))
   (lemma "indefinite_add" ("f1" "f1!1" "f2" "-f2!1" "E" "E!1"))
   (case-replace "f1!1 + -f2!1 = f1!1 - f2!1")
   (("1" (assert))
    ("2" (hide-all-but 1) (apply-extensionality :hide? t) (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1"
     (flatten)
     (skosimp)
     (typepred "f1!1")
     (typepred "f2!1")
     (expand "integral")
     (assert)
     (hide -1 -2 2)
     (lemma "integral_ae_eq"
      ("f" "phi(E!1) * f1!1" "h" "phi(E!1) * f2!1"))
     (("1"
       (assert)
       (hide 2)
       (expand "ae_eq?")
       (expand "restrict")
       (expand "*")
       (expand "pointwise_ae?")
       (expand "ae?")
       (expand "fullset")
       (expand "ae_in?")
       (skosimp)
       (inst + "E!2")
       (skosimp)
       (inst - "x!1")
       (assert))
      ("2"
       (hide 2)
       (rewrite "prod_measurable")
       (hide -1 2)
       (lemma "phi_is_simple" ("X" "E!1"))
       (("1" (lemma "simple_is_measurable") (inst - "phi(E!1)"))
        ("2" (typepred "E!1") (expand "measurable_set?") (propax))))))
    ("2"
     (skosimp)
     (lemma "indefinite_eq" ("f1" "f1!1" "f2" "f2!1"))
     (assert))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1"
     (flatten)
     (skosimp)
     (expand "integral")
     (lemma "integral_ae_le"
      ("f1" "lambda (x:T): 0" "f2" "phi(E!1) * f!1"))
     (("1"
       (rewrite "integral_zero")
       (assert)
       (hide 2)
       (expand "ae_nonneg?")
       (expand "ae_le?")
       (expand "pointwise_ae?")
       (expand "ae?")
       (expand "fullset")
       (expand "ae_in?")
       (skosimp)
       (inst + "E!2")
       (skosimp)
       (inst - "x!1")
       (assert)
       (expand "*")
       (expand "phi")
       (assert)
       (assert)
       (case-replace "E!1(x!1)")
       (("1" (assert)) ("2" (assert))))
      ("2" (rewrite "integrable_zero"))))
    ("2"
     (flatten)
     (inst - "{x | f!1(x) < 0}")
     (("1"
       (expand "integral")
       (lemma "integral_nonneg" ("f" "-(phi({x | f!1(x) < 0}) * f!1)"))
       (("1"
         (split -1)
         (("1"
           (rewrite "integral_opp")
           (case-replace
            "integral(phi({x_1: T | f!1(x_1) < 0}) * f!1)=0")
           (("1"
             (hide -2 -3)
             (lemma "indefinite_opp"
              ("f" "f!1" "E" "{x_1: T | f!1(x_1) < 0}"))
             (("1"
               (expand "integral" -1)
               (replace -2)
               (lemma "indefinite_eq_0"
                ("f" "-f!1" "E" "{x_2: T | f!1(x_2) < 0}"))
               (("1"
                 (replace -2)
                 (assert)
                 (split -1)
                 (("1"
                   (hide -2 -3)
                   (expand "ae_nonneg?")
                   (expand "pointwise_ae?")
                   (expand "ae?")
                   (expand "fullset")
                   (expand "ae_in?")
                   (inst + "{x_1: T | f!1(x_1) < 0}")
                   (("1" (skosimp) (assert))
                    ("2"
                     (expand "negligible_set?")
                     (flatten)
                     (inst + "{x_1: T | f!1(x_1) < 0}")
                     (expand "null_set?")
                     (assert)
                     (split)
                     (("1"
                       (hide -1 -2)
                       (lemma "measurable_lt" ("f" "f!1"))
                       (flatten)
                       (split -1)
                       (("1"
                         (inst - "0")
                         (expand "measurable_set?")
                         (propax))
                        ("2" (rewrite "integrable_is_measurable"))))
                      ("2"
                       (expand "subset?")
                       (expand "member")
                       (skosimp))))))
                  ("2"
                   (expand "ae_in?")
                   (inst + "emptyset[T]")
                   (skosimp)
                   (typepred "x!1")
                   (assert)
                   (expand "-")
                   (assert))))
                ("2"
                 (expand "integrable?")
                 (rewrite "indefinite_integrable"))))
              ("2"
               (hide-all-but 1)
               (lemma "measurable_lt" ("f" "f!1"))
               (flatten)
               (split -1)
               (("1"
                 (inst - "0")
                 (expand "integrable?")
                 (rewrite "indefinite_integrable")
                 (expand "measurable_set?")
                 (propax))
                ("2" (rewrite "integrable_is_measurable"))))
              ("3"
               (typepred "f!1")
               (hide -2 2)
               (lemma "integrable_is_measurable")
               (inst - "f!1")
               (rewrite "measurable_lt")
               (inst - "0")
               (expand "measurable_set?")
               (propax))))
            ("2" (assert))))
          ("2"
           (skosimp)
           (expand "-")
           (expand "*")
           (expand "phi")
           (expand "member")
           (hide-all-but 1)
           (grind))))
        ("2" (rewrite "integrable_opp"))))
      ("2"
       (typepred "f!1")
       (lemma "measurable_lt")
       (inst - "f!1")
       (assert)
       (flatten)
       (hide -2)
       (split)
       (("1" (inst - "0") (expand "measurable_set?") (propax))
        ("2" (assert) (rewrite "integrable_is_measurable"))))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "indefinite_0_le" ("f" "f2!1-f1!1"))
   (split)
   (("1"
     (flatten)
     (split -2)
     (("1"
       (hide-all-but (-1 1))
       (skosimp)
       (inst - "E!1")
       (rewrite "indefinite_diff")
       (assert))
      ("2" (hide-all-but (-1 1)) (grind))))
    ("2"
     (flatten)
     (split -3)
     (("1" (hide-all-but (-1 1)) (grind))
      ("2"
       (hide-all-but (-1 1))
       (skosimp)
       (inst - "E!1")
       (rewrite "indefinite_diff")
       (assert))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integral")
   (lemma "plus_minus_def" ("f" "f!1"))
   (rewrite "integral_diff" 1 :dir rl)
   (case-replace
    "phi(E!1) * f!1=phi(E!1) * plus(f!1) - phi(E!1) * minus(f!1)")
   (hide 2)
   (apply-extensionality :hide? t)
   (lemma "extensionality_postulate"
    ("f" "f!1" "g" "plus(f!1) - minus(f!1)"))
   (replace -1 -2 rl)
   (inst - "x!1")
   (hide -1)
   (grind))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp*)
   (expand "integral")
   (case-replace "phi(union(E1!1, E2!1)) = phi(E1!1)+phi(E2!1)")
   (("1"
     (expand "*" 1 1)
     (expand "+" 1 1)
     (lemma "integral_add"
      ("f1" "phi(E1!1) * f!1" "f2" "phi(E2!1) * f!1"))
     (expand "+" -1 1)
     (expand "*" -1 1)
     (expand "*" -1 1)
     (propax))
    ("2"
     (hide 2)
     (apply-extensionality :hide? t)
     (("1" (expand "disjoint?") (expand "empty?") (inst - "x!1") (grind))
      ("2" (hide -1) (grind))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "indefinite_union"
    ("f" "f!1" "E1" "E1!1" "E2" "difference(E2!1,E1!1)"))
   (("1"
     (rewrite "difference_disjoint")
     (lemma "union_diff_subset" ("a" "E1!1" "b" "E2!1"))
     (assert)
     (replace -1)
     (hide -1 -3)
     (name-replace "INT1" "integral(E1!1, f!1)")
     (name-replace "INT2" "integral(E2!1, f!1)")
     (typepred "f!1")
     (expand "integrable?")
     (lemma "indefinite_integrable"
      ("E" "difference(E2!1, E1!1)" "f" "phi(E2!1) * f!1"))
     (("1"
       (case-replace
        "phi(difference(E2!1, E1!1)) * (phi(E2!1) * f!1)=phi(difference(E2!1, E1!1))*f!1")
       (("1"
         (hide -1)
         (expand "integral")
         (lemma "integral_ae_le"
          ("f1" "lambda x: 0" "f2" "phi(difference(E2!1, E1!1)) * f!1"))
         (("1"
           (split -1)
           (("1" (rewrite "integral_zero") (assert))
            ("2"
             (hide-all-but (-4 1))
             (expand "ae_nonneg?")
             (expand "ae_le?")
             (expand "pointwise_ae?")
             (expand "ae?")
             (expand "fullset")
             (expand "ae_in?")
             (skosimp)
             (inst + "E!1")
             (skosimp)
             (inst - "x!1")
             (assert)
             (grind))))
          ("2" (rewrite "integrable_zero"))))
        ("2" (hide-all-but 1) (apply-extensionality :hide? t) (grind))))
      ("2" (propax))))
    ("2"
     (typepred "f!1")
     (hide 2 -3)
     (expand "integrable?")
     (lemma "union_diff_subset" ("a" "E1!1" "b" "E2!1"))
     (assert))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral_ae_eq" ("f" "lambda x: 0" "h" "phi(N!1)* h!1"))
   (("1"
     (rewrite "integral_zero")
     (expand "integral" +)
     (assert)
     (hide 2)
     (typepred "N!1")
     (expand "ae_eq?")
     (expand "restrict")
     (expand "pointwise_ae?")
     (expand "ae?")
     (expand "fullset")
     (expand "ae_in?")
     (inst + "N!1")
     (skosimp)
     (hide -1)
     (grind))
    ("2"
     (rewrite "prod_measurable")
     (lemma "phi_is_simple" ("X" "N!1"))
     (("1" (expand "simple?") (propax))
      ("2"
       (typepred "N!1")
       (expand "null_set?")
       (expand "measurable_set?")
       (flatten))))
    ("3" (rewrite "integrable_zero"))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (case "FORALL (DX: disjoint_indexed_measurable[T, S],
                       f: integrable[T, S, m]):ae_nonneg?(f) =>
                 convergence?(series(LAMBDA n: integral(DX(n), f)),
                              integral(IUnion(DX), f))")
   (("1"
     (skosimp)
     (inst-cp - "DX!1" "minus(f!1)")
     (inst - "DX!1" "plus(f!1)")
     (split)
     (("1"
       (split)
       (("1"
         (case "forall (u:sequence[real],l:real): convergence?(u,l) iff convergence(u,l)")
         (("1"
           (inst-cp - "series(LAMBDA n: integral(DX!1(n), f!1))"
            "integral(IUnion(DX!1), f!1)")
           (("1"
             (inst-cp - "series(LAMBDA n: integral(DX!1(n), minus(f!1)))"
              "integral(IUnion(DX!1), minus(f!1))")
             (("1"
               (inst - "series(LAMBDA n: integral(DX!1(n), plus(f!1)))"
                "integral(IUnion(DX!1), plus(f!1))")
               (("1"
                 (replace -1)
                 (replace -2)
                 (replace -3)
                 (hide -1 -2 -3)
                 (lemma "cnv_seq_diff"
                  ("s2"
                   "series(LAMBDA n: integral(DX!1(n), minus(f!1)))"
                   "l2"
                   "integral(IUnion(DX!1), minus(f!1))"
                   "s1"
                   "series(LAMBDA n: integral(DX!1(n), plus(f!1)))"
                   "l1"
                   "integral(IUnion(DX!1), plus(f!1))"))
                 (("1"
                   (assert)
                   (rewrite "series_diff")
                   (expand "-" -1)
                   (case-replace
                    "(LAMBDA (x: nat):
                                               integral(DX!1(x), plus(f!1)) -
                                                integral(DX!1(x), minus(f!1)))=LAMBDA n: integral(DX!1(n), f!1)")
                   (("1"
                     (hide -1)
                     (name-replace "LHS"
                      "series(LAMBDA n: integral(DX!1(n), f!1))")
                     (("1"
                       (hide -2 -3)
                       (rewrite "indefinite_diff" -1 :dir rl)
                       (case-replace "plus(f!1) - minus(f!1)=f!1")
                       (apply-extensionality :hide? t)
                       (hide-all-but 1)
                       (grind))
                      ("2"
                       (skosimp)
                       (expand "integrable?")
                       (rewrite "indefinite_integrable")
                       (expand "measurable_set?")
                       (propax))))
                    ("2"
                     (apply-extensionality 1 :hide? t)
                     (("1"
                       (hide-all-but 1)
                       (lemma "indefinite_diff"
                        ("E"
                         "DX!1(x!1)"
                         "f1"
                         "plus(f!1)"
                         "f2"
                         "minus(f!1)"))
                       (replace -1 1 rl)
                       (case-replace "plus(f!1) - minus(f!1)=f!1")
                       (apply-extensionality :hide? t)
                       (hide-all-but 1)
                       (grind))
                      ("2"
                       (skosimp)
                       (expand "integrable?")
                       (rewrite "indefinite_integrable")
                       (expand "measurable_set?")
                       (propax))
                      ("3"
                       (skosimp)
                       (expand "integrable?")
                       (rewrite "indefinite_integrable")
                       (expand "measurable_set?")
                       (propax))
                      ("4"
                       (skosimp)
                       (expand "integrable?")
                       (rewrite "indefinite_integrable")
                       (expand "measurable_set?")
                       (propax))
                      ("5"
                       (skosimp)
                       (expand "measurable_set?")
                       (propax))))
                    ("3"
                     (skosimp)
                     (expand "integrable?")
                     (rewrite "indefinite_integrable")
                     (expand "measurable_set?")
                     (propax))))
                  ("2"
                   (skosimp)
                   (expand "integrable?")
                   (rewrite "indefinite_integrable")
                   (expand "measurable_set?")
                   (propax))
                  ("3"
                   (skosimp)
                   (expand "integrable?")
                   (rewrite "indefinite_integrable")
                   (expand "measurable_set?")
                   (propax))
                  ("4" (skosimp) (expand "measurable_set?") (propax))))
                ("2"
                 (skosimp)
                 (expand "integrable?")
                 (rewrite "indefinite_integrable")
                 (expand "measurable_set?")
                 (propax))
                ("3" (expand "measurable_set?") (propax))))
              ("2"
               (skosimp)
               (expand "integrable?")
               (rewrite "indefinite_integrable")
               (expand "measurable_set?")
               (propax))
              ("3" (skosimp) (expand "measurable_set?") (propax))))
            ("2"
             (skosimp)
             (expand "integrable?")
             (rewrite "indefinite_integrable")
             (expand "measurable_set?")
             (propax))
            ("3" (expand "measurable_set?") (propax))))
          ("2"
           (hide-all-but 1)
           (skosimp*)
           (rewrite "metric_convergence_def")
           (expand "metric_converges_to")
           (expand "convergence")
           (expand "member")
           (expand "ball")
           (split)
           (("1"
             (skosimp*)
             (inst - "epsilon!1")
             (skosimp)
             (inst + "n!1")
             (skosimp)
             (inst - "i!1")
             (grind))
            ("2"
             (skosimp*)
             (inst - "r!1")
             (skosimp)
             (inst + "n!1")
             (skosimp)
             (inst - "i!1")
             (grind))))))
        ("2"
         (hide-all-but 1)
         (expand "ae_nonneg?")
         (expand "pointwise_ae?")
         (expand "ae?")
         (expand "ae_in?")
         (inst + "emptyset")
         (grind))))
      ("2"
       (hide-all-but 1)
       (expand "ae_nonneg?")
       (expand "pointwise_ae?")
       (expand "ae?")
       (expand "ae_in?")
       (inst + "emptyset")
       (grind))))
    ("2"
     (hide 2)
     (skosimp)
     (lemma "increasing_IUnion" ("A" "DX!1"))
     (skosimp)
     (case "forall n: S(B!1(n)) & measurable_set?(B!1(n)) & B!1(n) = IUnion(n,DX!1)")
     (("1"
       (lemma "monotone_convergence" ("F" "lambda n: phi(B!1(n))*f!1"))
       (("1"
         (split)
         (("1"
           (flatten)
           (hide -1 -2)
           (inst - "phi(IUnion(DX!1))*f!1")
           (("1"
             (split)
             (("1"
               (expand "converges_upto?")
               (expand "o ")
               (flatten)
               (case-replace
                "series(LAMBDA n: integral(DX!1(n), f!1))=LAMBDA n: integral(phi(B!1(n)) * f!1)")
               (("1" (expand "integral" 1 2) (propax))
                ("2"
                 (hide 2 -1 -2)
                 (rewrite "extensionality_postulate" 1 :dir rl)
                 (("1"
                   (copy -1)
                   (induct "x")
                   (("1"
                     (expand "series")
                     (expand "sigma")
                     (expand "sigma")
                     (expand "integral" 1 1)
                     (assert))
                    ("2"
                     (skosimp*)
                     (expand "series")
                     (expand "sigma" 1)
                     (replace -1)
                     (hide -1)
                     (lemma "indefinite_union"
                      ("E1" "B!1(j!1)" "E2" "DX!1(1+j!1)" "f" "f!1"))
                     (("1"
                       (split -1)
                       (("1"
                         (inst -6 "j!1")
                         (replace -6)
                         (replace -6 * rl)
                         (expand "integral" 1 1)
                         (expand "integral" -1)
                         (assert))
                        ("2"
                         (hide-all-but (-1 1))
                         (inst - "j!1")
                         (flatten)
                         (hide -1 -2)
                         (replace -1)
                         (hide -1)
                         (typepred "DX!1")
                         (expand "disjoint_indexed_measurable?")
                         (expand "disjoint?")
                         (expand "disjoint?")
                         (expand "intersection")
                         (expand "empty?")
                         (expand "member")
                         (skosimp*)
                         (expand "IUnion")
                         (expand "image")
                         (expand "Union")
                         (skosimp)
                         (typepred "a!1")
                         (skolem - "n!2")
                         (replace -1)
                         (hide -1)
                         (inst - "n!2" "1+j!1")
                         (assert)
                         (inst - "x!1")
                         (assert))))
                      ("2"
                       (expand "integrable?")
                       (rewrite "indefinite_integrable" 1)
                       (inst -5 "j!1")
                       (inst - "j!1+1")
                       (expand "measurable_set?")
                       (assert))
                      ("3" (inst - "j!1") (flatten))))
                    ("3"
                     (skosimp)
                     (inst - "x!2")
                     (flatten)
                     (rewrite "indefinite_integrable"))
                    ("4"
                     (skosimp)
                     (expand "integrable?")
                     (rewrite "indefinite_integrable")
                     (expand "measurable_set?")
                     (propax))
                    ("5" (expand "measurable_set?") (propax))))
                  ("2"
                   (skosimp)
                   (expand "integrable?")
                   (rewrite "indefinite_integrable")
                   (expand "measurable_set?")
                   (propax))
                  ("3" (expand "measurable_set?") (propax))))
                ("3"
                 (skosimp)
                 (expand "integrable?")
                 (rewrite "indefinite_integrable")
                 (expand "measurable_set?")
                 (propax))
                ("4" (skosimp) (expand "measurable_set?") (propax))))
              ("2"
               (hide 2)
               (replace -5)
               (hide -3 -4 -5 -6)
               (expand "ae_convergence?")
               (expand "fullset")
               (expand "ae_convergence_in?")
               (expand "ae_in?")
               (inst + "emptyset")
               (expand "member")
               (skosimp)
               (hide 1)
               (hide -1)
               (expand "*")
               (expand "phi")
               (expand "member")
               (rewrite "metric_convergence_def")
               (expand "metric_converges_to")
               (skosimp)
               (case-replace "IUnion(B!1)(x!1)")
               (("1"
                 (expand "IUnion")
                 (skosimp)
                 (inst + "i!1")
                 (skosimp)
                 (expand "increasing?")
                 (inst - "i!1" "i!2")
                 (assert)
                 (expand "subset?")
                 (inst - "x!1")
                 (expand "ball")
                 (expand "member")
                 (assert)
                 (expand "abs")
                 (assert))
                ("2"
                 (assert)
                 (inst + "0")
                 (skosimp)
                 (case-replace "B!1(i!1)(x!1)")
                 (("1" (expand "IUnion") (inst + "i!1"))
                  ("2"
                   (assert)
                   (expand "ball")
                   (expand "abs")
                   (assert))))))))
            ("2" (rewrite "indefinite_integrable"))))
          ("2"
           (expand "ae_increasing?")
           (hide 2 -3 -4 -5)
           (expand "ae_nonneg?")
           (expand "pointwise_ae?")
           (expand "ae?")
           (expand "fullset")
           (expand "ae_in?")
           (skosimp)
           (inst + "E!1")
           (skosimp)
           (expand "member")
           (inst -3 "x!1")
           (skosimp)
           (assert)
           (expand "*")
           (expand "increasing?")
           (inst - "i!1" "j!1")
           (assert)
           (expand "phi")
           (expand "member")
           (case-replace "B!1(i!1)(x!1)")
           (("1" (expand "subset?") (inst -4 "x!1") (assert) (assert))
            ("2"
             (assert)
             (lift-if 3)
             (prop)
             (("1" (assert)) ("2" (assert))))))))
        ("2"
         (skosimp)
         (rewrite "indefinite_integrable")
         (inst - "n!1")
         (flatten))))
      ("2"
       (hide -5 2 -4)
       (induct "n")
       (("1" (assert)) ("2" (assert) (expand "measurable_set?") (assert))
        ("3" (rewrite "IUnion_0_def"))
        ("4"
         (skosimp*)
         (inst -6 "j!1")
         (replace -6)
         (lemma "measurable_union" ("a" "B!1(j!1)" "b" "DX!1(j!1+1)"))
         (("1"
           (expand "measurable_set?")
           (assert)
           (rewrite "IUnion_n_def")
           (replace -4 * rl)
           (propax))
          ("2" (expand "measurable_set?") (propax)) ("3" (propax))))))))
    ("3"
     (skosimp*)
     (expand "integrable?")
     (rewrite "indefinite_integrable")
     (expand "measurable_set?")
     (propax))
    ("4" (skosimp*) (expand "measurable_set?") (propax))
    ("5"
     (skosimp)
     (skosimp)
     (expand "integrable?")
     (rewrite "indefinite_integrable")
     (expand "measurable_set?")
     (propax))
    ("6" (expand "measurable_set?") (propax))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integrable?")
   (case-replace "phi(emptyset[T]) * g!1=lambda x: 0")
   (("1" (rewrite "integrable_zero"))
    ("2"
     (apply-extensionality :hide? t)
     (expand "*")
     (expand "emptyset")
     (expand "phi")
     (expand "member")
     (assert))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "F!1")
   (expand "integrable?")
   (lemma "isf_is_integrable")
   (inst - "phi[T, S](intersection(E!1,F!1))")
   (("1"
     (expand "intersection")
     (expand "phi")
     (expand "member")
     (expand "*")
     (case-replace
      "(LAMBDA (x_1: T):
                          IF E!1(x_1) THEN 1 ELSE 0 ENDIF *
                           IF F!1(x_1) THEN 1 ELSE 0 ENDIF)=(LAMBDA (x_1: T):
                          IF E!1(x_1) AND F!1(x_1) THEN 1 ELSE 0 ENDIF)")
     (apply-extensionality :hide? t)
     (hide-all-but 1)
     (grind))
    ("2"
     (hide 2)
     (rewrite "isf_phi")
     (hide 2)
     (expand "mu_fin?")
     (lemma "m_monotone" ("a" "intersection[T](E!1, F!1)" "b" "F!1"))
     (split -1)
     (("1" (expand "x_le") (assert)) ("2" (hide-all-but 1) (grind))))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (typepred "F!1")
   (typepred "E!1")
   (lemma "measurable_intersection" ("a" "E!1" "b" "F!1"))
   (expand "measurable_set?")
   (assert)
   (expand "mu_fin?")
   (lemma "m_monotone" ("a" "intersection[T](E!1, F!1)" "b" "F!1"))
   (split -1)
   (("1" (expand "x_le") (assert)) ("2" (hide-all-but 1) (grind))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f1!1")
   (typepred "f2!1")
   (expand "integrable?")
   (lemma "integrable_add"
    ("f1" "phi(E!1) * f1!1" "f2" "phi(E!1) * f2!1"))
   (("1"
     (case-replace
      "((+[T])(phi(E!1) * f1!1, phi(E!1) * f2!1))=(phi(E!1) * ((+[T])(f1!1, f2!1)))")
     (apply-extensionality :hide? t)
     (hide-all-but 1)
     (grind))
    ("2" (propax)) ("3" (propax))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (expand "integrable?")
   (lemma "integrable_scal" ("c" "c!1" "f" "phi(E!1) * f!1"))
   (("1"
     (case-replace
      "(*[T](c!1, phi(E!1) * f!1))=(phi(E!1) * (*[T](c!1, f!1)))")
     (apply-extensionality :hide? t)
     (hide-all-but 1)
     (grind))
    ("2" (propax))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (expand "integrable?")
   (lemma "integrable_opp" ("f" "phi(E!1) * f!1"))
   (("1"
     (case-replace "(-(phi(E!1) * f!1))=(phi(E!1) * -f!1)")
     (apply-extensionality :hide? t)
     (hide-all-but 1)
     (grind))
    ("2" (propax))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f1!1")
   (typepred "f2!1")
   (expand "integrable?")
   (lemma "integrable_diff"
    ("f1" "phi(E!1) * f1!1" "f2" "phi(E!1) * f2!1"))
   (("1"
     (case-replace
      "((-[T])(phi(E!1) * f1!1, phi(E!1) * f2!1))=(phi(E!1) * ((-[T])(f1!1, f2!1)))")
     (hide-all-but 1)
     (apply-extensionality :hide? t)
     (grind))
    ("2" (propax)) ("3" (propax))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (expand "integrable?")
   (lemma "integrable_plus" ("f" "phi(E!1) * f!1"))
   (("1"
     (case-replace "(plus[T](phi(E!1) * f!1))=(phi(E!1) * plus[T](f!1))")
     (apply-extensionality :hide? t)
     (("1" (hide-all-but 1) (grind)) ("2" (hide-all-but 1) (grind))))
    ("2" (propax))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (expand "integrable?")
   (lemma "integrable_minus" ("f" "phi(E!1) * f!1"))
   (("1"
     (case-replace
      "(minus[T](phi(E!1) * f!1))=(phi(E!1) * minus[T](f!1))")
     (apply-extensionality :hide? t)
     (("1" (hide-all-but 1) (grind)) ("2" (hide-all-but 1) (grind))))
    ("2" (propax))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (expand "integrable?")
   (lemma "indefinite_integrable"
    ("E" "E1!1" "f" "phi(union(E1!1, E2!1)) * f!1"))
   (("1"
     (case-replace
      "(phi(E1!1) * (phi(union(E1!1, E2!1)) * f!1))=(phi(E1!1) * f!1)")
     (apply-extensionality :hide? t)
     (hide-all-but 1)
     (grind))
    ("2" (propax))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (expand "integrable?")
   (lemma "indefinite_integrable"
    ("E" "E2!1" "f" "phi(union(E1!1, E2!1)) * f!1"))
   (("1"
     (case-replace
      "(phi(E2!1) * (phi(union(E1!1, E2!1)) * f!1))=(phi(E2!1) * f!1)")
     (apply-extensionality :hide? t)
     (hide-all-but 1)
     (grind))
    ("2" (propax))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (expand "integrable?")
   (lemma "indefinite_integrable" ("E" "E1!1" "f" "phi(E2!1) * f!1"))
   (("1"
     (case-replace "(phi(E1!1) * (phi(E2!1) * f!1))=(phi(E1!1) * f!1)")
     (hide-all-but (-3 1))
     (apply-extensionality :hide? t)
     (expand "subset?")
     (inst - "x!1")
     (grind))
    ("2" (propax))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integrable?")
   (typepred "N!1")
   (lemma "integral_ae_eq" ("f" "lambda x: 0" "h" "phi(N!1) * h!1"))
   (("1"
     (assert)
     (hide 2)
     (expand "ae_eq?")
     (expand "restrict")
     (expand "pointwise_ae?")
     (expand "*")
     (expand "phi")
     (expand "member")
     (expand "ae?")
     (expand "fullset")
     (expand "ae_in?")
     (inst + "N!1")
     (skosimp)
     (assert))
    ("2"
     (hide 2)
     (rewrite "prod_measurable")
     (lemma "phi_is_simple" ("X" "N!1"))
     (("1" (expand "simple?") (propax))
      ("2" (expand "null_set?") (expand "measurable_set?") (flatten))))
    ("3" (rewrite "integrable_zero"))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "integrable?")
   (rewrite "indefinite_integrable")
   (expand "measurable_set?")
   (propax))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (typepred "S")
   (rewrite "measurable_IUnion")
   (skolem + "n!1")
   (expand "measurable_set?")
   (propax))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: indefinite_integral
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "indefinite_countably_additive_TCC3" ("DX" "DX!1"))
   (expand "integrable?")
   (rewrite "indefinite_integrable"))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (typepred "nu!1")
   (expand "sigma_finite_measure?")
   (expand "measure?")
   (flatten)
   (expand "measure_countably_additive?")
   (inst - "lambda i: intersection(A_of(nu!1)(i),E!1)")
   (("1"
     (name "AA" "A_of(nu!1)")
     (replace -1)
     (expand "fm_contraction")
     (expand "o ")
     (expand "A_of")
     (lemma "A_of_TCC1" ("f" "nu!1"))
     (lemma "choose_member"
      ("a"
       "{X: disjoint_indexed_measurable[T, S] |
                     IUnion[nat, T](X) = fullset[T] AND (FORALL i: nu!1(X(i))`1)}"))
     (split)
     (("1"
       (replace -3)
       (expand "member")
       (flatten)
       (hide -3 -4)
       (case-replace "IUnion(LAMBDA i: intersection(AA(i), E!1))=E!1")
       (("1"
         (hide -1)
         (lemma "x_sum_eq"
          ("S"
           "LAMBDA i: nu!1(intersection(AA(i), E!1))"
           "T"
           "LAMBDA i: (TRUE, nu!1(intersection(AA(i), E!1))`2)"))
         (("1"
           (split)
           (("1"
             (expand "x_eq")
             (flatten)
             (replace -1 * rl)
             (assert)
             (flatten)
             (assert))
            ("2"
             (hide 2)
             (skosimp)
             (hide -1 -3 -4)
             (inst - "i!1")
             (lemma "measure_monotone"
              ("f"
               "nu!1"
               "a"
               "intersection(AA(i!1), E!1)"
               "b"
               "AA(i!1)"))
             (split)
             (("1"
               (expand "x_le")
               (assert)
               (flatten)
               (expand "x_eq")
               (propax))
              ("2"
               (assert)
               (typepred "nu!1")
               (expand "sigma_finite_measure?")
               (propax))
              ("3"
               (hide-all-but 1)
               (expand "intersection")
               (expand "subset?")
               (expand "member")
               (skosimp))))))
          ("2"
           (skosimp)
           (lemma "measurable_intersection" ("a" "AA(i!1)" "b" "E!1"))
           (("1" (expand "measurable_set?") (propax))
            ("2" (expand "measurable_set?") (propax))))))
        ("2"
         (hide-all-but (-1 1))
         (apply-extensionality :hide? t)
         (lemma "extensionality_postulate"
          ("f" "IUnion[nat, T](AA)" "g" "fullset[T]"))
         (flatten)
         (split -2)
         (("1"
           (hide -2 -3)
           (inst - "x!1")
           (expand "fullset")
           (expand "IUnion")
           (skosimp)
           (case-replace "E!1(x!1)")
           (("1"
             (expand "intersection")
             (expand "member")
             (inst + "i!1")
             (assert))
            ("2" (assert) (skosimp) (expand "intersection") (assert))))
          ("2" (propax))))))
      ("2" (expand "nonempty?") (propax))))
    ("2"
     (hide 2)
     (typepred "A_of[T, S](nu!1)")
     (expand "disjoint_indexed_measurable?")
     (expand "disjoint?")
     (skosimp)
     (inst - "i!1" "j!1")
     (assert)
     (expand "disjoint?")
     (expand "intersection")
     (expand "empty?")
     (expand "member")
     (skosimp)
     (inst - "x!1")
     (assert))
    ("3"
     (skosimp)
     (lemma "measurable_intersection"
      ("a" "A_of[T, S](nu!1)(i!1)" "b" "E!1"))
     (("1" (expand "measurable_set?") (propax))
      ("2" (expand "measurable_set?") (propax))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1"
     (flatten)
     (expand "isf?")
     (split)
     (("1"
       (lemma "phi_is_simple[T,S]" ("X" "A!1"))
       (("1"
         (lemma "simple_times" ("h1" "phi(A!1)" "h2" "f!1"))
         (("1" (propax)) ("2" (propax))))
        ("2" (typepred "A!1") (expand "measurable_set?") (propax))))
      ("2"
       (expand "mu_fin?")
       (expand "contraction")
       (expand "nonzero_set?")
       (expand "intersection")
       (expand "phi")
       (expand "member")
       (expand "*")
       (case-replace
        "{x: T | IF A!1(x) THEN 1 ELSE 0 ENDIF * f!1(x) /= 0}={x_1: T | A!1(x_1) AND f!1(x_1) /= 0}")
       (hide -1 2)
       (apply-extensionality :hide? t)
       (grind))))
    ("2"
     (flatten)
     (expand "isf?")
     (flatten)
     (hide -1)
     (expand "nonzero_set?")
     (expand "mu_fin?")
     (expand "contraction")
     (expand "intersection")
     (expand "phi")
     (expand "member")
     (expand "*")
     (case-replace
      "{x: T | IF A!1(x) THEN 1 ELSE 0 ENDIF * f!1(x) /= 0}={x_1: T | A!1(x_1) AND f!1(x_1) /= 0}")
     (hide -1 2)
     (apply-extensionality :hide? t)
     (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (lemma "contraction_isf" ("mu" "mu!1" "A" "A!1" "f" "f!1"))
   (assert)
   (expand "isf_integral")
   (expand "mu")
   (expand "contraction")
   (case "FORALL (c: real):
                 NOT c = 0 IMPLIES
                  S(inverse_image[T, real]
                        (((reals@real_fun_ops[T].*)(phi[T, S](A!1), f!1)),
                         singleton[real](c)))")
   (("1"
     (case-replace
      "(LAMBDA (c:real):
                   IF c = 0 THEN 0
                   ELSE c *
                         mu!1(intersection(A!1,
                                          inverse_image[T, real]
                                          (f!1, singleton[real](c))))`2
                   ENDIF)=(LAMBDA (c:real):
                    IF c = 0 THEN 0
                    ELSE c *
                          mu!1(inverse_image[T, real]
                                  (((reals@real_fun_ops[T].*)
                                        (phi[T, S](A!1), f!1)),
                                   singleton[real](c)))`2
                    ENDIF)")
     (("1"
       (hide -1)
       (name "F"
             "LAMBDA(c: real):IF c = 0 THEN 0
                           ELSE c *
                                 mu!1(inverse_image[T, real]
                                         (((reals@real_fun_ops[T].*)
                                               (phi[T, S](A!1), f!1)),
                                          singleton[real](c)))`2
                           ENDIF")
       (("1"
         (replace -1)
         (expand "isf?")
         (expand "simple?")
         (flatten)
         (hide -2 -3 -5 -6 -8)
         (lemma "sigma_add[real]"
          ("f" "F" "X" "image[T, real](f!1, fullset[T])" "t" "0"))
         (expand "F" -1 3)
         (replace -1 1 rl)
         (case "subset?[real](image[T, real]
                               (((reals@real_fun_ops[T].*)(phi[T, S](A!1), f!1)),
                                fullset[T]),add[real](0, image[T, real](f!1, fullset[T])))")
         (("1"
           (lemma "sigma_subset[real]"
            ("X"
             "image[T, real]
                            (((reals@real_fun_ops[T].*)(phi[T, S](A!1), f!1)),
                             fullset[T])"
             "Y"
             "add[real](0, image[T, real](f!1, fullset[T]))"
             "f"
             "F"))
           (replace -2)
           (replace -1)
           (hide -1 -3)
           (assert)
           (lemma "sigma_eq[real]"
            ("X"
             "difference[real](add[real](0, image[T, real](f!1, fullset[T])),
                                    image[T, real]
                                        (((reals@real_fun_ops[T].*)
                                              (phi[T, S](A!1), f!1)),
                                         fullset[T]))"))
           (inst - "F" "lambda (c:real): 0")
           (("1"
             (split -1)
             (("1" (replace -1) (rewrite "sigma_zero[real]" 1))
              ("2"
               (hide 2)
               (skosimp)
               (typepred "t!1")
               (hide -2 -3 -4 -5)
               (expand "difference")
               (expand "member")
               (flatten)
               (expand "add")
               (expand "F")
               (expand "inverse_image")
               (expand "member")
               (expand "singleton")
               (expand "*")
               (split -1)
               (("1" (replace -1 * rl) (propax))
                ("2"
                 (case-replace "t!1=0")
                 (assert)
                 (case-replace
                  "{x: T | phi[T, S](A!1)(x) * f!1(x) = t!1}=emptyset[T]")
                 (("1"
                   (typepred "mu!1")
                   (expand "measure?")
                   (flatten)
                   (expand "measure_empty?")
                   (replace -1)
                   (assert))
                  ("2"
                   (hide 4)
                   (apply-extensionality 1 :hide? t)
                   (expand "emptyset")
                   (hide -2)
                   (expand "fullset")
                   (expand "image")
                   (inst + "x!1")
                   (assert))))))))
            ("2"
             (hide 2)
             (expand "convergent?")
             (flatten)
             (hide 2)
             (rewrite "finite_difference")
             (rewrite "finite_add"))))
          ("2"
           (hide-all-but 1)
           (expand "subset?")
           (expand "add")
           (expand "fullset")
           (expand "*")
           (expand "phi")
           (expand "image")
           (expand "member")
           (skosimp*)
           (case-replace "A!1(x!2)")
           (("1" (inst + "x!2") (assert)) ("2" (assert))))))
        ("2" (propax))))
      ("2"
       (hide 2)
       (apply-extensionality :hide? t)
       (("1"
         (case-replace "x!1=0")
         (assert)
         (case-replace
          "inverse_image[T, real]
                      (((reals@real_fun_ops[T].*)(phi[T, S](A!1), f!1)),
                       singleton[real](x!1))=intersection[T]
                      (A!1, inverse_image[T, real](f!1, singleton[real](x!1)))")
         (hide-all-but (1 2))
         (apply-extensionality :hide? t)
         (grind))
        ("2"
         (skosimp)
         (inst - "c!1")
         (assert)
         (case-replace
          "inverse_image[T, real]
                      (((reals@real_fun_ops[T].*)(phi[T, S](A!1), f!1)),
                       singleton[real](c!1))=intersection[T]
                      (A!1, inverse_image[T, real](f!1, singleton[real](c!1)))")
         (hide 3 -1 -2 -3)
         (apply-extensionality :hide? t)
         (expand "inverse_image")
         (expand "intersection")
         (expand "phi")
         (expand "*")
         (expand "member")
         (expand "singleton")
         (grind))))
      ("3"
       (hide 2)
       (skosimp)
       (inst - "c!1")
       (assert)
       (case-replace
        "inverse_image[T, real]
                    (((reals@real_fun_ops[T].*)(phi[T, S](A!1), f!1)),
                     singleton[real](c!1))=intersection[T]
                    (A!1, inverse_image[T, real](f!1, singleton[real](c!1)))")
       (hide -1 -2 -3 3)
       (apply-extensionality :hide? t)
       (grind))))
    ("2"
     (hide 2)
     (skosimp)
     (lemma "prod_measurable[T,S]" ("g1" "phi[T, S](A!1)" "g2" "f!1"))
     (("1"
       (expand "measurable_function?")
       (inst - "singleton[real](c!1)")
       (("1" (expand "measurable_set?") (propax))
        ("2" (lemma "singleton_is_borel") (inst - "c!1"))))
      ("2"
       (lemma "phi_is_simple[T,S]" ("X" "A!1"))
       (("1" (expand "simple?") (flatten))
        ("2" (typepred "A!1") (expand "measurable_set?") (propax))))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1"
     (flatten)
     (expand "nn_integrable?")
     (skosimp)
     (inst +
      "lambda (n:nat): ((reals@real_fun_ops[T].*)
                                          (phi[T, S](A!1), u!1(n)))")
     (("1"
       (split)
       (("1"
         (expand "pointwise_convergence?")
         (skosimp)
         (inst - "x!1")
         (expand "*")
         (expand "phi")
         (expand "member")
         (case-replace "A!1(x!1)")
         (("1" (assert))
          ("2"
           (assert)
           (hide -1 -2 1)
           (expand "convergence?")
           (skosimp)
           (inst + "0")
           (skosimp)
           (assert))))
        ("2"
         (hide -1)
         (expand "convergent?")
         (skosimp)
         (inst + "l!1")
         (expand "o ")
         (case-replace
          "(LAMBDA (n: nat): isf_integral[T,S,contraction(mu!1,A!1)](u!1(n)))=(LAMBDA (n: nat):
                               isf_integral[T,S,mu!1]((((reals@real_fun_ops[T].*)
                                              (phi[T, S](A!1), u!1(n))))))")
         (("1"
           (hide -1 2)
           (apply-extensionality :hide? t)
           (("1" (rewrite "contraction_isf_integral"))
            ("2"
             (skosimp)
             (typepred "u!1(n!1)")
             (rewrite "contraction_isf")
             (expand "isf?")
             (propax))))
          ("2"
           (hide -1 2)
           (skosimp)
           (typepred "u!1(n!1)")
           (hide -2)
           (rewrite "contraction_isf")
           (hide 2)
           (expand "isf?")
           (propax))))))
      ("2"
       (typepred "u!1")
       (hide -2 -3)
       (expand "increasing_nn_isf?")
       (expand "pointwise_increasing?")
       (skosimp)
       (inst - "x!1")
       (expand "increasing?")
       (skolem + ("i!1" "j!1"))
       (inst - "i!1" "j!1")
       (flatten)
       (assert)
       (expand "*")
       (expand "phi")
       (expand "member")
       (case-replace "A!1(x!1)")
       (("1" (assert)) ("2" (assert))))
      ("3"
       (expand "nn_isf?")
       (skosimp)
       (typepred "u!1(n!1)")
       (expand "nn_isf?")
       (split)
       (("1" (rewrite "contraction_isf") (expand "isf?") (propax))
        ("2" (skosimp) (inst - "x!1") (hide -1 -3 -4) (grind))))))
    ("2"
     (flatten)
     (typepred "f!1")
     (lemma "nn_measurable_def" ("f" "f!1"))
     (expand "nn_measurable?")
     (flatten)
     (replace -2)
     (replace -3)
     (assert)
     (skosimp)
     (expand "pointwise_converges_upto?")
     (flatten)
     (expand "nn_integrable?")
     (skosimp)
     (inst +
      "lambda (n:nat): ((reals@real_fun_ops[T].*)
                                        (phi[T, S](A!1), u!1(n)))+((reals@real_fun_ops[T].*)
                                        (phi[T, S](complement(A!1)), w!1(n)))")
     (("1"
       (split)
       (("1"
         (expand "pointwise_convergence?")
         (skosimp)
         (inst - "x!1")
         (inst -5 "x!1")
         (hide-all-but (-1 -5 1))
         (expand "+")
         (expand "*")
         (expand "phi")
         (expand "complement")
         (expand "member")
         (case-replace "A!1(x!1)")
         (("1" (assert)) ("2" (assert))))
        ("2"
         (expand "convergent?")
         (skosimp)
         (inst + "l!1")
         (expand "o ")
         (case "FORALL (n: nat):
                       isf?[T, S, contraction(mu!1, A!1)]
                           ((+[T])
                                ((((reals@real_fun_ops[T].*)
                                       (phi[T, S](A!1), u!1(n)))),
                                 ((((reals@real_fun_ops[T].*)
                                        (phi[T, S](complement[T](A!1)), w!1(n)))))))")
         (("1"
           (case-replace
            "(LAMBDA (n: nat):
                                 isf_integral[T,S,contraction(mu!1,A!1)]((((reals@real_fun_ops[T].*)
                                                (phi[T, S](A!1), u!1(n))))
                                               +
                                               (((reals@real_fun_ops[T].*)
                                                 (phi[T, S](complement(A!1)),
                                                  w!1(n))))))=(LAMBDA (n: nat): isf_integral[T,S,mu!1](u!1(n)))")
           (apply-extensionality 1 :hide? t)
           (hide 2)
           (inst - "x!1")
           (rewrite "isf_integral_add[T, S, contraction(mu!1, A!1)]")
           (("1"
             (case-replace
              "isf_integral[T,S,contraction(mu!1,A!1)](((((reals@real_fun_ops[T].*)
                                         (phi[T, S](complement(A!1)), w!1(x!1))))))=0")
             (("1"
               (hide -1 -2)
               (case-replace
                "isf_integral[T, S, mu!1](u!1(x!1))=isf_integral[T, S, mu!1](((reals@real_fun_ops[T].*)
                                          (phi[T, S](A!1), u!1(x!1))))")
               (("1"
                 (hide -1)
                 (lemma "contraction_isf_integral"
                  ("mu" "mu!1" "A" "A!1" "f" "u!1(x!1)"))
                 (("1"
                   (case-replace
                    "(((reals@real_fun_ops[T].*)(phi[T, S](A!1), u!1(x!1))))=u!1(x!1)")
                   (("1"
                     (typepred "u!1(x!1)")
                     (lemma "contraction_isf"
                      ("mu" "mu!1" "A" "A!1" "f" "u!1(x!1)"))
                     (("1" (replace -4 -1) (assert))
                      ("2"
                       (expand "isf?")
                       (expand "simple?")
                       (flatten)
                       (hide 2)
                       (assert))))
                    ("2"
                     (hide-all-but (1 -6))
                     (apply-extensionality :hide? t)
                     (expand "*")
                     (expand "pointwise_convergence?")
                     (inst - "x!2")
                     (expand "phi")
                     (expand "member")
                     (case-replace "A!1(x!2)")
                     (("1" (assert))
                      ("2"
                       (assert)
                       (typepred "u!1(x!1)")
                       (expand "nn_isf?")
                       (inst - "x!2")
                       (expand ">=" -2)
                       (expand "<=" -2)
                       (hide -1)
                       (rewrite "metric_convergence_def")
                       (expand "metric_converges_to")
                       (inst - "u!1(x!1)(x!2)")
                       (("1"
                         (skosimp)
                         (expand "ball")
                         (expand "member")
                         (inst - "max(n!1,x!1)")
                         (split -2)
                         (("1"
                           (typepred "u!1(max(n!1, x!1))")
                           (expand "nn_isf?")
                           (inst - "x!2")
                           (case-replace
                            "abs(-1 * u!1(max(n!1, x!1))(x!2))=u!1(max(n!1, x!1))(x!2)")
                           (("1"
                             (hide -1 -2)
                             (typepred "u!1")
                             (expand "increasing_nn_isf?")
                             (expand "pointwise_increasing?")
                             (inst - "x!2")
                             (expand "increasing?")
                             (inst - "x!1" "max(n!1, x!1)")
                             (split -1)
                             (("1" (assert))
                              ("2" (hide-all-but 1) (grind))))
                            ("2" (hide-all-but (-2 1)) (grind))))
                          ("2" (hide-all-but 1) (grind))))
                        ("2" (assert))))))))
                  ("2"
                   (hide 2)
                   (typepred "u!1(x!1)")
                   (expand "isf?")
                   (flatten)
                   (assert)
                   (expand "mu_fin?")
                   (expand "contraction")
                   (lemma "m_monotone[T,S,mu!1]"
                    ("a"
                     "intersection(A!1, nonzero_set?(u!1(x!1)))"
                     "b"
                     "nonzero_set?(u!1(x!1))"))
                   (("1"
                     (split -1)
                     (("1"
                       (expand "x_le")
                       (assert)
                       (flatten)
                       (assert)
                       (expand "nonzero_set?")
                       (propax))
                      ("2"
                       (hide-all-but 1)
                       (expand "subset?")
                       (expand "intersection")
                       (expand "nonzero_set?")
                       (expand "member")
                       (skosimp))))
                    ("2"
                     (lemma "nonzero_measurable[T, S, mu!1]"
                      ("g" "u!1(x!1)"))
                     (("1" (propax)) ("2" (expand "simple?") (flatten))))
                    ("3"
                     (hide 2)
                     (rewrite "measurable_intersection")
                     (lemma "nonzero_measurable[T, S, mu!1]"
                      ("g" "u!1(x!1)"))
                     (("1" (propax))
                      ("2" (expand "simple?") (flatten))))))))
                ("2"
                 (hide 2)
                 (case-replace
                  "(((reals@real_fun_ops[T].*)(phi[T, S](A!1), u!1(x!1))))=u!1(x!1)")
                 (hide 2 -6)
                 (expand "*")
                 (apply-extensionality :hide? t)
                 (expand "phi")
                 (expand "member")
                 (expand "pointwise_convergence?")
                 (hide -1 -2)
                 (inst -3 "x!2")
                 (rewrite "metric_convergence_def")
                 (expand "metric_converges_to")
                 (expand "member")
                 (expand "ball")
                 (case-replace "A!1(x!2)")
                 (("1" (assert))
                  ("2"
                   (assert)
                   (inst -3 "u!1(x!1)(x!2)")
                   (("1"
                     (skosimp)
                     (typepred "u!1")
                     (expand "increasing_nn_isf?")
                     (expand "pointwise_increasing?")
                     (inst - "x!2")
                     (expand "increasing?")
                     (inst - "x!1" "max(n!1,x!1)")
                     (split -1)
                     (("1"
                       (inst -4 "max(n!1, x!1)")
                       (split -4)
                       (("1"
                         (case-replace
                          "abs(-1 * u!1(max(n!1, x!1))(x!2))=u!1(max(n!1, x!1))(x!2)")
                         (("1" (assert))
                          ("2"
                           (hide-all-but 1)
                           (typepred "u!1(max(n!1, x!1))")
                           (expand "nn_isf?")
                           (inst - "x!2")
                           (expand "abs")
                           (assert)
                           (hide -1)
                           (grind))))
                        ("2" (hide-all-but 1) (grind))))
                      ("2" (hide-all-but 1) (grind))))
                    ("2"
                     (assert)
                     (typepred "u!1(x!1)")
                     (expand "nn_isf?")
                     (inst - "x!2")
                     (expand ">=" -2)
                     (expand "<=" -2)
                     (assert))))))
                ("3"
                 (hide 2)
                 (typepred "u!1(x!1)")
                 (lemma "isf_times_simple_is_isf[T, S, mu!1]"
                  ("i" "u!1(x!1)" "h" "phi[T, S](A!1)"))
                 (("1"
                   (case-replace
                    "(((reals@real_fun_ops[T].*)(phi[T, S](A!1), u!1(x!1))))=*[T](u!1(x!1), phi[T, S](A!1))")
                   (apply-extensionality 1 :hide? t)
                   (expand "*")
                   (expand "phi")
                   (expand "member")
                   (case-replace "A!1(x!2)")
                   (("1" (assert)) ("2" (assert))))
                  ("2"
                   (rewrite "phi_is_simple")
                   (typepred "A!1")
                   (expand "measurable_set?")
                   (propax))))))
              ("2"
               (hide 2)
               (expand "isf_integral")
               (expand "mu")
               (expand "contraction")
               (expand "intersection")
               (expand "complement")
               (expand "phi")
               (expand "member")
               (case-replace
                "(LAMBDA (c:real):
                             IF c = 0 THEN 0
                             ELSE c *
                                   mu!1({x: T |
                                          A!1(x) AND
                                           inverse_image[T, real]
                                               ((((((reals@real_fun_ops[T].*)
                                                    (LAMBDA
                                                     (x_1: T):
                                                     IF NOT A!1(x_1) THEN 1 ELSE 0 ENDIF,
                                                     w!1(x!1)))))),
                                                singleton[real](c))
                                               (x)})`2
                             ENDIF)=(LAMBDA (c:real):0)")
               (("1" (hide -1) (rewrite "sigma_zero" 1))
                ("2"
                 (hide-all-but 1)
                 (apply-extensionality :hide? t)
                 (("1"
                   (case-replace "x!2 = 0")
                   (assert)
                   (case-replace
                    "{x: T |
                                  A!1(x) AND
                                   inverse_image[T, real]
                                       ((((((reals@real_fun_ops[T].*)
                                                (LAMBDA (x_1: T):
                                                   IF NOT A!1(x_1) THEN 1 ELSE 0 ENDIF,
                                                 w!1(x!1)))))),
                                        singleton[real](x!2))
                                       (x)}=emptyset[T]")
                   (("1"
                     (typepred "mu!1")
                     (expand "measure?")
                     (expand "measure_empty?")
                     (flatten)
                     (replace -1)
                     (assert))
                    ("2"
                     (hide 3)
                     (apply-extensionality :hide? t)
                     (expand "emptyset")
                     (flatten)
                     (expand "inverse_image")
                     (expand "*")
                     (expand "member")
                     (assert)
                     (expand "singleton")
                     (assert))))
                  ("2"
                   (skosimp)
                   (case-replace
                    "{x: T |
                               A!1(x) AND
                                inverse_image[T, real]
                                    (((((((reals@real_fun_ops[T].*)
                                              (LAMBDA (x_1: T):
                                                 IF NOT A!1(x_1) THEN 1 ELSE 0 ENDIF,
                                               w!1(x!1))))))),
                                     singleton[real](c!1))
                                    (x)}=emptyset[T]")
                   (("1" (assert))
                    ("2"
                     (hide 3)
                     (apply-extensionality :hide? t)
                     (expand "emptyset")
                     (flatten)
                     (assert)
                     (expand "inverse_image")
                     (expand "member")
                     (expand "*")
                     (expand "singleton")
                     (assert))))))
                ("3"
                 (hide 2)
                 (hide-all-but 1)
                 (skosimp)
                 (case-replace
                  "{x: T |
                             A!1(x) AND
                              inverse_image[T, real]
                                  (((((((reals@real_fun_ops[T].*)
                                            (LAMBDA (x_1: T):
                                               IF NOT A!1(x_1) THEN 1 ELSE 0 ENDIF,
                                             w!1(x!1))))))),
                                   singleton[real](c!1))
                                  (x)}=emptyset[T]")
                 (("1" (assert))
                  ("2"
                   (hide 3)
                   (apply-extensionality :hide? t)
                   (expand "emptyset")
                   (flatten)
                   (expand "inverse_image")
                   (expand "member")
                   (expand "*")
                   (assert)
                   (expand "singleton")
                   (assert))))))))
            ("2"
             (hide 2)
             (hide -1)
             (expand "isf?")
             (split)
             (("1"
               (typepred "w!1")
               (expand "increasing_nn_simple?")
               (inst - "x!1")
               (expand "nn_simple?")
               (flatten)
               (rewrite "simple_times[T,S]" 1)
               (hide-all-but 1)
               (rewrite "phi_is_simple")
               (lemma "measurable_complement[T,S]" ("a" "A!1"))
               (expand "measurable_set?")
               (propax))
              ("2"
               (hide-all-but 1)
               (expand "nonzero_set?")
               (expand "*")
               (expand "complement")
               (expand "mu_fin?")
               (expand "contraction")
               (expand "intersection")
               (expand "phi")
               (expand "member")
               (case-replace
                "{x_1: T |
                             A!1(x_1) AND
                              IF NOT A!1(x_1) THEN 1 ELSE 0 ENDIF * w!1(x!1)(x_1) /= 0}=emptyset[T]")
               (("1"
                 (typepred "mu!1")
                 (expand "measure?")
                 (flatten)
                 (expand "measure_empty?")
                 (replace -1)
                 (assert))
                ("2"
                 (hide 2)
                 (apply-extensionality :hide? t)
                 (expand "emptyset")
                 (flatten)
                 (assert))))))
            ("3"
             (hide -1 2)
             (typepred "u!1(x!1)")
             (lemma
              "isf_times_simple_is_isf[T, S, contraction(mu!1, A!1)]"
              ("i" "u!1(x!1)" "h" "phi[T, S](A!1)"))
             (("1"
               (case-replace
                "(*[T](u!1(x!1), phi[T, S](A!1)))=(((((reals@real_fun_ops[T].*)(phi[T, S](A!1), u!1(x!1))))))")
               (apply-extensionality 1 :hide? t)
               (expand "*")
               (expand "phi")
               (expand "member")
               (case-replace "A!1(x!2)")
               (("1" (assert)) ("2" (assert))))
              ("2"
               (hide 2)
               (expand "isf?")
               (expand "mu_fin?")
               (flatten)
               (assert)
               (expand "contraction")
               (lemma "m_monotone[T,S,mu!1]"
                ("a"
                 "intersection(A!1, nonzero_set?(u!1(x!1)))"
                 "b"
                 "nonzero_set?(u!1(x!1))"))
               (("1"
                 (split -1)
                 (("1"
                   (expand "x_le")
                   (flatten)
                   (assert)
                   (expand "nonzero_set?")
                   (propax))
                  ("2"
                   (hide-all-but 1)
                   (expand "subset?")
                   (expand "intersection")
                   (expand "member")
                   (skosimp))))
                ("2"
                 (lemma "nonzero_measurable[T,S,mu!1]" ("g" "u!1(x!1)"))
                 (("1" (propax)) ("2" (expand "simple?") (flatten))))
                ("3"
                 (rewrite "measurable_intersection[T,S]" 1)
                 (lemma "nonzero_measurable[T,S,mu!1]" ("g" "u!1(x!1)"))
                 (("1" (propax)) ("2" (expand "simple?") (flatten))))))
              ("3"
               (rewrite "phi_is_simple[T, S]")
               (typepred "A!1")
               (expand "measurable_set?")
               (propax))))))
          ("2"
           (hide 2)
           (skosimp)
           (rewrite "isf_add[T, S, contraction(mu!1, A!1)]" 1)
           (("1"
             (hide 2)
             (expand "isf?")
             (split)
             (("1"
               (rewrite "simple_times" +)
               (("1"
                 (typepred "w!1")
                 (expand "increasing_nn_simple?")
                 (inst - "n!1")
                 (expand "nn_simple?")
                 (propax))
                ("2"
                 (rewrite "phi_is_simple" 1)
                 (lemma "measurable_complement[T,S]" ("a" "A!1"))
                 (expand "measurable_set?")
                 (propax))))
              ("2"
               (expand "nonzero_set?")
               (expand "/=")
               (expand "mu_fin?")
               (expand "contraction")
               (expand "intersection")
               (expand "*")
               (expand "complement")
               (expand "phi")
               (expand "member")
               (case-replace
                "{x_1: T |
                             A!1(x_1) AND
                              NOT (IF NOT A!1(x_1) THEN 1 ELSE 0 ENDIF * w!1(n!1)(x_1) =
                                    0)}=emptyset[T]")
               (("1"
                 (typepred "mu!1")
                 (expand "measure?")
                 (flatten)
                 (expand "measure_empty?")
                 (replace -1)
                 (assert))
                ("2"
                 (hide-all-but 1)
                 (apply-extensionality :hide? t)
                 (expand "emptyset")
                 (flatten)
                 (assert))))))
            ("2"
             (hide 2)
             (lemma
              "isf_times_simple_is_isf[T, S, contraction(mu!1, A!1)]"
              ("i" "u!1(n!1)" "h" "phi[T, S](A!1)"))
             (("1"
               (case-replace
                "(*[T](u!1(n!1), phi[T, S](A!1)))=(((((reals@real_fun_ops[T].*)(phi[T, S](A!1), u!1(n!1))))))")
               (apply-extensionality 1 :hide? t)
               (expand "*")
               (expand "phi")
               (expand "member")
               (case-replace "A!1(x!1)")
               (("1" (assert)) ("2" (assert))))
              ("2"
               (hide 2)
               (lemma "contraction_isf"
                ("mu" "mu!1" "A" "A!1" "f" "u!1(n!1)"))
               (("1"
                 (replace -1)
                 (hide -1)
                 (lemma "isf_times_simple_is_isf[T, S, mu!1]"
                  ("i" "u!1(n!1)" "h" "phi[T, S](A!1)"))
                 (("1"
                   (case-replace
                    "(((reals@real_fun_ops[T].*)(phi[T, S](A!1), u!1(n!1))))=(*[T](u!1(n!1), phi[T, S](A!1)))")
                   (hide-all-but 1)
                   (apply-extensionality :hide? t)
                   (expand "*")
                   (expand "phi")
                   (expand "member")
                   (case-replace "A!1(x!1)")
                   (("1" (assert)) ("2" (assert))))
                  ("2"
                   (rewrite "phi_is_simple" 1)
                   (typepred "A!1")
                   (expand "measurable_set?")
                   (propax))))
                ("2"
                 (typepred "u!1(n!1)")
                 (expand "isf?")
                 (expand "simple?")
                 (flatten)
                 (hide -9 2)
                 (assert))))
              ("3"
               (rewrite "phi_is_simple" 1)
               (typepred "A!1")
               (expand "measurable_set?")
               (propax))))))))))
      ("2"
       (typepred "w!1")
       (typepred "u!1")
       (hide-all-but (-1 -2 1))
       (expand "increasing_nn_isf?")
       (expand "increasing_nn_simple?")
       (flatten)
       (expand "pointwise_increasing?")
       (skosimp)
       (hide -2)
       (inst - "x!1")
       (inst - "x!1")
       (expand "increasing?")
       (skolem + ("i!1" "j!1"))
       (flatten)
       (inst - "i!1" "j!1")
       (inst - "i!1" "j!1")
       (assert)
       (expand "+")
       (expand "*")
       (expand "complement")
       (expand "phi")
       (expand "member")
       (case-replace "A!1(x!1)")
       (("1" (assert)) ("2" (assert))))
      ("3"
       (expand "nn_isf?")
       (skosimp)
       (split)
       (("1"
         (rewrite "isf_add[T, S, contraction(mu!1, A!1)]" +)
         (("1"
           (hide 2)
           (expand "isf?")
           (split)
           (("1"
             (rewrite "simple_times")
             (("1"
               (typepred "w!1")
               (expand "increasing_nn_simple?")
               (expand "nn_simple?")
               (inst - "n!1")
               (flatten))
              ("2"
               (rewrite "phi_is_simple")
               (typepred "A!1")
               (lemma "measurable_complement" ("a" "A!1"))
               (expand "measurable_set?")
               (propax))))
            ("2"
             (expand "nonzero_set?")
             (expand "*")
             (expand "complement")
             (expand "phi")
             (expand "member")
             (expand "mu_fin?")
             (expand "contraction")
             (expand "intersection")
             (expand "member")
             (case-replace
              "{x_1: T |
                           A!1(x_1) AND
                            IF NOT A!1(x_1) THEN 1 ELSE 0 ENDIF * w!1(n!1)(x_1) /= 0}=emptyset[T]")
             (("1"
               (typepred "mu!1")
               (expand "measure?")
               (flatten)
               (expand "measure_empty?")
               (replace -1)
               (assert))
              ("2"
               (hide-all-but 1)
               (apply-extensionality :hide? t)
               (expand "emptyset")
               (flatten)
               (assert))))))
          ("2"
           (hide 2)
           (typepred "u!1(n!1)")
           (lemma "contraction_isf"
            ("mu"
             "mu!1"
             "A"
             "A!1"
             "f"
             "((reals@real_fun_ops[T].*)(phi[T, S](A!1), u!1(n!1)))"))
           (("1"
             (replace -1)
             (hide -1)
             (case-replace
              "(((reals@real_fun_ops[T].*)
                              (phi[T, S](A!1),
                               ((reals@real_fun_ops[T].*)
                                    (phi[T, S](A!1), u!1(n!1))))))=((reals@real_fun_ops[T].*)
                                    (phi[T, S](A!1), u!1(n!1)))")
             (("1"
               (hide -1)
               (lemma "isf_times_simple_is_isf[T, S, mu!1]"
                ("i" "u!1(n!1)" "h" "phi[T,S](A!1)"))
               (("1"
                 (expand "*")
                 (expand "phi")
                 (expand "member")
                 (case-replace
                  "(LAMBDA (x: T): u!1(n!1)(x) * IF A!1(x) THEN 1 ELSE 0 ENDIF)=(LAMBDA (x: T): IF A!1(x) THEN 1 ELSE 0 ENDIF * u!1(n!1)(x))")
                 (apply-extensionality :hide? t)
                 (case-replace "A!1(x!1)")
                 (("1" (assert)) ("2" (assert))))
                ("2"
                 (rewrite "phi_is_simple" 1)
                 (typepred "A!1")
                 (expand "measurable_set?")
                 (propax))))
              ("2"
               (hide-all-but 1)
               (apply-extensionality :hide? t)
               (expand "*")
               (expand "phi")
               (expand "member")
               (case-replace "A!1(x!1)")
               (("1" (assert)) ("2" (assert))))))
            ("2"
             (expand "isf?")
             (hide 2)
             (flatten)
             (rewrite "simple_times")
             (rewrite "phi_is_simple")
             (typepred "A!1")
             (expand "measurable_set?")
             (propax))))))
        ("2"
         (skosimp)
         (expand "+")
         (expand "*")
         (hide-all-but 1)
         (expand "phi")
         (expand "complement")
         (expand "member")
         (case-replace "A!1(x!1)")
         (("1"
           (typepred "u!1(n!1)")
           (expand "nn_isf?")
           (inst - "x!1")
           (assert))
          ("2"
           (assert)
           (typepred "w!1")
           (expand "increasing_nn_simple?")
           (flatten)
           (expand "nn_simple?")
           (inst - "n!1")
           (flatten)
           (inst - "x!1")
           (assert))))))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (lemma "contraction_nn_integrable" ("mu" "mu!1" "A" "A!1" "f" "f!1"))
   (("1"
     (assert)
     (expand "nn_integrable?")
     (skosimp*)
     (expand "nn_integral")
     (typepred "u!2")
     (typepred "u!1")
     (lemma "choose_member"
      ("a"
       "{u: increasing_nn_isf[T, S, contraction(mu!1, A!1)] |
                             pointwise_convergence?(u, f!1)}"))
     (case "nonempty?[increasing_nn_isf[T, S, contraction(mu!1, A!1)]]
                     ({u: increasing_nn_isf[T, S, contraction(mu!1, A!1)] |
                         pointwise_convergence?[T](u, f!1)})")
     (("1"
       (name-replace "U2"
        "choose({u: increasing_nn_isf[T, S, contraction(mu!1, A!1)] |
                              pointwise_convergence?(u, f!1)})")
       (split -2)
       (("1"
         (expand "member")
         (hide -2)
         (lemma "nn_convergence[T,S,contraction(mu!1,A!1)]"
          ("u1" "u!2" "u2" "U2" "f" "f!1"))
         (replace -8)
         (replace -7)
         (replace -2)
         (flatten)
         (typepred "U2")
         (hide -4 -5 -7 -10 -11)
         (case "nonempty?({u: increasing_nn_isf[T, S, mu!1] |
                                      pointwise_convergence?(u,
                                                             ((reals@real_fun_ops
                                                               [T].*)
                                                              (phi[T, S](A!1), f!1)))})")
         (("1"
           (lemma "choose_member"
            ("a"
             "{u: increasing_nn_isf[T, S, mu!1] |
                                    pointwise_convergence?(u,
                                                           ((reals@real_fun_ops
                                                             [T].*)
                                                            (phi[T, S](A!1), f!1)))}"))
           (split -1)
           (("1"
             (name-replace "U1"
              "choose({u: increasing_nn_isf[T, S, mu!1] |
                                     pointwise_convergence?(u,
                                                            ((reals@real_fun_ops
                                                              [T].*)
                                                             (phi[T, S](A!1), f!1)))})")
             (expand "member")
             (hide -2)
             (lemma "nn_convergence[T,S,mu!1]"
              ("u1" "u!1" "u2" "U1" "f" "phi[T, S](A!1)* f!1"))
             (("1"
               (assert)
               (flatten)
               (typepred "U1")
               (hide -2 -4 -9 -10 -11)
               (lemma "nn_convergence[T,S,mu!1]"
                ("f"
                 "phi[T, S](A!1)* f!1"
                 "u1"
                 "U1"
                 "u2"
                 "lambda (n:nat): phi[T, S](A!1)*U2(n)"))
               (("1"
                 (assert)
                 (split -1)
                 (("1"
                   (flatten)
                   (replace -2)
                   (hide -1 -2 -3 -4 -5)
                   (expand "o")
                   (case "FORALL (n: nat):
                                 isf?[T, S, mu!1]
                                     (((reals@real_fun_ops[T].*)(phi[T, S](A!1), U2(n))))")
                   (("1"
                     (case-replace
                      "(LAMBDA (x: nat): isf_integral[T,S,contraction(mu!1,A!1)](U2(x)))=(LAMBDA (x: nat):
                                    isf_integral[T,S,mu!1](((reals@real_fun_ops[T].*)
                                                      (phi[T, S](A!1), U2(x)))))")
                     (hide 2)
                     (apply-extensionality :hide? t)
                     (rewrite "contraction_isf_integral"))
                    ("2"
                     (hide 2 -3)
                     (skosimp)
                     (typepred "U2(n!1)")
                     (lemma "contraction_isf"
                      ("mu" "mu!1" "A" "A!1" "f" "U2(n!1)"))
                     (assert))))
                  ("2"
                   (hide-all-but (-5 1))
                   (expand "pointwise_convergence?")
                   (skosimp)
                   (inst - "x!1")
                   (rewrite "metric_convergence_def")
                   (rewrite "metric_convergence_def")
                   (expand "metric_converges_to")
                   (skosimp)
                   (inst - "r!1")
                   (skosimp)
                   (inst + "n!1")
                   (skosimp)
                   (inst - "i!1")
                   (assert)
                   (expand "ball")
                   (expand "*")
                   (expand "phi")
                   (expand "member")
                   (case-replace "A!1(x!1)")
                   (("1" (assert))
                    ("2" (assert) (expand "abs") (assert))))))
                ("2"
                 (hide-all-but (-4 1))
                 (expand "increasing_nn_isf?")
                 (expand "pointwise_increasing?")
                 (skosimp)
                 (inst - "x!1")
                 (expand "increasing?")
                 (skolem + ("i!1" "j!1"))
                 (flatten)
                 (inst - "i!1" "j!1")
                 (assert)
                 (expand "*")
                 (expand "phi")
                 (expand "member")
                 (case-replace "A!1(x!1)")
                 (("1" (assert)) ("2" (assert))))
                ("3"
                 (hide-all-but (-4 1))
                 (skosimp)
                 (expand "nn_isf?")
                 (split)
                 (("1"
                   (typepred "U2(n!1)")
                   (lemma "contraction_isf"
                    ("mu" "mu!1" "A" "A!1" "f" "U2(n!1)"))
                   (assert))
                  ("2"
                   (hide -1)
                   (typepred "U2(n!1)")
                   (expand "nn_isf?")
                   (skosimp)
                   (inst - "x!1")
                   (hide -1)
                   (grind))))
                ("4" (hide-all-but 1) (skosimp) (grind))))
              ("2" (hide-all-but 1) (grind))))
            ("2" (expand "nonempty?") (propax))))
          ("2"
           (hide 2)
           (expand "nonempty?")
           (expand "empty?")
           (expand "member")
           (inst - "u!1"))))
        ("2" (expand "nonempty?") (propax))))
      ("2"
       (hide-all-but (-6 -7 1))
       (expand "nonempty?")
       (expand "empty?")
       (inst - "u!2")
       (expand "member")
       (propax))))
    ("2"
     (expand "nn_measurable?")
     (split)
     (("1"
       (lemma "nn_integrable_is_measurable[T,S,contraction(mu!1, A!1)]")
       (inst - "f!1"))
      ("2" (skosimp) (typepred "f!1(x!1)") (assert))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (rewrite "integrable_pm_def[T, S, contraction(mu!1, A!1)]")
   (rewrite "integrable_pm_def[T, S, mu!1]")
   (case-replace
    "plus(((reals@real_fun_ops[T].*)
                                  (phi[T, S](A!1), f!1)))=phi[T, S](A!1)*plus(f!1)")
   (("1"
     (hide -1)
     (case-replace
      "minus(((reals@real_fun_ops[T].*)
                                    (phi[T, S](A!1), f!1)))=phi[T, S](A!1)*minus(f!1)")
     (("1"
       (hide -1)
       (lemma
        "nn_integrable_is_nn_integrable[T,S,contraction(mu!1,A!1)]")
       (lemma "nn_integrable_is_nn_integrable[T,S,mu!1]")
       (split)
       (("1"
         (flatten)
         (inst-cp -4 "plus(f!1)")
         (inst -4 "minus(f!1)")
         (split -4)
         (("1"
           (split -5)
           (("1"
             (hide -3 -4)
             (lemma "contraction_nn_integrable" ("mu" "mu!1" "A" "A!1"))
             (inst-cp - "minus(f!1)")
             (("1"
               (inst - "plus(f!1)")
               (("1"
                 (assert)
                 (split)
                 (("1"
                   (rewrite "nn_integrable_is_integrable[T, S, mu!1]"))
                  ("2"
                   (rewrite "nn_integrable_is_integrable[T, S, mu!1]"))))
                ("2"
                 (hide 2)
                 (expand "nn_measurable?")
                 (hide-all-but 1)
                 (grind))))
              ("2"
               (hide 2)
               (expand "nn_measurable?")
               (hide-all-but 1)
               (grind))))
            ("2" (hide-all-but 1) (grind))))
          ("2" (hide-all-but 1) (grind))))
        ("2"
         (flatten)
         (inst-cp -3
          "((reals@real_fun_ops[T].*)
                                 (phi[T, S](A!1), plus(f!1)))")
         (split -4)
         (("1"
           (inst -4
            "((reals@real_fun_ops[T].*)
                                   (phi[T, S](A!1), minus(f!1)))")
           (split -4)
           (("1"
             (hide -3 -4)
             (lemma "contraction_nn_integrable" ("mu" "mu!1" "A" "A!1"))
             (inst-cp - "minus(f!1)")
             (("1"
               (inst - "plus(f!1)")
               (("1"
                 (assert)
                 (hide -3 -4 -5)
                 (split)
                 (("1"
                   (rewrite
                    "nn_integrable_is_integrable[T, S, contraction(mu!1, A!1)]"))
                  ("2"
                   (rewrite
                    "nn_integrable_is_integrable[T, S, contraction(mu!1, A!1)]"))))
                ("2"
                 (expand "nn_measurable?")
                 (hide-all-but 1)
                 (grind))))
              ("2" (expand "nn_measurable?") (hide-all-but 1) (grind))))
            ("2" (hide-all-but 1) (grind))))
          ("2" (hide-all-but 1) (grind))))))
      ("2"
       (hide 2)
       (apply-extensionality :hide? t)
       (("1" (grind)) ("2" (grind))))))
    ("2"
     (hide 2)
     (apply-extensionality :hide? t)
     (("1" (grind)) ("2" (grind))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (lemma "contraction_integrable" ("mu" "mu!1" "A" "A!1" "f" "f!1"))
   (assert)
   (rewrite "integral_pm[T, S, contraction(mu!1, A!1)]")
   (rewrite "integral_pm[T, S, mu!1]")
   (rewrite "integrable_pm_def[T, S, mu!1]")
   (flatten)
   (lemma "integrable_pm_def[T, S,contraction(mu!1, A!1)]" ("f0" "f!1"))
   (replace -4 -1)
   (flatten -1)
   (hide -5)
   (lemma "contraction_nn_integral" ("mu" "mu!1" "A" "A!1"))
   (rewrite "integral_nn[T, S, mu!1]")
   (("1"
     (rewrite "integral_nn[T, S, mu!1]")
     (("1"
       (rewrite "integral_nn[T, S,contraction(mu!1, A!1)]")
       (("1"
         (rewrite "integral_nn[T, S,contraction(mu!1, A!1)]")
         (("1"
           (lemma
            "nn_integrable_is_nn_integrable[T, S, contraction(mu!1, A!1)]"
            ("f" "minus(f!1)"))
           (split -1)
           (("1"
             (lemma
              "nn_integrable_is_nn_integrable[T, S, contraction(mu!1, A!1)]"
              ("f" "plus(f!1)"))
             (split -1)
             (("1"
               (hide -4 -5)
               (inst-cp - "minus(f!1)")
               (inst - "plus(f!1)")
               (replace -3)
               (replace -4)
               (hide-all-but 1)
               (case-replace
                "plus(((reals@real_fun_ops[T].*)
                                             (phi[T, S](A!1), f!1)))=phi[T, S](A!1) * plus(f!1)")
               (("1"
                 (case-replace
                  "minus(((reals@real_fun_ops[T].*)
                                               (phi[T, S](A!1), f!1)))=phi[T, S](A!1) * minus(f!1)")
                 (hide-all-but 1)
                 (grind)
                 (apply-extensionality :hide? t)
                 (("1" (grind)) ("2" (grind))))
                ("2"
                 (hide 2)
                 (apply-extensionality :hide? t)
                 (("1" (grind)) ("2" (grind))))))
              ("2" (hide-all-but 1) (grind))))
            ("2" (hide-all-but 1) (grind))))
          ("2"
           (hide-all-but (-3 1))
           (lemma
            "nn_integrable_is_nn_integrable[T, S, contraction(mu!1, A!1)]"
            ("f" "minus(f!1)"))
           (split)
           (("1" (propax)) ("2" (hide-all-but 1) (grind))))))
        ("2"
         (hide-all-but (1 -2))
         (lemma
          "nn_integrable_is_nn_integrable[T, S, contraction(mu!1, A!1)]"
          ("f" "plus(f!1)"))
         (split)
         (("1" (propax)) ("2" (hide-all-but 1) (grind))))))
      ("2"
       (hide-all-but (-5 1))
       (lemma "nn_integrable_is_nn_integrable[T, S, mu!1]"
        ("f"
         "minus(((reals@real_fun_ops[T].*)
                                      (phi[T, S](A!1), f!1)))"))
       (split)
       (("1" (propax)) ("2" (hide-all-but 1) (grind))))))
    ("2"
     (hide-all-but (-4 1))
     (lemma "nn_integrable_is_nn_integrable[T, S, mu!1]"
      ("f"
       "plus(((reals@real_fun_ops[T].*)
                                    (phi[T, S](A!1), f!1)))"))
     (split)
     (("1" (propax)) ("2" (hide-all-but 1) (grind))))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (assert)
   (lemma "measurable_intersection[T,S]")
   (inst - "A!1" "E!1")
   (expand "measurable_set?")
   (propax))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (typepred "mu!1")
   (expand "measure?")
   (flatten)
   (split)
   (("1"
     (expand "measure_empty?")
     (case-replace "intersection[T](A!1, emptyset[T])=emptyset[T]")
     (hide-all-but 1)
     (apply-extensionality :hide? t)
     (grind))
    ("2"
     (expand "measure_countably_additive?")
     (skosimp)
     (inst - "lambda (n:nat): intersection[T](A!1, X!1(n))")
     (("1"
       (expand "o")
       (name-replace "LHS"
        "x_sum(LAMBDA (x: nat): mu!1(intersection[T](A!1, X!1(x))))")
       (("1"
         (case-replace
          "IUnion(LAMBDA (n: nat): intersection[T](A!1, X!1(n)))=intersection[T](A!1, IUnion(X!1))")
         (hide -1)
         (assert)
         (hide 1 -2)
         (lemma "measurable_intersection[T,S]"
          ("a" "A!1" "b" "IUnion(X!1)"))
         (("1"
           (expand "measurable_set?")
           (case-replace
            "IUnion(LAMBDA (n: nat): intersection[T](A!1, X!1(n)))=intersection[T](A!1, IUnion(X!1))")
           (hide-all-but 1)
           (apply-extensionality :hide? t)
           (expand "intersection")
           (expand "IUnion")
           (expand "member")
           (case-replace "A!1(x!1)")
           (assert))
          ("2" (expand "measurable_set?") (propax))))
        ("2"
         (hide-all-but 1)
         (skosimp)
         (lemma "measurable_intersection[T,S]"
          ("a" "A!1" "b" "X!1(x!1)"))
         (("1" (expand "measurable_set?") (propax))
          ("2" (expand "measurable_set?") (propax))))))
      ("2"
       (hide-all-but 1)
       (typepred "X!1")
       (expand "disjoint_indexed_measurable?")
       (expand "disjoint?")
       (expand "disjoint?")
       (expand "intersection")
       (expand "empty?")
       (expand "member")
       (skosimp)
       (skosimp)
       (inst - "i!1" "j!1")
       (assert)
       (inst - "x!1")
       (assert))
      ("3"
       (hide-all-but 1)
       (skosimp)
       (lemma "measurable_intersection[T,S]" ("a" "A!1" "b" "X!1(n!1)"))
       (("1" (expand "measurable_set?") (propax))
        ("2" (expand "measurable_set?") (propax))))))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (lemma "contraction_TCC3" ("mu" "mu!1" "A" "A!1"))
   (typepred "A!1")
   (typepred "mu!1")
   (lemma "measure_monotone" ("f" "mu!1" "b" "A!1"))
   (replace -2)
   (expand "x_le")
   (expand "finite_measure?")
   (expand "measure?" -5)
   (hide -2)
   (flatten)
   (split)
   (("1" (expand "measure_empty?") (replace -4) (assert))
    ("2"
     (skosimp)
     (typepred "X!1")
     (expand "measure_countably_additive?")
     (inst -6 "X!1")
     (expand "o ")
     (expand "x_eq")
     (flatten)
     (hide -5)
     (inst-cp - "intersection[T](A!1, IUnion(X!1))")
     (split -3)
     (("1"
       (flatten)
       (replace -1)
       (replace -7)
       (replace -8 1 rl)
       (hide -8)
       (expand "x_sum")
       (case-replace
        "FORALL (i:nat): mu!1(intersection[T](A!1, X!1(i)))`1")
       (("1"
         (lift-if 1)
         (prop)
         (rewrite "limit_lemma")
         (hide-all-but (-6 -8 1))
         (skolem + "i!1")
         (lemma "measurable_intersection" ("a" "A!1" "b" "X!1(i!1)"))
         (("1" (expand "measurable_set?") (propax))
          ("2" (expand "measurable_set?") (propax))))
        ("2" (replace 1) (propax))
        ("3"
         (skosimp)
         (hide-all-but (-5 1 -3))
         (expand "disjoint_indexed_measurable?")
         (expand "measurable_set?")
         (lemma "measurable_intersection" ("a" "A!1" "b" "X!1(i!1)"))
         (("1" (assert) (expand "measurable_set?") (propax))
          ("2" (expand "measurable_set?") (propax))))))
      ("2" (hide-all-but 1) (grind))))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "measurable_set?")
   (lemma "A_of_TCC1" ("f" "nu!1"))
   (lemma "choose_member"
    ("a"
     "{X: disjoint_indexed_measurable[T, S] |
                   IUnion[nat, T](X) = fullset[T] AND (FORALL i: nu!1(X(i))`1)}"))
   (split)
   (("1"
     (expand "member")
     (flatten)
     (inst - "i!1")
     (expand "A_of")
     (propax))
    ("2" (expand "nonempty?") (propax))))


proof_type: j_proof
decl_type: tcc
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (typepred "nu!1")
   (expand "sigma_finite_measure?")
   (flatten)
   (expand "measure_sigma_finite?")
   (skosimp)
   (inst + "X!1")
   (replace -2)
   (skosimp)
   (inst - "i!1")
   (expand "contraction")
   (lemma "m_monotone[T,S,nu!1]"
    ("a" "intersection(A!1, X!1(i!1))" "b" "X!1(i!1)"))
   (("1"
     (expand "x_le")
     (assert)
     (hide-all-but 1)
     (expand "intersection")
     (expand "subset?")
     (expand "member")
     (skosimp))
    ("2" (expand "measurable_set?") (propax))
    ("3"
     (expand "measurable_set?")
     (typepred "A!1")
     (typepred "X!1(i!1)")
     (lemma "measurable_intersection" ("a" "A!1" "b" "X!1(i!1)"))
     (("1" (expand "measurable_set?") (propax))
      ("2" (expand "measurable_set?") (propax))))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (rewrite "contraction_isf")
   (expand "isf?")
   (expand "simple?")
   (propax))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (skosimp)
   (typepred "f!1")
   (expand "nn_measurable?")
   (flatten)
   (inst - "x1!1")
   (assert))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (skosimp)
   (typepred "f!1")
   (expand "nn_measurable?")
   (flatten)
   (inst - "x1!1")
   (hide -1)
   (grind))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1" (grind))
    ("2"
     (typepred "f!1")
     (rewrite "contraction_nn_integrable")
     (hide 2)
     (expand "nn_measurable?")
     (split)
     (("1"
       (lemma
        "nn_integrable_is_measurable[T, S, contraction(mu!1, A!1)]")
       (inst - "f!1"))
      ("2" (skosimp) (hide -1) (grind))))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: measure_contraction
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (rewrite "contraction_integrable")
   (hide 2)
   (rewrite "integrable_is_measurable[T, S, contraction(mu!1, A!1)]"))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: measure_contraction_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (split)
   (("1"
     (flatten)
     (case-replace
      "FORALL n: integrable?[T, S, contraction(mu, A!1(n))](h!1)")
     (("1"
       (lemma "indefinite_countably_additive[T, S, mu]"
        ("DX" "A!1" "f" "h!1"))
       (("1"
         (replace -4)
         (rewrite "indefinite_fullset[T, S, mu]")
         (case-replace
          "(LAMBDA n:
                                     integral[T, S, contraction(mu, A!1(n))](h!1))=LAMBDA n: integral[T, S, mu](A!1(n), h!1)")
         (("1"
           (hide -1)
           (expand "convergent?")
           (inst + "integral[T, S, mu](h!1)"))
          ("2"
           (apply-extensionality :hide? t)
           (("1"
             (expand "integral" 1 2)
             (inst - "x!1")
             (rewrite "contraction_integral" 1)
             (expand "measurable_set?")
             (propax))
            ("2"
             (skosimp)
             (expand "integrable?" 1)
             (rewrite "indefinite_integrable[T, S, mu]")
             (expand "measurable_set?")
             (propax))
            ("3" (expand "measurable_set?") (propax))))
          ("3"
           (skosimp)
           (expand "integrable?" 1)
           (rewrite "indefinite_integrable[T, S, mu]")
           (expand "measurable_set?")
           (propax))
          ("4" (expand "measurable_set?") (propax))))
        ("2" (propax))))
      ("2"
       (skosimp)
       (rewrite "contraction_integrable" 1)
       (("1"
         (rewrite "indefinite_integrable[T, S, mu]")
         (expand "measurable_set?")
         (propax))
        ("2" (expand "measurable_set?") (propax))))
      ("3" (expand "measurable_set?") (propax))))
    ("2"
     (flatten)
     (name "F" "lambda n: *[T](phi(IUnion(n,A!1)),h!1)")
     (case "forall n: integrable?[T, S, mu](F(n))")
     (("1"
       (case "pointwise_converges_upto?(F,h!1)")
       (("1"
         (lemma "monotone_convergence_scaf[T, S, mu]"
          ("f" "h!1" "F" "F"))
         (("1"
           (replace -2 -1)
           (replace 1 -1)
           (hide 2)
           (expand "bounded?")
           (split)
           (("1"
             (expand "convergent?")
             (skosimp)
             (expand "bounded_above?")
             (inst + "l!1")
             (skolem + "n!1")
             (expand "o ")
             (expand "pointwise_converges_upto?")
             (flatten)
             (case-replace
              "series(LAMBDA n:
                                          integral[T, S, contraction(mu, A!1(n))](h!1))=integral[T,S,mu] o F")
             (("1"
               (hide -1)
               (hide-all-but (-2 -6 1 -3))
               (rewrite "metric_convergence_def")
               (expand "metric_converges_to")
               (inst-cp - "n!1")
               (inst -4 "integral[T, S, mu](F(n!1))-l!1")
               (("1"
                 (skosimp)
                 (inst - "n!1+n!2")
                 (inst - "n!1+n!2")
                 (assert)
                 (expand "ball")
                 (expand "o ")
                 (expand "pointwise_increasing?")
                 (lemma "integral_ae_le[T, S, mu]"
                  ("f1" "F(n!1)" "f2" "F(n!1 + n!2)"))
                 (split)
                 (("1" (assert))
                  ("2"
                   (hide-all-but (-1 1))
                   (expand "ae_le?")
                   (expand "pointwise_ae?")
                   (expand "ae?")
                   (expand "fullset")
                   (expand "ae_in?")
                   (inst + "emptyset")
                   (("1"
                     (skosimp)
                     (expand "member")
                     (inst - "x!1")
                     (expand "increasing?")
                     (inst - "n!1" "n!1+n!2")
                     (assert))
                    ("2"
                     (expand "negligible_set?")
                     (inst + "emptyset[T]")
                     (expand "null_set?")
                     (expand "mu_fin?")
                     (expand "mu")
                     (typepred "mu")
                     (expand "measure?")
                     (flatten)
                     (expand "measure_empty?")
                     (replace -1)
                     (assert)
                     (expand "subset?")
                     (skosimp))))))
                ("2" (assert))))
              ("2"
               (hide -6 2)
               (case "forall n: series(LAMBDA n: integral[T, S, contraction(mu, A!1(n))](h!1))(n) =
                            integral[T, S, mu](F(n))")
               (("1"
                 (rewrite "extensionality_postulate" -1)
                 (assert)
                 (expand "o ")
                 (replace -1 1 rl)
                 (assert)
                 (apply-extensionality :hide? t)
                 (expand "measurable_set?")
                 (propax))
                ("2"
                 (hide -1 -2 2 -4)
                 (induct "n")
                 (("1"
                   (expand "series")
                   (expand "sigma")
                   (assert)
                   (inst - "n!1")
                   (inst - "n!1")
                   (rewrite "contraction_integral" +)
                   (("1" (expand "F") (rewrite "IUnion_0_def"))
                    ("2" (expand "measurable_set?") (propax))))
                  ("2"
                   (skosimp)
                   (expand "series")
                   (expand "sigma" 1)
                   (replace -1)
                   (hide -1)
                   (inst -2 "1+j!1")
                   (rewrite "contraction_integral")
                   (("1"
                     (case-replace
                      "F(1 + j!1)=+[T](*[T](phi[T,S](A!1(1 + j!1)), h!1),F(j!1))")
                     (("1" (rewrite "integral_add[T,S,mu]") (assert))
                      ("2"
                       (hide 2 -1 -2)
                       (apply-extensionality :hide? t)
                       (expand "+")
                       (expand "F")
                       (expand "*")
                       (case-replace
                        "phi(IUnion(1 + j!1, A!1))(x!1)=phi[T, S](A!1(1 + j!1))(x!1)+phi(IUnion(j!1, A!1))(x!1)")
                       (("1" (assert))
                        ("2"
                         (hide -2 2)
                         (expand "phi")
                         (expand "member")
                         (hide -1)
                         (rewrite "IUnion_n_def")
                         (expand "union")
                         (expand "member")
                         (case-replace "IUnion(j!1, A!1)(x!1)")
                         (("1"
                           (case-replace "A!1(1 + j!1)(x!1)")
                           (("1"
                             (hide 1)
                             (typepred "A!1")
                             (expand "disjoint_indexed_measurable?")
                             (expand "disjoint?")
                             (expand "IUnion")
                             (expand "image")
                             (expand "Union")
                             (skosimp)
                             (typepred "a!1")
                             (skolem - "k!1")
                             (inst - "k!1" "1+j!1")
                             (assert)
                             (expand "disjoint?")
                             (expand "empty?")
                             (inst - "x!1")
                             (grind))
                            ("2" (assert))))
                          ("2" (assert))))))))
                    ("2" (expand "measurable_set?") (propax))))
                  ("3" (expand "measurable_set?") (propax))))
                ("3" (expand "measurable_set?") (propax))
                ("4" (propax))))
              ("3" (expand "measurable_set?") (propax))))
            ("2"
             (expand "bounded_below?")
             (inst + "0")
             (skolem + "n!1")
             (expand "o ")
             (inst - "n!1")
             (lemma "integral_nonneg[T, S, mu]" ("f" "F(n!1)"))
             (assert)
             (skosimp)
             (hide-all-but (1 -7))
             (inst - "x!1")
             (expand "F")
             (expand "*")
             (expand "phi")
             (lift-if)
             (assert))))
          ("2" (propax))))
        ("2"
         (hide 2)
         (expand "pointwise_converges_upto?")
         (split)
         (("1"
           (expand "pointwise_convergence?")
           (skosimp)
           (hide -4)
           (rewrite "metric_convergence_def")
           (expand "metric_converges_to")
           (skosimp)
           (expand "ball")
           (expand "member")
           (hide-all-but (-4 -5 1))
           (expand "F")
           (expand "*")
           (expand "phi")
           (expand "member")
           (expand "fullset")
           (rewrite "extensionality_postulate" -1 :dir rl)
           (inst - "x!1")
           (expand "IUnion" -1)
           (skolem - "n!1")
           (inst + "n!1")
           (skosimp)
           (case-replace "IUnion(i!1, A!1)(x!1)")
           (("1" (expand "abs") (assert))
            ("2"
             (hide 2)
             (expand "IUnion")
             (expand "image")
             (expand "Union")
             (inst + "A!1(n!1)")
             (inst + "n!1")
             (assert))))
          ("2"
           (expand "pointwise_increasing?")
           (skosimp)
           (expand "increasing?")
           (skolem + ("i!1" "j!1"))
           (flatten)
           (hide-all-but (-7 -6 -1 1))
           (expand "F")
           (expand "*")
           (expand "phi")
           (expand "member")
           (inst - "x!1")
           (case-replace "IUnion(i!1, A!1)(x!1)")
           (("1"
             (case-replace "IUnion(j!1, A!1)(x!1)")
             (("1" (assert))
              ("2"
               (hide 2 -3)
               (expand "IUnion")
               (expand "image")
               (expand "Union")
               (skosimp)
               (inst + "a!1")
               (typepred "a!1")
               (skosimp)
               (inst + "x!2")
               (assert))))
            ("2" (assert) (lift-if 2) (assert))))))))
      ("2"
       (replace -1 1 rl)
       (hide -3 -1 2)
       (induct "n")
       (("1"
         (rewrite "IUnion_0_def")
         (inst - "0")
         (rewrite "contraction_integrable")
         (expand "measurable_set?")
         (propax))
        ("2"
         (skosimp)
         (rewrite "IUnion_n_def")
         (inst - "1+j!1")
         (rewrite "contraction_integrable" -2)
         (("1"
           (case-replace
            "(*[T](phi(union(IUnion(j!1, A!1), A!1(1 + j!1))), h!1))=+[T]((*[T](phi(IUnion(j!1, A!1)), h!1)),*[T](phi[T, S](A!1(1 + j!1)), h!1))")
           (("1" (hide -1) (rewrite "integrable_add[T, S, mu]" 1))
            ("2"
             (hide 2 -1 -2 -4)
             (expand "fullset")
             (rewrite "extensionality_postulate" -1 :dir rl)
             (apply-extensionality :hide? t)
             (expand "*")
             (expand "+")
             (expand "phi")
             (expand "union")
             (expand "member")
             (case-replace "IUnion(j!1, A!1)(x!1)")
             (("1"
               (expand "IUnion" -1)
               (expand "image")
               (expand "Union")
               (skosimp)
               (typepred "a!1")
               (skolem - "n!1")
               (replace -1)
               (hide -1 -3)
               (typepred "n!1")
               (typepred "A!1")
               (expand "disjoint_indexed_measurable?")
               (expand "disjoint?")
               (inst - "n!1" "1+j!1")
               (assert)
               (expand "disjoint?")
               (expand "intersection")
               (expand "empty?")
               (inst - "x!1")
               (expand "member")
               (assert))
              ("2" (assert))))))
          ("2" (expand "measurable_set?") (propax))))))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: sigma_finite_measure_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "contraction_integrable_def[T, S, mu]"
    ("h" "h!1" "A" "A_of(mu)"))
   (rewrite "A_of_def1")
   (typepred "h!1")
   (expand "nn_measurable?")
   (flatten)
   (expand ">=" -3)
   (replace -2)
   (replace -3 1 rl)
   (assert))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: sigma_finite_measure_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "indefinite_countably_additive[T, S, mu]"
    ("f" "f!1" "DX" "A_of(mu)"))
   (rewrite "A_of_def1" -1)
   (rewrite "indefinite_fullset[T, S, mu]")
   (case-replace
    "(LAMBDA n:
                                integral[T, S, contraction(mu, A_of(mu)(n))]
                                    (f!1))=LAMBDA n: integral[T,S,mu](A_of(mu)(n), f!1)")
   (("1"
     (apply-extensionality :hide? t)
     (("1"
       (hide 2)
       (rewrite "contraction_integral")
       (expand "integral" 1 2)
       (propax))
      ("2"
       (hide-all-but 1)
       (typepred "f!1")
       (skosimp)
       (lemma "nn_integrable_is_integrable[T, S, mu]")
       (inst - "f!1")
       (expand "integrable?" 1)
       (rewrite "indefinite_integrable[T, S, mu]")
       (expand "measurable_set?")
       (propax))
      ("3" (expand "measurable_set?") (propax))
      ("4"
       (skosimp)
       (hide-all-but 1)
       (typepred "f!1")
       (lemma "nn_integrable_is_integrable[T, S, mu]")
       (inst - "f!1")
       (rewrite "contraction_integrable")
       (("1"
         (rewrite "indefinite_integrable[T, S, mu]")
         (expand "measurable_set?")
         (propax))
        ("2" (expand "measurable_set?") (propax))))))
    ("2"
     (hide-all-but 1)
     (typepred "f!1")
     (skosimp)
     (expand "integrable?")
     (rewrite "indefinite_integrable[T, S, mu]")
     (expand "measurable_set?")
     (propax))
    ("3" (expand "measurable_set?") (propax))
    ("4"
     (hide-all-but 1)
     (typepred "f!1")
     (skosimp)
     (lemma "nn_integrable_is_integrable[T, S, mu]")
     (inst - "f!1")
     (rewrite "contraction_integrable" 1)
     (("1"
       (rewrite "indefinite_integrable[T, S, mu]")
       (expand "measurable_set?")
       (propax))
      ("2" (expand "measurable_set?") (propax))))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: sigma_finite_measure_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (skosimp)
   (expand "fm_contraction")
   (expand "contraction")
   (expand "to_measure")
   (expand "x_eq")
   (lemma "A_of_def2" ("n" "n!1" "mu" "mu"))
   (lemma "m_monotone[T,S,mu]"
    ("a" "intersection(A_of(mu)(n!1), A!1)" "b" "A_of(mu)(n!1)"))
   (("1"
     (assert)
     (expand "x_le")
     (expand "subset?")
     (expand "intersection")
     (expand "member")
     (skosimp))
    ("2" (expand "measurable_set?") (propax))
    ("3" (expand "measurable_set?") (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: sigma_finite_measure_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (case "forall n: integrable?[T, S, mu](*[T](phi(P_of(mu)(n)),F!1(n)))")
   (("1"
     (case "forall n: integral[T, S, contraction(mu, P_of(mu)(n))](F!1(n)) = integral[T, S, mu](*[T](phi(P_of(mu)(n)), F!1(n)))")
     (("1"
       (name "G" "lambda n: *[T](phi(P_of(mu)(n)), F!1(n))")
       (hide -1)
       (case "forall n: integrable?[T, S, mu](G(n))")
       (("1"
         (case "FORALL n:
                       integral[T, S, contraction(mu, P_of(mu)(n))](F!1(n)) =
                        integral[T, S, mu](G(n))")
         (("1"
           (case-replace
            "(LAMBDA n:
                                integral[T, S, contraction(mu, P_of(mu)(n))](F!1(n)))=integral o G")
           (("1"
             (hide -1)
             (case "ae_increasing?(G)")
             (("1"
               (case "forall g: ae_convergence?(F!1,g) <=> ae_convergence?(G, g)")
               (("1"
                 (hide-all-but (-1 -2 -4 1))
                 (lemma "monotone_convergence" ("F" "G"))
                 (replace -3)
                 (case-replace
                  "((EXISTS g: ae_convergence?(F!1, g)) <=> bounded?(integral o G))")
                 (("1"
                   (expand "bounded?" 1)
                   (skosimp)
                   (inst -5 "g!1")
                   (assert)
                   (inst -5 "g!1")
                   (assert))
                  ("2"
                   (flatten)
                   (hide -3 2)
                   (split 1)
                   (("1"
                     (skosimp*)
                     (split -2)
                     (("1"
                       (name-replace "DRL1" "integral o G")
                       (hide-all-but (-1 1))
                       (expand "bounded?")
                       (expand "bounded_above?")
                       (expand "bounded_below?")
                       (flatten)
                       (skosimp*)
                       (inst + "max(1,max(a!1,-a!2))")
                       (("1"
                         (skosimp)
                         (inst - "x!1")
                         (inst - "x!1")
                         (grind))
                        ("2" (grind))))
                      ("2" (inst + "g!1") (inst -3 "g!1") (assert))))
                    ("2"
                     (flatten)
                     (hide -2)
                     (split -2)
                     (("1"
                       (skosimp)
                       (inst + "f!1")
                       (inst - "f!1")
                       (assert))
                      ("2"
                       (hide-all-but (-1 1))
                       (name-replace "DRL1" "integral o G")
                       (expand "bounded?")
                       (skosimp)
                       (typepred "c!1")
                       (split)
                       (("1"
                         (expand "bounded_above?")
                         (inst + "c!1")
                         (skosimp)
                         (inst - "x!1")
                         (grind))
                        ("2"
                         (expand "bounded_below?")
                         (inst + "-c!1")
                         (skosimp)
                         (inst - "x!1")
                         (grind))))))))))
                ("2"
                 (hide-all-but (1 -6 -1 -7))
                 (skosimp)
                 (split)
                 (("1"
                   (flatten)
                   (hide -3 -2)
                   (expand "ae_convergence?")
                   (expand "fullset")
                   (expand "ae_convergence_in?")
                   (expand "ae_in?")
                   (skosimp)
                   (inst + "E!1")
                   (skosimp)
                   (inst - "x!1")
                   (expand "member")
                   (assert)
                   (expand "G")
                   (expand "*")
                   (expand "phi")
                   (expand "member")
                   (rewrite "metric_convergence_def")
                   (rewrite "metric_convergence_def")
                   (expand "metric_converges_to")
                   (skosimp)
                   (inst - "r!1")
                   (skosimp)
                   (expand "ball")
                   (expand "member")
                   (lemma "P_of_def1" ("mu" "mu"))
                   (expand "fullset")
                   (rewrite "extensionality_postulate" -1 :dir rl)
                   (inst - "x!1")
                   (expand "IUnion")
                   (skolem - "k!1")
                   (inst + "n!1+k!1")
                   (skosimp)
                   (inst - "i!1")
                   (lemma "P_of_def3" ("mu" "mu" "i" "k!1" "j" "i!1"))
                   (expand "subset?")
                   (assert)
                   (inst - "x!1")
                   (assert))
                  ("2"
                   (flatten)
                   (expand "ae_convergence?")
                   (hide -2)
                   (expand "ae_increasing?")
                   (expand "fullset")
                   (expand "ae_convergence_in?")
                   (expand "ae_in?")
                   (skosimp*)
                   (inst + "union(E!1,E!2)")
                   (skosimp)
                   (inst - "x!1")
                   (inst - "x!1")
                   (expand "union")
                   (expand "member")
                   (flatten)
                   (assert)
                   (rewrite "metric_convergence_def")
                   (rewrite "metric_convergence_def")
                   (hide 1 2)
                   (expand "metric_converges_to")
                   (skosimp)
                   (inst - "r!1")
                   (skosimp)
                   (expand "ball")
                   (expand "member")
                   (expand "G")
                   (expand "*")
                   (expand "phi")
                   (expand "member")
                   (lemma "P_of_def1" ("mu" "mu"))
                   (expand "fullset")
                   (rewrite "extensionality_postulate" -1 :dir rl)
                   (inst - "x!1")
                   (expand "IUnion")
                   (skolem - "k!1")
                   (inst + "n!1+k!1")
                   (skosimp)
                   (inst - "i!1")
                   (lemma "P_of_def3" ("mu" "mu" "i" "k!1" "j" "i!1"))
                   (expand "subset?")
                   (assert)
                   (inst - "x!1")
                   (assert))))))
              ("2"
               (hide-all-but (-5 -6 1))
               (expand "ae_increasing?")
               (skosimp)
               (inst + "E!1")
               (skosimp)
               (inst - "x!1")
               (expand "G")
               (expand "*")
               (expand "phi")
               (assert)
               (skosimp)
               (inst - "i!1" "j!1")
               (assert)
               (lemma "P_of_def3" ("mu" "mu" "i" "i!1" "j" "j!1"))
               (assert)
               (expand "subset?")
               (inst - "x!1")
               (expand "member")
               (inst - "j!1" "x!1")
               (case-replace "P_of(mu)(i!1)(x!1)")
               (("1" (assert)) ("2" (assert) (lift-if 3) (assert))))))
            ("2"
             (hide 2)
             (apply-extensionality :hide? t)
             (("1" (inst - "x!1") (expand "o ") (propax))
              ("2" (expand "measurable_set?") (propax))))))
          ("2" (expand "G") (propax)) ("3" (propax))))
        ("2" (expand "G") (propax))))
      ("2"
       (hide 2)
       (skosimp)
       (inst - "n!1")
       (inst - "n!1")
       (lemma "contraction_integral[T,S]"
        ("f" "F!1(n!1)" "mu" "mu" "A" "P_of(mu)(n!1)"))
       (("1" (propax)) ("2" (expand "measurable_set?") (propax))))
      ("3" (propax)) ("4" (expand "measurable_set?") (propax))
      ("5" (propax))))
    ("2"
     (hide-all-but (-3 1))
     (skosimp)
     (inst - "n!1")
     (lemma "contraction_integrable[T,S]"
      ("mu"
       "mu"
       "A"
       "P_of(mu)(n!1)"
       "f"
       "*[T](phi(P_of(mu)(n!1)), F!1(n!1))"))
     (("1"
       (assert)
       (lemma
        "indefinite_integrable[T, S, contraction(mu, P_of(mu)(n!1))]"
        ("E" "P_of(mu)(n!1)" "f" "F!1(n!1)"))
       (replace -1 -2)
       (flatten)
       (case-replace
        "(((reals@real_fun_ops[T].*)
                        (phi[T, S](P_of(mu)(n!1)),
                         *[T](phi(P_of(mu)(n!1)), F!1(n!1)))))=((*[T](phi(P_of(mu)(n!1)), F!1(n!1))))")
       (apply-extensionality :hide? t)
       (expand "*")
       (expand "phi")
       (expand "member")
       (lift-if 1)
       (assert))
      ("2"
       (hide 2)
       (lemma
        "integrable_is_measurable[T, S, contraction(mu, P_of(mu)(n!1))]")
       (("1"
         (inst - "F!1(n!1)")
         (lemma "phi_is_simple" ("X" "P_of[T, S](mu)(n!1)"))
         (expand "simple?")
         (flatten)
         (rewrite "prod_measurable"))
        ("2" (expand "measurable_set?") (propax))))
      ("3" (expand "measurable_set?") (propax))))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: sigma_finite_measure_props
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "f!1")
   (rewrite "contraction_integrable")
   (("1"
     (rewrite "indefinite_integrable[T, S, mu]")
     (expand "measurable_set?")
     (propax))
    ("2" (expand "measurable_set?") (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "null_integrable1")
   (case "nonempty?({(N1,f) |
                          FORALL x:
                            NOT member(x, N1) =>
                             integrable?(LAMBDA y: h1!1(x, y)) AND
                              integral(LAMBDA y: h1!1(x, y)) = f(x)})")
   (("1"
     (lemma "choose_member"
      ("a"
       "{(N1,f) |
                        FORALL x:
                          NOT member(x, N1) =>
                           integrable?(LAMBDA y: h1!1(x, y)) AND
                            integral(LAMBDA y: h1!1(x, y)) = f(x)}"))
     (expand "nonempty?")
     (assert)
     (replace -2 -1 rl)
     (hide -2 1)
     (inst - "x!1")
     (assert))
    ("2"
     (hide-all-but 1)
     (typepred "h1!1")
     (expand "nonempty?")
     (expand "integrable1?")
     (skosimp)
     (expand "empty?")
     (inst -2 "(N1!2,f!2)")
     (expand "member")
     (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "null_integrable2")
   (case "nonempty?({(N2,g) |
                          FORALL y:
                            NOT member(y, N2) =>
                             integrable?(LAMBDA x: h2!1(x, y)) AND
                              integral(LAMBDA x: h2!1(x, y)) = g(y)})")
   (("1"
     (lemma "choose_member"
      ("a"
       "{(N2,g) |
                          FORALL y:
                            NOT member(y, N2) =>
                             integrable?(LAMBDA x: h2!1(x, y)) AND
                              integral(LAMBDA x: h2!1(x, y)) = g(y)}"))
     (expand "nonempty?")
     (assert)
     (replace -2 * rl)
     (inst - "y!1")
     (assert))
    ("2"
     (hide-all-but 1)
     (typepred "h2!1")
     (expand "integrable2?")
     (skosimp)
     (expand "nonempty?")
     (expand "empty?")
     (inst -2 "(N2!2,g!2)")
     (expand "member")
     (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (apply-extensionality :hide? t)
   (("1"
     (expand "integral1")
     (expand "member")
     (lemma "null_integral1_def" ("h1" "LAMBDA x, y: 0"))
     (("1"
       (inst - "null_integrable1(LAMBDA x, y: 0)`1"
        "null_integrable1(LAMBDA x, y: 0)`2" "x!1")
       (("1"
         (expand "member")
         (case-replace "null_integrable1(LAMBDA x, y: 0)`1(x!1)")
         (assert)
         (split)
         (("1" (flatten) (rewrite "integral_zero") (assert))
          ("2"
           (assert)
           (decompose-equality)
           (rewrite "integrable1_zero"))))
        ("2" (rewrite "integrable1_zero"))))
      ("2" (rewrite "integrable1_zero"))))
    ("2" (rewrite "integrable1_zero"))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "ae_eq?")
   (expand "restrict")
   (expand "pointwise_ae?")
   (expand "ae?")
   (expand "fullset")
   (expand "ae_in?")
   (expand "member")
   (expand "integral1")
   (expand "member")
   (name "NN3" "null_integrable1(h1!1)`1")
   (name "NN2" "null_integrable1(g1!1)`1")
   (name "NN1" "null_integrable1(g1!1+h1!1)`1")
   (inst + "union(NN1,union(NN2,NN3))")
   (skosimp)
   (expand "union")
   (expand "member")
   (flatten)
   (replace -1)
   (replace -2)
   (replace -3)
   (expand "+" 4 2)
   (assert)
   (name "FF3" "null_integrable1(h1!1)`2")
   (name "FF2" "null_integrable1(g1!1)`2")
   (name "FF1" "null_integrable1(g1!1+h1!1)`2")
   (replace -1)
   (replace -2)
   (replace -3)
   (lemma "null_integral1_def"
    ("h1" "h1!1" "f" "FF3" "N1" "NN3" "x" "x!1"))
   (assert)
   (flatten)
   (lemma "null_integral1_def"
    ("h1" "g1!1" "f" "FF2" "N1" "NN2" "x" "x!1"))
   (assert)
   (flatten)
   (lemma "null_integral1_def"
    ("h1" "g1!1+h1!1" "f" "FF1" "N1" "NN1" "x" "x!1"))
   (assert)
   (flatten)
   (replace -2 * rl)
   (replace -4 * rl)
   (replace -6 * rl)
   (lemma "integral_add[T2,S2,nu]"
    ("f1" "LAMBDA y: g1!1(x!1, y)" "f2" "LAMBDA y: h1!1(x!1, y)"))
   (expand "+" 4)
   (expand "+" -1)
   (propax))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "h1!1")
   (lemma "integrable1_scal" ("c" "c!1" "h1" "h1!1"))
   (expand "integral1")
   (expand "member")
   (name "NN2" "null_integrable1(c!1 * h1!1)`1")
   (name "NN1" "null_integrable1(h1!1)`1")
   (replace -1)
   (replace -2)
   (name "FF2" "null_integrable1(c!1 * h1!1)`2")
   (name "FF1" "null_integrable1(h1!1)`2")
   (replace -1)
   (replace -2)
   (expand "ae_eq?")
   (expand "restrict")
   (expand "pointwise_ae?")
   (expand "ae?")
   (expand "fullset")
   (expand "ae_in?")
   (expand "member")
   (inst + "union(NN1,NN2)")
   (skosimp)
   (expand "union")
   (expand "member")
   (flatten)
   (expand "*" 3)
   (assert)
   (lemma "null_integral1_def"
    ("h1" "h1!1" "N1" "NN1" "f" "FF1" "x" "x!1"))
   (assert)
   (flatten)
   (lemma "null_integral1_def"
    ("h1" "c!1*h1!1" "N1" "NN2" "f" "FF2" "x" "x!1"))
   (assert)
   (flatten)
   (replace -2 3 rl)
   (replace -4 3 rl)
   (expand "*" 3)
   (lemma "integral_scal[T2,S2,nu]"
    ("c" "c!1" "f" "LAMBDA y: h1!1(x!1, y)"))
   (expand "*")
   (propax))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral1_scal" ("c" "-1" "h1" "h1!1"))
   (case-replace "-1 * h1!1=-h1!1")
   (("1" (assert) (expand "-") (expand "*") (assert))
    ("2" (hide-all-but 1) (apply-extensionality :hide? t) (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral1_opp" ("h1" "h1!1"))
   (lemma "integral1_add" ("g1" "g1!1" "h1" "-h1!1"))
   (lemma "ae_eq_equivalence[T1,S1,mu]")
   (expand "equivalence?")
   (expand "transitive?")
   (flatten)
   (case-replace "g1!1 + -h1!1=g1!1 - h1!1")
   (("1"
     (hide -1)
     (name-replace "LHS" "integral1(g1!1 - h1!1)")
     (inst - "LHS" "integral1(g1!1) + integral1(-h1!1)"
      "integral1(g1!1) - integral1(h1!1)")
     (assert)
     (hide-all-but (1 -4))
     (expand "ae_eq?")
     (expand "restrict")
     (expand "pointwise_ae?")
     (expand "ae?")
     (expand "fullset")
     (expand "ae_in?")
     (skosimp)
     (inst + "E!1")
     (skosimp)
     (inst - "x!1")
     (assert)
     (expand "+")
     (expand "-")
     (assert))
    ("2" (hide-all-but 1) (apply-extensionality :hide? t) (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (lemma "integrable2_zero")
   (apply-extensionality :hide? t)
   (expand "integral2")
   (expand "member")
   (lift-if)
   (prop)
   (lemma "null_integral2_def"
    ("N2"
     "null_integrable2(LAMBDA x, y: 0)`1"
     "g"
     "null_integrable2(LAMBDA x, y: 0)`2"
     "h2"
     "LAMBDA x, y: 0"
     "y"
     "x!1"))
   (assert)
   (split)
   (("1" (flatten) (rewrite "integral_zero") (assert))
    ("2" (decompose-equality))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (expand "ae_eq?")
   (expand "restrict")
   (expand "pointwise_ae?")
   (expand "ae?")
   (expand "fullset")
   (expand "ae_in?")
   (expand "member")
   (expand "+" 1 2)
   (expand "integral2")
   (expand "member")
   (name "NN3" "null_integrable2(h2!1)`1")
   (name "NN2" "null_integrable2(g2!1)`1")
   (name "NN1" "null_integrable2(g2!1+h2!1)`1")
   (replace -1)
   (replace -2)
   (replace -3)
   (name "GG3" "null_integrable2(h2!1)`2")
   (name "GG2" "null_integrable2(g2!1)`2")
   (name "GG1" "null_integrable2(g2!1+h2!1)`2")
   (replace -1)
   (replace -2)
   (replace -3)
   (inst + "union(NN1,union(NN2,NN3))")
   (skosimp)
   (expand "union")
   (expand "member")
   (flatten)
   (assert)
   (lemma "null_integral2_def"
    ("h2" "h2!1" "N2" "NN3" "g" "GG3" "y" "x!1"))
   (lemma "null_integral2_def"
    ("h2" "g2!1" "N2" "NN2" "g" "GG2" "y" "x!1"))
   (lemma "null_integral2_def"
    ("h2" "g2!1+h2!1" "N2" "NN1" "g" "GG1" "y" "x!1"))
   (assert)
   (flatten)
   (replace -2 4 rl)
   (replace -4 4 rl)
   (replace -6 4 rl)
   (lemma "integral_add[T1,S1,mu]"
    ("f1" "LAMBDA x: g2!1(x, x!1)" "f2" "LAMBDA x: h2!1(x, x!1)"))
   (("1" (expand "+") (propax)) ("2" (propax)) ("3" (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (typepred "h2!1")
   (lemma "integrable2_scal" ("c" "c!1" "h2" "h2!1"))
   (expand "integral2")
   (expand "member")
   (expand "ae_eq?")
   (expand "restrict")
   (expand "pointwise_ae?")
   (expand "ae?")
   (expand "fullset")
   (expand "ae_in?")
   (expand "member")
   (expand "*" 1 3)
   (name "NN2" "null_integrable2(h2!1)`1")
   (name "NN1" "null_integrable2(c!1*h2!1)`1")
   (name "GG2" "null_integrable2(h2!1)`2")
   (name "GG1" "null_integrable2(c!1*h2!1)`2")
   (replace -1)
   (replace -2)
   (replace -3)
   (replace -4)
   (inst + "union(NN1,NN2)")
   (skosimp)
   (expand "union")
   (expand "member")
   (flatten)
   (assert)
   (lemma "null_integral2_def"
    ("h2" "h2!1" "g" "GG2" "N2" "NN2" "y" "x!1"))
   (lemma "null_integral2_def"
    ("h2" "c!1*h2!1" "g" "GG1" "N2" "NN1" "y" "x!1"))
   (assert)
   (flatten)
   (replace -2 3 rl)
   (replace -4 3 rl)
   (lemma "integral_scal[T1,S1,mu]"
    ("c" "c!1" "f" "LAMBDA x: h2!1(x, x!1)"))
   (("1" (expand "*") (propax)) ("2" (propax))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral2_scal" ("h2" "h2!1" "c" "-1"))
   (case-replace "-1 * h2!1=-h2!1")
   (("1" (expand "*") (expand "-") (assert))
    ("2" (apply-extensionality :hide? t) (hide-all-but 1) (grind))))


proof_type: f_proof
decl_type: formula
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-incomplete
description: nil
script:
  (""
   (skosimp)
   (lemma "integral2_opp" ("h2" "h2!1"))
   (lemma "integral2_add" ("g2" "g2!1" "h2" "-h2!1"))
   (case-replace "g2!1 + -h2!1=g2!1 - h2!1")
   (("1"
     (hide -1)
     (lemma "ae_eq_equivalence[T2,S2,nu]")
     (expand "equivalence?")
     (flatten)
     (expand "transitive?")
     (inst - "integral2(g2!1 - h2!1)"
      "integral2(g2!1) + integral2(-h2!1)"
      "integral2(g2!1) - integral2(h2!1)")
     (assert)
     (hide-all-but (-4 1))
     (expand "ae_eq?")
     (expand "restrict")
     (expand "pointwise_ae?")
     (expand "ae?")
     (expand "fullset")
     (expand "ae_in?")
     (skosimp)
     (inst + "E!1")
     (skosimp)
     (inst - "x!1")
     (assert)
     (expand "-")
     (expand "+")
     (assert))
    ("2" (hide-all-but 1) (apply-extensionality :hide? t) (grind))))


proof_type: t_proof
decl_type: tcc
library: measure_integration
theory: product_integral_def
signature: nil
run_date: Unknown date
run_time: ----
status: proved-complete
description: nil
script:
  (""
   (typepred "S1")
   (expand "sigma_algebra?")
   (expand "subset_algebra_empty?")
   (flatten)
   (expand "member")
   (propax))


