SimMechanics Rotation Control via Torque Application

Using a body sensor block I am retrieving the rotation matrix of a simulated body. Knowing the initial rotation and the current body rotation, I am attempting to apply a torque to this body so that it returns to the initial rotation. I have converted the rotation matrix form to Euler angles, determined the difference between the rotations via cross product and have multiplied this by the diagonal terms of the body's inertia tensor (Ixx, Iyy and Izz). The resultant vector is input to a body actuator that is set to actuate my model with an applied torque. However, my simulation does not run and a singularity occurs. Is there a way to achieve rotation regulation of a body that I may have overlooked?

답변 (1개)

Steve Miller
Steve Miller 2021년 11월 24일

0 개 추천

If you are getting an error concerning a singularity, I suspect you are either
  1. Using a Gimbal Joint which has gone into Gimbal Lock (two degrees of freedom are aligned). In this case, switch to a Spherical Joint
  2. Are missing inertia on a degree of freedom. In this case, add inertia to that degree of freedom.
--Steve

카테고리

질문:

Leo
2015년 3월 14일

답변:

2021년 11월 24일

Community Treasure Hunt

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

Start Hunting!

Translated by