Why do I receive an error while running the example provided in the section "Rotating the body with the Rotation matrix" of the documentation for SimMechanics 2.2 (R14)?

1 view (last 30 days)
I set up the test body according to the instructions given in the documentation at the following page:
web([docroot,'/toolbox/physmod/mech/mech_review9.html#16600'])
I follow the instructions to set up an inertia tensor given in the "Rotating the Body Relative to Its Center of Gravity" section at the following page:
web([docroot,'/toolbox/physmod/mech/mech_review11.html#16537'])
Upon updating the Simulink diagram, I receive the following error dialog:
Error evaluating function mech_hgdraw: Error using ==> mech_hgdraw>CreateObjects
Error: untitled/Body: Body inertia matrix is not symmetric..
The following error message is also displayed at the MATLAB command prompt:
Error: untitled/Body: Body inertia matrix is not symmetric.
I expect the updated diagram to rotate the body.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 27 Jun 2009
This change has been incorporated into the documentation in Release 14 Service Pack 3 (R14SP3). For previous releases, read below for any additional information:
We have verified that this is a bug in the documentation example for SimMechanics 2.2 (R14) as a result of round-off errors. As a work-around, please type the following at the MATLAB command prompt before updating the Simulink diagram:
Irot = (Irot + Irot')/2;

More Answers (0)

Community Treasure Hunt

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

Start Hunting!