MAGNETIC FIELD DUE TO A CIRCULAR CURRENT Thesis for ”'12 Degree OI M. S. MICHIGAN STATE UNIVERSITY Bartin T. Smith 3.960 mmmmmInwnuummu ' 3 1293 01764 0073 L I B R A R Y Michigan State University \CEINHET’IRN 8000* 4-H» hutfron y-u ' "OID Fl" ' manor MAGNETIC FIELD DUE TO A CIRCULAR CURRENT By Bartin T. Smith AN ABSTRACT Submitted to the College of Science and Arts of Michigan State University of Agriculture and Applied Science in partial fulfillment of the requirements for the degree of MASTER OF SCIENCE Department of Physics and Astronomy 1960 %/m j MW; fl Bartin T. Smith ABSTRACT Mathematical expressions for the magnitude of the magnetic field due to a circular current are derived. The difficulty of evaluating elliptic integrals of modulus near 1 is obviated by successive applications of Landen's Transformation, resulting in expressions readily calculable on computers. The expressions for complete elliptic integrals of the first and second kinds are programmed, with explanations of order pairs. Directions for change of parameters are included. Programs for the magnitudes of the components of the magnetic field parallel and perpendicular to the axis are presented, with explanations as to scaling and use as a subroutine. MAGNETIC FIELD DUE TO A CIRCULAR CURRENT BY Bartin T. Smith A THESIS Submitted to the College of Science and Arts of Michigan State University of Agriculture and Applied Science in partial fulfillment of the requirements for the degree of MASTER OF SCIENCE Department of Physics and Astronomy 1960 The work on this thesis was partially supported by the Atomic Energy Commission under Contract AT(11-l) - 872 ii ACKNOWLEDGMENTS I wish to express my appreciation to Dr. H. G. Blosser for suggesting the problem and for his ready assistance and advice. I would also like to thank Dr. M. M. Gordon for making available his knowledge of computer programming through his many helpful suggestions. II. III. IV. TABLE OF CONTENTS INTRODUCTION DERIVATION OF MAGNETIC FIELD MAGNITUDES TRANSFORMATION OF ELLIPTIC INTEGRALS . PROGRAMS A. Subroutine for K, E . B. Routine for BP . . . . C. Routine for B Z iii 18 18 22 26 I. INTRODUCTION In many physical experiments it is desirable to know the magnitude at any location of a magnetic field due to a circular current. Though the mathematical expressions for the magnitudes are well known, the numerical difficulties involved in the evaluation of these expressions in any given case may be quite large. It is the purpose of this thesis to consider such a case, and to show whereby the numerical difficulties may be alleviated. The mathe- matical operations necessary are readily adaptable to computer pro- gramming, and use has been made of the Michigan State University digital computer, Mistic. The need for the ready calculation of magnetic fields due to circular currents arose in connection with the problem of current control in the trimming coils of the proposed Michigan State University cyclotron. II. DERIVATION OF MAGNETIC FIELD MAGNITUDES N Fig. 1 We wish first to write an expression for the vector potential at any point P not on a coil of radius L. Noting that there is no loss of generality if we let P be in the x-z plane, we may write for the distance of P from any line element ds (see fig. 1): 1/ 2 2 ‘ 2 2 2 2 r: L +P -2LPcose+z = «(IO-Loos 9) +(Lsin9) +z Using the expression for r, the vector potential is then: ds r A :Eif _ 4n CW/(IO - L cos 9)2+(L sin9)2 + z2 When we consider opposing elements on opposite sides of the x axis, we see that there is no contribution from x components of the current, since the resultant current (21 cos 9) is perpendicular to the/0 - 2 plane. Consequently, A]O = A = 0. So since ds = adcp, 1T A :PoI LcosGdG o (P-LcosG)2+(Lsin9)2+z 9 211' 2 2 In the manner of Smythe (5), let 9 : 1T + 24>, so cos 9 = 2 sin cp-l, and d9 = qu) so we have 1r /— 2 A z’JoLI 2 (2 sin (buds 9 11 2 .1. {(L+)O)Z+zz} 1— 41")“; (I); 2 o (Li-P) +2 I 2 Defining k E 4L; 2 , and substituting, we get (L +p) + z i g 1 Ik Z , 2 2 A _po (L) 2 81H (19qu _ dL [1] 9‘ 211’ p 2 2 1/2 2 2 .1/2 Examining the first integral, we note that 2 i 511143 1; £2 1 .. [1-k sin ¢] _ k '— 2 2 2 2 2 [l-k sin .¢]2 [1-k sin ¢l so that 1 1 1 m ¢ ¢ ; _ 2 - — [l-k sin ¢] dqa =—(K-E) 1 2 1 2 2 _ k — k k 0 0 Z O [l-k sinch]2 [l-kzsinch]Z where K and E are complete elliptic integrals of the first and second kinds, respectively. 4 The second integral of equation 1 is K, giving us a final expression for the vector potential: 1 pl 2. 2 o L k Ae'nkIfi) 1'7K'E The magnetic induction vector may be calculated from B = VXA. Since there is no component of A in either the Z or/O direction, this becomes B : -éaAe +3 3(pAe) — az )0 W— aAe 1 8(PA9) orB 2- 82 “1desz [2] Rewrite A G in the form: 1 )1 I E A9: 0 [(L+/O)2+z] 1- 2142/9 K-E )0 [(L+)O) +z ] .1 3A p I 2 \ Tie—‘2; z[(L+p)2+zz] 1-[ :5 2]) K-E (L )+2 1 F01 L 2]E 1 ZLP \BK§_15_+K 4apz [@513 J'Efi [I +10) +2 -[(L+/O) +2 1} 8k 62 ' —-_ .1. .1. 5 L 2 5k 2(L )‘2 Also, since k = 2 ’0 , we have —- = - [O z (L+p)2+z 57‘ 2 2 3 -- ‘ [(L+p) +2 ]2 and £21: _ _k_ 1.5: .15 :30 " 2p 4p ' 4L Substituting these expressions in Eq. [2] and simplifying, we obtain: }1 Iz 13/0: 0 -K 2 2 2 L 1 + +p +2 E [3] (L-P)2+ z2 2 2 2 2P1T[(L+P) + z ] For the z component, it can be shown similarly that )11 2 2 2 Bz= O 1 K+L P2 22E [4] 3:- (L-P)+z III. TRANSFORMATION OF ELLIPTIC INTEGRALS Using the preceding formulae for BP and Bz, one may calculate the modulus k and refer to tables for the corresponding K and E. However, since in a practical problem, k is not likely to be an even number with its complete elliptic integrals listed, it is necessary to interpolate between known values or to calculate them directly. With the availability of automatic calculating machinery, this latter course is preferable since it provides greater accuracy with a negligible sacrifice of speed. In the regions where k is small, that is, whenf) is not near L or when z is large, the power series representation would be adequate, since its repetitive form lends itself well to computer calculation. When k is large, however, a situation that occurs at points near the coil, the series representation converges very slowly. The power series is obtained by expanding the radical in a binomial series: NI=I NI: {' d4) ,= Z . ————+—— = dcp 14-1-<—sin2q>+-}—%k4sin4¢+. . . .1] 2 , 2 2 2'4 0 l-k Sln q) - K Hg 1 3 . . . (Zn-1) 2n _ 2n +. 2-4. . . (2n) 1‘ 5m ‘1’ + NI=I . (Zn-l) _1_r_ (Zn) 2 2 1- 3 . Since by Wallis' Theorem: sin nedcp + 2- 4 O . we have: 2 2 1 2 . b-ttg) k +(l—3) k4+... + 1T K-‘z' 1° 3' 5. . .(Zn-l)‘ 2 2n+ 2.4 2°4'6...(2n) k . . . . . . th . As an illustration of 121115, con51der the coeff1c1ent of the n— term in the series for K: 2 2 '1 3-5 ...(Zn-1I _ (2n)! 2 4 6... (2n) " 22n(n')2 . . . . . - ‘— n -n Usmg Stirling's approx1mation, n! : ‘_/21Tnn e , we may show that this fraction may be written l/nTr. It can be seen that if this is . . 2n . ' . . the coeff1c1ent of k , the result 15 a very slowly converging series when k is nearly 1. That k can never be greater than 1 is true by definition. The modulus k is equal to the numerical eccentricity of an ellipse. For example, in calculating the arc length of an ellipse, the situation from which, according to Hancock (4), the "elliptic integral" derives its 2 2 name, we have: ifE-z- +y-2- = 1 where a and b are the major and minor a b axes respectively, x X a2 a2- b2 2 — 2 I X ’d 2 a : - 1 ‘1) Z —. s O / -+[dx dx 2 2 dx o a - x a2 b2 b2 Upon introducing the numerical eccentricity e = —;—2—— = 1 - -—7:, a a we have, with x = a sinq>, {4) S = aJ W/l - ezsinch do 0 which, it can be seen, is an elliptic integral of the second kind. 2 Since 1 - —2- can never be greater than 1, the series will converge, a b . however slowly. The quotient g- is called the complementary modulus k‘, and setting e = k, we have k2 + k'2 = l. A method of changing a slowly convergent elliptic integral into a highly convergent one is the method of Landen's transformation. Writing now F(k, (p) for the incomplete elliptic integral of the first kind, we wish to find a F(kl’ cpl) such that it will be more rapidly convergent than F(k, (1:) and can be related to it by F(k, W = C F(kl' cpl), where C is a constant of proportionality to be determined. 2 2 Instead of using the radical-\[l -k sin ¢, substitute for the 2 . . 2 2 2 modulus k the eccentr1c1ty (a - b )/a , where, as before, a > b. This give 5: 2 2 1 2 2 2 2 “/l-ksin ¢=;_\/a cos ¢+b sin¢ and now: F(k, <13) 2 aF(a, b, (p) and E(k, (p) = ’a-1 E(a, b, (1)) With this notation, we shall consider a geometrical derivation of Landen's transformation as given by Cayley (1). On a circle of radius AOB, let P be any point, and Q be any point on the diameter other than the center, as in fig. 2. Considering a, b, and c1 as noted in the figure, we may write 1 . . a1 = % (a+b), b1 = \/ab, and c1 = E (a - b) where a1 is the radius, 1 andOQ—al-b---2-(a-b)—c1 Fig. 2 We see that QP sinq>1= a1 sin Zcp and QP cos cpl = c1+ a1 cos 24>. Upon substituting the preceding expressions for a1 and c , we 1 2 2 2 2 2 obtain: OP = a cos 4) + b sin 4) so that a sianp c +a cos 24> . l l l Sincpl = , cos (pl [5] _\/ 2 2 2 , 2 V 2 2 2 , a cos
+b We may write: sin(2q>-¢1)= sin 24>cos ¢1_ c0524) sin 4,1 : (a-b) sin a) ZV—z 2 2_2 acos¢+bsm¢ and cos(2q'>-¢1)= cos 24> cos (121+ sin2
+b Sincp a1 cos ¢1+b151n cpl
Upon integrating we have
(I)
d
If d<1> = 1 4’1
2 Z 2 2, 2 Z 2 2.2
acos¢+bsm¢ acos¢+b Sinq>
0 o l l l l
01'
l
F(a, b, (p) = EF(a1, b1, cpl)
Mk. 4» = ama. b. s) =§F