Skip to content

Commit fce3709

Browse files
authored
Merge pull request #499 from Seasawher/auto-update-branch
2 parents d4d73b8 + 5f7bbe0 commit fce3709

File tree

6 files changed

+56
-15
lines changed

6 files changed

+56
-15
lines changed

docs/attributes.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Attributes
22

3-
Mathlib version: `3aa3aca5742a8520388e668df501f753cb7ca679`
3+
Mathlib version: `24899e1184118f6ac3a1584767be5e6ad9c8d18e`
44

55
## Std.Internal.tree_tac
66
simp theorems used by internal DTreeMap lemmas

docs/commands.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Commands
22

3-
Mathlib version: `3aa3aca5742a8520388e668df501f753cb7ca679`
3+
Mathlib version: `24899e1184118f6ac3a1584767be5e6ad9c8d18e`
44

55
## \#adaptation_note
66
Defined in: `adaptationNoteCmd`

docs/options.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Options
22

3-
Mathlib version: `3aa3aca5742a8520388e668df501f753cb7ca679`
3+
Mathlib version: `24899e1184118f6ac3a1584767be5e6ad9c8d18e`
44

55
## Elab.async
66
type: `Bool`
@@ -806,7 +806,7 @@ enable the ppRoundtrip linter
806806
## linter.pythonStyle
807807
type: `Bool`
808808

809-
default: `true`
809+
default: `false`
810810

811811

812812

@@ -1986,7 +1986,7 @@ Number of results requested from statesearch (default 6)
19861986
## statesearch.revision
19871987
type: `String`
19881988

1989-
default: `"v4.24.0-rc1"`
1989+
default: `"v4.24.0"`
19901990

19911991
Revision of LeanStateSearch to use
19921992

docs/tactics.md

Lines changed: 43 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Tactics
22

3-
Mathlib version: `3aa3aca5742a8520388e668df501f753cb7ca679`
3+
Mathlib version: `24899e1184118f6ac3a1584767be5e6ad9c8d18e`
44

55
## \#adaptation_note
66
Defined in: `«tactic#adaptation_note_»`
@@ -2474,6 +2474,38 @@ Defined in: `tacticFconstructor`
24742474
(it calls `apply` using the first matching constructor of an inductive datatype)
24752475
except that it does not reorder goals.
24762476

2477+
## field
2478+
Defined in: `Mathlib.Tactic.FieldSimp.field`
2479+
2480+
The `field` tactic proves equality goals in (semi-)fields. For example:
2481+
```lean
2482+
example {x y : ℚ} (hx : x + y ≠ 0) : x / (x + y) + y / (x + y) = 1 := by
2483+
field
2484+
example {a b : ℝ} (ha : a ≠ 0) : a / (a * b) - 1 / b = 0 := by field
2485+
```
2486+
The scope of the tactic is equality goals which are *universal*, in the sense that they are true in
2487+
any field in which the appropriate denominators don't vanish. (That is, they are consequences purely
2488+
of the field axioms.)
2489+
2490+
Checking the nonvanishing of the necessary denominators is done using a variety of tricks -- in
2491+
particular this part of the reasoning is non-universal, i.e. can be specific to the field at hand
2492+
(order properties, explicit `≠ 0` hypotheses, `CharZero` if that is known, etc). The user can also
2493+
provide additional terms to help with the nonzeroness proofs. For example:
2494+
```lean
2495+
example {K : Type*} [Field K] (hK : ∀ x : K, x ^ 2 + 1 ≠ 0) (x : K) :
2496+
1 / (x ^ 2 + 1) + x ^ 2 / (x ^ 2 + 1) = 1 := by
2497+
field [hK]
2498+
```
2499+
2500+
The `field` tactic is built from the tactics `field_simp` (which clears the denominators) and `ring`
2501+
(which proves equality goals universally true in commutative (semi-)rings). If `field` fails to
2502+
prove your goal, you may still be able to prove your goal by running the `field_simp` and `ring_nf`
2503+
normalizations in some order. For example, this statement:
2504+
```lean
2505+
example {a b : ℚ} (H : b + a ≠ 0) : a / (a + b) + b / (b + a) = 1
2506+
```
2507+
is not proved by `field` but is proved by `ring_nf at *; field`.
2508+
24772509
## field_simp
24782510
Defined in: `Mathlib.Tactic.FieldSimp.fieldSimp`
24792511

@@ -2497,6 +2529,10 @@ example {K : Type*} [Field K] {x : K} (hx0 : x ≠ 0) :
24972529
-- new goal: `⊢ (x ^ 2 + 1) * (x ^ 2 + 1 + x) = x ^ 2`
24982530
```
24992531

2532+
A very common pattern is `field_simp; ring` (clear denominators, then the resulting goal is
2533+
solvable by the axioms of a commutative ring). The finishing tactic `field` is a shorthand for this
2534+
pattern.
2535+
25002536
Cancelling and combining denominators will generally require checking "nonzeroness"/"positivity"
25012537
side conditions. The `field_simp` tactic attempts to discharge these, and will omit such steps if it
25022538
cannot discharge the corresponding side conditions. The discharger will try, among other things,
@@ -5561,11 +5597,16 @@ Defined in: `Lean.Parser.Tactic.open`
55615597
but it opens a namespace only within the tactics `tacs`.
55625598

55635599
## order
5564-
Defined in: `Mathlib.Tactic.Order.tacticOrder`
5600+
Defined in: `Mathlib.Tactic.Order.tacticOrder_`
55655601

55665602
A finishing tactic for solving goals in arbitrary `Preorder`, `PartialOrder`,
55675603
or `LinearOrder`. Supports ``, ``, and lattice operations.
55685604

5605+
## order_core
5606+
Defined in: `Mathlib.Tactic.Order.order_core`
5607+
5608+
`order_core` is the part of the `order` tactic that tries to find a contradiction.
5609+
55695610
## peel
55705611
Defined in: `Mathlib.Tactic.Peel.peel`
55715612

lake-manifest.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"type": "git",
66
"subDir": null,
77
"scope": "",
8-
"rev": "3aa3aca5742a8520388e668df501f753cb7ca679",
8+
"rev": "24899e1184118f6ac3a1584767be5e6ad9c8d18e",
99
"name": "mathlib",
1010
"manifestFile": "lake-manifest.json",
1111
"inputRev": "master",
@@ -15,7 +15,7 @@
1515
"type": "git",
1616
"subDir": null,
1717
"scope": "leanprover-community",
18-
"rev": "9f492660e9837df43fd885a2ad05c520da9ff9f5",
18+
"rev": "dfd06ebfe8d0e8fa7faba9cb5e5a2e74e7bd2805",
1919
"name": "plausible",
2020
"manifestFile": "lake-manifest.json",
2121
"inputRev": "main",
@@ -35,7 +35,7 @@
3535
"type": "git",
3636
"subDir": null,
3737
"scope": "leanprover-community",
38-
"rev": "90f3b0f429411beeeb29bbc248d799c18a2d520d",
38+
"rev": "d768126816be17600904726ca7976b185786e6b9",
3939
"name": "importGraph",
4040
"manifestFile": "lake-manifest.json",
4141
"inputRev": "main",
@@ -55,7 +55,7 @@
5555
"type": "git",
5656
"subDir": null,
5757
"scope": "leanprover-community",
58-
"rev": "14d8accc7513f8a85ae142201907f49f518ae0ec",
58+
"rev": "725ac8cd67acd70a7beaf47c3725e23484c1ef50",
5959
"name": "aesop",
6060
"manifestFile": "lake-manifest.json",
6161
"inputRev": "master",
@@ -65,7 +65,7 @@
6565
"type": "git",
6666
"subDir": null,
6767
"scope": "leanprover-community",
68-
"rev": "2e582a44b0150db152bff1c8484eb557fb5340da",
68+
"rev": "2676cb5599c12c434daac781e2cea44e8105fc41",
6969
"name": "Qq",
7070
"manifestFile": "lake-manifest.json",
7171
"inputRev": "master",
@@ -75,7 +75,7 @@
7575
"type": "git",
7676
"subDir": null,
7777
"scope": "leanprover-community",
78-
"rev": "9c1ad6d93126e346c859d4a17d71b010e7951f92",
78+
"rev": "8da40b72fece29b7d3fe3d768bac4c8910ce9bee",
7979
"name": "batteries",
8080
"manifestFile": "lake-manifest.json",
8181
"inputRev": "main",
@@ -85,7 +85,7 @@
8585
"type": "git",
8686
"subDir": null,
8787
"scope": "leanprover",
88-
"rev": "b62fd39acc32da6fb8bb160c82d1bbc3cb3c186e",
88+
"rev": "91c18fa62838ad0ab7384c03c9684d99d306e1da",
8989
"name": "Cli",
9090
"manifestFile": "lake-manifest.json",
9191
"inputRev": "main",

lean-toolchain

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
leanprover/lean4:v4.24.0-rc1
1+
leanprover/lean4:v4.24.0

0 commit comments

Comments
 (0)