Use vrrotvec to calculate the rotation angles between two vectors (R2015b)
4 ビュー (過去 30 日間)
古いコメントを表示
I need to calculate the rotation angle to transform vector a = [1, 0, 0]' to b = [1/sqrt(3), 1/sqrt(3), 1/sqrt(3)]',such that I script below:
X = [1, 0, 0]';
Y = [1/sqrt(3), 1/sqrt(3), 1/sqrt(3)]';
R = vrrotvec(X, Y);
As the outcome, I have R = 0, -0.7071, 0.7071, 0.9553
What is the meaning of the first three items, i.e. 0, -0.7071 and 0.7071? Are they the cosine value of the rotation angle against x-, y- and z-axes?
5 件のコメント
採用された回答
dan
2017 年 8 月 23 日
The first 3 elements is the vector in the first coordinate system. The fourth element is the rotation about the new vector to get to the vector you want.
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Trigonometry についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!