We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Sometimes it is nice to have the rotation that aligns two vectors (e.g. when aligning randomly oriented data according to a chosen frame).
If it is a good fit for the package, I can try to make a PR. I already have some code doing it laying somewhere.
The text was updated successfully, but these errors were encountered:
This function seems already implemented as Rotations.rotation_between.
Rotations.rotation_between
julia> using Rotations, LinearAlgebra julia> r = Rotations.rotation_between([1,0,0],[0,1/√2,1/√2]) 3×3 QuatRotation{Float64} with indices SOneTo(3)×SOneTo(3)(QuaternionF64(0.707107, 0.0, -0.5, 0.5, false)): -1.11022e-16 -0.707107 -0.707107 0.707107 0.5 -0.5 0.707107 -0.5 0.5 julia> r * [1,0,0] 3-element StaticArraysCore.SVector{3, Float64} with indices SOneTo(3): -1.1102230246251565e-16 0.7071067811865475 0.7071067811865475 julia> dot(rotation_axis(r), [1,0,0]) 3.437762736252422e-63 julia> dot(rotation_axis(r), [0,1/√2,1/√2]) 0.0
Sorry, something went wrong.
Please comment here if Rotations.rotation_between is not sufficient.
No branches or pull requests
Sometimes it is nice to have the rotation that aligns two vectors (e.g. when aligning randomly oriented data according to a chosen frame).
If it is a good fit for the package, I can try to make a PR. I already have some code doing it laying somewhere.
The text was updated successfully, but these errors were encountered: