How to translate MATLAB's euler angle quadrotor equations into body frame?
5 次查看(过去 30 天)
显示 更早的评论
In the following MIT lecture notes Equation (6.10) is given with body-frame angular velocities, whereas in this Matlab tutorial, the equations are given in euler angles. I have tried, using cross product properties, to translate between the two. The two equation presentations are given in detail in this post, I was unable to move the latex expressions over to Matlab's latex editor.
0 个评论
回答(1 个)
SAI SRUJAN
2024-5-1
Hi Johannes,
I understand that you are facing an issue translating the MATLAB's euler angle quadrotor equations into body frame angular velocities.
To address the transformation of Euler angle-based quadrotor dynamics into body frame representations within MATLAB, the following code uses symbolic math to define the transformation and calculate the body frame angular velocities from given Euler angle rates.
Please go through the following code sample to proceed further,
syms phi theta psi dot_phi dot_theta dot_psi
T = [1, 0, -sin(theta);
0, cos(phi), cos(theta)*sin(phi);
0, -sin(phi), cos(theta)*cos(phi)];
eulerRates = [dot_phi; dot_theta; dot_psi];
bodyFrameVelocities = T * eulerRates;
p = bodyFrameVelocities(1);
q = bodyFrameVelocities(2);
r = bodyFrameVelocities(3);
I hope this helps!
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Symbolic Math Toolbox 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!