Theorem: LaurentPolynomial.isLocalization
File: Mathlib/Algebra/Polynomial/Laurent.lean

Proof steps:
state_before: R : Type u_1
inst✝ : CommSemiring R
t : ↥(Submonoid.closure {X})
⊢ IsUnit ((algebraMap R[X] R[T;T⁻¹]) ↑t)
state_after: case mk
R : Type u_1
inst✝ : CommSemiring R
t : R[X]
ht : t ∈ Submonoid.closure {X}
⊢ IsUnit ((algebraMap R[X] R[T;T⁻¹]) ↑⟨t, ht⟩)
tactic: cases' t with t ht
state_before: case mk
R : Type u_1
inst✝ : CommSemiring R
t : R[X]
ht : t ∈ Submonoid.closure {X}
⊢ IsUnit ((algebraMap R[X] R[T;T⁻¹]) ↑⟨t, ht⟩)
state_after: case mk.intro
R : Type u_1
inst✝ : CommSemiring R
n : ℕ
ht : X ^ n ∈ Submonoid.closure {X}
⊢ IsUnit ((algebraMap R[X] R[T;T⁻¹]) ↑⟨X ^ n, ht⟩)
tactic: rcases Submonoid.mem_closure_singleton.mp ht with ⟨n, rfl⟩
state_before: case mk.intro
R : Type u_1
inst✝ : CommSemiring R
n : ℕ
ht : X ^ n ∈ Submonoid.closure {X}
⊢ IsUnit ((algebraMap R[X] R[T;T⁻¹]) ↑⟨X ^ n, ht⟩)
state_after: no goals
tactic: simp only [isUnit_T n, algebraMap_eq_toLaurent, Polynomial.toLaurent_X_pow]
state_before: R : Type u_1
inst✝ : CommSemiring R
f : R[T;T⁻¹]
⊢ ∃ x, f * (algebraMap R[X] R[T;T⁻¹]) ↑x.2 = (algebraMap R[X] R[T;T⁻¹]) x.1
state_after: case Qf
R : Type u_1
inst✝ : CommSemiring R
f : R[X]
n : ℕ
⊢ ∃ x, toLaurent f * T (-↑n) * (algebraMap R[X] R[T;T⁻¹]) ↑x.2 = (algebraMap R[X] R[T;T⁻¹]) x.1
tactic: induction' f using LaurentPolynomial.induction_on_mul_T with f n
state_before: case Qf
R : Type u_1
inst✝ : CommSemiring R
f : R[X]
n : ℕ
⊢ ∃ x, toLaurent f * T (-↑n) * (algebraMap R[X] R[T;T⁻¹]) ↑x.2 = (algebraMap R[X] R[T;T⁻¹]) x.1
state_after: case Qf
R : Type u_1
inst✝ : CommSemiring R
f : R[X]
n : ℕ
this : X ^ n ∈ Submonoid.closure {X}
⊢ ∃ x, toLaurent f * T (-↑n) * (algebraMap R[X] R[T;T⁻¹]) ↑x.2 = (algebraMap R[X] R[T;T⁻¹]) x.1
tactic: have := (Submonoid.closure ({X} : Set R[X])).pow_mem Submonoid.mem_closure_singleton_self n
state_before: case Qf
R : Type u_1
inst✝ : CommSemiring R
f : R[X]
n : ℕ
this : X ^ n ∈ Submonoid.closure {X}
⊢ ∃ x, toLaurent f * T (-↑n) * (algebraMap R[X] R[T;T⁻¹]) ↑x.2 = (algebraMap R[X] R[T;T⁻¹]) x.1
state_after: case Qf
R : Type u_1
inst✝ : CommSemiring R
f : R[X]
n : ℕ
this : X ^ n ∈ Submonoid.closure {X}
⊢ toLaurent f * T (-↑n) * (algebraMap R[X] R[T;T⁻¹]) ↑(f, ⟨X ^ n, this⟩).2 =
    (algebraMap R[X] R[T;T⁻¹]) (f, ⟨X ^ n, this⟩).1
tactic: refine ⟨(f, ⟨_, this⟩), ?_⟩
state_before: case Qf
R : Type u_1
inst✝ : CommSemiring R
f : R[X]
n : ℕ
this : X ^ n ∈ Submonoid.closure {X}
⊢ toLaurent f * T (-↑n) * (algebraMap R[X] R[T;T⁻¹]) ↑(f, ⟨X ^ n, this⟩).2 =
    (algebraMap R[X] R[T;T⁻¹]) (f, ⟨X ^ n, this⟩).1
state_after: no goals
tactic: simp only [algebraMap_eq_toLaurent, Polynomial.toLaurent_X_pow, mul_T_assoc,
        add_left_neg, T_zero, mul_one]
state_before: R : Type u_1
inst✝ : CommSemiring R
f g : R[X]
⊢ (algebraMap R[X] R[T;T⁻¹]) f = (algebraMap R[X] R[T;T⁻¹]) g → ∃ c, ↑c * f = ↑c * g
state_after: R : Type u_1
inst✝ : CommSemiring R
f g : R[X]
⊢ f = g → ∃ c, ↑c * f = ↑c * g
tactic: rw [algebraMap_eq_toLaurent, algebraMap_eq_toLaurent, Polynomial.toLaurent_inj]
state_before: R : Type u_1
inst✝ : CommSemiring R
f g : R[X]
⊢ f = g → ∃ c, ↑c * f = ↑c * g
state_after: R : Type u_1
inst✝ : CommSemiring R
f : R[X]
⊢ ∃ c, ↑c * f = ↑c * f
tactic: rintro rfl
state_before: R : Type u_1
inst✝ : CommSemiring R
f : R[X]
⊢ ∃ c, ↑c * f = ↑c * f
state_after: no goals
tactic: exact ⟨1, rfl⟩