Helmholtz coil
A Helmholtz coil is a device for producing a region of nearly uniform magnetic field, named after the German physicist Hermann von Helmholtz. It consists of two electromagnets on the same axis. Besides creating magnetic fields, Helmholtz coils are also used in scientific apparatus to cancel external magnetic fields, such as the Earth's magnetic field. Description. A Helmholtz pair consists of two identical circular magnetic coils that are placed symmetrically along a common axis, one on each side of the experimental area, and separated by a distance formula_1 equal to the radius formula_2 of the coil. Each  coil carries an equal electric current in the same direction. Setting formula_3, which is what defines a Helmholtz pair, minimizes the nonuniformity of the field at the center of the coils, in the sense of setting formula_4 (meaning that the first nonzero derivative is formula_5 as explained below), but leaves about 7% variation in field strength between the center and the planes of the coils. A slightly larger value of formula_1 reduces the difference in field between the center and the planes of the coils, at the expense of worsening the field's uniformity in the region near the center , as measured by formula_7. In some applications, a Helmholtz coil is used to cancel out the Earth's magnetic field, producing a region with a magnetic field intensity much closer to zero. Mathematics. The calculation of the exact magnetic field at any point in space is mathematically complex and involves the study of Bessel functions. Things are simpler along the axis of the coil-pair, and it is convenient to think about the Taylor series expansion of the field strength as a function of formula_8, the distance from the central point of the coil-pair along the axis. By symmetry , the odd-order terms in the expansion are zero. By arranging the coils so that the origin formula_9 is an inflection point for the field strength due to each coil separately, one can guarantee that the order formula_10 term is also zero, and hence the leading non-constant term is of order formula_11. The inflection point for a simple coil is located along the coil axis at a distance formula_12 from its centre. Thus the locations for the two coils are formula_13. The calculation detailed below gives the exact value of the magnetic field at the center point. If the  radius is "R", the number of turns in each coil is "n" and the current through the coils is "I", then the magnetic field B at the midpoint between the coils will be given by where formula_15 is the permeability of free space . Derivation. Start with the formula for the on-axis field due to a single wire loop which is itself derived from the Biot–Savart law: Here The Helmholtz coils consists of "n" turns of wire, so the equivalent current in a one-turn coil is "n" times the current "I" in the "n"-turn coil. Substituting "nI" for  I in the above formula gives the field for an "n"-turn coil: In a Helmholtz coil, a point halfway between the two loops has an "x" value equal to R/2, so calculate the field strength at that point: There are also two coils instead of one (the coil above is at "x"=0; there is a second coil at "x"="R"). From symmetry, the field strength at the midpoint will be twice the single coil value: Time-varying magnetic field. Most Helmholtz coils use DC (direct) current to produce a static magnetic field. Many applications and experiments require a time-varying magnetic  field. These applications include magnetic field susceptibility tests, scientific experiments, and biomedical studies (the interaction between magnetic field and living tissue). The required magnetic fields are usually either pulse or continuous sinewave. The magnetic field frequency range can be anywhere from near DC (0 Hz) to many kilohertz or even megahertz (MHz). An AC Helmholtz coil driver is needed to generate the required time-varying magnetic field. The waveform amplifier driver must be able to output high AC current to produce the magnetic field. Driver voltage and current. Use the above equation in the mathematics section to calculate the coil  current for a desired magnetic field, . formula_25 where formula_15 is the permeability of free space or formula_18 formula_19 = coil current, in amperes, formula_20 = coil radius, in meters, n = number of turns in each coil. Then calculate the required Helmholtz coil driver amplifier voltage: where High-frequency series resonant. Generating a static magnetic field is relatively easy; the strength of the field is proportional to the current. Generating a high-frequency magnetic field is more challenging. The coils are inductors, and their impedance increases proportionally with frequency. To provide the same field intensity at twice the frequency requires  twice the voltage across the coil. Instead of directly driving the coil with a high voltage, a series resonant circuit may be used to provide the high voltage. A series capacitor is added in series with the coils. The capacitance is chosen to resonate the coil at the desired frequency. Only the coils parasitic resistance remains. This method only works at frequencies close to the resonant frequency; to generate the field at other frequencies requires different capacitors. The Helmholtz coil resonant frequency, formula_31, and capacitor value, C, are given below. Maxwell coils. To improve the uniformity of the field in  the space inside the coils, additional coils can be added around the outside. James Clerk Maxwell showed in 1873 that a third larger-diameter coil located midway between the two Helmholtz coils with the coil distance increased from coil radius formula_2 to formula_35 can reduce the variance of the field on the axis to zero up to the sixth derivative of position. This is sometimes called a Maxwell coil.