フィルターのクリア

Info

この質問は閉じられています。 編集または回答するには再度開いてください。

Can somebody help me to modify this code?

2 ビュー (過去 30 日間)
Darsana P M
Darsana P M 2018 年 5 月 2 日
閉鎖済み: MATLAB Answer Bot 2021 年 8 月 20 日
I am working with quaternion calculus. So inorder to find the quaternion rotation matrix,
Brot = q.B.(q^-1)
then to find B,
B = (q^-1). Brot.q
I was trying to find these values B and Brot in matlab. But I got different answers. Can somebody tell me the cause for the mistake?
q1=[4 3 2 6];
q2= qInv(q1);
B=[1 2 3;4 5 6;7 8 9];
Q1=q1(2:4);
Q2=q2(2:4);
J= Q1*B;
JJ=J*Q2;
KK= Q2*JJ;
JK= KK*Q1;
Can somebody help me to solve this?
  1 件のコメント
Cristian Garcia Milan
Cristian Garcia Milan 2020 年 5 月 22 日
What is yout error exactly?

回答 (1 件)

James Tursa
James Tursa 2020 年 5 月 22 日
In this
Brot = q.B.(q^-1)
and this
B = (q^-1). Brot.q
expression, the dot (.) is likely supposed to represent quaternion multiply, not standard matrix multiply as you seem to be doing.

この質問は閉じられています。

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by