Industrial

Educational

Scientific

Engineering questions

Sample problems

Examples gallery

Step-by-step tutorials

Verification examples

Programming examples

Distributive examples

Success stories

Customers

Main >> Applications >> Sample problems

Relay dynamics simulation using Tcl/Tk and Parametric command line - QuickField simulation example

Relay-plunger motion under electromagnetic and spring forces, with Tcl/Tk and the parametric command line evaluating force as the plunger moves..

To combine the electromagnetic field analysis with the moving core dynamics both Tcl/Tk and LabelMover are used. Interaction between LabelMover and Tcl is performed using parametric command line interface.

Engineering question

How is the relay's plunger motion calculated using QuickField and Tcl/Tk via LabelMover's parametric command line?

Answer
Set up an axisymmetric QuickField DC Magnetics problem and replace the multi-turn coil with an equivalent total current. Use Tcl/Tk (via LabelMover's parametric command line) to integrate the plunger's equation of motion, calling LabelMover at each step to get the electromagnetic force.

More questions →

Typical applications
electromagnetic relays, relay armatures, electromechanical switching devices

Relay dynamics simulation using Tcl/Tk and Parametric command line

Download

Simulation problem

Problem Type
Axisymmetric problem of DC magnetics.

Geometry
Relay dynamics simulation The electromagnetic and spring forces act on the plunger. Both forces depend on the plunger position Coil Plunger Spring 20 mm x Ø 7.2 mm

Given
Current I = 400 Ampere*turns;
Plunger pull-out position xmax = 10 mm.
Plunger pull in position xmin = 6 mm.
Plunger weight m = 4.5 g;
Spring constant k = 4 N/m
Spring free position xspring.free = 15 mm.

Task
Relay-plunger motion under electromagnetic and spring forces, with Tcl/Tk and the parametric command line evaluating force as the plunger moves..

Solution
The multi-turn winding is replaced with the equivalent total current.

The motion function can be found from second-order differential equation
m · d²x/dt² = f(x),
where m - is a plunger weight (kg),
x - is a plunger position (m)
f(x) - is the force acting on the plunger (N).
The force acting on the plunger is a sum of spring force fspring(x) = k·(xspring.free - x) and electromagnetic force.

The equations are solved in Tcl. The dynamic link is used to invoke LabelMover and calculate the electromagnetic force at each step.

The calculations are stopped when x=xmin (pull in position, plunger hits damper).
Tcl/Tk to QuickField LabelMover link The equations are solved in Tcl. The dynamic link is used to invoke QuickField LabelMover and calculate the electromagnetic force at each step Tcl/Tk QuickField + LabelMover Initial conditions x0 = xmax, v0 = 0 m/s Invoke LabelMover to calculate Force(xi) vi+1 = vi + Force/mass*Δt xi+1 = xi + vi+1* Δt x>xmin ? true false EXIT

Results
The plunger hits initial position (0.006 m) after 0.06 s. The plot was created using plotchart library.
Plot of the plunger position in meters vs time in seconds.

Related examples