Built with Alectryon, running Coq+SerAPI v8.10.0+0.7.0. Coq sources are in this panel; goals and messages will appear in the other. Bubbles () indicate interactive fragments: hover for details, tap to reveal contents. Use Ctrl+↑ Ctrl+↓ to navigate, Ctrl+🖱️ to focus.
(************************************************************************) (* * The Coq Proof Assistant / The Coq Development Team *) (* v * INRIA, CNRS and contributors - Copyright 1999-2018 *) (* <O___,, * (see CREDITS file for the list of authors) *) (* \VV/ **************************************************************) (* // * This file is distributed under the terms of the *) (* * GNU Lesser General Public License Version 2.1 *) (* * (see LICENSE file for the text of the license) *) (************************************************************************) Require Import Rbase. Require Import Rfunctions. Require Import SeqSeries. Local Open Scope R_scope. (*****************************************************************)
To define transcendental functions
and exponential function
(*****************************************************************) (*********)Un_cv (fun n : nat => Rabs (/ INR (fact (S n)) * / / INR (fact n))) 0Un_cv (fun n : nat => Rabs (/ INR (fact (S n)) * / / INR (fact n))) 0eps:RH:eps > 0Hgt:eps > 1exists N : nat, forall n : nat, (n >= N)%nat -> R_dist (Rabs (/ INR (fact (S n)) * / / INR (fact n))) 0 < epseps:RH:eps > 0Hnotgt:~ eps > 1exists N : nat, forall n : nat, (n >= N)%nat -> R_dist (Rabs (/ INR (fact (S n)) * / / INR (fact n))) 0 < epseps:RH:eps > 0Hgt:eps > 1exists N : nat, forall n : nat, (n >= N)%nat -> R_dist (Rabs (/ INR (fact (S n)) * / / INR (fact n))) 0 < epseps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%nat/ INR (S n) > 0 -> Rabs (/ INR (S n)) < epseps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%nat/ INR (S n) > 0eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 0/ INR (S n) < epseps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%nat/ INR (S n) > 0eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 0/ eps - 1 < 0 -> / INR (S n) < epseps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 0/ eps - 1 < 0eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%nat/ INR (S n) > 0eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 0H2:/ eps < 1 + INR n/ INR (S n) < epseps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 0/ eps - 1 < 0eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%nat/ INR (S n) > 0eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 0/ eps - 1 < 0eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%nat/ INR (S n) > 0eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%natH1:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%nat/ INR (S n) > 0unfold Rgt; apply Rinv_0_lt_compat; apply lt_INR_0; apply lt_O_Sn.eps:RH:eps > 0Hgt:eps > 1n:natH0:(n >= 0)%nat/ INR (S n) > 0eps:RH:eps > 0Hnotgt:~ eps > 1exists N : nat, forall n : nat, (n >= N)%nat -> R_dist (Rabs (/ INR (fact (S n)) * / / INR (fact n))) 0 < epseps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Z -> exists N : nat, forall n : nat, (n >= N)%nat -> R_dist (Rabs (/ INR (fact (S n)) * / / INR (fact n))) 0 < epseps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Zeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%nat/ INR (S n) > 0 -> Rabs (/ INR (S n)) < epseps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%nat/ INR (S n) > 0eps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Zeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 0/ INR (S n) < epseps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%nat/ INR (S n) > 0eps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Zeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 0/ eps - 1 < INR x -> / INR (S n) < epseps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 0/ eps - 1 < INR xeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%nat/ INR (S n) > 0eps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Zeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 0H4:/ eps < 1 + INR n/ INR (S n) < epseps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 0/ eps - 1 < INR xeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%nat/ INR (S n) > 0eps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Zeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 0/ eps - 1 < INR xeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%nat/ INR (S n) > 0eps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Zeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 0H4:IZR (up (/ eps - 1)) = IZR (Z.of_nat x)/ eps - 1 < INR xeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%nat/ INR (S n) > 0eps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Zeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%natH3:/ INR (S n) > 00 <= / INR (S n)eps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%nat/ INR (S n) > 0eps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Zeps:RH:eps > 0Hnotgt:~ eps > 1H0:(0 <= up (/ eps - 1))%Zx:natH1:up (/ eps - 1) = Z.of_nat xn:natH2:(n >= x)%nat/ INR (S n) > 0eps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Zeps:RH:eps > 0Hnotgt:~ eps > 1(0 <= up (/ eps - 1))%Zeps:RH:eps > 0Hnotgt:~ eps > 10 <= / eps - 1eps:RH:eps > 0Hnotgt:~ eps > 1/ eps - 1 <= IZR (up (/ eps - 1))eps:RH:eps > 0H0:eps < 10 < / eps - 1 \/ 0 = / eps - 1eps:RH:eps > 0H0:eps = 10 < / eps - 1 \/ 0 = / eps - 1eps:RH:eps > 0Hnotgt:~ eps > 1/ eps - 1 <= IZR (up (/ eps - 1))eps:RH:eps > 0H0:eps = 10 < / eps - 1 \/ 0 = / eps - 1eps:RH:eps > 0Hnotgt:~ eps > 1/ eps - 1 <= IZR (up (/ eps - 1))elim (archimed (/ eps - 1)); intros; clear H1; unfold Rgt in H0; apply Rlt_le; assumption. Qed.eps:RH:eps > 0Hnotgt:~ eps > 1/ eps - 1 <= IZR (up (/ eps - 1))