AFTD Auto-Formalizing Theoretical Domains

TensorSpecies.Tensor.IsReindexing.comp

theoremverifiedformalizationimported Lean

The composition of two maps satisfying IsReindexing also satisfies the IsReindexing.

Statement

set_option autoImplicit true in
set_option relaxedAutoImplicit true in
open TensorSpecies TensorSpecies.Tensor in
open Module in
variable {C : Type} in
open Fin in
lemma TensorSpecies.Tensor.IsReindexing.comp {n n1 n2 : ℕ} {c : Fin n → C} {c1 : Fin n1 → C}
    {c2 : Fin n2 → C} {σ : Fin n1 → Fin n} {σ2 : Fin n2 → Fin n1}
    (h : IsReindexing c c1 σ) (h2 : IsReindexing c1 c2 σ2) : IsReindexing c c2 (σ ∘ σ2)
Formalizes
Physlib, `TensorSpecies.Tensor.IsReindexing.comp`
Lean proof
By Joseph Tooby-Smith, from github.com/leanprover-community/physlib at e411c6e89692 (Copyright (c) 2025 Joseph Tooby-Smith. All rights reserved, Apache-2.0). Compiled here against leanprover/lean4:v4.33.1, Mathlib v4.33.1; written for leanprover/lean4:v4.34.1.
Verified
09 Oct 2026
Axioms
none — Lean reports it depends on no axioms
Built on 4

Lean source view module on GitHub

set_option autoImplicit true in
set_option relaxedAutoImplicit true in
open TensorSpecies TensorSpecies.Tensor in
open Module in
variable {C : Type} in
open Fin in
/-- The composition of two maps satisfying `IsReindexing` also satisfies the `IsReindexing`. -/
lemma TensorSpecies.Tensor.IsReindexing.comp {n n1 n2 : ℕ} {c : Fin n → C} {c1 : Fin n1 → C}
    {c2 : Fin n2 → C} {σ : Fin n1 → Fin n} {σ2 : Fin n2 → Fin n1}
    (h : IsReindexing c c1 σ) (h2 : IsReindexing c1 c2 σ2) : IsReindexing c c2 (σ ∘ σ2) :=
  ⟨h.1.comp h2.1, fun x => (h.2 (σ2 x)).trans (h2.2 x)⟩
See it in the graphDiscuss this resultChallenge it