Theorem: multiplicity.exists_eq_pow_mul_and_not_dvd
File: Mathlib/RingTheory/Multiplicity.lean

tactic: obtain ⟨c, hc⟩ := multiplicity.pow_multiplicity_dvd hfin
state_before: α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
⊢ ∃ c, b = a ^ (multiplicity a b).get hfin * c ∧ ¬a ∣ c
state_after: case intro
α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c : α
hc : b = a ^ (multiplicity a b).get hfin * c
⊢ ∃ c, b = a ^ (multiplicity a b).get hfin * c ∧ ¬a ∣ c

tactic: refine ⟨c, hc, ?_⟩
state_before: case intro
α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c : α
hc : b = a ^ (multiplicity a b).get hfin * c
⊢ ∃ c, b = a ^ (multiplicity a b).get hfin * c ∧ ¬a ∣ c
state_after: case intro
α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c : α
hc : b = a ^ (multiplicity a b).get hfin * c
⊢ ¬a ∣ c

tactic: rintro ⟨k, hk⟩
state_before: case intro
α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c : α
hc : b = a ^ (multiplicity a b).get hfin * c
⊢ ¬a ∣ c
state_after: case intro.intro
α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c : α
hc : b = a ^ (multiplicity a b).get hfin * c
k : α
hk : c = a * k
⊢ False

tactic: rw [hk, ← mul_assoc, ← _root_.pow_succ] at hc
state_before: case intro.intro
α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c : α
hc : b = a ^ (multiplicity a b).get hfin * c
k : α
hk : c = a * k
⊢ False
state_after: case intro.intro
α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c k : α
hc : b = a ^ ((multiplicity a b).get hfin + 1) * k
hk : c = a * k
⊢ False

tactic: have h₁ : a ^ ((multiplicity a b).get hfin + 1) ∣ b := ⟨k, hc⟩
state_before: case intro.intro
α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c k : α
hc : b = a ^ ((multiplicity a b).get hfin + 1) * k
hk : c = a * k
⊢ False
state_after: case intro.intro
α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c k : α
hc : b = a ^ ((multiplicity a b).get hfin + 1) * k
hk : c = a * k
h₁ : a ^ ((multiplicity a b).get hfin + 1) ∣ b
⊢ False

tactic: exact (multiplicity.eq_coe_iff.1 (by simp)).2 h₁
state_before: case intro.intro
α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c k : α
hc : b = a ^ ((multiplicity a b).get hfin + 1) * k
hk : c = a * k
h₁ : a ^ ((multiplicity a b).get hfin + 1) ∣ b
⊢ False
state_after: no goals

tactic: simp
state_before: α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
hfin : Finite a b
c k : α
hc : b = a ^ ((multiplicity a b).get hfin + 1) * k
hk : c = a * k
h₁ : a ^ ((multiplicity a b).get hfin + 1) ∣ b
⊢ multiplicity a b = ↑((multiplicity a b).get hfin)
state_after: no goals