JuliaManifolds / Manifolds.jl

Manifolds.jl provides a library of manifolds aiming for an easy-to-use and fast implementation.
https://juliamanifolds.github.io/Manifolds.jl
MIT License
368 stars 53 forks source link

Discrepancy in documentation: at what point is vector X in `translate_diff` #743

Closed Affie closed 5 days ago

Affie commented 5 days ago

https://juliamanifolds.github.io/Manifolds.jl/stable/manifolds/group.html#Manifolds.translate_diff-Tuple{AbstractDecoratorManifold,%20Vararg{Any}}

translate_diff(G::AbstractDecoratorManifold, p, q, X, conv::ActionDirectionAndSide=LeftForwardAction())

Affie commented 5 days ago

I'm also not sure if the implementation w.r.t. ActionDirectionAndSide is consistent. I'm busy looking at https://juliamanifolds.github.io/Manifolds.jl/stable/manifolds/group.html#Manifolds.translate-Tuple{AbstractDecoratorManifold,%20Vararg{Any}}

It looks like the LeftInvariantRepresentation implementation may be swopped around or RightBackwardAction but I'm not following the ActionDirectionAndSide that well yet.

Edit: From slack the correct call is translate_diff(G, q, p, X, Manifolds.RightBackwardAction())

when you want to differentiate p∘q with respect to p in the direction X (tangent at p).