ATell-SoundTheory / CliffordAlgebras.jl

A fast and lightweight Julia package for Clifford and geometric algebras.
https://atell-soundtheory.github.io/CliffordAlgebras.jl/
MIT License
36 stars 4 forks source link

Support for Base.Number as scalar field #18

Open Benr444 opened 1 year ago

Benr444 commented 1 year ago

Would it be possible to support scalar multiplication with any Base.Number subtype?

Restriction to Base.Real right now has several issues. The complex scalar Base.im can't be used to define a complexified Clifford Algebra. Also, it restricts the kinds of packages we can interact with--ones like Measurements.jl work (the principle type <: Base.Real) whereas ones like Unitful.jl don't work (the principle type is not a subtype of Base.Real)

You can kind hack together solutions to both of these right now but it's not great. Thanks!

Benr444 commented 1 year ago

Also, I love this package so thanks for making it

ATell-SoundTheory commented 1 year ago

Thank you for your feedback! Would you be able to make a pull request? I'm insanely busy right now and if you wish this to be added soon then making a PR is probably the fastest way.