You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -151,7 +151,7 @@ The symmetrical algebra does not need to track this parity, but has higher multi
151
151
Symmetric differential function algebra of Leibniz trivializes the orientation into a single class of index multi-sets, while Grassmann's exterior algebra is partitioned into two oriented equivalence classes by anti-symmetry.
152
152
Full tensor algebra can be sub-partitioned into equivalence classes in multiple ways based on the element symmetry, grade, and metric signature composite properties.
153
153
154
-
By virtue of Julia's multiple dispatch on the field type `𝕂`, methods can specialize on the dimension `n` and grade `G` with a `TensorBundle{n}` via the `TensorAlgebra{V}` subtypes, such as `Submanifold{V,G}`, `Simplex{V,G,B,𝕂}`.
154
+
By virtue of Julia's multiple dispatch on the field type `𝕂`, methods can specialize on the dimension `n` and grade `G` with a `TensorBundle{n}` via the `TensorAlgebra{V}` subtypes, such as `Submanifold{V,G}`, `Single{V,G,B,𝕂}`.
155
155
156
156
The elements of the `Basis` can be generated in many ways using the `Submanifold` elements created by the `@basis` macro,
157
157
```julia
@@ -189,7 +189,7 @@ In order to work with a `TensorAlgebra{V}`, it is necessary for some computation
189
189
Staging of precompilation and caching is designed so that a user can smoothly transition between very high dimensional and low dimensional algebras in a single session, with varying levels of extra caching and optimizations.
190
190
The parametric type formalism in `DirectSum` is highly expressive and enables pre-allocation of geometric algebra computations involving specific sparse subalgebras, including the representation of rotational groups.
191
191
192
-
It is possible to reach `Simplex` elements with up to `N=62` vertices from a `TensorAlgebra` having higher maximum dimensions than supported by Julia natively.
192
+
It is possible to reach `Single` elements with up to `N=62` vertices from a `TensorAlgebra` having higher maximum dimensions than supported by Julia natively.
193
193
The 62 indices require full alpha-numeric labeling with lower-case and capital letters. This now allows you to reach up to `4,611,686,018,427,387,904` dimensions with Julia `using DirectSum`. Then the volume element is
equal(a::TensorTerm{V,G},b::TensorTerm{V,G}) where {V,G} =basis(a) ==basis(b) ?value(a) ==value(b) :0==value(a) ==value(b)
403
403
404
404
for T ∈ (Fields...,Symbol,Expr)
405
405
@evalbegin
406
-
Base.isapprox(a::S,b::T;atol::Real=0,rtol::Real=Base.rtoldefault(a,b,atol),nans::Bool=false,norm::Function=LinearAlgebra.norm) where {S<:TensorAlgebra,T<:$T} = Base.isapprox(a,Simplex{Manifold(a)}(b);atol=atol,rtol=rtol,nans=nans,norm=norm)
406
+
Base.isapprox(a::S,b::T;atol::Real=0,rtol::Real=Base.rtoldefault(a,b,atol),nans::Bool=false,norm::Function=LinearAlgebra.norm) where {S<:TensorAlgebra,T<:$T} = Base.isapprox(a,Single{Manifold(a)}(b);atol=atol,rtol=rtol,nans=nans,norm=norm)
407
407
Base.isapprox(a::S,b::T;atol::Real=0,rtol::Real=Base.rtoldefault(a,b,atol),nans::Bool=false,norm::Function=LinearAlgebra.norm) where {S<:$T,T<:TensorAlgebra} = Base.isapprox(b,a;atol=atol,rtol=rtol,nans=nans,norm=norm)
408
408
end
409
409
end
@@ -412,18 +412,19 @@ for Field ∈ Fields
412
412
TF = Field ∉ Fields ?:Any::T
413
413
EF = Field ≠ Any ? Field : ExprField
414
414
@evalbegin
415
-
Base.:*(a::F,b::Submanifold{V}) where {F<:$EF,V} =Simplex{V}(a,b)
416
-
Base.:*(a::Submanifold{V},b::F) where {F<:$EF,V} =Simplex{V}(b,a)
417
-
Base.:*(a::F,b::Simplex{V,G,B,T}where B) where {F<:$Field,V,G,T<:$Field} =Simplex{V,G}(Base.:*(a,b.v),basis(b))
418
-
Base.:*(a::Simplex{V,G,B,T}where B,b::F) where {F<:$Field,V,G,T<:$Field} =Simplex{V,G}(Base.:*(a.v,b),basis(a))
419
-
Base.adjoint(b::Simplex{V,G,B,T}) where {V,G,B,T<:$Field} =Simplex{dual(V),G,B',$TF}(Base.conj(value(b)))
415
+
Base.:*(a::F,b::Submanifold{V}) where {F<:$EF,V} =Single{V}(a,b)
416
+
Base.:*(a::Submanifold{V},b::F) where {F<:$EF,V} =Single{V}(b,a)
417
+
Base.:*(a::F,b::Single{V,G,B,T}where B) where {F<:$Field,V,G,T<:$Field} =Single{V,G}(Base.:*(a,b.v),basis(b))
418
+
Base.:*(a::Single{V,G,B,T}where B,b::F) where {F<:$Field,V,G,T<:$Field} =Single{V,G}(Base.:*(a.v,b),basis(a))
419
+
Base.adjoint(b::Single{V,G,B,T}) where {V,G,B,T<:$Field} =Single{dual(V),G,B',$TF}(Base.conj(value(b)))
420
420
end
421
421
end
422
422
423
423
for M ∈ (:Signature,:DiagonalForm,:Submanifold)
424
424
@evalbegin
425
-
@inline (V::$M)(s::LinearAlgebra.UniformScaling{T}) where T =Simplex{V}(T<:Bool? (s.λ ?1:-1) : s.λ,getbasis(V,(one(T)<<(mdims(V)-diffvars(V)))-1))
0 commit comments