Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion Modelica/Mechanics/Translational/Examples/Accelerate.mo
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,23 @@ Demonstrate usage of component
<a href=\"modelica://Modelica.Mechanics.Translational.Sources.Accelerate\">Sources.Accelerate</a>
by moving a mass with a predefined acceleration.
</p>
</html>"),
</html>",
figures = {
Figure(
title = "Mass variables",
identifier = "79d80",
preferred = true,
plots = {
Plot(
curves = {
Curve(y = mass.a, legend = "Accelleration of mass"),
Curve(y = mass.s, legend = "Position of mass"),
Curve(y = mass.v, legend = "Velocity of mass")
}
)
}
)
}
),
experiment(StopTime=1.0, Interval=0.001));
end Accelerate;
18 changes: 17 additions & 1 deletion Modelica/Mechanics/Translational/Examples/Brake.mo
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,22 @@ After 0.1&nbsp;s, a brake is activated and it is shown that the mass decelerates
it arrives at rest and remains at rest. Two versions of this system are present,
one where the brake is implicitly grounded and one where it is grounded explicitly.
</p>
</html>"),
</html>",
figures = {
Figure(
title = "Braking mass",
identifier = "cfd0a",
preferred = true,
plots = {
Plot(
curves = {
Curve(y = mass1.s, legend = "Position of mass1"),
Curve(y = mass1.v, legend = "Velocity of mass1")
}
)
}
)
}
),
experiment(StopTime=2.0, Interval=0.001));
end Brake;
24 changes: 23 additions & 1 deletion Modelica/Mechanics/Translational/Examples/ElastoGap.mo
Original file line number Diff line number Diff line change
Expand Up @@ -77,5 +77,27 @@ While mass1 is moved by both spring/damper forces all the time, this is not the
since elastoGap1 lifts off at s&nbsp;&gt;&nbsp;-0.5 m and elastoGap2 lifts off at s&nbsp;&lt;&nbsp;+0.5 m.
Therefore, mass2 moves freely as long as -0.5&nbsp;m&nbsp;&lt;&nbsp;s&nbsp;&lt;&nbsp;+0.5&nbsp;m.
</p>
</html>"));
</html>",
figures = {
Figure(
title = "Positions and velocitites",
identifier = "00623",
preferred = true,
plots = {
Plot(
curves = {
Curve(y = mass1.s, legend = "Position of mass1"),
Curve(y = mass2.s, legend = "Position of mass2")
}
),
Plot(
curves = {
Curve(y = mass1.v, legend = "Velocity of mass1"),
Curve(y = mass2.v, legend = "Velocity of mass2")
}
)
}
)
}
));
end ElastoGap;
17 changes: 16 additions & 1 deletion Modelica/Mechanics/Translational/Examples/Friction.mo
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,21 @@ equation
<strong>reinit</strong>(&hellip;), convergence problems). In this case use the ElastoGap
to model a stop (see example Preload).</li>
</ol>
</html>"),
</html>",
figures = {
Figure(
title = "Stribeck curve",
identifier = "c0a76",
preferred = true,
plots = {
Plot(
curves = {
Curve(x = stop1.f, y = stop1.v, legend = "Force from stop1 as a function of velocity from stop1")
}
)
}
)
}
),
experiment(StopTime=5.0, Interval=0.001));
end Friction;
17 changes: 16 additions & 1 deletion Modelica/Mechanics/Translational/Examples/HeatLosses.mo
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,21 @@ a convection element to the environment. The total heat flow generated by the
elements and transported to the environment
is present in variable convection.fluid.
</p>
</html>"),
</html>",
figures = {
Figure(
title = "Heat loss",
identifier = "3f446",
preferred = true,
plots = {
Plot(
curves = {
Curve(y = convection.Q_flow, legend = "Heat flow to convection component")
}
)
}
)
}
),
experiment(StopTime=2.0, Interval=0.001));
end HeatLosses;
24 changes: 23 additions & 1 deletion Modelica/Mechanics/Translational/Examples/InitialConditions.mo
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,29 @@ combination). In this case the system is not at rest.
<blockquote>
<img src=\"modelica://Modelica/Resources/Images/Mechanics/Translational/Examples/InitialConditions.png\" alt=\"Initial conditions\">
</blockquote>
</html>"),
</html>",
figures = {
Figure(
title = "Mass positions",
identifier = "f49c2",
preferred = true,
plots = {
Plot(
curves = {
Curve(y = m1.s, legend = "Position of mass m1"),
Curve(y = m2.s, legend = "Position of mass m2")
}
),
Plot(
curves = {
Curve(y = m3.s, legend = "Position of mass m3"),
Curve(y = m4.s, legend = "Position of mass m4")
}
)
}
)
}
),
experiment(StopTime=5.0, Interval=0.001),
Diagram(coordinateSystem(preserveAspectRatio=false, extent={{-100,-100},
{100,100}}), graphics={
Expand Down
18 changes: 17 additions & 1 deletion Modelica/Mechanics/Translational/Examples/Oscillator.mo
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,22 @@ conditions s(start=-0.5) and v(start=0) for the sliding masses
are set.
If damping is added the amplitudes are bounded.
</p>
</html>"),
</html>",
figures = {
Figure(
title = "Mass position",
identifier = "2191a",
preferred = true,
plots = {
Plot(
curves = {
Curve(y = mass1.s, legend = "Position of mass1"),
Curve(y = mass2.s, legend = "Position of mass2")
}
)
}
)
}
),
experiment(StopTime=1.0, Interval=0.001));
end Oscillator;
17 changes: 16 additions & 1 deletion Modelica/Mechanics/Translational/Examples/PreLoad.mo
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,21 @@ the start value <code>spool.s.start</code> influences the offset.
<div>
<img src=\"modelica://Modelica/Resources/Images/Mechanics/Translational/Examples/PreLoad2.png\" alt=\"Preload 2\">
</div>
</html>"),
</html>",
figures = {
Figure(
title = "Force vs. position",
identifier = "008d0",
preferred = true,
plots = {
Plot(
curves = {
Curve(x = spool.s, y = force.f, legend = "Position of spool vs. force")
}
)
}
)
}
),
experiment(StopTime=100, Interval=0.1));
end PreLoad;
19 changes: 18 additions & 1 deletion Modelica/Mechanics/Translational/Examples/Sensors.mo
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,23 @@ length&nbsp;<var>L</var> of the component.
Plot <code>positionSensor1.s</code>, <code>positionSensor2.s</code> and <code>mass.s</code>
to see the difference.
</p>
</html>"),
</html>",
figures = {
Figure(
title = "Positions",
identifier = "5669c",
preferred = true,
plots = {
Plot(
curves = {
Curve(y = positionSensor1.s, legend = "Output from positionSensor"),
Curve(y = positionSensor2.s, legend = "Output from positionSensor2"),
Curve(y = mass.s, legend = "Position of mass")
}
)
}
)
}
),
experiment(StopTime=1.0, Interval=0.001));
end Sensors;
19 changes: 18 additions & 1 deletion Modelica/Mechanics/Translational/Examples/SignConvention.mo
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,24 @@ In the third system the two arrows are opposed which means that the
force acts in the opposite direction (in the same direction as in
the two other examples).
</p>
</html>"),
</html>",
figures = {
Figure(
title = "Mass variables",
identifier = "67a2d",
preferred = true,
plots = {
Plot(
curves = {
Curve(y = mass1.a, legend = "Accelleration of mass1"),
Curve(y = mass1.s, legend = "Position of mass1"),
Curve(y = mass1.v, legend = "Velocity of mass1")
}
)
}
)
}
),
Diagram(coordinateSystem(preserveAspectRatio=true, extent={{-100,-100},
{100,100}}),graphics={Text(
extent={{-100,80},{-82,60}},
Expand Down
Loading