Theorem: IsAlgClosed.ringEquivOfCardinalEqOfCharP
File: Mathlib/FieldTheory/IsAlgClosed/Classification.lean

tactic: apply Classical.choice
state_before: K L : Type
inst✝⁶ : Field K
inst✝⁵ : Field L
inst✝⁴ : IsAlgClosed K
inst✝³ : IsAlgClosed L
p : ℕ
inst✝² : Fact (Nat.Prime p)
inst✝¹ : CharP K p
inst✝ : CharP L p
hK : ℵ₀ < (#K)
hKL : (#K) = (#L)
⊢ K ≃+* L

tactic: cases' exists_isTranscendenceBasis (ZMod p)
  (show Function.Injective (algebraMap (ZMod p) K) from RingHom.injective _) with s hs
state_before: case a
K L : Type
inst✝⁶ : Field K
inst✝⁵ : Field L
inst✝⁴ : IsAlgClosed K
inst✝³ : IsAlgClosed L
p : ℕ
inst✝² : Fact (Nat.Prime p)
inst✝¹ : CharP K p
inst✝ : CharP L p
hK : ℵ₀ < (#K)
hKL : (#K) = (#L)
⊢ Nonempty (K ≃+* L)

tactic: cases' exists_isTranscendenceBasis (ZMod p)
  (show Function.Injective (algebraMap (ZMod p) L) from RingHom.injective _) with t ht
state_before: case a.intro
K L : Type
inst✝⁶ : Field K
inst✝⁵ : Field L
inst✝⁴ : IsAlgClosed K
inst✝³ : IsAlgClosed L
p : ℕ
inst✝² : Fact (Nat.Prime p)
inst✝¹ : CharP K p
inst✝ : CharP L p
hK : ℵ₀ < (#K)
hKL : (#K) = (#L)
s : Set K
hs : IsTranscendenceBasis (ZMod p) Subtype.val
⊢ Nonempty (K ≃+* L)

tactic: have : (#s) = (#t) := by
  rw [← cardinal_eq_cardinal_transcendence_basis_of_aleph0_lt _ hs
    (lt_aleph0_of_finite (ZMod p)).le hK,
    ← cardinal_eq_cardinal_transcendence_basis_of_aleph0_lt _ ht
      (lt_aleph0_of_finite (ZMod p)).le, hKL]
  rwa [← hKL]
state_before: case a.intro.intro
K L : Type
inst✝⁶ : Field K
inst✝⁵ : Field L
inst✝⁴ : IsAlgClosed K
inst✝³ : IsAlgClosed L
p : ℕ
inst✝² : Fact (Nat.Prime p)
inst✝¹ : CharP K p
inst✝ : CharP L p
hK : ℵ₀ < (#K)
hKL : (#K) = (#L)
s : Set K
hs : IsTranscendenceBasis (ZMod p) Subtype.val
t : Set L
ht : IsTranscendenceBasis (ZMod p) Subtype.val
⊢ Nonempty (K ≃+* L)

tactic: cases' Cardinal.eq.1 this with e
state_before: case a.intro.intro
K L : Type
inst✝⁶ : Field K
inst✝⁵ : Field L
inst✝⁴ : IsAlgClosed K
inst✝³ : IsAlgClosed L
p : ℕ
inst✝² : Fact (Nat.Prime p)
inst✝¹ : CharP K p
inst✝ : CharP L p
hK : ℵ₀ < (#K)
hKL : (#K) = (#L)
s : Set K
hs : IsTranscendenceBasis (ZMod p) Subtype.val
t : Set L
ht : IsTranscendenceBasis (ZMod p) Subtype.val
this : (#↑s) = (#↑t)
⊢ Nonempty (K ≃+* L)

tactic: exact ⟨equivOfTranscendenceBasis _ _ e hs ht⟩
state_before: case a.intro.intro.intro
K L : Type
inst✝⁶ : Field K
inst✝⁵ : Field L
inst✝⁴ : IsAlgClosed K
inst✝³ : IsAlgClosed L
p : ℕ
inst✝² : Fact (Nat.Prime p)
inst✝¹ : CharP K p
inst✝ : CharP L p
hK : ℵ₀ < (#K)
hKL : (#K) = (#L)
s : Set K
hs : IsTranscendenceBasis (ZMod p) Subtype.val
t : Set L
ht : IsTranscendenceBasis (ZMod p) Subtype.val
this : (#↑s) = (#↑t)
e : ↑s ≃ ↑t
⊢ Nonempty (K ≃+* L)

tactic: rw [← cardinal_eq_cardinal_transcendence_basis_of_aleph0_lt _ hs
  (lt_aleph0_of_finite (ZMod p)).le hK,
  ← cardinal_eq_cardinal_transcendence_basis_of_aleph0_lt _ ht
    (lt_aleph0_of_finite (ZMod p)).le, hKL]
state_before: K L : Type
inst✝⁶ : Field K
inst✝⁵ : Field L
inst✝⁴ : IsAlgClosed K
inst✝³ : IsAlgClosed L
p : ℕ
inst✝² : Fact (Nat.Prime p)
inst✝¹ : CharP K p
inst✝ : CharP L p
hK : ℵ₀ < (#K)
hKL : (#K) = (#L)
s : Set K
hs : IsTranscendenceBasis (ZMod p) Subtype.val
t : Set L
ht : IsTranscendenceBasis (ZMod p) Subtype.val
⊢ (#↑s) = (#↑t)

tactic: rwa [← hKL]
state_before: K L : Type
inst✝⁶ : Field K
inst✝⁵ : Field L
inst✝⁴ : IsAlgClosed K
inst✝³ : IsAlgClosed L
p : ℕ
inst✝² : Fact (Nat.Prime p)
inst✝¹ : CharP K p
inst✝ : CharP L p
hK : ℵ₀ < (#K)
hKL : (#K) = (#L)
s : Set K
hs : IsTranscendenceBasis (ZMod p) Subtype.val
t : Set L
ht : IsTranscendenceBasis (ZMod p) Subtype.val
⊢ ℵ₀ < (#L)