Physics Library / Electrostatics

Coulomb's Law Lab

Stationary point charges in vacuum · SI units

Forces on held charges

+ source− sourceNet forcePair contributionProbe P

Net force on q₁
Fₓ / Fᵧ (mN)
External |E| at selected charge

Superposition on the selected charge

Sourceqⱼ (μC)Distance (m)Fₓ (mN)Fᵧ (mN)|F| (mN)

The inverse-square relationship

Two charges only · charge values held fixed in this sweep

|F| = k |q₁q₂| / r²

Current separation
Current pair force
At twice this distance
At half this distance

The gold point marks the present pair. The vertical axis is logarithmic; doubling r gives one quarter of the force. Hypothetical half/double values do not require moving the markers beyond the view.

A field exists before a test charge is added

Probe P is not one of the source charges
|E(P)|
Eₓ / Eᵧ (N/C)
|qtestE(P)|

Reading the forces and the field

Magnitude and direction are separate

Coulomb's law gives the magnitude k|q₁q₂|/r². The signs determine direction: like charges repel and opposite charges attract. The force on charge i from charge j is k qᵢqⱼ(rᵢ − rⱼ)/|rᵢ − rⱼ|³. With this displacement convention, a positive product points away from the other source and a negative product points toward it.

Every interacting pair exerts equal and opposite forces, even when the charge magnitudes differ. With three or more charges, each object's net force is a vector sum of several such contributions; two different net forces need not be opposite. External supports hold all source positions fixed in this lab.

Distance matters twice

The magnitude is proportional to the product of the charge magnitudes and inversely proportional to separation squared. Doubling one charge doubles a pair force. Doubling both multiplies it by four. Doubling the distance divides it by four; halving the distance multiplies it by four.

The spatial view uses equal meter scales on both axes. Force arrows share a common linear scale within each configuration, with a scale bar; that common scale adapts to keep arrows in view. Therefore use the numerical force readout or the fixed-charge separation sweep when comparing magnitudes between different configurations. Field-grid arrows show direction only.

The electric field is a property of the sources

The field at a point P is E(P) = k Σ qⱼ(P − rⱼ)/|P − rⱼ|³. It points in the direction of force on a positive test charge. A negative test charge feels the opposite direction, while a zero test charge feels no force even if the field there is nonzero. The virtual test charge does not modify the source configuration.

At an actual source position, the external field used in Fᵢ = qᵢEothers(rᵢ) excludes that source's own field. A charge is not assigned a self-force. The selected-force table omits the selected source; the probe-field table includes all sources.

Lines trace field direction, not particle motion

The tangent to a field line follows E. Lines point away from positive sources and toward negative sources, and may enter or leave the displayed region. They are not trajectories of moving charges. An isolated source has a radial pattern; opposite signs form a dipole pattern; like signs can give a zero-field point between them.

These curves are a two-dimensional slice of a three-dimensional point-charge field. Their seeds are illustrative: do not infer a calibrated field magnitude from the number or density of lines in this drawing. Use the probe or the fixed logarithmic shading scale instead. The field is not defined at a nonzero point source, and its direction is not defined at a field null.

Superposition makes larger configurations understandable

Each source contributes its own field vector, and these vectors add. In force mode, the dashed contributions on the selected charge add to its gold net force. In field mode, the table decomposes the field at P. A zero result may reflect cancellation, not absence of individual interactions.

The three-charge balance preset has a vanishing net force on its middle charge, despite nonzero pair forces. The quadrupole preset alternates signs around a square. Changing charge count preserves existing charges and adds separated markers; each marker's charge and position remain individually editable.

What the model does and does not include

Positions are meters and input charges are microcoulombs: 1 μC = 10⁻⁶ C. Calculations and exports use SI units. The vacuum constant is k = 1/(4πε₀), using ε₀ = 8.8541878188 × 10⁻¹² F/m from the 2022 CODATA values. This is not an exact defined constant or an uncertainty analysis.

The model assumes prescribed, stationary point charges in vacuum. It does not simulate conductors, induction, finite charged spheres, magnetic fields, radiation or mechanical acceleration. A 0.30 m center-separation limit prevents coincident input sources. Small 0.12 m exclusion disks terminate field drawings and suppress probe displays very near sources; no softening is applied to Coulomb's law outside those display exclusions.

Field-line integration uses the established ODEX solver for the normalized direction dr/ds = E/|E|, with arclength s rather than physical time. Lines are truncated near sources, nulls, the view boundary or an integration limit. During dragging, live field arrows replace curves; curves are recomputed after movement settles. No browser animation of charge motion or production-side computation is involved.