JuliaApproximation / HarmonicOrthogonalPolynomials.jl

A Julia package for working with spherical harmonic expansions
MIT License
24 stars 2 forks source link

How to represent tangent bundle? #5

Open dlfivefifty opened 4 years ago

dlfivefifty commented 4 years ago

When we do vector-spherical harmonics we'll want

V = VectorSphericalHarmonics()
eltype(V)

to be a type representing the tangent bundle.

dlfivefifty commented 4 years ago

https://github.com/mateuszbaran/FunManifolds.jl has this implemented, though it looks like it doesn't actually impose that the vector is in the tangent space.

@daanhb have you thought about this at all for DomainSets.jl?

daanhb commented 4 years ago

@dlfivefifty not really. There is no notion of a manifold, let alone tangent spaces.

The only thing I did is make sure that mappings are not assumed to map between spaces of the same dimension, to enable working with a lower-dimensional parameter domain. A UnitCircle has a parameterization for example, which goes from 1d to 2d, and it has a left inverse which maps back. I guess that could be done for a sphere, and the jacobian of the map could generically be used to verify whether a vector is in the tangent space. But everything on top of that has yet to be invented.

dlfivefifty commented 4 years ago

OK. I think the right way to think of this is as a generalisation of a dual number, where the value is a SphericalCoordinate <: SVector{3} and the dual part is TangentVector <: SVector{3}.

Probably best to think how a circle in the complex plane would work first. One option would be to treat the tangent vector using lazy arrays, e.g., for something in the tangent space with constant c at the point (1/sqrt(2),1/sqrt(2)) would be represented via:

TangentDual(SVector(1/sqrt(2), 1/sqrt(2)), ApplyVector(*, c, SVector(1/sqrt(2),-1/sqrt(2))))

(Makes me wonder if we can have ApplyArray conform to the static array interface...)

daanhb commented 4 years ago

Looks interesting, just let me know if there is anything you feel belongs to DomainSets. I wasn't thinking of differential geometry myself, but I would like to expand on the parameterization of domains (or a suitable interface for it). In fact that was part of the motivation for improving maps.