Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

Coupled Oscillators

Coupled Oscillators

Estimated OpenModelica Forum
I performed the following simulation,

http://ymauxa.bay.livefilestore.com/y1p … png?psid=1
corresponding to the picture below,

http://ymauxa.bay.livefilestore.com/y1p … png?psid=1
the code is,
model mecanico4
  Modelica.Mechanics.Translational.Fixed fixed1 ;
  Modelica.Mechanics.Translational.Fixed fixed2 ;
  Modelica.Mechanics.Translational.SlidingMass slidingMass1(L=0, s(start=0.1));
  Modelica.Mechanics.Translational.SlidingMass slidingMass2(L=0, s(start=0.6));
  Modelica.Mechanics.Translational.Spring spring1 (c=1000) ;
  Modelica.Mechanics.Translational.Spring spring2 (c=15);
  Modelica.Mechanics.Translational.Spring spring3 (c=1000) ;
equation
  connect(spring1.flange_b,fixed1.flange_b) ;
  connect(slidingMass1.flange_b,spring1.flange_a) ;
  connect(slidingMass1.flange_a,spring2.flange_b) ;
  connect(slidingMass2.flange_b,spring2.flange_a) ;
  connect(slidingMass2.flange_a,spring3.flange_b) ;
  connect(spring3.flange_a,fixed2.flange_b) ;
 
end mecanico4;

if I make the simulation for 10 seconds, the graph is,
http://ymauxa.bay.livefilestore.com/y1p … png?psid=1

if the simulation up to 80 seconds, the system behaves as expected,

http://ymauxa.bay.livefilestore.com/y1p … png?psid=1
when it reaches a simulation time of 100 seconds, the behavior is different,

http://ymauxa.bay.livefilestore.com/y1p … png?psid=1
may be due to this, or is correct?

I say goodbye to you carefully
Eduardo Ghershman

There are 0 guests and 0 other users also viewing this topic