feat: make informal_definition and informal_lemma commands (#300)

* make informal_definition and informal_lemma commands
* drop the fields "math", "physics", and "proof" from InformalDefinition/InformalLemma and use docstrings instead
* render informal docstring in dependency graph
This commit is contained in:
KUO-TSAN HSU (Gordon) 2025-02-02 03:17:17 +08:00 committed by GitHub
parent 6aab0ba3cd
commit f8f94979ab
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
33 changed files with 666 additions and 1089 deletions

View file

@ -48,17 +48,19 @@ lemma contractSelfField_equivariant {S : TensorSpecies} {c : S.C} {g : S.G}
simpa using congrFun (congrArg (fun x => x.hom.toFun)
((S.contractSelfHom c).comm g)) (ψ ⊗ₜ[S.k] φ)
informal_lemma contractSelfField_non_degenerate where
math :≈ "The contraction of two vectors of the same color is non-degenerate.
I.e. ⟪ψ, φ⟫ₜₛ = 0 for all φ implies ψ = 0."
proof :≈ "The basic idea is that being degenerate contradicts the assumption of having a unit
in the tensor species."
deps :≈ [``contractSelfField]
/-- The contraction of two vectors of the same color is non-degenerate, i.e., `⟪ψ, φ⟫ₜₛ = 0` for all
`φ` implies `ψ = 0`.
Proof: the basic idea is that being degenerate contradicts the assumption of having a
unit in the tensor species.
-/
informal_lemma contractSelfField_non_degenerate where
deps := [``contractSelfField]
/-- The contraction `⟪ψ, φ⟫ₜₛ` is related to the tensor tree
`{ψ | μ ⊗ (S.dualRepIsoDiscrete c).hom φ | μ}ᵀ`. -/
informal_lemma contractSelfField_tensorTree where
math :≈ "The contraction ⟪ψ, φ⟫ₜₛ is related to the tensor tree
{ψ | μ ⊗ (S.dualRepIsoDiscrete c).hom φ | μ}ᵀ "
deps :≈ [``contractSelfField, ``TensorTree]
deps := [``contractSelfField, ``TensorTree]
/-!