Greetings to all,
I'm trying to model an actuator. When I use the following line of code to define the limits of the extended and retracted length of the actuator, I get the following graph:
s_rel=smooth(0, if strokeUpperLimit then l_cyl else if strokeLowerLimit then l_cyl + l_rod else flange_a.s - flange_b.s);
What is the best way to put limits to a variable ?
It's hard to give advice based on one line of a model code without the context. (Which are the parameters, variables, which interfaces are involved, etc.) I'd recommend to take a look at: Modelica.Mechanics.Translational.Components.MassWithStopAndFriction which includes limits to where the mass can travel: Example using the mass with stop