I am quite new to using Dymola and am currently working on creating a mechanical model for a robotic arm. I am using the block 'Source - Position' to impose the position of the joints. I want to introduce friction and intend to use a table to model it (angular velocity : torque). Therefore, I chose the 'BearingFriction' component. My problem is that for certain input position values I get the following error:
Error: Singular inconsistent scalar system for bearingFriction.sa = ((if bearingFriction.locked then 0 else (if bearingFriction.startForward then -1.34 else (if bearingFriction.startBackward then 1.34 else (if pre(bearingFriction.mode) == 1 then -1.34 else 1.34))))-der)/( -(if bearingFriction.locked then 0 else 1.0)) = 19.8524/-0
Fixed point iterating to handle problem.
I am stuck on this problem, I tried for example to change solver, tolerance, and interpolation method of the table but with no result. I share with you my code (with an example of values for which I have the error):
model Test
Modelica.Mechanics.Rotational.Components.Inertia inertia(J=2)
annotation (Placement(transformation(extent={{-40,14},{-20,34}})));
Modelica.Mechanics.Rotational.Components.BearingFriction bearingFriction(tau_pos=[0,1; 10,1.5; 20,
2.1; 40,2.6; 100,4.8; 150,5.1; 300,5.8; 600,6], peak=1.34)
annotation (Placement(transformation(extent={{-4,14},{16,34}})));
Modelica.Mechanics.Rotational.Components.Inertia inertia1(J=3)
annotation (Placement(transformation(extent={{74,14},{94,34}})));
Modelica.Mechanics.Rotational.Components.IdealGear idealGear(ratio=20)
annotation (Placement(transformation(extent={{36,14},{56,34}})));
Modelica.Mechanics.Rotational.Sources.Position position(exact=true)
annotation (Placement(transformation(extent={{-82,14},{-62,34}})));
Modelica.Blocks.Sources.ContinuousClock continuousClock
annotation (Placement(transformation(extent={{-160,14},{-140,34}})));
Modelica.Blocks.Tables.CombiTable1Ds combiTable1Ds(
table=[0.0,70.2029; 0.00482,70.2029; 0.00964,70.2029; 0.01446,70.2014; 0.01928,70.197;
0.0241,70.1876; 0.02892,70.1663],
columns={2},
smoothness=Modelica.Blocks.Types.Smoothness.ModifiedContinuousDerivative)
annotation (Placement(transformation(extent={{-122,14},{-102,34}})));
equation
connect(inertia.flange_b, bearingFriction.flange_a)
annotation (Line(points={{-20,24},{-4,24}}, color={0,0,0}));
connect(bearingFriction.flange_b, idealGear.flange_a)
annotation (Line(points={{16,24},{36,24}}, color={0,0,0}));
connect(idealGear.flange_b, inertia1.flange_a)
annotation (Line(points={{56,24},{74,24}}, color={0,0,0}));
connect(position.flange, inertia.flange_a)
annotation (Line(points={{-62,24},{-40,24}}, color={0,0,0}));
connect(continuousClock.y, combiTable1Ds.u)
annotation (Line(points={{-139,24},{-124,24}}, color={0,0,127}));
connect(combiTable1Ds.y[1], position.phi_ref)
annotation (Line(points={{-101,24},{-84,24}}, color={0,0,127}));
annotation (
uses(Modelica(version="4.0.0")),
Diagram(coordinateSystem(extent={{-160,-100},{100,100}})),
Icon(coordinateSystem(extent={{-160,-100},{100,100}})));
end Test;
If you ignore the
idealGearandinertia1the problem becomes clearer:You have a rigid motion of the
inertia- and you want to compute friction, but the friction cannot influence the motion of theinertia.The solutions I can see are: