SkillAgentSearch skills...

Grassmann.jl

⟨Grassmann-Clifford-Hodge⟩ differential geometric algebra

Install / Use

/learn @chakravala/Grassmann.jl

README

<p align="center"> <img src="./docs/src/assets/logo.png" alt="Grassmann.jl"/> </p>

Grassmann.jl

⟨Grassmann-Clifford-Hodge⟩ multilinear differential geometric algebra

JuliaCon 2019 Grassmann.jl YouTube PDF 2019 PDF 2021 PDF 2025 Hardcover 2025 Paperback 2025 Docs Dev

The Grassmann.jl package provides tools for computations based on multi-linear algebra and spin groups using the extended geometric algebra known as Grassmann-Clifford-Hodge algebra. Algebra operations include exterior, regressive, inner, and geometric, along with the Hodge star and boundary operators. Code generation enables concise usage of the algebra syntax. DirectSum.jl multivector parametric type polymorphism is based on tangent vector spaces and conformal projective geometry. Additionally, the universal interoperability between different sub-algebras is enabled by AbstractTensors.jl, on which the type system is built. The design is based on TensorAlgebra{V} abstract type interoperability from AbstractTensors.jl with a K-module type parameter V from DirectSum.jl. Abstract vector space type operations happen at compile-time, resulting in a differential geometric algebra of multivectors.

DOI GitHub tag (latest SemVer) Liberapay patrons Build status Gitter

   ____  ____    ____   _____  _____ ___ ___   ____  ____   ____
  /    T|    \  /    T / ___/ / ___/|   T   T /    T|    \ |    \
 Y   __j|  D  )Y  o  |(   \_ (   \_ | _   _ |Y  o  ||  _  Y|  _  Y
 |  T  ||    / |     | \__  T \__  T|  \_/  ||     ||  |  ||  |  |
 |  l_ ||    \ |  _  | /  \ | /  \ ||   |   ||  _  ||  |  ||  |  |
 |     ||  .  Y|  |  | \    | \    ||   |   ||  |  ||  |  ||  |  |
 l___,_jl__j\_jl__j__j  \___j  \___jl___j___jl__j__jl__j__jl__j__j

Please consider donating to show your thanks and appreciation to this project at liberapay, GitHub Sponsors, Patreon, or contribute (documentation, tests, examples) in the repositories.

TensorAlgebra{V} design and code generation

Mathematical foundations and definitions specific to the Grassmann.jl implementation provide an extensible platform for computing with a universal language for finite element methods based on a discrete manifold bundle. Tools built on these foundations enable computations based on multi-linear algebra and spin groups using the geometric algebra known as Grassmann algebra or Clifford algebra. This foundation is built on a DirectSum.jl parametric type system for tangent bundles and vector spaces generating the algorithms for local tangent algebras in a global context. With this unifying mathematical foundation, it is possible to improve efficiency of multi-disciplinary research using geometric tensor calculus by relying on universal mathematical principles.

  • AbstractTensors.jl: Tensor algebra abstract type interoperability setup
  • DirectSum.jl: Tangent bundle, vector space and Submanifold definition
  • Grassmann.jl: ⟨Grassmann-Clifford-Hodge⟩ multilinear differential geometric algebra
using Grassmann, Makie; @basis S"∞+++"
streamplot(vectorfield(exp((π/4)*(v12+v∞3)),V(2,3,4),V(1,2,3)),-1.5..1.5,-1.5..1.5,-1.5..1.5,gridsize=(10,10))

paper/img/wave.png

More information and tutorials are available at https://grassmann.crucialflow.com/dev

Requirements

Grassmann.jl is a package for the Julia language, which can be obtained from their website or the recommended method for your operating system (GNU/Linux/Mac/Windows). Go to docs.julialang.org for documentation. Availability of this package and its subpackages can be automatically handled with the Julia package manager using Pkg; Pkg.add("Grassmann") or

pkg> add Grassmann

If you would like to keep up to date with the latest commits, instead use

pkg> add Grassmann#master

which is not recommended if you want to use a stable release. When the master branch is used it is possible that some of the dependencies also require a development branch before the release. This may include, but not limited to:

This requires a merged version of ComputedFieldTypes at https://github.com/vtjnash/ComputedFieldTypes.jl

Interoperability of TensorAlgebra with other packages is enabled by DirectSum.jl and AbstractTensors.jl.

The package is compatible via Requires.jl with Reduce.jl, Symbolics.jl, SymPy.jl, SymEngine.jl, AbstractAlgebra.jl, GaloisFields.jl, LightGraphs.jl, UnicodePlots.jl, Makie.jl, GeometryBasics.jl, Meshes.jl,

Sponsor this at liberapay, GitHub Sponsors, Patreon, or Lulu.

DirectSum.jl parametric type polymorphism

The AbstractTensors package is intended for universal interoperation of the abstract TensorAlgebra type system. All TensorAlgebra{V} subtypes have type parameter V, used to store a Submanifold{M} value, which is parametrized by M the TensorBundle choice. This means that different tensor types can have a commonly shared underlying K-module parametric type expressed by defining V::Submanifold{M}. Each TensorAlgebra subtype must be accompanied by a corresponding TensorBundle parameter, which is fully static at compile time. Due to the parametric type system for the K-module types, the compiler can fully pre-allocate and often cache.

Let V be a K-module of rank n be specified by instance with the tuple (n,P,g,ν,μ) with P specifying the presence of the projective basis and g is a metric tensor specification. The type TensorBundle{n,P,g,ν,μ} encodes this information as byte-encoded data available at pre-compilation, where μ is an integer specifying the order of the tangent bundle (i.e. multiplicity limit of the Leibniz-Taylor monomials). Lastly, ν is the number of tangent variables, bases for the vectors and covectors; and bases for differential operators and scalar functions. The purpose of the TensorBundle type is to specify the K-module basis at compile time. When assigned in a workspace, V = Submanifold(::TensorBundle).

The metric signature of the Submanifold{V,1} elements of a vector space V can be specified with the V"..." by using + or - to specify whether the Submanifold{V,1} element of the corresponding index squares to +1 or -1. For example, S"+++" construc

View on GitHub
GitHub Stars507
CategoryDevelopment
Updated3d ago
Forks41

Languages

Julia

Security Score

100/100

Audited on Mar 26, 2026

No findings