feat: Add notes infastructure

This commit is contained in:
jstoobysmith 2024-12-04 13:37:23 +00:00
parent 6b42cdd4e6
commit 33ef43ed7d
11 changed files with 568 additions and 28 deletions

View file

@ -5,6 +5,7 @@ Authors: Joseph Tooby-Smith
-/
import HepLean.PerturbationTheory.Wick.Species
import HepLean.Mathematics.SuperAlgebra.Basic
import HepLean.Meta.Notes.Basic
/-!
# Operator algebra
@ -23,9 +24,13 @@ We will formally define the operator ring, in terms of the fields present in the
- Tong, https://www.damtp.cam.ac.uk/user/tong/qft/qft.pdf
-/
note "
<h1>Operator algebra</h1>
This is a test note."
namespace Wick
informal_definition WickAlgebra where
informal_definition_note WickAlgebra where
math :≈ "
Modifications of this may be needed.
A structure with the following data:
@ -50,7 +55,7 @@ informal_definition WickAlgebra where
ref :≈ "https://physics.stackexchange.com/questions/24157/"
deps :≈ [``SuperAlgebra, ``SuperAlgebra.superCommuator]
informal_definition WickMonomial where
informal_definition_note WickMonomial where
math :≈ "The type of elements of the Wick algebra which is a product of fields."
deps :≈ [``WickAlgebra]

View file

@ -7,6 +7,7 @@ import HepLean.PerturbationTheory.Wick.String
import Mathlib.Algebra.Order.Ring.Nat
import Mathlib.Data.Fintype.Sum
import Mathlib.Logic.Equiv.Fin
import HepLean.Meta.Notes.Basic
/-!
# Wick Contract
@ -40,6 +41,7 @@ inductive WickContract : {ni : } → {i : Fin ni → S.𝓯} → {n : }
namespace WickContract
/-- The number of nodes of a Wick contraction. -/
@[note_attr]
def size {ni : } {i : Fin ni → S.𝓯} {n : } {c : Fin n → S.𝓯}
{no : } {o : Fin no → S.𝓯} {str : WickString i c o final} {k : } {b1 b2 : Fin k → Fin n} :
WickContract str b1 b2 → := fun