/- Copyright 2026 The Formal Conjectures Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. -/ module public import Mathlib.GroupTheory.Solvable public import Mathlib.Order.Lattice.Nat@[expose] public section

Derived length

Group.derivedLength G is the length of the derived series of G: the least k with derivedSeries G k = ⊥, which exists exactly when G is solvable (Group.IsSolvable).

namespace Groupvariable (G : Type*) [Group G]

The derived length of G: the least k with derivedSeries G k = ⊥. It is 0 if there is none, that is, if G is not solvable.

noncomputable def derivedLength : ℕ := sInf {k : ℕ | derivedSeries G k = ⊥}theorem derivedLength_of_not_isSolvable (h : ¬ IsSolvable G) : derivedLength G = 0 := G:Type u_1inst✝:Group Gh:¬IsSolvable G⊢ derivedLength G = 0 G:Type u_1inst✝:Group Gh:¬IsSolvable Gthis:{k | derivedSeries G k = ⊥} = ∅⊢ derivedLength G = 0 All goals completed! 🐙theorem derivedLength_of_subsingleton [Subsingleton G] : derivedLength G = 0 := Nat.sInf_eq_zero.mpr (Or.inl (G:Type u_1inst✝¹:Group Ginst✝:Subsingleton G⊢ 0 ∈ {k | derivedSeries G k = ⊥} All goals completed! 🐙))G:Type u_1inst✝¹:Group Ginst✝:IsSimpleGroup Ghk:sInf {k | derivedSeries G k = ⊥} = 1⊢ sInf {k | derivedSeries G k = ⊥} ∈ {k | derivedSeries G k = ⊥} apply Nat.sInf_mem (G:Type u_1inst✝¹:Group Ginst✝:IsSimpleGroup Ghk:sInf {k | derivedSeries G k = ⊥} = 1⊢ {k | derivedSeries G k = ⊥}.Nonempty All goals completed! 🐙) G:Type u_1inst✝¹:Group Ginst✝:IsSimpleGroup Ghk:derivedSeries G 1 = ⊥⊢ sInf {k | derivedSeries G k = ⊥} = 1 G:Type u_1inst✝¹:Group Ginst✝:IsSimpleGroup Ghk:derivedSeries G 1 = ⊥⊢ sInf {k | derivedSeries G k = ⊥} ≤ 1G:Type u_1inst✝¹:Group Ginst✝:IsSimpleGroup Ghk:derivedSeries G 1 = ⊥⊢ 1 ≤ sInf {k | derivedSeries G k = ⊥} G:Type u_1inst✝¹:Group Ginst✝:IsSimpleGroup Ghk:derivedSeries G 1 = ⊥⊢ sInf {k | derivedSeries G k = ⊥} ≤ 1 G:Type u_1inst✝¹:Group Ginst✝:IsSimpleGroup Ghk:derivedSeries G 1 = ⊥⊢ 1 ∈ {k | derivedSeries G k = ⊥} All goals completed! 🐙 G:Type u_1inst✝¹:Group Ginst✝:IsSimpleGroup Ghk:derivedSeries G 1 = ⊥⊢ 1 ≤ sInf {k | derivedSeries G k = ⊥} G:Type u_1inst✝¹:Group Ginst✝:IsSimpleGroup Ghk:derivedSeries G 1 = ⊥h:sInf {k | derivedSeries G k = ⊥} < 1⊢ False G:Type u_1inst✝¹:Group Ginst✝:IsSimpleGroup Gh:sInf {k | derivedSeries G k = ⊥} < 1hk:1 ∈ {k | derivedSeries G k = ⊥}⊢ False All goals completed! 🐙end Group