Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Classes of invariant homogeneous cocycles in continuous cohomology

Definition
MilnorConjecture_HomogeneousCochains

by vatsj · Sep 24, 2026 · Mathlib 0df444a (Lean v4.33.1)

algebracontinuous-cohomologygroup-cohomology

Let GGG be a locally compact topological group, kkk a topological ring and MMM a topological kkk-module, regarded as a trivial representation of GGG. Mathlib computes continuous cohomology Hctsn(G,M)H^n_{\mathrm{cts}}(G,M)Hctsn​(G,M) from the complex of GGG-invariant elements of C(G,C(G,⋯C(G,M)))C(G, C(G, \cdots C(G, M)))C(G,C(G,⋯C(G,M))) (n+1n+1n+1 nested copies of GGG in degree nnn), with an inductively defined differential.

This file translates that model into functions of several variables. For a continuous F:Gn+1→MF : G^{n+1}\to MF:Gn+1→M which is invariant under simultaneous left translation,

F(gx0,…,gxn)=F(x0,…,xn)(g∈G),F(gx_0,\dots,gx_n) = F(x_0,\dots,x_n)\quad (g\in G),F(gx0​,…,gxn​)=F(x0​,…,xn​)(g∈G),

and satisfies the homogeneous cocycle identity

∑i=0n+1(−1)i F(y0,…,yi^,…,yn+1)=0,\sum_{i=0}^{n+1} (-1)^i\, F(y_0,\dots,\widehat{y_i},\dots,y_{n+1}) = 0,i=0∑n+1​(−1)iF(y0​,…,yi​​,…,yn+1​)=0,

it defines the class [F]∈Hctsn(G,M)[F] \in H^n_{\mathrm{cts}}(G,M)[F]∈Hctsn​(G,M) of the corresponding nested cochain x0↦x1↦⋯↦F(x0,…,xn)x_0\mapsto x_1\mapsto\cdots\mapsto F(x_0,\dots,x_n)x0​↦x1​↦⋯↦F(x0​,…,xn​). The file proves that Mathlib's differential of this nested cochain is the alternating face sum above, and that the GGG-action translates all arguments.

This is reusable infrastructure: it gives a concrete way to write down classes in Mathlib's continuous cohomology with trivial coefficients.

Formalization Note curryN, coboundary and classOf are sorry-free; local compactness of GGG is used only to make iterated currying continuous.

Definition code
import Mathlib

/-!
# Homogeneous cochains with trivial coefficients, as functions of several variables

Mathlib's continuous cohomology `continuousCohomology n A` is the homology of the complex
of `G`-invariant elements of `C(G, C(G, ⋯ C(G, A)))` (`n + 1` nested copies of `G`), with the
inductively defined differential `TopRep.d`. For trivial coefficients `M` and a locally compact
group `G`, this file turns a continuous function `F : Gⁿ⁺¹ → M` that is invariant under
simultaneous left translation and satisfies the homogeneous cocycle identity
`∑ᵢ (-1)ⁱ F(x₀, …, x̂ᵢ, …, xₙ₊₁) = 0` into a class in `continuousCohomology n`.
-/

open CategoryTheory

namespace MilnorConjecture

universe u

variable {k G M : Type u} [Ring k] [TopologicalSpace k] [Group G] [TopologicalSpace G]
  [IsTopologicalGroup G] [LocallyCompactSpace G] [AddCommGroup M] [Module k M]
  [TopologicalSpace M] [IsTopologicalAddGroup M] [ContinuousSMul k M]

variable (k G M) in
/-- `M` as a trivial continuous `k`-linear representation of `G`. -/
abbrev trivialRep : TopRep k G := TopRep.of (ContRepresentation.trivial k G M)

/-- The map `(x, v) ↦ (x, v₀, …, vₙ₋₁)` from `G × Gⁿ` to `Gⁿ⁺¹`. -/
def consMap (n : ℕ) : C(G × (Fin n → G), Fin (n + 1) → G) :=
  ⟨fun p ↦ Fin.cons p.1 p.2, by fun_prop⟩

variable (k G M) in
/-- Currying `n` times: a continuous `F : Gⁿ → M` becomes the element
`x₀ ↦ x₁ ↦ ⋯ ↦ F(x₀, …, xₙ₋₁)` of `C(G, C(G, ⋯ C(G, M)))`, the `n`-th term of Mathlib's
resolution `TopRep.resolutionX`. The assignment is itself continuous. -/
noncomputable def curryN : (n : ℕ) →
    C(C(Fin n → G, M), ((trivialRep k G M).resolutionX n : Type u))
  | 0 => ⟨fun F ↦ F Fin.elim0, continuous_eval_const _⟩
  | n + 1 => ⟨fun F ↦ (curryN n).comp (F.comp (consMap n)).curry,
      (ContinuousMap.continuous_postcomp _).comp
        (ContinuousMap.continuous_curry.comp (ContinuousMap.continuous_precomp _))⟩

@[simp]
lemma curryN_zero_apply (F : C(Fin 0 → G, M)) : curryN k G M 0 F = F Fin.elim0 := rfl

@[simp]
lemma curryN_succ_apply {n : ℕ} (F : C(Fin (n + 1) → G, M)) (x : G) :
    curryN k G M (n + 1) F x = curryN k G M n ⟨fun v ↦ F (Fin.cons x v), by fun_prop⟩ := rfl

lemma curryN_sub {n : ℕ} (F F' : C(Fin n → G, M)) :
    curryN k G M n (F - F') = curryN k G M n F - curryN k G M n F' := by
  induction n with
  | zero => rfl
  | succ n ih =>
    ext1 x
    rw [curryN_succ_apply, ContinuousMap.sub_apply, curryN_succ_apply, curryN_succ_apply, ← ih]
    rfl

/-- The `i`-th face map `Gⁿ⁺¹ → Gⁿ`, deleting the `i`-th coordinate. -/
def faceMap (n : ℕ) (i : Fin (n + 1)) : C(Fin (n + 1) → G, Fin n → G) :=
  ⟨fun y ↦ y ∘ i.succAbove, by fun_prop⟩

/-- The homogeneous coboundary with trivial coefficients:
`(δF)(y₀, …, yₙ) = ∑ᵢ (-1)ⁱ F(y₀, …, ŷᵢ, …, yₙ)`. -/
def coboundary (n : ℕ) (F : C(Fin n → G, M)) : C(Fin (n + 1) → G, M) :=
  ∑ i : Fin (n + 1), ((-1 : ℤ) ^ (i : ℕ)) • F.comp (faceMap n i)

omit [Group G] [IsTopologicalGroup G] [LocallyCompactSpace G] in
lemma coboundary_apply {n : ℕ} (F : C(Fin n → G, M)) (y : Fin (n + 1) → G) :
    coboundary n F y = ∑ i : Fin (n + 1), ((-1 : ℤ) ^ (i : ℕ)) • F (y ∘ i.succAbove) := by
  simp [coboundary, faceMap]

/-- Mathlib's inductively defined differential agrees with the alternating face sum. -/
lemma d_curryN (n : ℕ) (F : C(Fin n → G, M)) :
    ((trivialRep k G M).d n).hom (curryN k G M n F) = curryN k G M (n + 1) (coboundary n F) := by
  induction n with
  | zero =>
    ext x
    show F Fin.elim0 = coboundary 0 F (Fin.cons x Fin.elim0)
    rw [coboundary_apply, Fin.sum_univ_one]
    simp only [Fin.val_zero, pow_zero, one_smul]
    exact congrArg F (funext fun i ↦ i.elim0)
  | succ n ih =>
    ext1 x
    rw [TopRep.hom_d_succ]
    change curryN k G M (n + 1) F - ((trivialRep k G M).d n).hom (curryN k G M (n + 1) F x) = _
    rw [curryN_succ_apply, ih, ← curryN_sub, curryN_succ_apply]
    congr 1
    ext w
    simp only [ContinuousMap.sub_apply, ContinuousMap.coe_mk]
    rw [coboundary_apply, coboundary_apply]
    show F w - ∑ i : Fin (n + 1), ((-1 : ℤ) ^ (i : ℕ)) • F (Fin.cons x (w ∘ i.succAbove)) = _
    conv_rhs => rw [Fin.sum_univ_succ, Fin.val_zero, pow_zero, one_smul, Fin.succAbove_zero,
      Fin.cons_comp_succ]
    rw [sub_eq_add_neg, ← Finset.sum_neg_distrib]
    congr 1
    refine Finset.sum_congr rfl fun j _ ↦ ?_
    rw [Fin.val_succ, pow_succ, mul_neg_one, neg_smul, Fin.cons_comp_succ_succAbove]
    rfl

lemma curryN_zero {n : ℕ} : curryN k G M n 0 = 0 := by
  simpa using curryN_sub (k := k) (0 : C(Fin n → G, M)) 0

/-- Left translation `(v₀, …, vₙ₋₁) ↦ (g v₀, …, g vₙ₋₁)` on `Gⁿ`. -/
def translate (n : ℕ) (g : G) : C(Fin n → G, Fin n → G) :=
  ⟨fun v i ↦ g * v i, by fun_prop⟩

/-- With trivial coefficients, `g` acts on `C(G, ⋯ C(G, M))` by translating every argument
by `g⁻¹`. -/
lemma ρ_curryN (n : ℕ) (g : G) (F : C(Fin n → G, M)) :
    ((trivialRep k G M).resolutionX n).ρ g (curryN k G M n F) =
      curryN k G M n (F.comp (translate n g⁻¹)) := by
  induction n with
  | zero =>
    show F Fin.elim0 = F (fun i ↦ g⁻¹ * Fin.elim0 i)
    exact congrArg F (funext fun i ↦ i.elim0)
  | succ n ih =>
    ext1 x
    rw [ContRepresentation.coind₁_apply_apply, curryN_succ_apply, ih, curryN_succ_apply]
    congr 1
    ext v
    simp only [ContinuousMap.comp_apply, ContinuousMap.coe_mk, translate]
    congr 1
    funext i
    cases i using Fin.cases <;> simp

lemma curryN_mem_invariants {n : ℕ} (F : C(Fin n → G, M))
    (hF : ∀ (g : G) (v : Fin n → G), F (fun i ↦ g * v i) = F v) :
    curryN k G M n F ∈ ((trivialRep k G M).resolutionX n).ρ.invariants := by
  intro g
  rw [ρ_curryN]
  congr 1
  ext v
  exact hF g⁻¹ v

variable [IsTopologicalRing k]

variable (k) in
/-- The class in `continuousCohomology n` of a continuous `F : Gⁿ⁺¹ → M` that is invariant
under simultaneous left translation and is a homogeneous cocycle (`δF = 0`), with `M` a
trivial representation of `G`. -/
noncomputable def classOf (n : ℕ) (F : C(Fin (n + 1) → G, M))
    (hinv : ∀ (g : G) (v : Fin (n + 1) → G), F (fun i ↦ g * v i) = F v)
    (hcoc : coboundary (n + 1) F = 0) :
    continuousCohomology n (trivialRep k G M) :=
  let σ : (trivialRep k G M).homogeneousCochains.X n :=
    ⟨curryN k G M (n + 1) F, curryN_mem_invariants F hinv⟩
  let ι : TopModuleCat.of k k ⟶ (trivialRep k G M).homogeneousCochains.X n :=
    TopModuleCat.ofHom (ContinuousLinearMap.toSpanSingleton k σ)
  have hd : ((trivialRep k G M).homogeneousCochains.d n (n + 1)).hom σ = 0 := by
    apply Subtype.ext
    rw [TopRep.homogeneousCochains.d_apply]
    change ((trivialRep k G M).d (n + 1)).hom (curryN k G M (n + 1) F) = 0
    rw [d_curryN, hcoc, curryN_zero]
  have hσ : ι ≫ (trivialRep k G M).homogeneousCochains.d n (n + 1) = 0 := by
    apply ConcreteCategory.ext
    apply ContinuousLinearMap.ext_ring
    have h1 : ι 1 = σ := one_smul k σ
    rw [ConcreteCategory.comp_apply, h1]
    simpa using hd
  (ContinuousCohomology.π _ n).hom
    (((trivialRep k G M).homogeneousCochains.liftCycles ι (n + 1) (by simp) hσ).hom 1)

end MilnorConjecture
Source
Standard homogeneous-cochain description of continuous group cohomology (cf. Neukirch-Schmidt-Wingberg, Cohomology of Number Fields), specialised to Mathlib's `continuousCohomology` (Mathlib/RepresentationTheory/Homological/ContCohomology/Basic.lean).
Read-back

What the Lean code literally says, in plain math · claude-opus-5-5

Read-back: Def_MilnorConjecture_HomogeneousCochains.lean

All declarations live in the namespace MilnorConjecture, and the file imports only Mathlib.

Ambient setting (the variable binders)

Three types kkk, GGG, MMM are fixed, all in the same universe uuu. They come with these assumptions:

  • kkk is a (not necessarily commutative) ring with a topology. No compatibility between the ring operations and the topology is assumed, except in classOf (see below).
  • GGG is a group with a topology making it a topological group, and GGG is locally compact. No Hausdorff, profinite, or compactness assumption is made.
  • MMM is an additive commutative group and a kkk-module, with a topology making (M,+)(M,+)(M,+) a topological additive group and scalar multiplication k×M→Mk\times M\to Mk×M→M jointly continuous.

Just before classOf, one more assumption is added: kkk is a topological ring. Only classOf uses it.

Notation used below:

  • C(X,Y)C(X,Y)C(X,Y) is the space of continuous maps X→YX \to YX→Y with the compact-open topology.
  • GnG^nGn means the space of functions {0,…,n−1}→G\{0,\dots,n-1\}\to G{0,…,n−1}→G (product topology). For n=0n=0n=0 this is a one-point space whose only element is the empty tuple ()()().

trivialRep

trivk(G,M)\mathrm{triv}_k(G,M)trivk​(G,M) is the object of Mathlib's category TopRepk(G)\mathrm{TopRep}_k(G)TopRepk​(G) built from MMM with the trivial action: g⋅m=mg\cdot m = mg⋅m=m for all g∈Gg\in Gg∈G, m∈Mm\in Mm∈M.

Mathlib's resolution objects Xn:=resolutionXnX_n := \mathrm{resolutionX}_nXn​:=resolutionXn​ of this representation are defined recursively:

  • X0=MX_0 = MX0​=M;
  • Xn+1=C(G,Xn)X_{n+1} = C(G, X_n)Xn+1​=C(G,Xn​), with the coinduced action (g⋅f)(x)=g⋅(f(g−1x))(g\cdot f)(x) = g\cdot\bigl(f(g^{-1}x)\bigr)(g⋅f)(x)=g⋅(f(g−1x)).

So Xn=C(G,C(G,…,C(G,M)))X_n = C(G, C(G,\dots, C(G,M)))Xn​=C(G,C(G,…,C(G,M))) with nnn nested copies of C(G,⋅)C(G,\cdot)C(G,⋅). Because the action on MMM is trivial, ggg acts on an element φ∈Xn\varphi\in X_nφ∈Xn​ by

(g⋅φ)(x1)(x2)⋯(xn)=φ(g−1x1)(g−1x2)⋯(g−1xn).(g\cdot\varphi)(x_1)(x_2)\cdots(x_n) = \varphi(g^{-1}x_1)(g^{-1}x_2)\cdots(g^{-1}x_n).(g⋅φ)(x1​)(x2​)⋯(xn​)=φ(g−1x1​)(g−1x2​)⋯(g−1xn​).

Mathlib's differential dn:Xn→Xn+1d_n : X_n\to X_{n+1}dn​:Xn​→Xn+1​ is also defined recursively:

  • d0(m)=d_0(m) = d0​(m)= the constant function x↦mx\mapsto mx↦m;
  • dn+1(f)=(x↦f−dn(f(x)))d_{n+1}(f) = \bigl(x \mapsto f - d_n(f(x))\bigr)dn+1​(f)=(x↦f−dn​(f(x))) for f∈Xn+1f\in X_{n+1}f∈Xn+1​.

The homogeneous cochain complex in Mathlib has degree-nnn term

Cn=Xn+1G,\mathcal C^n = X_{n+1}^{G},Cn=Xn+1G​,

the GGG-invariant elements of Xn+1X_{n+1}Xn+1​ with the subspace topology. Note the shift: degree nnn uses Xn+1X_{n+1}Xn+1​. Its differential Cn→Cn+1\mathcal C^n\to\mathcal C^{n+1}Cn→Cn+1 is the restriction of dn+1d_{n+1}dn+1​.

continuousCohomology n =Hn= H^n=Hn is the nnn-th homology of this complex, taken in the category of topological kkk-modules. ContinuousCohomology.π is the canonical projection from the nnn-cocycles onto HnH^nHn.

consMap

For n∈Nn\in\mathbb Nn∈N, consn:G×Gn→Gn+1\mathrm{cons}_n : G\times G^n \to G^{n+1}consn​:G×Gn→Gn+1 is the continuous map

(x,(v0,…,vn−1))↦(x,v0,…,vn−1).(x, (v_0,\dots,v_{n-1}))\mapsto (x, v_0,\dots,v_{n-1}).(x,(v0​,…,vn−1​))↦(x,v0​,…,vn−1​).

It prepends xxx as the new coordinate 000.

curryN

For each nnn, curryn\mathrm{curry}_ncurryn​ is a continuous map

curryn:C(Gn,M)→Xn.\mathrm{curry}_n : C(G^n, M)\to X_n.curryn​:C(Gn,M)→Xn​.

The continuity is with respect to the compact-open topology on the source and the topology of XnX_nXn​. It is defined by recursion on nnn:

  • curry0(F)=F(())∈M=X0\mathrm{curry}_0(F) = F(())\in M = X_0curry0​(F)=F(())∈M=X0​, i.e. FFF evaluated at the empty tuple.
  • curryn+1(F)\mathrm{curry}_{n+1}(F)curryn+1​(F) is the element of Xn+1=C(G,Xn)X_{n+1} = C(G, X_n)Xn+1​=C(G,Xn​) given by
x  ↦  curryn(v↦F(x,v0,…,vn−1)).x\;\mapsto\;\mathrm{curry}_n\bigl(v\mapsto F(x, v_0,\dots,v_{n-1})\bigr).x↦curryn​(v↦F(x,v0​,…,vn−1​)).

Formally, it is curryn\mathrm{curry}_ncurryn​ composed with the ordinary currying G→C(Gn,M)G\to C(G^n,M)G→C(Gn,M) of F∘consnF\circ \mathrm{cons}_nF∘consn​.

Unwinding the recursion, the first (outermost) argument is coordinate 000:

curryn(F)(x0)(x1)⋯(xn−1)=F(x0,x1,…,xn−1).\mathrm{curry}_n(F)(x_0)(x_1)\cdots(x_{n-1}) = F(x_0,x_1,\dots,x_{n-1}).curryn​(F)(x0​)(x1​)⋯(xn−1​)=F(x0​,x1​,…,xn−1​).

The following lemmas about curryN are proved:

  • curryN_zero_apply: curry0(F)=F(())\mathrm{curry}_0(F) = F(())curry0​(F)=F(()).
  • curryN_succ_apply: for F∈C(Gn+1,M)F\in C(G^{n+1},M)F∈C(Gn+1,M) and x∈Gx\in Gx∈G,
curryn+1(F)(x)=curryn(v↦F(x,v)).\mathrm{curry}_{n+1}(F)(x) = \mathrm{curry}_n\bigl(v\mapsto F(x,v)\bigr).curryn+1​(F)(x)=curryn​(v↦F(x,v)).
  • curryN_sub: curryn(F−F′)=curryn(F)−curryn(F′)\mathrm{curry}_n(F-F') = \mathrm{curry}_n(F)-\mathrm{curry}_n(F')curryn​(F−F′)=curryn​(F)−curryn​(F′) for all F,F′∈C(Gn,M)F,F'\in C(G^n,M)F,F′∈C(Gn,M).
  • curryN_zero: curryn(0)=0\mathrm{curry}_n(0)=0curryn​(0)=0 for every nnn.

faceMap

For n∈Nn\in\mathbb Nn∈N and i∈{0,…,n}i\in\{0,\dots,n\}i∈{0,…,n}, ∂i:Gn+1→Gn\partial_i : G^{n+1}\to G^n∂i​:Gn+1→Gn deletes coordinate iii:

(y0,…,yn)↦(y0,…,yi^,…,yn).(y_0,\dots,y_n)\mapsto (y_0,\dots,\widehat{y_i},\dots,y_n).(y0​,…,yn​)↦(y0​,…,yi​​,…,yn​).

Formally, yyy is precomposed with the increasing injection {0,…,n−1}→{0,…,n}\{0,\dots,n-1\}\to\{0,\dots,n\}{0,…,n−1}→{0,…,n} that skips iii.

coboundary

For n∈Nn\in\mathbb Nn∈N and F∈C(Gn,M)F\in C(G^n,M)F∈C(Gn,M), δnF∈C(Gn+1,M)\delta_n F\in C(G^{n+1},M)δn​F∈C(Gn+1,M) is

δnF=∑i=0n(−1)i F∘∂i.\delta_n F = \sum_{i=0}^{n}(-1)^i\, F\circ\partial_i .δn​F=i=0∑n​(−1)iF∘∂i​.

Here (−1)i∈Z(-1)^i\in\mathbb Z(−1)i∈Z acts on MMM as an integer multiple.

coboundary_apply states the pointwise formula. It needs only the topologies on GGG, not the group structure:

(δnF)(y0,…,yn)=∑i=0n(−1)iF(y0,…,yi^,…,yn).(\delta_n F)(y_0,\dots,y_n) = \sum_{i=0}^n (-1)^i F(y_0,\dots,\widehat{y_i},\dots,y_n).(δn​F)(y0​,…,yn​)=i=0∑n​(−1)iF(y0​,…,yi​​,…,yn​).

Edge case n=0n=0n=0: δ0F\delta_0 Fδ0​F is the constant function y↦F(())y\mapsto F(())y↦F(()).

d_curryN

For every nnn and every F∈C(Gn,M)F\in C(G^n,M)F∈C(Gn,M), Mathlib's differential satisfies

dn(currynF)=curryn+1(δnF)in Xn+1.d_n\bigl(\mathrm{curry}_n F\bigr) = \mathrm{curry}_{n+1}\bigl(\delta_n F\bigr)\quad\text{in } X_{n+1}.dn​(curryn​F)=curryn+1​(δn​F)in Xn+1​.

Here dn:Xn→Xn+1d_n: X_n\to X_{n+1}dn​:Xn​→Xn+1​ is the resolution differential, not the cochain-complex differential in degree nnn.

translate

For n∈Nn\in\mathbb Nn∈N and g∈Gg\in Gg∈G, tg:Gn→Gnt_g : G^n\to G^ntg​:Gn→Gn is left multiplication by ggg in every coordinate:

tg(v0,…,vn−1)=(gv0,…,gvn−1).t_g(v_0,\dots,v_{n-1}) = (g v_0,\dots, g v_{n-1}).tg​(v0​,…,vn−1​)=(gv0​,…,gvn−1​).

For n=0n=0n=0 it is the identity of the one-point space.

ρ_curryN

For every nnn, g∈Gg\in Gg∈G and F∈C(Gn,M)F\in C(G^n,M)F∈C(Gn,M), the action of ggg on XnX_nXn​ satisfies

g⋅curryn(F)=curryn(F∘tg−1).g\cdot \mathrm{curry}_n(F) = \mathrm{curry}_n\bigl(F\circ t_{g^{-1}}\bigr).g⋅curryn​(F)=curryn​(F∘tg−1​).

The right side is the function v↦F(g−1v0,…,g−1vn−1)v\mapsto F(g^{-1}v_0,\dots,g^{-1}v_{n-1})v↦F(g−1v0​,…,g−1vn−1​).

curryN_mem_invariants

Suppose F∈C(Gn,M)F\in C(G^n,M)F∈C(Gn,M) satisfies

F(gv0,…,gvn−1)=F(v0,…,vn−1)for all g∈G and v∈Gn.F(gv_0,\dots,gv_{n-1}) = F(v_0,\dots,v_{n-1})\quad\text{for all } g\in G \text{ and } v\in G^n.F(gv0​,…,gvn−1​)=F(v0​,…,vn−1​)for all g∈G and v∈Gn.

Then curryn(F)\mathrm{curry}_n(F)curryn​(F) is a GGG-invariant element of XnX_nXn​.

For n=0n=0n=0 the hypothesis holds automatically, and the conclusion says F(())∈MF(())\in MF(())∈M is invariant, which is automatic for the trivial action.

classOf

Inputs:

  • the ring kkk, given explicitly;
  • GGG and MMM, given implicitly;
  • all of the ambient assumptions above, plus: kkk is a topological ring;
  • a natural number nnn;
  • a continuous function F∈C(Gn+1,M)F\in C(G^{n+1},M)F∈C(Gn+1,M) of n+1n+1n+1 variables;
  • a hypothesis hinv\mathrm{hinv}hinv: FFF is invariant under simultaneous left translation, i.e. F(gv0,…,gvn)=F(v0,…,vn)F(gv_0,\dots,gv_n)=F(v_0,\dots,v_n)F(gv0​,…,gvn​)=F(v0​,…,vn​) for all g∈Gg\in Gg∈G and v∈Gn+1v\in G^{n+1}v∈Gn+1;
  • a hypothesis hcoc\mathrm{hcoc}hcoc: δn+1F=0\delta_{n+1}F = 0δn+1​F=0 as a function on Gn+2G^{n+2}Gn+2, i.e.
∑i=0n+1(−1)iF(y0,…,yi^,…,yn+1)=0for all (y0,…,yn+1)∈Gn+2.\sum_{i=0}^{n+1}(-1)^i F(y_0,\dots,\widehat{y_i},\dots,y_{n+1}) = 0\quad\text{for all } (y_0,\dots,y_{n+1})\in G^{n+2}.i=0∑n+1​(−1)iF(y0​,…,yi​​,…,yn+1​)=0for all (y0​,…,yn+1​)∈Gn+2.

Output: an element of HnH^nHn, the nnn-th continuous cohomology of the trivial representation trivk(G,M)\mathrm{triv}_k(G,M)trivk​(G,M) (in the Mathlib sense above).

Construction:

  1. Let σ=curryn+1(F)∈Xn+1\sigma = \mathrm{curry}_{n+1}(F)\in X_{n+1}σ=curryn+1​(F)∈Xn+1​. This is invariant by hinv\mathrm{hinv}hinv, so σ∈Cn\sigma\in\mathcal C^nσ∈Cn.
  2. Let ι:k→Cn\iota : k\to\mathcal C^nι:k→Cn be the continuous kkk-linear map r↦r⋅σr\mapsto r\cdot\sigmar↦r⋅σ.
  3. The file proves that the complex differential kills σ\sigmaσ, using d_curryN and hcoc\mathrm{hcoc}hcoc: dn+1(σ)=curryn+2(δn+1F)=0d_{n+1}(\sigma)=\mathrm{curry}_{n+2}(\delta_{n+1}F)=0dn+1​(σ)=curryn+2​(δn+1​F)=0. Hence ι\iotaι composed with the differential is zero.
  4. ι\iotaι therefore lifts to a map from kkk into the degree-nnn cycles of the homogeneous cochain complex.
  5. The output is πn\pi_nπn​ applied to the image of 1∈k1\in k1∈k under this lift.

In other words, classOf is the cohomology class in HnH^nHn of the cocycle σ=curryn+1(F)\sigma = \mathrm{curry}_{n+1}(F)σ=curryn+1​(F), whose value is σ(x0)⋯(xn)=F(x0,…,xn)\sigma(x_0)\cdots(x_n) = F(x_0,\dots,x_n)σ(x0​)⋯(xn​)=F(x0​,…,xn​).

Edge case n=0n=0n=0:

  • FFF is a function of one variable, and hinv\mathrm{hinv}hinv says F(gv)=F(v)F(gv)=F(v)F(gv)=F(v) for all g,vg,vg,v. Taking g=v−1g=v^{-1}g=v−1 gives F(v)=F(1)F(v) = F(1)F(v)=F(1), so FFF must be constant.
  • hcoc\mathrm{hcoc}hcoc says F(y1)−F(y0)=0F(y_1)-F(y_0)=0F(y1​)−F(y0​)=0 for all y0,y1y_0,y_1y0​,y1​, which a constant FFF satisfies automatically.
  • The output lies in H0H^0H0.

In every degree, both hypotheses can be satisfied, for example by F=0F=0F=0.

Human review
  • Endorsed by Shuze Chen · Sep 25, 2026

    Confirmed by the moderator at approval.

  • Endorsed by vatsj · Sep 25, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me