Theorem: IsCyclotomicExtension.subsingleton_iff
File: Mathlib/NumberTheory/Cyclotomic/Basic.lean

tactic: have : Subsingleton (Subalgebra A B) := inferInstance
state_before: n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
⊢ IsCyclotomicExtension S A B ↔ S = ∅ ∨ S = {1}
state_after: n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ IsCyclotomicExtension S A B ↔ S = ∅ ∨ S = {1}

tactic: constructor
state_before: n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ IsCyclotomicExtension S A B ↔ S = ∅ ∨ S = {1}
state_after: case mp
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ IsCyclotomicExtension S A B → S = ∅ ∨ S = {1}

case mpr
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ S = ∅ ∨ S = {1} → IsCyclotomicExtension S A B

tactic: rintro ⟨hprim, -⟩
state_before: case mp
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ IsCyclotomicExtension S A B → S = ∅ ∨ S = {1}
state_after: case mp.mk
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
hprim : ∀ {n : ℕ+}, n ∈ S → ∃ r, IsPrimitiveRoot r ↑n
⊢ S = ∅ ∨ S = {1}

tactic: rw [← subset_singleton_iff_eq]
state_before: case mp.mk
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
hprim : ∀ {n : ℕ+}, n ∈ S → ∃ r, IsPrimitiveRoot r ↑n
⊢ S = ∅ ∨ S = {1}
state_after: case mp.mk
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
hprim : ∀ {n : ℕ+}, n ∈ S → ∃ r, IsPrimitiveRoot r ↑n
⊢ S ⊆ {1}

tactic: intro t ht
state_before: case mp.mk
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
hprim : ∀ {n : ℕ+}, n ∈ S → ∃ r, IsPrimitiveRoot r ↑n
⊢ S ⊆ {1}
state_after: case mp.mk
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
hprim : ∀ {n : ℕ+}, n ∈ S → ∃ r, IsPrimitiveRoot r ↑n
t : ℕ+
ht : t ∈ S
⊢ t ∈ {1}

tactic: obtain ⟨ζ, hζ⟩ := hprim ht
state_before: case mp.mk
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
hprim : ∀ {n : ℕ+}, n ∈ S → ∃ r, IsPrimitiveRoot r ↑n
t : ℕ+
ht : t ∈ S
⊢ t ∈ {1}
state_after: case mp.mk.intro
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
hprim : ∀ {n : ℕ+}, n ∈ S → ∃ r, IsPrimitiveRoot r ↑n
t : ℕ+
ht : t ∈ S
ζ : B
hζ : IsPrimitiveRoot ζ ↑t
⊢ t ∈ {1}

tactic: rw [mem_singleton_iff, ← PNat.coe_eq_one_iff]
state_before: case mp.mk.intro
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
hprim : ∀ {n : ℕ+}, n ∈ S → ∃ r, IsPrimitiveRoot r ↑n
t : ℕ+
ht : t ∈ S
ζ : B
hζ : IsPrimitiveRoot ζ ↑t
⊢ t ∈ {1}
state_after: case mp.mk.intro
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
hprim : ∀ {n : ℕ+}, n ∈ S → ∃ r, IsPrimitiveRoot r ↑n
t : ℕ+
ht : t ∈ S
ζ : B
hζ : IsPrimitiveRoot ζ ↑t
⊢ ↑t = 1

tactic: exact mod_cast hζ.unique (IsPrimitiveRoot.of_subsingleton ζ)
state_before: case mp.mk.intro
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
hprim : ∀ {n : ℕ+}, n ∈ S → ∃ r, IsPrimitiveRoot r ↑n
t : ℕ+
ht : t ∈ S
ζ : B
hζ : IsPrimitiveRoot ζ ↑t
⊢ ↑t = 1
state_after: no goals

tactic: rintro (rfl | rfl)
state_before: case mpr
n : ℕ+
S T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ S = ∅ ∨ S = {1} → IsCyclotomicExtension S A B
state_after: case mpr.inl
n : ℕ+
T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ IsCyclotomicExtension ∅ A B

case mpr.inr
n : ℕ+
T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ IsCyclotomicExtension {1} A B

tactic: exact ⟨fun h => h.elim, fun x => by convert (mem_top (R := A) : x ∈ ⊤)⟩
state_before: case mpr.inl
n : ℕ+
T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ IsCyclotomicExtension ∅ A B
state_after: no goals

tactic: convert (mem_top (R := A) : x ∈ ⊤)
state_before: n : ℕ+
T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
x : B
⊢ x ∈ adjoin A {b | ∃ n ∈ ∅, b ^ ↑n = 1}
state_after: no goals

tactic: rw [iff_singleton]
state_before: case mpr.inr
n : ℕ+
T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ IsCyclotomicExtension {1} A B
state_after: case mpr.inr
n : ℕ+
T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ (∃ r, IsPrimitiveRoot r ↑1) ∧ ∀ (x : B), x ∈ adjoin A {b | b ^ ↑1 = 1}

tactic: exact ⟨⟨0, IsPrimitiveRoot.of_subsingleton 0⟩,
  fun x => by convert (mem_top (R := A) : x ∈ ⊤)⟩
state_before: case mpr.inr
n : ℕ+
T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
⊢ (∃ r, IsPrimitiveRoot r ↑1) ∧ ∀ (x : B), x ∈ adjoin A {b | b ^ ↑1 = 1}
state_after: no goals

tactic: convert (mem_top (R := A) : x ∈ ⊤)
state_before: n : ℕ+
T : Set ℕ+
A : Type u
B : Type v
K : Type w
L : Type z
inst✝⁶ : CommRing A
inst✝⁵ : CommRing B
inst✝⁴ : Algebra A B
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Algebra K L
inst✝ : Subsingleton B
this : Subsingleton (Subalgebra A B)
x : B
⊢ x ∈ adjoin A {b | b ^ ↑1 = 1}
state_after: no goals