Electric field simulation: field lines, magnetic field and Lorentz force
Pick an arrangement of charges and see its field lines, enter a current to get the magnetic field, or give a particle a speed to get the Lorentz force. The calculation runs in your browser.
Opens without an account 3 times a day. A free account removes the limit.
- 3 panelscharges, magnetic field, Lorentz force
- 3 arrangementsa dipole, two equal charges, three charges
- up to 12 equipotentialsdashed, at right angles to the lines
- NIST CODATA 2022ε₀, μ₀, e, mₑ and mₚ
Electric and magnetic field simulation: what it draws and calculates
The EduFacturing tool draws the electric field of charges, calculates the magnetic field of a wire, a loop and a solenoid, and finds the Lorentz force on a particle. It puts electrostatics, the field of a current and the Lorentz force on one screen, for a lesson or for checking a problem.
Field lines, magnetic field, Lorentz force: what you get
Sums the electric field of the charges
The field at every point is the vector sum of the fields of all the charges. The charge is 0.5 to 5 nC in steps of 0.5, the same for all.
Draws field lines and equipotentials
From 4 to 16 lines per positive charge. They end on a negative charge, at the edge of the 0.4 m by 0.4 m square or at a point of zero field. Dashed equipotentials cross them at right angles.
Calculates the magnetic field of a wire, loop and solenoid
For a straight wire, a loop and a solenoid you enter a current and a size and read B in nT, µT, mT or T.
Calculates the Lorentz force
For a proton, an electron or your own charge, enter vₓ, v_y and B_z and get |v|, F, its direction, the orbit radius, the frequency and the direction of rotation. A negative charge brings a warning.
When you need an electric field simulation
The electric field is drawn as a map, while the magnetic field and the Lorentz force are given as numbers.
A lesson on electric field and potential
A teacher swaps the dipole for two equal charges: the lines push apart and leave the area, and the equipotentials cross them at right angles.
Checking a magnetic field problem
A student checks an answer: 2 A at 5 cm from a straight wire gives 8.00 µT, and a solenoid with 800 turns per metre at 1 A gives about 1.01 mT.
Electron or proton: the sign of the charge
At 10⁶ m/s and 1 mT the electron's orbit has a radius of 5.69 mm and the proton's about 10.4 m, and they turn opposite ways.
How field lines and the Lorentz force are calculated
Every change goes through four steps.
Field and potential
The contributions of all the charges are summed: the field as a vector, the potential as a number.
Field lines
Each line is traced along the field step by step (fourth-order Runge-Kutta method). It stops near a charge, outside the 0.4 m by 0.4 m square, or where the field is almost zero.
Equipotentials
From 12 starting points the line is traced perpendicular to the field, and after each step Newton's method pulls it back to the starting potential.
Magnetic field and Lorentz force
The current and the size go into the formula for the chosen source. The radius and frequency are calculated only when speed, field and charge are not zero.
| Applies to | Formula | Meaning |
|---|---|---|
| Point charge | E = k·q / r²; V = k·q / r | k = 1/(4π·ε₀) ≈ 8.9876·10⁹ N·m²/C²; E is a vector, V is a number |
| Straight wire | B = μ₀·I / (2π·r) | an infinite wire; for a real one it holds far from the ends |
| Circular loop | B = μ₀·I / (2·R) | only at the centre of the loop |
| Solenoid | B = μ₀·n·I | n is turns per metre; far from the ends, at the very end the field is half |
| Particle in a field | F = q·(v × B); r = m·v / (|q|·B); f = |q|·B / (2π·m) | v in the plane, B along z, speed far below that of light; f does not depend on v |
The sign of the charge is visible
The sign of the charge is visible
Swap the electron for the proton at the same v and B and you see the opposite force, the opposite rotation and a different radius.
Constants from CODATA, not from memory
ε₀, μ₀, e and the masses come from the shared constants module. A note says that since 2019 μ₀ is not exact by definition.
There are three arrangements and they are preset: the charges do not move and all have the same size. The tool does not show the Coulomb force between two charges, only the field and the potential.
The magnetic field is not drawn, and points off the axis of a loop and at the ends of a solenoid are not calculated. The Lorentz panel takes v in the plane and B along z. The orbit circle is schematic. It is not for designing coils or magnets.
Questions about field lines and the Lorentz force
Why do electric field lines never cross?
The field at a point is one vector with one direction; a crossing would mean two at once. A test checks that two lines from the same charge never cross.
How are electric field lines drawn?
Each line follows the field from a positive charge. It ends on a negative charge, at the edge of the 0.4 m by 0.4 m square or at a point of zero field. Equipotentials cross it at right angles.
What is a Lorentz force, and what is the cyclotron frequency?
The Lorentz force on a moving charge is F = q·(v × B). The orbit radius is r = m·v / (|q|·B), and the cyclotron frequency f = |q|·B / (2π·m) does not depend on speed.
Can it calculate Coulomb's law?
Not directly. The tool does not show the Coulomb force between two charges, but the field E = k·q / r² and the potential V = k·q / r of an arrangement of charges.
Why do an electron and a proton turn opposite ways?
Their charges have opposite signs, so in F = q·(v × B) the forces are opposite. At 10⁶ m/s and 1 mT the radius is 5.69 mm for the electron and about 10.4 m for the proton, which is 1836 times heavier.
Is the tool free?
Yes. Without an account it opens 3 times a day. A free account removes the limit.
The electric and magnetic field simulation is free. Pro opens the rest
Pro costs 15 EUR a month and opens 45 Pro tools.
Related tools
Ray optics simulationRay optics simulation: a ray diagram generator for lenses and mirrors, Snell's law with the critical angle, and a prism. Free, 3 times a day without an account.
Vibrations and WavesPendulum period calculator with the exact period up to 170°, plus damped springs, resonance, interference, standing waves and the Doppler effect. Free online.
Wall U-value calculatorWall U-value calculator with dew point, Glaser condensation, thermal bridge, part cooling, fins and radiation. Free, 3 times a day without an account.
Physics Constants & Formula SolverPhysics constants and formulas in one place: 17 constants from SI 2019 and CODATA 2022, plus 17 formulas to solve for any unknown, with unit conversion.
Pick charges and see the field
Opens without an account 3 times a day. A free account removes the limit.