url
stringclasses
147 values
commit
stringclasses
147 values
file_path
stringlengths
7
101
full_name
stringlengths
1
94
start
stringlengths
6
10
end
stringlengths
6
11
tactic
stringlengths
1
11.2k
state_before
stringlengths
3
2.09M
state_after
stringlengths
6
2.09M
input
stringlengths
73
2.09M
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.pos_iff_ex
[207, 1]
[230, 53]
exact Rel.trans ‹x ≃ 1 * coe n› AA.identL
x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 x✝ : Positive x n : ℕ pos✝ : Positive n eqv✝ : x ≃ 1 * coe n ⊢ x ≃ coe n
no goals
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 x✝ : Positive x n : ℕ pos✝ : Positive n eqv✝ : x ≃ 1 * coe n ⊢ x ≃ coe n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.pos_iff_ex
[207, 1]
[230, 53]
intro (Exists.intro (n : ℕ) (And.intro (_ : Positive n) (_ : x ≃ coe n)))
x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 ⊢ (∃ n, Positive n ∧ x ≃ coe n) → Positive x
x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 n : ℕ left✝ : Positive n right✝ : x ≃ coe n ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 ⊢ (∃ n, Positive n ∧ x ≃ coe n) → Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.pos_iff_ex
[207, 1]
[230, 53]
apply Impl.sign_props.positive_iff_sign_pos1.mpr
x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 n : ℕ left✝ : Positive n right✝ : x ≃ coe n ⊢ Positive x
x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 n : ℕ left✝ : Positive n right✝ : x ≃ coe n ⊢ Integer.NonzeroWithSign x 1
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 n : ℕ left✝ : Positive n right✝ : x ≃ coe n ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.pos_iff_ex
[207, 1]
[230, 53]
apply Integer.NonzeroWithSign.intro n ‹Positive n›
x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 n : ℕ left✝ : Positive n right✝ : x ≃ coe n ⊢ Integer.NonzeroWithSign x 1
x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 n : ℕ left✝ : Positive n right✝ : x ≃ coe n ⊢ x ≃ 1 * coe n
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 n : ℕ left✝ : Positive n right✝ : x ≃ coe n ⊢ Integer.NonzeroWithSign x 1 TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.pos_iff_ex
[207, 1]
[230, 53]
exact Rel.trans ‹x ≃ coe n› (Rel.symm AA.identL)
x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 n : ℕ left✝ : Positive n right✝ : x ≃ coe n ⊢ x ≃ 1 * coe n
no goals
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ mul_ident : AA.Identity (coe 1) fun x x_1 => x * x_1 n : ℕ left✝ : Positive n right✝ : x ≃ coe n ⊢ x ≃ 1 * coe n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
apply Iff.intro
x : ℤ ⊢ Negative x ↔ ∃ n, Positive n ∧ x ≃ -coe n
case mp x : ℤ ⊢ Negative x → ∃ n, Positive n ∧ x ≃ -coe n case mpr x : ℤ ⊢ (∃ n, Positive n ∧ x ≃ -coe n) → Negative x
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ ⊢ Negative x ↔ ∃ n, Positive n ∧ x ≃ -coe n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
case mp => intro (_ : Negative x) show ∃ (n : ℕ), Positive n ∧ x ≃ -(coe n) have (Integer.NonzeroWithSign.intro (n : ℕ) (_ : Positive n) (_ : x ≃ -1 * coe n)) := Impl.sign_props.negative_iff_sign_neg1.mp ‹Negative x› exists n apply And.intro ‹Positive n› show x ≃ -(coe n) exact Rel.trans ‹x ≃ -1 * coe n› Integer.mul_neg_one
x : ℤ ⊢ Negative x → ∃ n, Positive n ∧ x ≃ -coe n
no goals
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ ⊢ Negative x → ∃ n, Positive n ∧ x ≃ -coe n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
case mpr => intro (Exists.intro (n : ℕ) (And.intro (_ : Positive n) (_ : x ≃ -(coe n)))) show Negative x apply Impl.sign_props.negative_iff_sign_neg1.mpr show Integer.NonzeroWithSign x (-1) apply Integer.NonzeroWithSign.intro n ‹Positive n› show x ≃ -1 * coe n exact Rel.trans ‹x ≃ -(coe n)› (Rel.symm Integer.mul_neg_one)
x : ℤ ⊢ (∃ n, Positive n ∧ x ≃ -coe n) → Negative x
no goals
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ ⊢ (∃ n, Positive n ∧ x ≃ -coe n) → Negative x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
intro (_ : Negative x)
x : ℤ ⊢ Negative x → ∃ n, Positive n ∧ x ≃ -coe n
x : ℤ x✝ : Negative x ⊢ ∃ n, Positive n ∧ x ≃ -coe n
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ ⊢ Negative x → ∃ n, Positive n ∧ x ≃ -coe n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
have (Integer.NonzeroWithSign.intro (n : ℕ) (_ : Positive n) (_ : x ≃ -1 * coe n)) := Impl.sign_props.negative_iff_sign_neg1.mp ‹Negative x›
x : ℤ x✝ : Negative x ⊢ ∃ n, Positive n ∧ x ≃ -coe n
x : ℤ x✝ : Negative x n : ℕ pos✝ : Positive n eqv✝ : x ≃ -1 * coe n ⊢ ∃ n, Positive n ∧ x ≃ -coe n
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ x✝ : Negative x ⊢ ∃ n, Positive n ∧ x ≃ -coe n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
exists n
x : ℤ x✝ : Negative x n : ℕ pos✝ : Positive n eqv✝ : x ≃ -1 * coe n ⊢ ∃ n, Positive n ∧ x ≃ -coe n
x : ℤ x✝ : Negative x n : ℕ pos✝ : Positive n eqv✝ : x ≃ -1 * coe n ⊢ Positive n ∧ x ≃ -coe n
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ x✝ : Negative x n : ℕ pos✝ : Positive n eqv✝ : x ≃ -1 * coe n ⊢ ∃ n, Positive n ∧ x ≃ -coe n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
apply And.intro ‹Positive n›
x : ℤ x✝ : Negative x n : ℕ pos✝ : Positive n eqv✝ : x ≃ -1 * coe n ⊢ Positive n ∧ x ≃ -coe n
x : ℤ x✝ : Negative x n : ℕ pos✝ : Positive n eqv✝ : x ≃ -1 * coe n ⊢ x ≃ -coe n
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ x✝ : Negative x n : ℕ pos✝ : Positive n eqv✝ : x ≃ -1 * coe n ⊢ Positive n ∧ x ≃ -coe n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
exact Rel.trans ‹x ≃ -1 * coe n› Integer.mul_neg_one
x : ℤ x✝ : Negative x n : ℕ pos✝ : Positive n eqv✝ : x ≃ -1 * coe n ⊢ x ≃ -coe n
no goals
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ x✝ : Negative x n : ℕ pos✝ : Positive n eqv✝ : x ≃ -1 * coe n ⊢ x ≃ -coe n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
intro (Exists.intro (n : ℕ) (And.intro (_ : Positive n) (_ : x ≃ -(coe n))))
x : ℤ ⊢ (∃ n, Positive n ∧ x ≃ -coe n) → Negative x
x : ℤ n : ℕ left✝ : Positive n right✝ : x ≃ -coe n ⊢ Negative x
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ ⊢ (∃ n, Positive n ∧ x ≃ -coe n) → Negative x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
apply Impl.sign_props.negative_iff_sign_neg1.mpr
x : ℤ n : ℕ left✝ : Positive n right✝ : x ≃ -coe n ⊢ Negative x
x : ℤ n : ℕ left✝ : Positive n right✝ : x ≃ -coe n ⊢ Integer.NonzeroWithSign x (-1)
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ n : ℕ left✝ : Positive n right✝ : x ≃ -coe n ⊢ Negative x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
apply Integer.NonzeroWithSign.intro n ‹Positive n›
x : ℤ n : ℕ left✝ : Positive n right✝ : x ≃ -coe n ⊢ Integer.NonzeroWithSign x (-1)
x : ℤ n : ℕ left✝ : Positive n right✝ : x ≃ -coe n ⊢ x ≃ -1 * coe n
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ n : ℕ left✝ : Positive n right✝ : x ≃ -coe n ⊢ Integer.NonzeroWithSign x (-1) TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.neg_iff_ex
[232, 1]
[254, 66]
exact Rel.trans ‹x ≃ -(coe n)› (Rel.symm Integer.mul_neg_one)
x : ℤ n : ℕ left✝ : Positive n right✝ : x ≃ -coe n ⊢ x ≃ -1 * coe n
no goals
Please generate a tactic in lean4 to solve the state. STATE: x : ℤ n : ℕ left✝ : Positive n right✝ : x ≃ -coe n ⊢ x ≃ -1 * coe n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
apply Iff.intro
n m : ℤ ⊢ n > m ↔ n ≥ m ∧ n ≄ m
case mp n m : ℤ ⊢ n > m → n ≥ m ∧ n ≄ m case mpr n m : ℤ ⊢ n ≥ m ∧ n ≄ m → n > m
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ ⊢ n > m ↔ n ≥ m ∧ n ≄ m TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
case mp => intro (_ : n > m) show n ≥ m ∧ n ≄ m have (And.intro (_ : n ≥ m) (_ : m ≄ n)) := Integer.lt_iff_le_neqv.mp ‹n > m› have : n ≄ m := Rel.symm ‹m ≄ n› exact And.intro ‹n ≥ m› ‹n ≄ m›
n m : ℤ ⊢ n > m → n ≥ m ∧ n ≄ m
no goals
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ ⊢ n > m → n ≥ m ∧ n ≄ m TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
case mpr => intro (And.intro (_ : n ≥ m) (_ : n ≄ m)) show n > m apply Integer.lt_iff_le_neqv.mpr show n ≥ m ∧ m ≄ n have : m ≄ n := Rel.symm ‹n ≄ m› exact And.intro ‹n ≥ m› ‹m ≄ n›
n m : ℤ ⊢ n ≥ m ∧ n ≄ m → n > m
no goals
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ ⊢ n ≥ m ∧ n ≄ m → n > m TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
intro (_ : n > m)
n m : ℤ ⊢ n > m → n ≥ m ∧ n ≄ m
n m : ℤ x✝ : n > m ⊢ n ≥ m ∧ n ≄ m
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ ⊢ n > m → n ≥ m ∧ n ≄ m TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
have (And.intro (_ : n ≥ m) (_ : m ≄ n)) := Integer.lt_iff_le_neqv.mp ‹n > m›
n m : ℤ x✝ : n > m ⊢ n ≥ m ∧ n ≄ m
n m : ℤ x✝ : n > m left✝ : n ≥ m right✝ : m ≄ n ⊢ n ≥ m ∧ n ≄ m
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ x✝ : n > m ⊢ n ≥ m ∧ n ≄ m TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
have : n ≄ m := Rel.symm ‹m ≄ n›
n m : ℤ x✝ : n > m left✝ : n ≥ m right✝ : m ≄ n ⊢ n ≥ m ∧ n ≄ m
n m : ℤ x✝ : n > m left✝ : n ≥ m right✝ : m ≄ n this : n ≄ m ⊢ n ≥ m ∧ n ≄ m
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ x✝ : n > m left✝ : n ≥ m right✝ : m ≄ n ⊢ n ≥ m ∧ n ≄ m TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
exact And.intro ‹n ≥ m› ‹n ≄ m›
n m : ℤ x✝ : n > m left✝ : n ≥ m right✝ : m ≄ n this : n ≄ m ⊢ n ≥ m ∧ n ≄ m
no goals
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ x✝ : n > m left✝ : n ≥ m right✝ : m ≄ n this : n ≄ m ⊢ n ≥ m ∧ n ≄ m TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
intro (And.intro (_ : n ≥ m) (_ : n ≄ m))
n m : ℤ ⊢ n ≥ m ∧ n ≄ m → n > m
n m : ℤ left✝ : n ≥ m right✝ : n ≄ m ⊢ n > m
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ ⊢ n ≥ m ∧ n ≄ m → n > m TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
apply Integer.lt_iff_le_neqv.mpr
n m : ℤ left✝ : n ≥ m right✝ : n ≄ m ⊢ n > m
n m : ℤ left✝ : n ≥ m right✝ : n ≄ m ⊢ m ≤ n ∧ m ≄ n
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ left✝ : n ≥ m right✝ : n ≄ m ⊢ n > m TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
show n ≥ m ∧ m ≄ n
n m : ℤ left✝ : n ≥ m right✝ : n ≄ m ⊢ m ≤ n ∧ m ≄ n
n m : ℤ left✝ : n ≥ m right✝ : n ≄ m ⊢ n ≥ m ∧ m ≄ n
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ left✝ : n ≥ m right✝ : n ≄ m ⊢ m ≤ n ∧ m ≄ n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
have : m ≄ n := Rel.symm ‹n ≄ m›
n m : ℤ left✝ : n ≥ m right✝ : n ≄ m ⊢ n ≥ m ∧ m ≄ n
n m : ℤ left✝ : n ≥ m right✝ : n ≄ m this : m ≄ n ⊢ n ≥ m ∧ m ≄ n
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ left✝ : n ≥ m right✝ : n ≄ m ⊢ n ≥ m ∧ m ≄ n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec1Integers.lean
AnalysisI.Ch4.Sec1.gt_iff_ge_neqv
[413, 1]
[428, 36]
exact And.intro ‹n ≥ m› ‹m ≄ n›
n m : ℤ left✝ : n ≥ m right✝ : n ≄ m this : m ≄ n ⊢ n ≥ m ∧ m ≄ n
no goals
Please generate a tactic in lean4 to solve the state. STATE: n m : ℤ left✝ : n ≥ m right✝ : n ≄ m this : m ≄ n ⊢ n ≥ m ∧ m ≄ n TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.one_plus_m
[150, 1]
[155, 51]
calc _ ≃ 1 + m := Rel.refl _ ≃ step 0 + m := AA.substL Rel.refl _ ≃ step (0 + m) := Natural.step_add _ ≃ step m := AA.subst₁ Natural.zero_add
m : ℕ ⊢ 1 + m ≃ step m
no goals
Please generate a tactic in lean4 to solve the state. STATE: m : ℕ ⊢ 1 + m ≃ step m TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
intro (_ : Positive q)
n q : ℕ ⊢ Positive q → Euclid n q
n q : ℕ x✝ : Positive q ⊢ Euclid n q
Please generate a tactic in lean4 to solve the state. STATE: n q : ℕ ⊢ Positive q → Euclid n q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
have : 0 < q := Natural.lt_zero_pos.mp ‹Positive q›
n q : ℕ x✝ : Positive q ⊢ Euclid n q
n q : ℕ x✝ : Positive q this : 0 < q ⊢ Euclid n q
Please generate a tactic in lean4 to solve the state. STATE: n q : ℕ x✝ : Positive q ⊢ Euclid n q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
apply Natural.ind_on (motive := λ n => Euclid n q) n
n q : ℕ x✝ : Positive q this : 0 < q ⊢ Euclid n q
case zero n q : ℕ x✝ : Positive q this : 0 < q ⊢ Euclid 0 q case step n q : ℕ x✝ : Positive q this : 0 < q ⊢ ∀ (m : ℕ), Euclid m q → Euclid (step m) q
Please generate a tactic in lean4 to solve the state. STATE: n q : ℕ x✝ : Positive q this : 0 < q ⊢ Euclid n q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
case zero => show Euclid 0 q let m := 0 let r := 0 have r_bounded : r < q := ‹0 < q› have n_divided : 0 ≃ m * q + r := calc 0 ≃ _ := Rel.symm Natural.zero_mul 0 * q ≃ _ := Rel.symm Natural.add_zero 0 * q + 0 ≃ _ := Rel.refl m * q + r ≃ _ := Rel.refl exact Euclid.intro m r r_bounded n_divided
n q : ℕ x✝ : Positive q this : 0 < q ⊢ Euclid 0 q
no goals
Please generate a tactic in lean4 to solve the state. STATE: n q : ℕ x✝ : Positive q this : 0 < q ⊢ Euclid 0 q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
let m := 0
n q : ℕ x✝ : Positive q this : 0 < q ⊢ Euclid 0 q
n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 ⊢ Euclid 0 q
Please generate a tactic in lean4 to solve the state. STATE: n q : ℕ x✝ : Positive q this : 0 < q ⊢ Euclid 0 q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
let r := 0
n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 ⊢ Euclid 0 q
n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 r : Nat := 0 ⊢ Euclid 0 q
Please generate a tactic in lean4 to solve the state. STATE: n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 ⊢ Euclid 0 q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
have r_bounded : r < q := ‹0 < q›
n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 r : Nat := 0 ⊢ Euclid 0 q
n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 r : Nat := 0 r_bounded : r < q ⊢ Euclid 0 q
Please generate a tactic in lean4 to solve the state. STATE: n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 r : Nat := 0 ⊢ Euclid 0 q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
have n_divided : 0 ≃ m * q + r := calc 0 ≃ _ := Rel.symm Natural.zero_mul 0 * q ≃ _ := Rel.symm Natural.add_zero 0 * q + 0 ≃ _ := Rel.refl m * q + r ≃ _ := Rel.refl
n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 r : Nat := 0 r_bounded : r < q ⊢ Euclid 0 q
n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 r : Nat := 0 r_bounded : r < q n_divided : 0 ≃ m * q + r ⊢ Euclid 0 q
Please generate a tactic in lean4 to solve the state. STATE: n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 r : Nat := 0 r_bounded : r < q ⊢ Euclid 0 q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
exact Euclid.intro m r r_bounded n_divided
n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 r : Nat := 0 r_bounded : r < q n_divided : 0 ≃ m * q + r ⊢ Euclid 0 q
no goals
Please generate a tactic in lean4 to solve the state. STATE: n q : ℕ x✝ : Positive q this : 0 < q m : Nat := 0 r : Nat := 0 r_bounded : r < q n_divided : 0 ≃ m * q + r ⊢ Euclid 0 q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
intro n (ih : Euclid n q)
n q : ℕ x✝ : Positive q this : 0 < q ⊢ ∀ (m : ℕ), Euclid m q → Euclid (step m) q
n✝ q : ℕ x✝ : Positive q this : 0 < q n : ℕ ih : Euclid n q ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: n q : ℕ x✝ : Positive q this : 0 < q ⊢ ∀ (m : ℕ), Euclid m q → Euclid (step m) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
have ⟨m', r', (_ : r' < q), (_ : n ≃ m' * q + r')⟩ := ih
n✝ q : ℕ x✝ : Positive q this : 0 < q n : ℕ ih : Euclid n q ⊢ Euclid (step n) q
n✝ q : ℕ x✝ : Positive q this : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: n✝ q : ℕ x✝ : Positive q this : 0 < q n : ℕ ih : Euclid n q ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
have : step r' ≤ q := Natural.lt_step_le.mp ‹r' < q›
n✝ q : ℕ x✝ : Positive q this : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' ⊢ Euclid (step n) q
n✝ q : ℕ x✝ : Positive q this✝ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this : step r' ≤ q ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: n✝ q : ℕ x✝ : Positive q this : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
have : step r' < q ∨ step r' ≃ q := Natural.le_split ‹step r' ≤ q›
n✝ q : ℕ x✝ : Positive q this✝ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this : step r' ≤ q ⊢ Euclid (step n) q
n✝ q : ℕ x✝ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: n✝ q : ℕ x✝ : Positive q this✝ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this : step r' ≤ q ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
apply Or.elim ‹step r' < q ∨ step r' ≃ q›
n✝ q : ℕ x✝ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q ⊢ Euclid (step n) q
case left n✝ q : ℕ x✝ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q ⊢ step r' < q → Euclid (step n) q case right n✝ q : ℕ x✝ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q ⊢ step r' ≃ q → Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: n✝ q : ℕ x✝ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
intro (_ : step r' < q)
case left n✝ q : ℕ x✝ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q ⊢ step r' < q → Euclid (step n) q
case left n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' < q ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: case left n✝ q : ℕ x✝ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q ⊢ step r' < q → Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
let m := m'
case left n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' < q ⊢ Euclid (step n) q
case left n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: case left n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' < q ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
let r := step r'
case left n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' ⊢ Euclid (step n) q
case left n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' r : ℕ := step r' ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: case left n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
have : r < q := ‹step r' < q›
case left n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' r : ℕ := step r' ⊢ Euclid (step n) q
case left n✝ q : ℕ x✝¹ : Positive q this✝² : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝¹ : step r' ≤ q this✝ : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' r : ℕ := step r' this : r < q ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: case left n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' r : ℕ := step r' ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
have : step n ≃ m * q + r := calc step n ≃ _ := AA.subst₁ ‹n ≃ m' * q + r'› step (m' * q + r') ≃ _ := Rel.symm Natural.add_step m' * q + step r' ≃ _ := Rel.refl m * q + r ≃ _ := Rel.refl
case left n✝ q : ℕ x✝¹ : Positive q this✝² : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝¹ : step r' ≤ q this✝ : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' r : ℕ := step r' this : r < q ⊢ Euclid (step n) q
case left n✝ q : ℕ x✝¹ : Positive q this✝³ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝² : step r' ≤ q this✝¹ : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' r : ℕ := step r' this✝ : r < q this : step n ≃ m * q + r ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: case left n✝ q : ℕ x✝¹ : Positive q this✝² : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝¹ : step r' ≤ q this✝ : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' r : ℕ := step r' this : r < q ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
exact ⟨m, r, ‹r < q›, ‹step n ≃ m * q + r›⟩
case left n✝ q : ℕ x✝¹ : Positive q this✝³ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝² : step r' ≤ q this✝¹ : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' r : ℕ := step r' this✝ : r < q this : step n ≃ m * q + r ⊢ Euclid (step n) q
no goals
Please generate a tactic in lean4 to solve the state. STATE: case left n✝ q : ℕ x✝¹ : Positive q this✝³ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝² : step r' ≤ q this✝¹ : step r' < q ∨ step r' ≃ q x✝ : step r' < q m : ℕ := m' r : ℕ := step r' this✝ : r < q this : step n ≃ m * q + r ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
intro (_ : step r' ≃ q)
case right n✝ q : ℕ x✝ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q ⊢ step r' ≃ q → Euclid (step n) q
case right n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: case right n✝ q : ℕ x✝ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q ⊢ step r' ≃ q → Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
let m := step m'
case right n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q ⊢ Euclid (step n) q
case right n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: case right n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
let r := 0
case right n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' ⊢ Euclid (step n) q
case right n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' r : Nat := 0 ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: case right n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
have : r < q := ‹0 < q›
case right n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' r : Nat := 0 ⊢ Euclid (step n) q
case right n✝ q : ℕ x✝¹ : Positive q this✝² : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝¹ : step r' ≤ q this✝ : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' r : Nat := 0 this : r < q ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: case right n✝ q : ℕ x✝¹ : Positive q this✝¹ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝ : step r' ≤ q this : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' r : Nat := 0 ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
have : step n ≃ m * q + r := calc step n ≃ _ := AA.subst₁ ‹n ≃ m' * q + r'› step (m' * q + r') ≃ _ := Rel.symm Natural.add_step m' * q + step r' ≃ _ := AA.substR ‹step r' ≃ q› m' * q + q ≃ _ := Rel.symm Natural.step_mul step m' * q ≃ _ := Rel.symm Natural.add_zero step m' * q + 0 ≃ _ := Rel.refl m * q + r ≃ _ := Rel.refl
case right n✝ q : ℕ x✝¹ : Positive q this✝² : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝¹ : step r' ≤ q this✝ : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' r : Nat := 0 this : r < q ⊢ Euclid (step n) q
case right n✝ q : ℕ x✝¹ : Positive q this✝³ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝² : step r' ≤ q this✝¹ : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' r : Nat := 0 this✝ : r < q this : step n ≃ m * q + r ⊢ Euclid (step n) q
Please generate a tactic in lean4 to solve the state. STATE: case right n✝ q : ℕ x✝¹ : Positive q this✝² : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝¹ : step r' ≤ q this✝ : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' r : Nat := 0 this : r < q ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch2.lean
AnalysisI.Ch2.euclidean_algorithm
[517, 1]
[564, 50]
exact ⟨m, r, ‹r < q›, ‹step n ≃ m * q + r›⟩
case right n✝ q : ℕ x✝¹ : Positive q this✝³ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝² : step r' ≤ q this✝¹ : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' r : Nat := 0 this✝ : r < q this : step n ≃ m * q + r ⊢ Euclid (step n) q
no goals
Please generate a tactic in lean4 to solve the state. STATE: case right n✝ q : ℕ x✝¹ : Positive q this✝³ : 0 < q n : ℕ ih : Euclid n q m' r' : ℕ r_bounded✝ : r' < q n_divided✝ : n ≃ m' * q + r' this✝² : step r' ≤ q this✝¹ : step r' < q ∨ step r' ≃ q x✝ : step r' ≃ q m : ℕ := step m' r : Nat := 0 this✝ : r < q this : step n ≃ m * q + r ⊢ Euclid (step n) q TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
apply Iff.intro
ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Positive x ↔ AltPositive x
case mp ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Positive x → AltPositive x case mpr ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ AltPositive x → Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Positive x ↔ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
case mp => intro (_ : Positive x) show AltPositive x have (Rational.AsRatio.intro a b (_ : Integer.Nonzero b) x_eqv) := Rational.as_ratio x have : x ≃ a / b := x_eqv have : sgn a * sgn b ≃ 1 := calc sgn a * sgn b ≃ _ := Rel.symm Rational.sgn_div_integers sgn ((a : ℚ) / b) ≃ _ := Rational.sgn_subst (Rel.symm ‹x ≃ a / b›) sgn x ≃ _ := Rational.sgn_positive.mp ‹Positive x› 1 ≃ _ := Rel.refl have (And.intro (_ : Integer.Sqrt1 (sgn b)) (_ : sgn a ≃ sgn b)) := Integer.mul_sqrt1_eqv.mp this have : sgn b ≃ 1 ∨ sgn b ≃ -1 := Integer.sqrt1_cases.mp ‹Integer.Sqrt1 (sgn b)› match this with | Or.inl (_ : sgn b ≃ 1) => have : sgn a ≃ 1 := Rel.trans ‹sgn a ≃ sgn b› ‹sgn b ≃ 1› have : AP (Positive a) := AP.mk (Integer.sgn_positive.mpr ‹sgn a ≃ 1›) have : AP (Positive b) := AP.mk (Integer.sgn_positive.mpr ‹sgn b ≃ 1›) exact AltPositive.mk ‹x ≃ a / b› | Or.inr (_ : sgn b ≃ -1) => have : sgn (-b) ≃ 1 := calc sgn (-b) ≃ _ := Integer.sgn_compat_neg (-(sgn b)) ≃ _ := AA.subst₁ ‹sgn b ≃ -1› (-(-1)) ≃ _ := Integer.neg_involutive 1 ≃ _ := Rel.refl have : sgn (-a) ≃ 1 := calc sgn (-a) ≃ _ := Integer.sgn_compat_neg (-(sgn a)) ≃ _ := AA.subst₁ ‹sgn a ≃ sgn b› (-(sgn b)) ≃ _ := Rel.symm Integer.sgn_compat_neg sgn (-b) ≃ _ := ‹sgn (-b) ≃ 1› 1 ≃ _ := Rel.refl have : Positive (-a) := Integer.sgn_positive.mpr ‹sgn (-a) ≃ 1› have : Positive (-b) := Integer.sgn_positive.mpr ‹sgn (-b) ≃ 1› have : AP (Positive (-a)) := AP.mk ‹Positive (-a)› have : AP (Positive (-b)) := AP.mk ‹Positive (-b)› have neg_eqv {z : ℤ} : -(z : ℚ) ≃ ((-z : ℤ) : ℚ) := Rational.eqv_symm Rational.neg_compat_from_integer have : x ≃ ((-a : ℤ) : ℚ) / ((-b : ℤ) : ℚ) := calc x ≃ _ := ‹x ≃ a / b› (a : ℚ) / b ≃ _ := Rel.symm Rational.div_neg_cancel (-(a : ℚ)) / (-(b : ℚ)) ≃ _ := Rational.div_substL neg_eqv ((-a : ℤ) : ℚ) / (-b : ℚ) ≃ _ := Rational.div_substR neg_eqv ((-a : ℤ) : ℚ) / ((-b : ℤ) : ℚ) ≃ _ := Rational.eqv_refl exact AltPositive.mk this
ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Positive x → AltPositive x
no goals
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Positive x → AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
case mpr => intro (_ : AltPositive x) show Positive x have (AltPositive.intro (a : ℤ) (b : ℤ) a_pos b_pos x_eqv) := ‹AltPositive x› have : AP (Positive a) := a_pos have : sgn a ≃ 1 := Integer.sgn_positive.mp this.ev have : AP (Positive b) := b_pos have : sgn b ≃ 1 := Integer.sgn_positive.mp this.ev have : x ≃ a / b := x_eqv have : sgn a ≃ sgn b := Rel.trans ‹sgn a ≃ 1› (Rel.symm ‹sgn b ≃ 1›) have : Integer.Nonzero b := Integer.nonzero_from_positive_inst have : Integer.Sqrt1 (sgn b) := Integer.sgn_nonzero.mp this have : sgn a * sgn b ≃ 1 := Integer.mul_sqrt1_eqv.mpr (And.intro this ‹sgn a ≃ sgn b›) have : sgn x ≃ 1 := calc sgn x ≃ _ := Rational.sgn_subst ‹x ≃ a / b› sgn ((a : ℚ) / (b : ℚ)) ≃ _ := Rational.sgn_div_integers sgn a * sgn b ≃ _ := ‹sgn a * sgn b ≃ 1› 1 ≃ _ := Rel.refl have : Positive x := Rational.sgn_positive.mpr this exact this
ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ AltPositive x → Positive x
no goals
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ AltPositive x → Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
intro (_ : Positive x)
ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Positive x → AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Positive x → AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have (Rational.AsRatio.intro a b (_ : Integer.Nonzero b) x_eqv) := Rational.as_ratio x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : x ≃ a / b := x_eqv
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : sgn a * sgn b ≃ 1 := calc sgn a * sgn b ≃ _ := Rel.symm Rational.sgn_div_integers sgn ((a : ℚ) / b) ≃ _ := Rational.sgn_subst (Rel.symm ‹x ≃ a / b›) sgn x ≃ _ := Rational.sgn_positive.mp ‹Positive x› 1 ≃ _ := Rel.refl
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : x ≃ Rational.from_integer a / Rational.from_integer b this : sgn a * sgn b ≃ 1 ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have (And.intro (_ : Integer.Sqrt1 (sgn b)) (_ : sgn a ≃ sgn b)) := Integer.mul_sqrt1_eqv.mp this
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : x ≃ Rational.from_integer a / Rational.from_integer b this : sgn a * sgn b ≃ 1 ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : x ≃ Rational.from_integer a / Rational.from_integer b this : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : x ≃ Rational.from_integer a / Rational.from_integer b this : sgn a * sgn b ≃ 1 ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : sgn b ≃ 1 ∨ sgn b ≃ -1 := Integer.sqrt1_cases.mp ‹Integer.Sqrt1 (sgn b)›
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : x ≃ Rational.from_integer a / Rational.from_integer b this : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this : sgn b ≃ 1 ∨ sgn b ≃ -1 ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : x ≃ Rational.from_integer a / Rational.from_integer b this : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
match this with | Or.inl (_ : sgn b ≃ 1) => have : sgn a ≃ 1 := Rel.trans ‹sgn a ≃ sgn b› ‹sgn b ≃ 1› have : AP (Positive a) := AP.mk (Integer.sgn_positive.mpr ‹sgn a ≃ 1›) have : AP (Positive b) := AP.mk (Integer.sgn_positive.mpr ‹sgn b ≃ 1›) exact AltPositive.mk ‹x ≃ a / b› | Or.inr (_ : sgn b ≃ -1) => have : sgn (-b) ≃ 1 := calc sgn (-b) ≃ _ := Integer.sgn_compat_neg (-(sgn b)) ≃ _ := AA.subst₁ ‹sgn b ≃ -1› (-(-1)) ≃ _ := Integer.neg_involutive 1 ≃ _ := Rel.refl have : sgn (-a) ≃ 1 := calc sgn (-a) ≃ _ := Integer.sgn_compat_neg (-(sgn a)) ≃ _ := AA.subst₁ ‹sgn a ≃ sgn b› (-(sgn b)) ≃ _ := Rel.symm Integer.sgn_compat_neg sgn (-b) ≃ _ := ‹sgn (-b) ≃ 1› 1 ≃ _ := Rel.refl have : Positive (-a) := Integer.sgn_positive.mpr ‹sgn (-a) ≃ 1› have : Positive (-b) := Integer.sgn_positive.mpr ‹sgn (-b) ≃ 1› have : AP (Positive (-a)) := AP.mk ‹Positive (-a)› have : AP (Positive (-b)) := AP.mk ‹Positive (-b)› have neg_eqv {z : ℤ} : -(z : ℚ) ≃ ((-z : ℤ) : ℚ) := Rational.eqv_symm Rational.neg_compat_from_integer have : x ≃ ((-a : ℤ) : ℚ) / ((-b : ℤ) : ℚ) := calc x ≃ _ := ‹x ≃ a / b› (a : ℚ) / b ≃ _ := Rel.symm Rational.div_neg_cancel (-(a : ℚ)) / (-(b : ℚ)) ≃ _ := Rational.div_substL neg_eqv ((-a : ℤ) : ℚ) / (-b : ℚ) ≃ _ := Rational.div_substR neg_eqv ((-a : ℤ) : ℚ) / ((-b : ℤ) : ℚ) ≃ _ := Rational.eqv_refl exact AltPositive.mk this
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this : sgn b ≃ 1 ∨ sgn b ≃ -1 ⊢ AltPositive x
no goals
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this : sgn b ≃ 1 ∨ sgn b ≃ -1 ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : sgn a ≃ 1 := Rel.trans ‹sgn a ≃ sgn b› ‹sgn b ≃ 1›
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 this : sgn a ≃ 1 ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : AP (Positive a) := AP.mk (Integer.sgn_positive.mpr ‹sgn a ≃ 1›)
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 this : sgn a ≃ 1 ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝¹ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 this✝ : sgn a ≃ 1 this : AP (Positive a) ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 this : sgn a ≃ 1 ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : AP (Positive b) := AP.mk (Integer.sgn_positive.mpr ‹sgn b ≃ 1›)
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝¹ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 this✝ : sgn a ≃ 1 this : AP (Positive a) ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝² : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 this✝¹ : sgn a ≃ 1 this✝ : AP (Positive a) this : AP (Positive b) ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝¹ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 this✝ : sgn a ≃ 1 this : AP (Positive a) ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
exact AltPositive.mk ‹x ≃ a / b›
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝² : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 this✝¹ : sgn a ≃ 1 this✝ : AP (Positive a) this : AP (Positive b) ⊢ AltPositive x
no goals
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝² : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ 1 this✝¹ : sgn a ≃ 1 this✝ : AP (Positive a) this : AP (Positive b) ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : sgn (-b) ≃ 1 := calc sgn (-b) ≃ _ := Integer.sgn_compat_neg (-(sgn b)) ≃ _ := AA.subst₁ ‹sgn b ≃ -1› (-(-1)) ≃ _ := Integer.neg_involutive 1 ≃ _ := Rel.refl
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this : sgn (-b) ≃ 1 ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : sgn (-a) ≃ 1 := calc sgn (-a) ≃ _ := Integer.sgn_compat_neg (-(sgn a)) ≃ _ := AA.subst₁ ‹sgn a ≃ sgn b› (-(sgn b)) ≃ _ := Rel.symm Integer.sgn_compat_neg sgn (-b) ≃ _ := ‹sgn (-b) ≃ 1› 1 ≃ _ := Rel.refl
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this : sgn (-b) ≃ 1 ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝¹ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝ : sgn (-b) ≃ 1 this : sgn (-a) ≃ 1 ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this : sgn (-b) ≃ 1 ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : Positive (-a) := Integer.sgn_positive.mpr ‹sgn (-a) ≃ 1›
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝¹ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝ : sgn (-b) ≃ 1 this : sgn (-a) ≃ 1 ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝² : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝¹ : sgn (-b) ≃ 1 this✝ : sgn (-a) ≃ 1 this : Positive (-a) ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝¹ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝ : sgn (-b) ≃ 1 this : sgn (-a) ≃ 1 ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : Positive (-b) := Integer.sgn_positive.mpr ‹sgn (-b) ≃ 1›
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝² : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝¹ : sgn (-b) ≃ 1 this✝ : sgn (-a) ≃ 1 this : Positive (-a) ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁵ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝³ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝² : sgn (-b) ≃ 1 this✝¹ : sgn (-a) ≃ 1 this✝ : Positive (-a) this : Positive (-b) ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝² : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝¹ : sgn (-b) ≃ 1 this✝ : sgn (-a) ≃ 1 this : Positive (-a) ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : AP (Positive (-a)) := AP.mk ‹Positive (-a)›
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁵ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝³ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝² : sgn (-b) ≃ 1 this✝¹ : sgn (-a) ≃ 1 this✝ : Positive (-a) this : Positive (-b) ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁵ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁴ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝³ : sgn (-b) ≃ 1 this✝² : sgn (-a) ≃ 1 this✝¹ : Positive (-a) this✝ : Positive (-b) this : AP (Positive (-a)) ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁵ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝³ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝² : sgn (-b) ≃ 1 this✝¹ : sgn (-a) ≃ 1 this✝ : Positive (-a) this : Positive (-b) ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : AP (Positive (-b)) := AP.mk ‹Positive (-b)›
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁵ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁴ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝³ : sgn (-b) ≃ 1 this✝² : sgn (-a) ≃ 1 this✝¹ : Positive (-a) this✝ : Positive (-b) this : AP (Positive (-a)) ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁵ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝⁴ : sgn (-b) ≃ 1 this✝³ : sgn (-a) ≃ 1 this✝² : Positive (-a) this✝¹ : Positive (-b) this✝ : AP (Positive (-a)) this : AP (Positive (-b)) ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁵ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁴ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝³ : sgn (-b) ≃ 1 this✝² : sgn (-a) ≃ 1 this✝¹ : Positive (-a) this✝ : Positive (-b) this : AP (Positive (-a)) ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have neg_eqv {z : ℤ} : -(z : ℚ) ≃ ((-z : ℤ) : ℚ) := Rational.eqv_symm Rational.neg_compat_from_integer
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁵ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝⁴ : sgn (-b) ≃ 1 this✝³ : sgn (-a) ≃ 1 this✝² : Positive (-a) this✝¹ : Positive (-b) this✝ : AP (Positive (-a)) this : AP (Positive (-b)) ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁵ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝⁴ : sgn (-b) ≃ 1 this✝³ : sgn (-a) ≃ 1 this✝² : Positive (-a) this✝¹ : Positive (-b) this✝ : AP (Positive (-a)) this : AP (Positive (-b)) neg_eqv : ∀ {z : ℤ}, -Rational.from_integer z ≃ Rational.from_integer (-z) ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁵ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝⁴ : sgn (-b) ≃ 1 this✝³ : sgn (-a) ≃ 1 this✝² : Positive (-a) this✝¹ : Positive (-b) this✝ : AP (Positive (-a)) this : AP (Positive (-b)) ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : x ≃ ((-a : ℤ) : ℚ) / ((-b : ℤ) : ℚ) := calc x ≃ _ := ‹x ≃ a / b› (a : ℚ) / b ≃ _ := Rel.symm Rational.div_neg_cancel (-(a : ℚ)) / (-(b : ℚ)) ≃ _ := Rational.div_substL neg_eqv ((-a : ℤ) : ℚ) / (-b : ℚ) ≃ _ := Rational.div_substR neg_eqv ((-a : ℤ) : ℚ) / ((-b : ℤ) : ℚ) ≃ _ := Rational.eqv_refl
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁵ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝⁴ : sgn (-b) ≃ 1 this✝³ : sgn (-a) ≃ 1 this✝² : Positive (-a) this✝¹ : Positive (-b) this✝ : AP (Positive (-a)) this : AP (Positive (-b)) neg_eqv : ∀ {z : ℤ}, -Rational.from_integer z ≃ Rational.from_integer (-z) ⊢ AltPositive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁸ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁶ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝⁵ : sgn (-b) ≃ 1 this✝⁴ : sgn (-a) ≃ 1 this✝³ : Positive (-a) this✝² : Positive (-b) this✝¹ : AP (Positive (-a)) this✝ : AP (Positive (-b)) neg_eqv : ∀ {z : ℤ}, -Rational.from_integer z ≃ Rational.from_integer (-z) this : x ≃ Rational.from_integer (-a) / Rational.from_integer (-b) ⊢ AltPositive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁵ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝⁴ : sgn (-b) ≃ 1 this✝³ : sgn (-a) ≃ 1 this✝² : Positive (-a) this✝¹ : Positive (-b) this✝ : AP (Positive (-a)) this : AP (Positive (-b)) neg_eqv : ∀ {z : ℤ}, -Rational.from_integer z ≃ Rational.from_integer (-z) ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
exact AltPositive.mk this
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁸ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁶ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝⁵ : sgn (-b) ≃ 1 this✝⁴ : sgn (-a) ≃ 1 this✝³ : Positive (-a) this✝² : Positive (-b) this✝¹ : AP (Positive (-a)) this✝ : AP (Positive (-b)) neg_eqv : ∀ {z : ℤ}, -Rational.from_integer z ≃ Rational.from_integer (-z) this : x ≃ Rational.from_integer (-a) / Rational.from_integer (-b) ⊢ AltPositive x
no goals
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Positive x a b : Integer.Impl.Difference ℕ b_nonzero✝ : Nonzero b x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁸ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : sgn a * sgn b ≃ 1 left✝ : Integer.Sqrt1 (sgn b) right✝ : sgn a ≃ sgn b this✝⁶ : sgn b ≃ 1 ∨ sgn b ≃ -1 h✝ : sgn b ≃ -1 this✝⁵ : sgn (-b) ≃ 1 this✝⁴ : sgn (-a) ≃ 1 this✝³ : Positive (-a) this✝² : Positive (-b) this✝¹ : AP (Positive (-a)) this✝ : AP (Positive (-b)) neg_eqv : ∀ {z : ℤ}, -Rational.from_integer z ≃ Rational.from_integer (-z) this : x ≃ Rational.from_integer (-a) / Rational.from_integer (-b) ⊢ AltPositive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
intro (_ : AltPositive x)
ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ AltPositive x → Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ AltPositive x → Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have (AltPositive.intro (a : ℤ) (b : ℤ) a_pos b_pos x_eqv) := ‹AltPositive x›
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : AP (Positive a) := a_pos
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this : AP (Positive a) ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : sgn a ≃ 1 := Integer.sgn_positive.mp this.ev
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this : AP (Positive a) ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : AP (Positive a) this : sgn a ≃ 1 ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this : AP (Positive a) ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : AP (Positive b) := b_pos
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : AP (Positive a) this : sgn a ≃ 1 ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : AP (Positive a) this✝ : sgn a ≃ 1 this : AP (Positive b) ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : AP (Positive a) this : sgn a ≃ 1 ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : sgn b ≃ 1 := Integer.sgn_positive.mp this.ev
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : AP (Positive a) this✝ : sgn a ≃ 1 this : AP (Positive b) ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : AP (Positive a) this✝¹ : sgn a ≃ 1 this✝ : AP (Positive b) this : sgn b ≃ 1 ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : AP (Positive a) this✝ : sgn a ≃ 1 this : AP (Positive b) ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : x ≃ a / b := x_eqv
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : AP (Positive a) this✝¹ : sgn a ≃ 1 this✝ : AP (Positive b) this : sgn b ≃ 1 ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : AP (Positive a) this✝² : sgn a ≃ 1 this✝¹ : AP (Positive b) this✝ : sgn b ≃ 1 this : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : AP (Positive a) this✝¹ : sgn a ≃ 1 this✝ : AP (Positive b) this : sgn b ≃ 1 ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : sgn a ≃ sgn b := Rel.trans ‹sgn a ≃ 1› (Rel.symm ‹sgn b ≃ 1›)
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : AP (Positive a) this✝² : sgn a ≃ 1 this✝¹ : AP (Positive b) this✝ : sgn b ≃ 1 this : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : AP (Positive a) this✝³ : sgn a ≃ 1 this✝² : AP (Positive b) this✝¹ : sgn b ≃ 1 this✝ : x ≃ Rational.from_integer a / Rational.from_integer b this : sgn a ≃ sgn b ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : AP (Positive a) this✝² : sgn a ≃ 1 this✝¹ : AP (Positive b) this✝ : sgn b ≃ 1 this : x ≃ Rational.from_integer a / Rational.from_integer b ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : Integer.Nonzero b := Integer.nonzero_from_positive_inst
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : AP (Positive a) this✝³ : sgn a ≃ 1 this✝² : AP (Positive b) this✝¹ : sgn b ≃ 1 this✝ : x ≃ Rational.from_integer a / Rational.from_integer b this : sgn a ≃ sgn b ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁵ : AP (Positive a) this✝⁴ : sgn a ≃ 1 this✝³ : AP (Positive b) this✝² : sgn b ≃ 1 this✝¹ : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : sgn a ≃ sgn b this : Nonzero b ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : AP (Positive a) this✝³ : sgn a ≃ 1 this✝² : AP (Positive b) this✝¹ : sgn b ≃ 1 this✝ : x ≃ Rational.from_integer a / Rational.from_integer b this : sgn a ≃ sgn b ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : Integer.Sqrt1 (sgn b) := Integer.sgn_nonzero.mp this
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁵ : AP (Positive a) this✝⁴ : sgn a ≃ 1 this✝³ : AP (Positive b) this✝² : sgn b ≃ 1 this✝¹ : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : sgn a ≃ sgn b this : Nonzero b ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : AP (Positive a) this✝⁵ : sgn a ≃ 1 this✝⁴ : AP (Positive b) this✝³ : sgn b ≃ 1 this✝² : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : sgn a ≃ sgn b this✝ : Nonzero b this : Integer.Sqrt1 (sgn b) ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁵ : AP (Positive a) this✝⁴ : sgn a ≃ 1 this✝³ : AP (Positive b) this✝² : sgn b ≃ 1 this✝¹ : x ≃ Rational.from_integer a / Rational.from_integer b this✝ : sgn a ≃ sgn b this : Nonzero b ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : sgn a * sgn b ≃ 1 := Integer.mul_sqrt1_eqv.mpr (And.intro this ‹sgn a ≃ sgn b›)
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : AP (Positive a) this✝⁵ : sgn a ≃ 1 this✝⁴ : AP (Positive b) this✝³ : sgn b ≃ 1 this✝² : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : sgn a ≃ sgn b this✝ : Nonzero b this : Integer.Sqrt1 (sgn b) ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : AP (Positive a) this✝⁶ : sgn a ≃ 1 this✝⁵ : AP (Positive b) this✝⁴ : sgn b ≃ 1 this✝³ : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : sgn a ≃ sgn b this✝¹ : Nonzero b this✝ : Integer.Sqrt1 (sgn b) this : sgn a * sgn b ≃ 1 ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁶ : AP (Positive a) this✝⁵ : sgn a ≃ 1 this✝⁴ : AP (Positive b) this✝³ : sgn b ≃ 1 this✝² : x ≃ Rational.from_integer a / Rational.from_integer b this✝¹ : sgn a ≃ sgn b this✝ : Nonzero b this : Integer.Sqrt1 (sgn b) ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : sgn x ≃ 1 := calc sgn x ≃ _ := Rational.sgn_subst ‹x ≃ a / b› sgn ((a : ℚ) / (b : ℚ)) ≃ _ := Rational.sgn_div_integers sgn a * sgn b ≃ _ := ‹sgn a * sgn b ≃ 1› 1 ≃ _ := Rel.refl
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : AP (Positive a) this✝⁶ : sgn a ≃ 1 this✝⁵ : AP (Positive b) this✝⁴ : sgn b ≃ 1 this✝³ : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : sgn a ≃ sgn b this✝¹ : Nonzero b this✝ : Integer.Sqrt1 (sgn b) this : sgn a * sgn b ≃ 1 ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁸ : AP (Positive a) this✝⁷ : sgn a ≃ 1 this✝⁶ : AP (Positive b) this✝⁵ : sgn b ≃ 1 this✝⁴ : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : sgn a ≃ sgn b this✝² : Nonzero b this✝¹ : Integer.Sqrt1 (sgn b) this✝ : sgn a * sgn b ≃ 1 this : sgn x ≃ 1 ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁷ : AP (Positive a) this✝⁶ : sgn a ≃ 1 this✝⁵ : AP (Positive b) this✝⁴ : sgn b ≃ 1 this✝³ : x ≃ Rational.from_integer a / Rational.from_integer b this✝² : sgn a ≃ sgn b this✝¹ : Nonzero b this✝ : Integer.Sqrt1 (sgn b) this : sgn a * sgn b ≃ 1 ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
have : Positive x := Rational.sgn_positive.mpr this
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁸ : AP (Positive a) this✝⁷ : sgn a ≃ 1 this✝⁶ : AP (Positive b) this✝⁵ : sgn b ≃ 1 this✝⁴ : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : sgn a ≃ sgn b this✝² : Nonzero b this✝¹ : Integer.Sqrt1 (sgn b) this✝ : sgn a * sgn b ≃ 1 this : sgn x ≃ 1 ⊢ Positive x
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁹ : AP (Positive a) this✝⁸ : sgn a ≃ 1 this✝⁷ : AP (Positive b) this✝⁶ : sgn b ≃ 1 this✝⁵ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : sgn a ≃ sgn b this✝³ : Nonzero b this✝² : Integer.Sqrt1 (sgn b) this✝¹ : sgn a * sgn b ≃ 1 this✝ : sgn x ≃ 1 this : Positive x ⊢ Positive x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁸ : AP (Positive a) this✝⁷ : sgn a ≃ 1 this✝⁶ : AP (Positive b) this✝⁵ : sgn b ≃ 1 this✝⁴ : x ≃ Rational.from_integer a / Rational.from_integer b this✝³ : sgn a ≃ sgn b this✝² : Nonzero b this✝¹ : Integer.Sqrt1 (sgn b) this✝ : sgn a * sgn b ≃ 1 this : sgn x ≃ 1 ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.alt_positive
[401, 1]
[473, 15]
exact this
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁹ : AP (Positive a) this✝⁸ : sgn a ≃ 1 this✝⁷ : AP (Positive b) this✝⁶ : sgn b ≃ 1 this✝⁵ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : sgn a ≃ sgn b this✝³ : Nonzero b this✝² : Integer.Sqrt1 (sgn b) this✝¹ : sgn a * sgn b ≃ 1 this✝ : sgn x ≃ 1 this : Positive x ⊢ Positive x
no goals
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : AltPositive x a b : ℤ a_pos : AP (Positive a) b_pos : AP (Positive b) x_eqv : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁹ : AP (Positive a) this✝⁸ : sgn a ≃ 1 this✝⁷ : AP (Positive b) this✝⁶ : sgn b ≃ 1 this✝⁵ : x ≃ Rational.from_integer a / Rational.from_integer b this✝⁴ : sgn a ≃ sgn b this✝³ : Nonzero b this✝² : Integer.Sqrt1 (sgn b) this✝¹ : sgn a * sgn b ≃ 1 this✝ : sgn x ≃ 1 this : Positive x ⊢ Positive x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.negative_iff_neg_positive
[477, 1]
[503, 15]
apply Iff.intro
ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Negative x ↔ ∃ y, Positive y ∧ x ≃ -y
case mp ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Negative x → ∃ y, Positive y ∧ x ≃ -y case mpr ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ (∃ y, Positive y ∧ x ≃ -y) → Negative x
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Negative x ↔ ∃ y, Positive y ∧ x ≃ -y TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.negative_iff_neg_positive
[477, 1]
[503, 15]
case mp => intro (_ : Negative x) show ∃ (y : ℚ), Positive y ∧ x ≃ -y have : sgn x ≃ -1 := Rational.sgn_negative.mp ‹Negative x› have : sgn (-x) ≃ 1 := calc sgn (-x) ≃ _ := Rational.sgn_compat_neg (-sgn x) ≃ _ := AA.subst₁ ‹sgn x ≃ -1› (-(-1)) ≃ _ := Integer.neg_involutive 1 ≃ _ := Rel.refl have : Positive (-x) := Rational.sgn_positive.mpr ‹sgn (-x) ≃ 1› have : x ≃ -(-x) := Rational.eqv_symm Rational.neg_involutive exact Exists.intro (-x) (And.intro ‹Positive (-x)› ‹x ≃ -(-x)›)
ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Negative x → ∃ y, Positive y ∧ x ≃ -y
no goals
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Negative x → ∃ y, Positive y ∧ x ≃ -y TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.negative_iff_neg_positive
[477, 1]
[503, 15]
case mpr => intro (Exists.intro (y : ℚ) (And.intro (_ : Positive y) (_ : x ≃ -y))) show Negative x have : sgn y ≃ 1 := Rational.sgn_positive.mp ‹Positive y› have : sgn x ≃ -1 := calc sgn x ≃ _ := Rational.sgn_subst ‹x ≃ -y› sgn (-y) ≃ _ := Rational.sgn_compat_neg (-(sgn y)) ≃ _ := AA.subst₁ ‹sgn y ≃ 1› (-1) ≃ _ := Rel.refl have : Negative x := Rational.sgn_negative.mpr this exact this
ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ (∃ y, Positive y ∧ x ≃ -y) → Negative x
no goals
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ (∃ y, Positive y ∧ x ≃ -y) → Negative x TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.negative_iff_neg_positive
[477, 1]
[503, 15]
intro (_ : Negative x)
ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Negative x → ∃ y, Positive y ∧ x ≃ -y
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Negative x ⊢ ∃ y, Positive y ∧ x ≃ -y
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ ⊢ Negative x → ∃ y, Positive y ∧ x ≃ -y TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.negative_iff_neg_positive
[477, 1]
[503, 15]
have : sgn x ≃ -1 := Rational.sgn_negative.mp ‹Negative x›
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Negative x ⊢ ∃ y, Positive y ∧ x ≃ -y
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Negative x this : sgn x ≃ -1 ⊢ ∃ y, Positive y ∧ x ≃ -y
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Negative x ⊢ ∃ y, Positive y ∧ x ≃ -y TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.negative_iff_neg_positive
[477, 1]
[503, 15]
have : sgn (-x) ≃ 1 := calc sgn (-x) ≃ _ := Rational.sgn_compat_neg (-sgn x) ≃ _ := AA.subst₁ ‹sgn x ≃ -1› (-(-1)) ≃ _ := Integer.neg_involutive 1 ≃ _ := Rel.refl
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Negative x this : sgn x ≃ -1 ⊢ ∃ y, Positive y ∧ x ≃ -y
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Negative x this✝ : sgn x ≃ -1 this : sgn (-x) ≃ 1 ⊢ ∃ y, Positive y ∧ x ≃ -y
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Negative x this : sgn x ≃ -1 ⊢ ∃ y, Positive y ∧ x ≃ -y TACTIC:
https://github.com/cruhland/lean4-analysis.git
e48553c40a65962fa08f8a86a9001433bf422a62
Lean4Analysis/Ch4/Ch4Sec2Rationals.lean
AnalysisI.Ch4.Sec2.negative_iff_neg_positive
[477, 1]
[503, 15]
have : Positive (-x) := Rational.sgn_positive.mpr ‹sgn (-x) ≃ 1›
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Negative x this✝ : sgn x ≃ -1 this : sgn (-x) ≃ 1 ⊢ ∃ y, Positive y ∧ x ≃ -y
ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Negative x this✝¹ : sgn x ≃ -1 this✝ : sgn (-x) ≃ 1 this : Positive (-x) ⊢ ∃ y, Positive y ∧ x ≃ -y
Please generate a tactic in lean4 to solve the state. STATE: ℚ : Type inst✝ : Rational ℚ x : ℚ x✝ : Negative x this✝ : sgn x ≃ -1 this : sgn (-x) ≃ 1 ⊢ ∃ y, Positive y ∧ x ≃ -y TACTIC: