Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect norm(::RodriguesParam) #187

Closed
hyrodium opened this issue Nov 4, 2021 · 4 comments
Closed

Incorrect norm(::RodriguesParam) #187

hyrodium opened this issue Nov 4, 2021 · 4 comments
Labels

Comments

@hyrodium
Copy link
Collaborator

hyrodium commented Nov 4, 2021

julia> using Rotations, LinearAlgebra

julia> R = RodriguesParam(1., 2., 3.)
3×3 RodriguesParam{Float64} with indices SOneTo(3)×SOneTo(3)(1.0, 2.0, 3.0):
 -0.733333  -0.133333  0.666667
  0.666667  -0.333333  0.666667
  0.133333   0.933333  0.333333

julia> norm(R)
3.7416573867739413

julia> norm(collect(R))
1.732050807568877

The last two returned values should be equal.

@hyrodium
Copy link
Collaborator Author

hyrodium commented Nov 4, 2021

And also norm(::MRP).

julia> R = MRP(1., 2., 3.)
3×3 MRP{Float64} with indices SOneTo(3)×SOneTo(3)(1.0, 2.0, 3.0):
  0.537778   0.764444   -0.355556
 -0.622222   0.644444    0.444444
  0.568889  -0.0177778   0.822222

julia> norm(R)
3.7416573867739413

julia> norm(collect(R))
1.7320508075688772

@hyrodium
Copy link
Collaborator Author

hyrodium commented Nov 4, 2021

julia> R = UnitQuaternion(1., 2., 3., 4.)
3×3 UnitQuaternion{Float64} with indices SOneTo(3)×SOneTo(3)(0.182574, 0.365148, 0.547723, 0.730297):
 -0.666667   0.133333  0.733333
  0.666667  -0.333333  0.666667
  0.333333   0.933333  0.133333

julia> norm(R)
0.9999999999999999

julia> norm(collect(R))
1.732050807568877

@hyrodium
Copy link
Collaborator Author

hyrodium commented Nov 4, 2021

@hyrodium hyrodium added the bug label Nov 5, 2021
@hyrodium
Copy link
Collaborator Author

This issue has been solved in #175.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant