Skip to content

Commit

Permalink
fixed zero element dispatch issue
Browse files Browse the repository at this point in the history
  • Loading branch information
chakravala committed Mar 11, 2020
1 parent 113b30b commit a9ce73c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "Grassmann"
uuid = "4df31cd9-4c27-5bea-88d0-e6a7146666d8"
authors = ["Michael Reed"]
version = "0.5.3"
version = "0.5.4"

[deps]
AbstractTensors = "a8e43f4a-99b7-5565-8bf1-0165161caaea"
Expand All @@ -17,7 +17,7 @@ SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"
[compat]
julia = "1"
Reduce = "1.2"
Leibniz = "0.0.4"
Leibniz = "0.0.5"
DirectSum = "0.5.3"
AbstractTensors = "0.4.3"
ComputedFieldTypes = "0.1"
Expand Down
3 changes: 2 additions & 1 deletion src/Grassmann.jl
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ end

using Leibniz
import Leibniz: ∇, Δ, d #
export ∇, Δ, ∂, d, ,
export ∇, Δ, ∂, d, δ, ,

generate_products(:(Leibniz.Operator),:svec)
for T (:(Simplex{V}),:(Chain{V}),:(MultiVector{V}))
Expand Down Expand Up @@ -80,6 +80,7 @@ end

::T) where T<:TensorAlgebra = ωManifold(ω)(∇)
d::T) where T<:TensorAlgebra = Manifold(ω)(∇)ω
δ::T) where T<:TensorAlgebra = -(ω)

function boundary_rank(t::T,d=gdims(t)) where T<:TensorAlgebra
out = gdims((t))
Expand Down
1 change: 1 addition & 0 deletions src/multivectors.jl
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ setindex!(m::Chain{V,G,T} where {V,G},k::T,i::Int) where T = (m.v[i] = k)
Base.firstindex(m::Chain) = 1
@pure Base.lastindex(m::Chain{V,G}) where {V,G} = binomial(ndims(V),G)
@pure Base.length(m::Chain{V,G}) where {V,G} = binomial(ndims(V),G)
Base.zero(::Chain{V,G,T}) where {V,G,T} = Chain{V,G}(zeros(svec(ndims(V),G,T)))

function (m::Chain{V,G,T})(i::Integer) where {V,G,T}
Simplex{V,G,SubManifold{V}(indexbasis(ndims(V),G)[i]),T}(m[i])
Expand Down

2 comments on commit a9ce73c

@chakravala
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator register()

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/10812

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if Julia TagBot is installed, or can be done manually through the github interface, or via:

git tag -a v0.5.4 -m "<description of version>" a9ce73cad2a61664b131b6bc476a28bf63df590b
git push origin v0.5.4

Please sign in to comment.