Relative position sensor

Distance between flanges a and b.

  • signal
  • translational
  • Modelica Standard Library
  • 3 ports
BlockRelative position sensorKindrelPositionSensorLibraryTranslational

Description

Measures the position of flange b relative to flange a, without transmitting force. Use it to monitor the stretch of a spring or the clearance at a stop.

Example

Mass, spring, and damper Two 1 kg masses on 100 N/m springs and 2 N·s/m dampers, pushed by 1 N, with every translational sensor.

Force step 1 NApplied forceMass 1 kgSpring-damperWallPositionVelocityAccelerationForce 1 NMass 1 kg (lower)Spring 100 N/mDamper 2 N·s/mWall (lower)Spring compressionPosition (lower)
In Gradara, select a Relative position sensor block and press F1, then choose Open example. It opens as a new model in My models, ready to run.

Also in this example:Fixed (translational)MassSpringDamperSpring-damperConstant forceForce stepPosition sensorVelocity sensorAcceleration sensor (linear)Force sensor

Ports

Outputs 1

  • Δss_rel

    Relative position flange_b.s − flange_a.s, in meters.

Conserving terminals 2

  • aflange_a

    Reference flange. No force is exchanged.

  • bflange_b

    Measured flange. No force is exchanged.

Equations

Modelica
s_rel = flange_b.s − flange_a.s
flange_a.f = flange_b.f = 0

Implementation

Modelica Standard Library 4.1.0Modelica.Mechanics.Translational.Sensors.RelPositionSensor
MSL documentation

See also

Select a block in Gradara and press F1 to open its page offline.