Solenoid & Toroid Magnetic Field Calculator
Calculate magnetic field strength inside a solenoid or toroid from current and geometry.
Magnetic Fields Inside Solenoids and Toroids
A long solenoid creates an approximately uniform magnetic field inside because the fields from many closely spaced current loops reinforce one another. For an ideal air-core solenoid, B=μ0nI. The turns-per-length value n matters because packing more turns into each meter increases the number of loop contributions at every interior point.
A toroid bends a solenoid into a closed ring. Its magnetic field is concentrated around the circular core and varies with radius as B=μ0NI/(2πr) for the ideal air-core case. Here N is the total number of turns, not turns per meter. Confusing N and n is a common source of incorrect answers.
| Symbol | Meaning | Why it appears / units |
|---|---|---|
| B | Magnetic flux density | Tesla (T). |
| μ0 | Permeability of free space | Approximately 4π×10−7 T·m/A. |
| n | Solenoid turns per unit length | m−1; n=N/L. |
| N | Total toroid turns | Dimensionless turn count. |
| I, r | Current and toroid radius | A and m; toroid field decreases as r increases. |
These formulas assume idealized geometry. A finite solenoid has edge effects near its ends, and magnetic cores change the field through their permeability. In many basic problems the air-core approximation is intended. Always identify whether the given turn quantity is total turns or turns per meter before choosing the formula.
Worked Examples
Common Mistakes
For a solenoid, first calculate n=N/L when only total turns and coil length are given.
The ideal toroid field varies as 1/r, so the radius at which B is evaluated is part of the calculation.
The air-core formulas use μ0. If relative permeability μr is provided, the ideal material result includes the factor μr.
Frequently Asked Questions
Formula Explorer connections
Interpretation: This relationship connects magnetic fields, moving charge, flux, induction or electromagnetic material response. Assumption: Specify field direction and sign convention. Uniform fields, linear materials, negligible edge effects or sinusoidal steady state may be assumed.