Skip to content

Commit 00514bb

Browse files
authored
fixes #1733 (ln_eq0) (#1744)
* fixes #1733
1 parent 2b30625 commit 00514bb

2 files changed

Lines changed: 15 additions & 10 deletions

File tree

CHANGELOG_UNRELEASED.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@
8181
+ lemmas `open_disjoint_itv_open`, `open_disjoint_itv_is_interval`,
8282
`open_disjoint_itv_trivIset`, `open_disjoint_itv_bigcup`
8383

84+
- in `exp.v`:
85+
+ lemma `ln_eq0`
8486

8587
### Changed
8688

theories/exp.v

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
(* mathcomp analysis (c) 2025 Inria and AIST. License: CeCILL-C. *)
22
From mathcomp Require Import all_ssreflect ssralg ssrint ssrnum matrix.
3-
From mathcomp Require Import interval rat.
3+
From mathcomp Require Import interval rat interval_inference.
44
From mathcomp Require Import boolp classical_sets functions mathcomp_extra.
5-
From mathcomp Require Import unstable reals ereal interval_inference.
6-
From mathcomp Require Import topology tvs normedtype landau sequences derive.
7-
From mathcomp Require Import realfun interval_inference convex.
5+
From mathcomp Require Import unstable reals topology ereal tvs normedtype.
6+
From mathcomp Require Import landau sequences derive realfun convex.
87

98
(**md**************************************************************************)
109
(* # Theory of exponential/logarithm functions *)
@@ -785,6 +784,13 @@ have [x0|x0 x1] := leP x 0; first by rewrite ln0.
785784
by rewrite -ler_expR expR0 lnK.
786785
Qed.
787786

787+
Lemma ln_eq0 x : 0 < x -> (ln x == 0) = (x == 1).
788+
Proof.
789+
move=> x0; apply/idP/idP => [/eqP lnx0|/eqP ->]; last by rewrite ln1.
790+
have [| |//] := ltgtP x 1; last by move/ln_gt0; rewrite lnx0 ltxx.
791+
by move/(conj x0)/andP/ln_lt0; rewrite lnx0 ltxx.
792+
Qed.
793+
788794
Lemma continuous_ln x : 0 < x -> {for x, continuous ln}.
789795
Proof.
790796
move=> x_gt0; rewrite -[x]lnK//.
@@ -1246,12 +1252,9 @@ Proof. by rewrite 2!ltNge lne_ge0. Qed.
12461252

12471253
Lemma lne_eq0 x : (lne x == 0) = (x == 1).
12481254
Proof.
1249-
apply/idP/idP => /eqP; last by move=> ->; rewrite lne1.
1250-
have [|x0] := leP x 0.
1251-
by case: x => [r| |]//; rewrite lee_fin => /= ->.
1252-
rewrite -lne1 => /lne_inj.
1253-
rewrite ?in_itv/= ?leey ?andbT// => /(_ _ _)/eqP.
1254-
by apply => //; exact: ltW.
1255+
rewrite /lne; move: x => [r| |] //; case: ifPn => r0.
1256+
by apply/esym; rewrite lt_eqF// lte_fin (le_lt_trans r0).
1257+
by rewrite !eqe ln_eq0// ltNge.
12551258
Qed.
12561259

12571260
Lemma lne_gt0 x : (0 < lne x) = (1 < x).

0 commit comments

Comments
 (0)