Web Simulation 

 

 

 

 

Ampere's Law and the Lorentz Force Tutorial 

This tutorial transitions from electromagnetic induction (how motion creates electricity) to the Lorentz Force Law: how electricity and magnetism create physical force. That is the principle behind electric motors, railguns, and mass spectrometers.

 

From Faraday to Lorentz

In Faraday's Law, we asked: “How does motion create electricity?” Here we ask: “How does electricity in a magnetic field create force?” The Lorentz Force on a charged particle is:

F = q(E + v × B)

For a current-carrying wire in a magnetic field we use the magnetic part. The force on a wire segment of length dL carrying current I is:

dF = I (dL × B)

So the wire is pushed perpendicular to both the current direction and the field. This is the “Magnetic Slingshot”: inject current, watch the wire deflect.

 

Mathematical foundation

1. The Lorentz Force (magnetic part)

For a straight wire of length L in a uniform field B, with current I along direction L, the total force is F = I (L × B). The magnitude is F = I L B sin θ, where θ is the angle between the wire and the field. Force is maximum when the wire is perpendicular to the field; zero when parallel.

2. The Right-Hand Rule (RHR)

Point your thumb in the direction of current I, your fingers in the direction of B. Your palm faces the direction of F. The vectors I, B, and F are mutually perpendicular: F = I × B (in appropriate units). The simulation shows a vector gizmo: blue = current, red = B-field, green = force.

3. Ampere's Law and the source of B

Ampere's Law relates current to the magnetic field it produces: ∫ B · dL = μ0 Ienc. In our setup, the horseshoe magnet provides a nearly uniform B in the gap (from North to South). We treat B as given; the Lorentz force then tells us how that field pushes the wire. So we combine: Ampere's Law (currents create B) with the Lorentz Force (B acts on current).

4. Motor action

Electrical energy is converted into kinetic energy: the force does work on the wire and it moves. When you flip the current from +I to −I, F reverses and the wire “jumps” to the other side of the magnet. That visual reversal confirms the cross-product direction.

 

Worked idea (direction)

Wire perpendicular to B, current up: Right-hand rule gives force out of the page (or into the gap). The wire bows one way. Reverse current: Thumb flips; force flips. The wire bows the opposite way. Turn off current: Force goes to zero; a spring-like tension in the wire pulls it back to straight. The “Aha!” moment is that current direction determines force direction via the cross product.

1.0
0.0
1.0
(0, 0, 0) N
Current (I) – Thumb
B-Field (B) – Fingers
Force (F) – Palm
Force vector: (0, 0, 0) N

 

Usage

Follow these steps to explore the Lorentz Force on a current-carrying wire:

  1. Current: Choose a pattern (DC, Step, Sinusoid, Pulse train, Pulse (hold)) from the dropdown. Use the Current I (A) slider to set DC value or pattern amplitude. Press Apply to run the selected pattern continuously; press Stop to stop it. When current flows through the wire in the magnet gap, the Lorentz force F = I(L × B) pushes the wire perpendicular to both I and B. The wire bows; wire color (yellow→pink) indicates current direction.
  2. Speed: The slider (0.1–1) next to Apply scales animation and pattern time. At 0.1 the sim runs at 10% speed; at 1 at full speed.
  3. B-field strength: Increase the field between the poles. Stronger B gives larger force and more deflection for the same current. B-field arrows from North to South show the field direction.
  4. Poles (flip): Reverse North/South. The field B flips direction, so the force F flips. The wire jumps to the other side.
  5. Right-Hand Rule (RHR) panel: The overlay shows current (blue), B-field (red), and force (green). They stay mutually perpendicular. Use it to check that F follows the cross product.
  6. F,B,I plot: At the bottom of the 3D canvas, an overlay shows I (blue), B (red), and F (green) over time for the last ~10 s. Useful to see how patterns and force evolve.
  7. 3D view: Use Iso, Front, Top, Side and Zoom+ / Zoom− to change the camera. Drag to rotate, scroll to zoom.
  8. The “Jump” test: Set current to +I, note which way the wire bows. Then set current to −I. The wire should jump to the opposite side. That confirms that F reverses when I reverses.

Tips: Use the RHR gizmo to see how I, B, and F are orthogonal. Compare strong B vs weak B for the same current. Use Apply with Pulse (hold) or Step to see the wire deflect, then Stop to see it snap back (spring-like behavior). Use Sinusoid or Pulse train for continuous motion. The F,B,I plot at the bottom tracks I, B, and F over time; lower the Speed slider to follow fast patterns more easily.

Parameters

  • Current pattern: Dropdown options: DC (slider), Step, Sinusoid, Pulse train, Pulse (hold). Apply runs the selected pattern continuously; Stop ends it. Amplitude for patterns is taken from the Current I slider when Apply is pressed.
  • Speed: Animation speed 0.1–1. Scales both pattern time and wire physics (0.1 = 10% speed, 1 = full speed).
  • Current I: Amperes, from −5 to +5. For DC it sets the current; for other patterns it sets the amplitude when Apply is pressed. Sign sets direction; force direction follows the right-hand rule.
  • B-field strength: Scaling factor for the magnetic field in the gap (0–3). Larger B gives larger F = I L B sin θ.
  • Poles: Flip magnet so B reverses. Force reverses; wire deflects the other way.
  • Force (F): Computed as F = I(L × B) for the wire segment in the field. Displayed as a vector (x, y, z) in newtons (arbitrary scale) and in the F,B,I plot (green) over time.
  • F,B,I plot: Overlay at the bottom of the 3D canvas. Shows I (blue), B (red), F (green) vs. time for the last ~10 s. Y-axis range ±4.
  • RHR legend: Blue = current (thumb), red = B-field (fingers), green = force (palm). The 3D arrows in the scene follow the same convention.

Magnitude vs angle

The force magnitude is F = I L B sin θ. When the wire is perpendicular to B, θ = 90° and F is maximum. When the wire is parallel to B, θ = 0 and F = 0. In this simulation the wire is placed perpendicular to the field in the gap, so you always see maximum effect for the given I and B.

Relation to Ampere's Law

Ampere's Law, ∫ B · dL = μ0 Ienc, describes how currents produce magnetic fields. Here we use a horseshoe magnet to supply B; we do not compute B from Ampere's Law in the sim. The focus is the Lorentz Force: given B and current I, how does the wire move? Together, Ampere (currents → B) and Lorentz (B and current → force) explain motor action and many devices.