Search code examples
modelicaopenmodelica

Error on simple four link mechanism simulation with modelica


I'm trying to implement a 4 link mechanism and the model I've put together is shown here:

                        

Revolute1 has a speed of 5 rad/s. All bars are 0.05 m in diameter. World settings are the default and you can see the bar vectors on the picture. Nothing else is changed.

When I try to run the simulation I get these errors on OpenModelica:

[1] 10:29:43 Symbolic Error [Modelica.Mechanics.MultiBody.Parts: 238:5-238:62]: Model is structurally singular, error found sorting equations

[2] 10:33:25 Translation Error Internal error Transformation Module PFPlusExt index Reduction Method Pantelides failed!

What am I doing wrong? It seems pretty straight-forward. Thanks.


Solution

  • You need to replace one of the Revolute joints with a RevolutePlanarLoopConstraint. Why? Citing the documentation:

    If a planar loop is present, e.g., consisting of 4 revolute joints where the joint axes are all parallel to each other, then there is no unique mathematical solution if all revolute joints are modelled with Joints.Revolute and the symbolic algorithms will fail. The reason is that, e.g., the cut-forces in the revolute joints perpendicular to the planar loop are not uniquely defined when 3-dim. descriptions of revolute joints are used