l3lab/ntp-mathlib huggingface dataset:
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, zero_mul, mk_zero]
    mul_zero := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, mul_zero, mk_zero]
    left_distrib := fun e f g =>
      Quot.inductionOn e fun ⟨m, x⟩ =>
        Quot.inductionOn f fun ⟨n, y⟩ =>
          Quot.inductionOn g fun ⟨s, z⟩ => by
            simp only [quot_mk_eq_mk, mk_add_mk, mk_mul_mk] -- Porting note: added this line
            simp only [add_assoc, add_comm, add_left_comm]
            apply R.sound
            

Proof state:
case H
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
e f g : PerfectClosure K p
x✝² : ℕ × K
m : ℕ
x : K
x✝¹ : ℕ × K
n : ℕ
y : K
x✝ : ℕ × K
s : ℕ
z : K
⊢ (⇑(frobenius K p))^[m]
      ((⇑(frobenius K p))^[n + s] x * (⇑(frobenius K p))^[m] ((⇑(frobenius K p))^[n] z + (⇑(frobenius K p))^[s] y)) =
    (⇑(frobenius K p))^[m + n] ((⇑(frobenius K p))^[s] x * (⇑(frobenius K p))^[m] z) +
      (⇑(frobenius K p))^[m + s] ((⇑(frobenius K p))^[n] x * (⇑(frobenius K p))^[m] y)

Next tactic:
simp only [iterate_map_mul, iterate_map_add, ← iterate_add_apply,
              mul_add, add_comm, add_left_comm]
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, zero_mul, mk_zero]
    mul_zero := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, mul_zero, mk_zero]
    left_distrib := fun e f g =>
      Quot.inductionOn e fun ⟨m, x⟩ =>
        Quot.inductionOn f fun ⟨n, y⟩ =>
          Quot.inductionOn g fun ⟨s, z⟩ => by
            simp only [quot_mk_eq_mk, mk_add_mk, mk_mul_mk] -- Porting note: added this line
            simp only [add_assoc, add_comm, add_left_comm]
            apply R.sound
            simp only [iterate_map_mul, iterate_map_add, ← iterate_add_apply,
              mul_add, add_comm, add_left_comm]
    right_distrib := fun e f g =>
      Quot.inductionOn e fun ⟨m, x⟩ =>
        Quot.inductionOn f fun ⟨n, y⟩ =>
          Quot.inductionOn g fun ⟨s, z⟩ => by
            

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
e f g : PerfectClosure K p
x✝² : ℕ × K
m : ℕ
x : K
x✝¹ : ℕ × K
n : ℕ
y : K
x✝ : ℕ × K
s : ℕ
z : K
⊢ (Quot.mk (R K p) (m, x) + Quot.mk (R K p) (n, y)) * Quot.mk (R K p) (s, z) =
    Quot.mk (R K p) (m, x) * Quot.mk (R K p) (s, z) + Quot.mk (R K p) (n, y) * Quot.mk (R K p) (s, z)

Next tactic:
simp only [quot_mk_eq_mk, mk_add_mk, mk_mul_mk]
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, zero_mul, mk_zero]
    mul_zero := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, mul_zero, mk_zero]
    left_distrib := fun e f g =>
      Quot.inductionOn e fun ⟨m, x⟩ =>
        Quot.inductionOn f fun ⟨n, y⟩ =>
          Quot.inductionOn g fun ⟨s, z⟩ => by
            simp only [quot_mk_eq_mk, mk_add_mk, mk_mul_mk] -- Porting note: added this line
            simp only [add_assoc, add_comm, add_left_comm]
            apply R.sound
            simp only [iterate_map_mul, iterate_map_add, ← iterate_add_apply,
              mul_add, add_comm, add_left_comm]
    right_distrib := fun e f g =>
      Quot.inductionOn e fun ⟨m, x⟩ =>
        Quot.inductionOn f fun ⟨n, y⟩ =>
          Quot.inductionOn g fun ⟨s, z⟩ => by
            simp only [quot_mk_eq_mk, mk_add_mk, mk_mul_mk] -- Porting note: added this line
            

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
e f g : PerfectClosure K p
x✝² : ℕ × K
m : ℕ
x : K
x✝¹ : ℕ × K
n : ℕ
y : K
x✝ : ℕ × K
s : ℕ
z : K
⊢ mk K p
      (m + n + s,
        (⇑(frobenius K p))^[s] ((⇑(frobenius K p))^[n] x + (⇑(frobenius K p))^[m] y) * (⇑(frobenius K p))^[m + n] z) =
    mk K p
      (m + s + (n + s),
        (⇑(frobenius K p))^[n + s] ((⇑(frobenius K p))^[s] x * (⇑(frobenius K p))^[m] z) +
          (⇑(frobenius K p))^[m + s] ((⇑(frobenius K p))^[s] y * (⇑(frobenius K p))^[n] z))

Next tactic:
simp only [add_assoc, add_comm _ s, add_left_comm _ s]
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, zero_mul, mk_zero]
    mul_zero := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, mul_zero, mk_zero]
    left_distrib := fun e f g =>
      Quot.inductionOn e fun ⟨m, x⟩ =>
        Quot.inductionOn f fun ⟨n, y⟩ =>
          Quot.inductionOn g fun ⟨s, z⟩ => by
            simp only [quot_mk_eq_mk, mk_add_mk, mk_mul_mk] -- Porting note: added this line
            simp only [add_assoc, add_comm, add_left_comm]
            apply R.sound
            simp only [iterate_map_mul, iterate_map_add, ← iterate_add_apply,
              mul_add, add_comm, add_left_comm]
    right_distrib := fun e f g =>
      Quot.inductionOn e fun ⟨m, x⟩ =>
        Quot.inductionOn f fun ⟨n, y⟩ =>
          Quot.inductionOn g fun ⟨s, z⟩ => by
            simp only [quot_mk_eq_mk, mk_add_mk, mk_mul_mk] -- Porting note: added this line
            simp only [add_assoc, add_comm _ s, add_left_comm _ s]
            

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
e f g : PerfectClosure K p
x✝² : ℕ × K
m : ℕ
x : K
x✝¹ : ℕ × K
n : ℕ
y : K
x✝ : ℕ × K
s : ℕ
z : K
⊢ mk K p
      (s + (m + n),
        (⇑(frobenius K p))^[s] ((⇑(frobenius K p))^[n] x + (⇑(frobenius K p))^[m] y) * (⇑(frobenius K p))^[m + n] z) =
    mk K p
      (s + (s + (m + n)),
        (⇑(frobenius K p))^[s + n] ((⇑(frobenius K p))^[s] x * (⇑(frobenius K p))^[m] z) +
          (⇑(frobenius K p))^[s + m] ((⇑(frobenius K p))^[s] y * (⇑(frobenius K p))^[n] z))

Next tactic:
apply R.sound
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, zero_mul, mk_zero]
    mul_zero := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, mul_zero, mk_zero]
    left_distrib := fun e f g =>
      Quot.inductionOn e fun ⟨m, x⟩ =>
        Quot.inductionOn f fun ⟨n, y⟩ =>
          Quot.inductionOn g fun ⟨s, z⟩ => by
            simp only [quot_mk_eq_mk, mk_add_mk, mk_mul_mk] -- Porting note: added this line
            simp only [add_assoc, add_comm, add_left_comm]
            apply R.sound
            simp only [iterate_map_mul, iterate_map_add, ← iterate_add_apply,
              mul_add, add_comm, add_left_comm]
    right_distrib := fun e f g =>
      Quot.inductionOn e fun ⟨m, x⟩ =>
        Quot.inductionOn f fun ⟨n, y⟩ =>
          Quot.inductionOn g fun ⟨s, z⟩ => by
            simp only [quot_mk_eq_mk, mk_add_mk, mk_mul_mk] -- Porting note: added this line
            simp only [add_assoc, add_comm _ s, add_left_comm _ s]
            apply R.sound
            

Proof state:
case H
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
e f g : PerfectClosure K p
x✝² : ℕ × K
m : ℕ
x : K
x✝¹ : ℕ × K
n : ℕ
y : K
x✝ : ℕ × K
s : ℕ
z : K
⊢ (⇑(frobenius K p))^[s]
      ((⇑(frobenius K p))^[s] ((⇑(frobenius K p))^[n] x + (⇑(frobenius K p))^[m] y) * (⇑(frobenius K p))^[m + n] z) =
    (⇑(frobenius K p))^[s + n] ((⇑(frobenius K p))^[s] x * (⇑(frobenius K p))^[m] z) +
      (⇑(frobenius K p))^[s + m] ((⇑(frobenius K p))^[s] y * (⇑(frobenius K p))^[n] z)

Next tactic:
simp only [iterate_map_mul, iterate_map_add, ← iterate_add_apply,
              add_mul, add_comm, add_left_comm]
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
a : PerfectClosure K p
⊢ 0 * a = 0

Next tactic:
refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
a : PerfectClosure K p
x✝ : ℕ × K
m : ℕ
x : K
⊢ 0 * Quot.mk (R K p) (m, x) = 0

Next tactic:
rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
a : PerfectClosure K p
x✝ : ℕ × K
m : ℕ
x : K
⊢ mk K p ((0, 0).1 + (m, x).1, (⇑(frobenius K p))^[(m, x).1] (0, 0).2 * (⇑(frobenius K p))^[(0, 0).1] (m, x).2) =
    mk K p (0, 0)

Next tactic:
simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, zero_mul, mk_zero]
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, zero_mul, mk_zero]
    mul_zero := fun a => by
      

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
a : PerfectClosure K p
⊢ a * 0 = 0

Next tactic:
refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, zero_mul, mk_zero]
    mul_zero := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
a : PerfectClosure K p
x✝ : ℕ × K
m : ℕ
x : K
⊢ Quot.mk (R K p) (m, x) * 0 = 0

Next tactic:
rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
instance PerfectClosure.commRing : CommRing (PerfectClosure K p) :=
  { PerfectClosure.addCommGroup K p, AddMonoidWithOne.unary,
    (inferInstance : CommMonoid (PerfectClosure K p)) with
    -- Porting note: added `zero_mul`, `mul_zero`
    zero_mul := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, zero_mul, mk_zero]
    mul_zero := fun a => by
      refine Quot.inductionOn a fun ⟨m, x⟩ => ?_
      rw [zero_def, quot_mk_eq_mk, mk_mul_mk]
      

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
src✝² : AddCommGroup (PerfectClosure K p) := addCommGroup K p
src✝¹ : AddMonoidWithOne (PerfectClosure K p) := AddMonoidWithOne.unary
src✝ : CommMonoid (PerfectClosure K p) := inferInstance
a : PerfectClosure K p
x✝ : ℕ × K
m : ℕ
x : K
⊢ mk K p ((m, x).1 + (0, 0).1, (⇑(frobenius K p))^[(0, 0).1] (m, x).2 * (⇑(frobenius K p))^[(m, x).1] (0, 0).2) =
    mk K p (0, 0)

Next tactic:
simp only [zero_add, iterate_zero, id_eq, RingHom.iterate_map_zero, mul_zero, mk_zero]
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y : ℕ × K
⊢ mk K p x = mk K p y ↔ ∃ z, (⇑(frobenius K p))^[y.1 + z] x.2 = (⇑(frobenius K p))^[x.1 + z] y.2

Next tactic:
constructor
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · 

Proof state:
case mp
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y : ℕ × K
⊢ mk K p x = mk K p y → ∃ z, (⇑(frobenius K p))^[y.1 + z] x.2 = (⇑(frobenius K p))^[x.1 + z] y.2

Next tactic:
intro H
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    

Proof state:
case mp
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y : ℕ × K
H : mk K p x = mk K p y
⊢ ∃ z, (⇑(frobenius K p))^[y.1 + z] x.2 = (⇑(frobenius K p))^[x.1 + z] y.2

Next tactic:
replace H := Quot.exact _ H
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    replace H := Quot.exact _ H
    

Proof state:
case mp
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y : ℕ × K
H : EqvGen (R K p) x y
⊢ ∃ z, (⇑(frobenius K p))^[y.1 + z] x.2 = (⇑(frobenius K p))^[x.1 + z] y.2

Next tactic:
induction H
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    replace H := Quot.exact _ H
    induction H
    

Proof state:
case mp.rel
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y x✝ y✝ : ℕ × K
a✝ : R K p x✝ y✝
⊢ ∃ z, (⇑(frobenius K p))^[y✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] y✝.2
case mp.refl
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y x✝ : ℕ × K
⊢ ∃ z, (⇑(frobenius K p))^[x✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] x✝.2
case mp.symm
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y x✝ y✝ : ℕ × K
a✝ : EqvGen (R K p) x✝ y✝
a_ih✝ : ∃ z, (⇑(frobenius K p))^[y✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] y✝.2
⊢ ∃ z, (⇑(frobenius K p))^[x✝.1 + z] y✝.2 = (⇑(frobenius K p))^[y✝.1 + z] x✝.2
case mp.trans
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y x✝ y✝ z✝ : ℕ × K
a✝¹ : EqvGen (R K p) x✝ y✝
a✝ : EqvGen (R K p) y✝ z✝
a_ih✝¹ : ∃ z, (⇑(frobenius K p))^[y✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] y✝.2
a_ih✝ : ∃ z, (⇑(frobenius K p))^[z✝.1 + z] y✝.2 = (⇑(frobenius K p))^[y✝.1 + z] z✝.2
⊢ ∃ z, (⇑(frobenius K p))^[z✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] z✝.2

Next tactic:
case rel x y H => cases' H with n x; exact ⟨0, rfl⟩
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    replace H := Quot.exact _ H
    induction H
    

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x✝ y✝ x y : ℕ × K
H : R K p x y
⊢ ∃ z, (⇑(frobenius K p))^[y.1 + z] x.2 = (⇑(frobenius K p))^[x.1 + z] y.2

Next tactic:
case rel x y H => cases' H with n x; exact ⟨0, rfl⟩
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    replace H := Quot.exact _ H
    induction H
    case rel x y H => 

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x✝ y✝ x y : ℕ × K
H : R K p x y
⊢ ∃ z, (⇑(frobenius K p))^[y.1 + z] x.2 = (⇑(frobenius K p))^[x.1 + z] y.2

Next tactic:
cases' H with n x
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    replace H := Quot.exact _ H
    induction H
    case rel x y H => cases' H with n x; 

Proof state:
case intro
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x✝ y : ℕ × K
n : ℕ
x : K
⊢ ∃ z,
    (⇑(frobenius K p))^[(n + 1, (frobenius K p) x).1 + z] (n, x).2 =
      (⇑(frobenius K p))^[(n, x).1 + z] (n + 1, (frobenius K p) x).2

Next tactic:
exact ⟨0, rfl⟩
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    replace H := Quot.exact _ H
    induction H
    case rel x y H => cases' H with n x; exact ⟨0, rfl⟩
    

Proof state:
case mp.refl
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y x✝ : ℕ × K
⊢ ∃ z, (⇑(frobenius K p))^[x✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] x✝.2
case mp.symm
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y x✝ y✝ : ℕ × K
a✝ : EqvGen (R K p) x✝ y✝
a_ih✝ : ∃ z, (⇑(frobenius K p))^[y✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] y✝.2
⊢ ∃ z, (⇑(frobenius K p))^[x✝.1 + z] y✝.2 = (⇑(frobenius K p))^[y✝.1 + z] x✝.2
case mp.trans
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y x✝ y✝ z✝ : ℕ × K
a✝¹ : EqvGen (R K p) x✝ y✝
a✝ : EqvGen (R K p) y✝ z✝
a_ih✝¹ : ∃ z, (⇑(frobenius K p))^[y✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] y✝.2
a_ih✝ : ∃ z, (⇑(frobenius K p))^[z✝.1 + z] y✝.2 = (⇑(frobenius K p))^[y✝.1 + z] z✝.2
⊢ ∃ z, (⇑(frobenius K p))^[z✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] z✝.2

Next tactic:
case refl H => exact ⟨0, rfl⟩
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    replace H := Quot.exact _ H
    induction H
    case rel x y H => cases' H with n x; exact ⟨0, rfl⟩
    

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y H : ℕ × K
⊢ ∃ z, (⇑(frobenius K p))^[H.1 + z] H.2 = (⇑(frobenius K p))^[H.1 + z] H.2

Next tactic:
case refl H => exact ⟨0, rfl⟩
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    replace H := Quot.exact _ H
    induction H
    case rel x y H => cases' H with n x; exact ⟨0, rfl⟩
    case refl H => 

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y H : ℕ × K
⊢ ∃ z, (⇑(frobenius K p))^[H.1 + z] H.2 = (⇑(frobenius K p))^[H.1 + z] H.2

Next tactic:
exact ⟨0, rfl⟩
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    replace H := Quot.exact _ H
    induction H
    case rel x y H => cases' H with n x; exact ⟨0, rfl⟩
    case refl H => exact ⟨0, rfl⟩
    

Proof state:
case mp.symm
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y x✝ y✝ : ℕ × K
a✝ : EqvGen (R K p) x✝ y✝
a_ih✝ : ∃ z, (⇑(frobenius K p))^[y✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] y✝.2
⊢ ∃ z, (⇑(frobenius K p))^[x✝.1 + z] y✝.2 = (⇑(frobenius K p))^[y✝.1 + z] x✝.2
case mp.trans
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x y x✝ y✝ z✝ : ℕ × K
a✝¹ : EqvGen (R K p) x✝ y✝
a✝ : EqvGen (R K p) y✝ z✝
a_ih✝¹ : ∃ z, (⇑(frobenius K p))^[y✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] y✝.2
a_ih✝ : ∃ z, (⇑(frobenius K p))^[z✝.1 + z] y✝.2 = (⇑(frobenius K p))^[y✝.1 + z] z✝.2
⊢ ∃ z, (⇑(frobenius K p))^[z✝.1 + z] x✝.2 = (⇑(frobenius K p))^[x✝.1 + z] z✝.2

Next tactic:
case symm x y H ih => cases' ih with w ih; exact ⟨w, ih.symm⟩
theorem eq_iff' (x y : ℕ × K) :
    mk K p x = mk K p y ↔ ∃ z, (frobenius K p)^[y.1 + z] x.2 = (frobenius K p)^[x.1 + z] y.2 := by
  constructor
  · intro H
    replace H := Quot.exact _ H
    induction H
    case rel x y H => cases' H with n x; exact ⟨0, rfl⟩
    case refl H => exact ⟨0, rfl⟩
    

Proof state:
K : Type u
inst✝² : CommRing K
p : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : CharP K p
x✝ y✝ x y : ℕ × K
H : EqvGen (R K p) x y
ih : ∃ z, (⇑(frobenius K p))^[y.1 + z] x.2 = (⇑(frobenius K p))^[x.1 + z] y.2
⊢ ∃ z, (⇑(frobenius K p))^[x.1 + z] y.2 = (⇑(frobenius K p))^[y.1 + z] x.2

Next tactic:
case symm x y H ih => cases' ih with w ih; exact ⟨w, ih.symm⟩