Order of Rotation Matrices

3 ビュー (過去 30 日間)
Julia Williams
Julia Williams 2019 年 8 月 1 日
編集済み: Julia Williams 2019 年 8 月 1 日
I am having trouble with the translating coordinates in different reference frames. The tip of the finger is relative to the second knuckle which is relative to the first which is relative to the base of the finger. So far I have this code which transforms the coordinates I have given. I am trying to get all the coordinates relative to the same axis (the base of the finger). I am using rotation matrices generated from Euler Angles and am translating the coordinates as well but I am not getting the output i should. Please let me know if I should provide additional information! Thank you! Should I be premultiplying the coordinates by the matrices?
%eul2rotm is repeated for the rest of the joints
eultip = NewData(10+rowcounter,:);
eultip1 = [deg2rad(eultip(1)) deg2rad(eultip(2)) deg2rad(eultip(3))];
rotmtip = eul2rotm(eultip, 'XYZ');
%cascading rotation matrices
Lbase = (rotmbase)*(rotmpalm);
Lpalm1 = (rotm1)*(rotmbase)*(rotmpalm);
Lpalm2 = (rotm2)*(rotm1)*(rotmbase)*(rotmpalm);
Lpalmtip = (rotmtip)*(rotm2)*(rotm1)*(rotmbase)*(rotmpalm);
vectorbase = NewData(3+rowcounter,:);
indexbase = Lbase * transpose(vectorbase);
% this repeats with the rest of the fingers
vector1 = NewData(5+ rowcounter,:) - vectorbase;
indexknuckle1 = Lpalm1 * transpose(vector1);

回答 (0 件)

カテゴリ

Help Center および File ExchangeAssembly についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by