TRIUMF: Canada's national laboratory for particle and nuclear physics

A computer program for beam transport calculations Tautz, Maurice Francis Mar 31, 1968

Your browser doesn't seem to have a PDF viewer, please download the PDF to view this item.

Item Metadata

Download

Media
51833-TRI-1968-05.pdf [ 59.3MB ]
Metadata
JSON: 51833-1.0314569.json
JSON-LD: 51833-1.0314569-ld.json
RDF/XML (Pretty): 51833-1.0314569-rdf.xml
RDF/JSON: 51833-1.0314569-rdf.json
Turtle: 51833-1.0314569-turtle.txt
N-Triples: 51833-1.0314569-rdf-ntriples.txt
Original Record: 51833-1.0314569-source.json
Full Text
51833-1.0314569-fulltext.txt
Citation
51833-1.0314569.ris

Full Text

TRI· UHIVERSITY ME SOH FACILITY TRIUM F UNIVERSITY OF ALBERTA SIMON FRASER UNIVERSITY \ UNIVERSITY OF VICTORIA ."'I UNIVERSITY OF BRITISH COLUMBIA A COMPUTER PROGRAM FOR BEAM TRANSPORT CALCULATIONS by MAURICE F. TAUTZ University of Victoria Physics Department TRJ-5-B-5 A COMPUTER PROGRAM FOR BEAM TRANSPORT CALCULATIONS by MAURICE FRANCIS TAUTZ B.Sc., University of Victor~a , 1964 A THESIS SUBMITTED IN PARTIAL FULFILLMENT OF THE REQUIREMENTS FOR THE DEGREE OF MASTER OF SCIENCE in the Department of Physics We accept this thesis as conforming t o the required standard Accepted by, the F~ulty ,of G?adua~n Studies on 1#.'13, IfiJ by 7'1 , -./1 Jb~'1j!~ean of Facul t y v © MAURICE FRANCIS TAUTZ, 1968 UNIVERSITY OF VICTORIA March 1968 Page 8 Fig . 1 Page 26 Line 27 Page 34 Line 3 Page 36 Line 20 Page 37 Line 1 Page 38 Li ne 15 Page 39 Line 5 Page 43 Line 16 Page 49 Line 10 Page 54 Eq. III-1 0 Page <;4 Eq. III- 12 Page 54 Line 15,1b ERRATA Upper left and lower right hand poles should be labelled north and the other two, south . Read 01 Equations 1- 4 , 1-5 01 . Read 01 (from equation (2 . 1 . 2) with - > B 0) 01 . r a au 1 a2f Read 01 U ar (r ar) + f a4>2 = 0 01 r a (au 1 a2f m2 01 Read 01 U ar r ar) f a4>2 = ~ Read 01 <I> = 2 s in 24> gr sin 4> r co s If! = gxy ". De l ete It from II. Read II X l X ' 0 + f, x' 0 = x' 0 - xo/f 01 x' t hen .12...= x' 01 0 r 0 Read II x' 0 Read II Fy = - ev Hz s i n ~1 01 Read " f,fiy - e s i n ~1 { Hzvdt B = - e s i n ~1 t Hzds " B Read "For the stati c , current free region that we are considering , Maxwell's equa tion i s II Errata - Page 2 . - ) - ) Page 54 Eq. III-13 Read II dA for " dS Page 55 Eq. III-15 Read II t H dy = - Yo H II. e Page 55 Line 19 Read II IB Hz cos ~1 dS + Yo H a " e Page 55 Eq. III-16 Read II IB Hz dS = - Yo H e cos 11 1 Page 55 Line 22 Delete this line. Page 56 y and Yo can be interchanged in the equations up to III-17 , since they are equal i n our approximacion . Page 56 Line 10 Read II yl = y~ +l1Y~ = Y~ - Yo .tlJ,QJU. r 0 Page 57 Line 13 Read II equations exist ll • Page 61 Line 4 Read II ~ tan r1 tan ~2 " Page 62 Line 9 Read "Fig . 4(A) " . Page 62 Line 12 Read II Fig. 4". Page 64 Line 6 Read "Fig. 4(B) " . Page 79 Line 11 Read " (for positively charged particles) ". Page 80 In table read II Z II for " W" Page 80 In table read II zit for II WIl • Page 83 Line 16 Delete llmagnet its" . Errata - Page 3 . Page 88 Line 9 Read II Page 89 Line 4 Read uri-7 ft for 1111-7" . Page 115 Line 21 Read "Po = 33 . 866 em/(rad . /100)". Page 115 Line 22 Read" .01 493 em. f~g " Page 116 Line 26 Read "coefficients tl • ii . ABSTRACT A computer program TRIUMF f or the solution of b.eam t r ans port problems is described. This program tracks, t o firs t order, particle trajectories and phase space e l lipses through any combi nation of up to 30 drift spaces, quadrupole magnets, and constant field bending magnets with r o tated pole faces. Particle trajectories or the beam envelope may be pl otted f or points eve r y 20 cm. along the optic axis . The phas e space ellipse at the exit of any beam element may also be pl o tted. The program does trajectory ma tching and ellipse matching to a waist or to a specified ellipse . I t will also attempt t o c r eate an ' identity system ' . The matching r outines are based on a method fo r finding the minimum of a funct i on of N variables without calculating fi r st derivatives due to Powell. The program has been written in Fortran II and wi ll run without modification on the I BM/360 digital computer. Chapter 1 Chapter 2 Chapter 3 References Appendix I Appendix II Appendix II I Appendix IV iii. TABLE OF CONTENTS Introduction Basic Beam Transport Concepts 2 . 1 Matrix Representation of Beam Handling Elements 2.2 Types of Beam Handling Elements 2 . 3 Phase Space Representation of a Particle Beam Description of TRIUMF Tracking and Matching Program 3 ·1 3·2 3·3 3 . 4 3·5 Tracking Facilities Matching Routines Method of Matching General Description of Program Conclusion Drift Space Matrix Components Quadrupole Magnet Matrix Components Constant Field Bending Magnet Matrix Components Liouville's Theorem and Phase Space Ellipse Calcula tions Appendix V Appendix VI Appendix VII Appendix VIII Input and Output Conventions Units Program Lis ting Sample Problem iv . LIST OF FIGURES ~ Figure 1 The Quadrupole Magnet 8 2 The Ideal Quadrupole Magnet 8 3 The Hard Edge Quadrupole Model 9 4 Plan View of a Bending Magnet 12 5 Phase Space Ellipses 17 6 The Thin Lens 44 7 Construction for the Calculation 50 of the Effec ts of Pole Edge Rotation on the Radial Trajectories 8 Fringing Field at the Edge of 53 a Bending Magnet (A) Side View (B) Plan View v. ACKNOWLEDGEMENTS The author wishes to express his appreciation to Dr . R. M. Pearce and Dr. L. P. Robertson for their guidance during the progress of the work and to Dr. D. E. Lobb, Dr. R. Odeh and Dr . J. L. Climenhaga for reading the rough draft of this thesis. The author also wishes to thank Mr. R. J . Louis for the many helpful discussions regarding beam transport theory . The computer program was run at the Computer Center, University of Victoria, and the author wishes to express his thanks to Mr. C. Bradley and Mr . D. Earl for their assistance during the running of the program . The author wishes to thank Miss J . Neargarth for the careful typing of the final manuscript. 1 . INTRODUCT ION The high energy particle beams extracted from large accelerators must be transported over long distances to the experimental areas . I n order to keep the lateral dimensions of the beam from growing it is necessary to have some system whi ch will focus the particles in the horizontal and ve r t ical directions perpendicular to the direction of travel of the beam . I t was shown in 1952 by Courant et al that particles can be effectively focussed in both transverse directions by using quadrupole magnets . Since then it has become a standard technique to use combinations of quadrupole magnets (doublets, triplets, etc . ) for controlling high energy beams. If the beam is required to be deflected as well as contai ned, then bending magnets are used . These magnets produce a uniform vertical field which bends the beam, enabling one to guide it to the appropriate experimental area . I n addition such magnets can focus or defocus particles in the two transverse directions depending on the field configuration at the entrance and exit pole faces . Bending magnets also produce di spersion of the beam, i.e. particles with the same initial conditions except for different initial momenta will have different trajectories through the magnet. This dispersion can be used to obtain 2. a better momentum resolution of the beam. If it is assumed that magnet construction problems have been solved and that uniform fields and quadrupole fields are available then a matrix formalism developed (to first order) by Penner in 1961 can be used to calculate the effect of these magnets on charged particles. The calculations performed by the TRIUMF program are based on Penner's method . Good introductions into the subject of beam transport are given by King (1964), Livingood (1961), Livingston and Blewett (1962) and Banford (1966) . The notation used in this thesis and the two basic problems in beam transport theory are introduced below. For any given beam transport system it i s assumed that there is a central trajectory, the opt ic axis, which is the path followed by a particle with zero initial displacement and s l ope,and momentum p . The displacements and slopes of other trajectories are referred to it . The distance along the optic axis is called z . Relative displacements in the horizontal plane are denoted by x and in the vertical plane by y. If for a given system the trajectory equations (x = x (z), y = y (z)) are known for any particle in the beam then one has essentially accomplished what is known as 'tracking'. The trajectory equations are found by solving the equations of motion for the particle in each beam handling element (drift space, quadrupole magnet, constant 3· field bending magnet) and then computing the cumulative effect on the particle for any point z along the optic axis . The sl opes of the trajectory equations, dx ~ and ~ , are denoted by x' and y ' respectively. A more difficult problem in beam transport theory i s ' matching '. Here,starting from a guessed initial system one varies designated element parameters until the beam at the exit of the system is closest to having certain desired properties . The initial system is determ~ by intuition, experience or from approximate calculations using ' thi n ' lenses in place of quadrupole magnets . The chief diff i cul ty in matching is that the action of the system on the beam is different i n the two transverse di rections and thus the solving of a matching problem usually entails simultaneous solution of two or more non-linear equations . The rest of the material in this thesis describes the TRIUMF digital computer program and how it is used to solve tracking and matching problems. Chapter 2 outlines the basic concepts and standard techniques used in beam transport theory which are needed to understand the content of the TRIUMF program. In section 2 . 1 the usefulness of matrices for beam transport calculations is shown . Section 2.2 describes the types of elements used in the program and section 2 . 3 discusses the mathematical analysis of particle beams. Chapter 3 describes the TRIUMF program. Sections 3 .1 and 3 . 2 give an outline of the facilities which have been incorporated into the program. In section 3.3 is 4-. a brief discussion of the method used to solve the matching problem and section 3 . 4- contains a description of the functions performed by the main program and by the various subroutines . Section 3.5 briefly compares the TRIUMF program with existing programs and suggests some possible improvements which could be made. Appendices I to IV supply the mathematical background for a better understanding of Chapter 2. In Appendices V to VII the information needed to successfully use the TRIUMF program is given. A sample problem is solved in Appendix VIII. From this problem it is seen that with the speed of the 360 computer even a fairly long job should take less than 10 minutes for compilation and execution . 5. 2 . BASI C BEAM TRANSPORT CONC EPTS 2 . 1 Matrix Representation of Beam Handl ing Elements I t has been shown by Penner (1961) that the acti on of a beam transport system on a charged particl e can be convenientl y descri bed by a matrix formal ism . Each particle defl ecting el ement in the system can be represented by two transfer matrices, one for the horizontal plane and one for the vertical plane . ' The transfer matrices for an entire system are computed by multiplying together the i ndividual element matrices. The initial par t i cl e displ acement, sl ope, and momentum deviation (all with respect to the central trajectory) can be taken as the components of a column vector. Multiplying this column vector whos e components are the input conditions by the transfer matrix gives a vector whose components are the out-pu t condit i ons. The transfer matrices are 3 x 3 and the passage of a particle through a system of elements is descri bed in the horizontal plane by 'This is only possible if the equations for the two transverse planes are independent as for the elements used in the TRIUMF program. In general treatment an element is represented by a matrix (Moore et aI, 1963). ( 2 .1.1) of motion is the case a more single 6 x 6 where Xo is the initial displacement, x the final displacement, x'o the initial slope and x ' is the final slope . dp = Po - p is the deviation of the 6. particle momentum Po from p where p is the momentum of a particle travelling down the central trajectory . A simil ar matrix equation holds in the vertical plane . To find the transfer matrix components for any given system el ement one has to integrate the equations of motion, d(mv» dt - > -> ev x B (2 . 1. 2) for a particle in the magnetic field of that element. The equations of motion for the displacements are made linear by neglecting second and higher order te rms in the displace-ment and s l ope . The matrix components are readily obtained and are gi ven in Appendix I, II, and III for a drift space, quadrupole magnet, and bending magnet respectively. 7. 2 . 2 Types of Beam Handling Elements The types of magnetic particle-deflecting elements used in the TRIUMF program are described below. 2 . 2 .1 Drift space: This is the space between magnets and is considered to be a region of zero magnetic field. It is specified by one parameter, the length L along the centr al trajectory of the field free region. 2 .2.2 Quadrupole magnet: A quadrupole lens consists of four iron pole pieces mounted on a common yoke and excited by current carrying coils arranged in the configuration shown in Fig. 1. The field can be approximately represented by B> grad ~ where ~ is a magnetostatic potential given by ~ = g (z) xy (Yagi, 1964). For g (z) = g, a constant, this is the fie l d produced by the magnet shown in Fig. 2 where the poles are rectangular hyperbolae of infinite permeability and the magnet is infinitely long in the z-direction. The field of this theoretical quadrupole magnet is then given by Bx a ax (gxy) gy By a (gxy) gx ay Bz ...Q.. (gxy) 0 az where aB aB x g -1l ay ax is the magnetic field gradient . ( 2 . 2 .1) 8. Fig. 1 . The Quadrupole Magnet 1!..E.f>R.€:.Sf.NT ,He. !,- oRCe.5 Ac:TING-ON A foS\"T\\j~ \ON \Rf\\J~LUN6-OUT (}>;: i"'€:. \> p..G-~ . Fig. 2 . The Ideal Quadrupole Magnet 9. For real quadrupoles the measured field gradient g (z) varies with z approximately as shown in Fig. 3 . The simple potential equation ~ = gxy can be retained if g (z) is replaced by the step function indicated by the dashed line in Fig. 3 . This is called the hard edge model (Blackstein, 1967). hard edge - - - - -actual Fig. 3. The Hard Edge Quadrupole Model. To replace the actual field by a fictitious hard edge model field the length L must be defined so that the magnet has approximately the same focussing action as does the real field. To first order accuracy L can be defined by -tOO L J g(z) dz -"X; g 10. where g (z) i s the measured field gradient and g is the value of the gradient well within the magnet (Banford, 1961). The force exerted on a particle carrYing charge e and which is travelling parallel to the z-axis with velocity z = v is given by the Lorentz force equation as or fx e(yBz - ZBy) -ev By -ev gx and (2.2.2) fy e(zBx - ~.) ev B x ev gy From this we see that for such particles the action of the field is focussing in the x-direction and defocus sing in the y-direction, i.e . the force in the x-direction is directed towards the optic axis, the force in the y- direction away from it. In Fig . 2 these forces are shown for a positive ion travelling out of the paper at points A and A' . If the magnet is rotated by 900 the north and south poles are exchanged and g becomes negative. The result is that the field now focusses in the y-direction and defocusses in the x-direction. A system of quadrupole magnets which is focussing in both directions can be obtained by alternating quadrupoles with positive and negative g-values (Courant et aI, 1952). 11. 2 . 2 . 3 Bending magnet (constant field): As in the case of quadrupoles a hard edge model can be used to represent a bending magnet. The field is taken as zero outside the pole faces and constant within. The approximate effective length L of the bending magnet can be defined +00 J By (z) dz L B where By (z) is the measured field, B is the field well within the magnet and the integral is taken over the curved central trajectory through the magnet. Bending magnets deflect the central trajectory i n the horizontal plane. Magnets which bend beams of positively charged particles to the right have a positive field. If the magnet bends such a beam to the left the field is negati ve . Fig. 4(A) shows the plan view of a positive field bending magnet. The pole faces are not necessarily normal to the central trajectory but may be at an entrance angle ~l or an exit angle 1l2. In both transverse . planes these rotated pole faces have a focussing or defocus sing effect on particles as explained in Appendix III. The parameters which specify a hard edge model constant field bending magnet are the effective length L , the field strength B, the entrance angle ~l, the exit angle ~2 and the angle of bend ¢ of the central trajectory. Only four of these 12 . (A) Angle of Bend to Right B , I (B) &~gle of Bend to Left ~M"-' ./' -----~\..-Fig . 4 . Plan View of a Bending Magnet are independent as L = ro ~ where ro = ro (p , B) as is shown in Appendix III . The sign conventions for ~ , ~l , and ~2 are explained in Appendix III. 13 · 14. 2.3 Phase Space Representation of a Particle Beam Particles emerging from accelerators have a range of displacements and slopes such that it is impossible to bring all the particl es to the optic axis or to have them all travell ing parallel to the optic axis at one time . In order to treat such beams mathematically the concept of phase space is often used. As discussed by Banford (1961) the motion of each particle in time can be represented by the motion of a point in a six dimensional phase space with co- ordinates (x, y, z, Px' Py' pz) . The total beam can be represented by a collection of points which for a beam of f i n i te dimensions is contained within a finite six di mensional hypervolume in phase space . From statistical mechanics "Mouville ' s theorem" states that under the action of forces which can be derived from a Hamiltonian function the motion of a group of particles is such that the l ocal density of representative points in the appropriate phase space remains constant . An alternate statement of Liouville's theorem is that the volume in phase space enclosing a given selection of points remains invariant. Appendix IV contains a derivation of Liouville's theorem . For quadrupoles and bending magnets the coordinate axis can be chosen such that equations of motion in the x-, y- and z-directions are independent of each other. Liou-ville ' s theorem then simplifies to the statement that the areas in the (x, px)' (y, Py) and (z, pz) planes which 15. contain the representative points are constant in time. Also, under the action of forces proportional to displacement such as are encountered in quadrupoles and bending magnets an elliptical contour in phase space remains an elliptical contour. It is convenient then to regard the particles of the beam as being confined within an elliptical phase space region. For beams that are acted on only by static magnetic fields the average axial momentum Pz is constant and we have m~ Pz X l Then the area in the space (x, x') constant times the area in t he (x, px) phase space. Similarily y' = PylPz and the same i s true for the (y, y ' ) space. The two dimensional phase spaces of invariant area can then be taken as (x, x') and (y, y') . Following Steffen (1964) the phase s pace ellipse equation in the (x, x') plane can be written in a normalized form as yx2 + 2axx' + ~x, 2 ( 2 . 3 . 1) where y~ - a 2 1 (2·3·2) and the "emittance" elli]2se area ( 2 ·3·3) 1T 16. A similar equation holds in the (y, y') plane and the following discussion applies equally well to this plane. I n fact any conclusions involving one transverse direction will be assumed valid for the other direction unless otherwise stated. For any orientation of the ellipse the maximum displacement of any particle in the beam is given by ~ = (£~)t and the maximum particle slape is Xlm The beam envelope is defined as the plot of ~ as a func t i on of z . The emittance has been defined above for the (x, x ' ) phase space and not the (x, px) phase space referred to in Liouville's t heorem. The invariant emittance is then tin (2 . 3 . 4) When the ellipse coefficient a is negative the ellipse is tilted forward and when it is positive it is tilted backwards . If a is zero the ellipse is upright and the beam envelope has a minimum (narrow waist) or a maximum (broad waist) value. At a waist the emittance is given by x'm~ and x' y -1!! ~ ~ 1 x'm y ( 2 . 3 .5) ~ x: + 2.0(J::,:;2 + (3~~= f.. ~f.>-o(L~l diverging beam a < 0 waist a = 0 Fig. 5. Phase Space Ellipses , x. 17. converging beam a > 0 When the initial particle displacement Xo and divergence X I o are changed due to the action of a beam transport devi ce in accordance with equations 2.1 .1 then in the case that dp/p = 0 the initial ellipse parameters Yo ' ao ' ~o become transformed by means of the equations (J (T222 - Tl2 T22 T122 -2 T21 T22 (TIl T22 + T12 T21) -2 Tll T12 18. When Liouville's theorem holds, the transformation matrices of equation 2.1 . 1 have unit determinant. This fact is useful in checking numerical work. A further discussion of equations 2 . 3 .1 to 2.3 . 6 is given in Appendix IV. 19· 3. DESCRIPTION OF TRIUMF TRACKING AND MATCHI NG PROGRAM 3.1 Tracking Facilities Tracking consists of finding the transfer matrices for points along the optic axis of some given beam transport system. I f these are known and the initial beam parameters have been specified then equations 2.3.6 and 2.1 .1 allow one to compute the phase space ellipse at any point along the optic axis or the trajectories of any particles in the beam. 3 ·1 .1 The tracking subroutine of TRIUMF can compute by matrix multiplication the transfer matrix for the system at the exit of each element. There are then four options : i) Particle tracking The transfer matrices are used in equation 2 . 1 .1 to find the position and direction of motion of the particle after passing through each element. This information is printed out along with the total distance down the optic axis. ii) El lipse tracking The transfer matrix components are substituted into equations 2.3. 6 and the ellipse coefficients alpha, beta and gamma are computed for points at the exit of each element. These values are printed out as well as the maximum particle slope and maximum particle displacement which are found from equations 2. 3 .4 . 20. iii) Ell ipse plotting This option gives the same information as the above but also produces a graph of the ellipse on the line printer. Print outs do not occur after every element and one must specify the elements after which a graph of the ellipse is desired. iv) Transfer matrix components The transfer matrix components at the exit of each element are printed out. 3·1. 2 For plotting purposes the subroutine TRACK can also compute the transfer matrices for positions inside magnets . The present program will upon request calculate the transfer matrix every 20 cm . along the optic axis . At these points the particle displacement and s l ope and the total distance down the optic axis are printed out. Plotting the parti cle displacement at each point yiel ds the particle trajectory . These same transfer matrices can be used to compute the ellipse parameters at every 20 cm. along the beam axis. Plotting the maximum particle displacement at each point yields a beam envelope trace. 21. 3 . 2 Matching Routines 3 . 2 .1 Trajectory Matching : For particle beams with a small emittance a narrow waist can be approximated by a focussed zero emittance beam (all particles have displacement x = 0) and a broad waist can be approximated by a parallel zero emittance beam (all particles have slope x ' = 0). Then considering particle trajectories may l ead to eff ective matching . For example, consider that the component T12 of the transfer matrix for a system in either transverse plane is zero . The final coordinates of a charged particle with initial di splacement zero and zero momentum deviation will be from equations 2.1.1 and thus x = 0 for any value of x ' o This transfer matrix will thus take any such particle and return it to the optic axis . This is termed the "fo cus to f ocus" condi tion . Similarly we see that if TIl = 0.0 and x ' o ~ = 0 then x = 0 for all Xo and this situati on is' termed the "parallel to focus" condition. If and x 'o = ~ = 0 , then x'= 0 for a l l Xo "parallel to parallel" condi tion. I f T22 = 0 T2l 0 This is the and ill! = 0 p then x' = 0 for all x' o This is the "focus to parallel " condition. 22. For the case where Tl3 = T23 = 0 . 0 we see that x and x' are independent of !ill p and the system is dispersionless. The components T13 , T23 are , for the first order elements considered in this program, non- zero only for bending magnets i n the horizontal plane and thus all. beam transport systems dealt with In TRIUMF are dispersion-less unless they contain bending magnets and then they can be non- dispe r sive only in the horizontal plane. The trajectory matching routines used in TRIUMF are as shown in the table. Matching Routine Rout ine Mathematical Condi tion Number parallel-to- focus I sets Tll 0.0 focus-to - focus 2 sets Tl2 0.0 parallel-to-parallel 3 sets T21 0.0 focus - to-paral l el 4 sets T22 0.0 achromatic system 0 sets Tl3 T23 0.0 (horizontal plane only) These routine numbers apply to either transverse plane . I f a routine number of 0 is specif i ed in the ve r t i cal plane no matching is done in that plane . 3 . 2 . 2 Ellips e Matching: TRIUMF has three routines grouped under the heading of ellipse matching: i) Routine 6 attempts to set the ellipse parameter alpha equal to zero. This corresponds to a search for a waist with an unrestricted value for the final beam size. ii) Routine 7 attempts to set both alpha and be ta to 23· some spec i fied value. Since the final gamma is determined through equation 2.3.2 and the emittance is invariant , this constitutes a search for a unique ellipse . i ii) Routine 5 attempts to create an identity section, that is it tries to set TIl = T12 = ~ 1 and T12 = T21 0 .0. Substitution of the above matrix components into equati ons 2.3.6 shows that such a transfer matrix l eaves the elli pse coef ficients of any input ellipse unchanged. Because the transfer matrices have unit determinant it is only necessary to set T12 = T21 = 0.0 and ITll\ = 1 in order to achi eve an i dentity system . The ellipse matching routines are l i sted in the table below. Matchi ng Routine Match to a waist Ma t ch t o a s pecified ellipse Ma t ch to an identity section Routine Number 6 7 5 Mathematical Condition sets a = 0 sets a - a r sets ~ r o o where ur ' ~r are the requested final ellipse parameters sets ITlll = 1 sets T12 = T21 = 0 . 0 All matching routines may be used independently in both planes. One could do , for example, ellipse matching in the horizontal plane and trajectory matching in the vertical plane. 24. 3.3 Method of Matching For both trajectory matching and ell ipse ma tching the same method is used. An error f unc t ion is formed by taking the square root of the sum of the squares of t he quanti ties which are desired to be s e t to zero . The minimum of this error function is searched f or u sing a method devel oped by Powell (1964). This me thod finds an uncon-s t r a i ned minimum of a function of N va riables without calculation of derivatives. It contains a variation of the method of minimizing a function of several val ues by changing one parameter at a time such t ha t the convergence r ate from a bad approximation to a minimum i s al ways efficient . The elements which are varied a re t hose within the matchi ng section which have been designated as variables in the i nput data . The number of variable elements can range from one to twenty and i t i s suggested that one should t ry to leave at least one element variable for tra j ectory matching and two el ements variable for ellipse matching or for generating dispersionless systems. No cons t r aints have been imposed upon the element parameters except in the case of drift lengths which are restricted to bei ng greater than zero . 25. 3 . 4 General Descrip t i on of Program The TRIUMF program consis t s of a main program and 5 subroutines. It i s wri tten in Fortran II and i s about 800 statements l ong. As can be seen by the program listing given in Appendix VII many 'comment' cards have been inserted to aid the reader. Further information is given below. 3.4.1 Main Program: This program is responsible for reading in all the input data. It reads in the design energy of the beam and computes the design momentum using equation VI-2 . Next it reads in the initial system parameters for each beam handling element. It then calls subroutine ASSIGN which computes the horizontal and vertical plane matrix components for each beam handling element in the system . Then an instruction card is read in to de t ermine the required job to be performed. Any information which is needed to complete the job and was not contained on the instruction card is also read in at this point. If the instruction card requests a tracking job the program calls subroutine TRACK. For a matching job subroutine MATCH is called. On a request for a system change the program makes the change, calls subroutine ASSIGN to find the new matrix components,and then reads in another instruction card. On returning from subrou tine TRACK or subroutine MATCH the program determines the next job by reading in another ins t ruction card. This process of reading an 26 . instruc tion card to determine the next job continues until an instruction card requesting termination of the program is encountered. 3 . 4 . 2 Subrout i ne TRACK: This subroutine will do trajectory tracking or plotting, ellipse tracking or plotting, a beam envelope trace or a print out of transfer matrix components . I t consists of a DO loop which is traversed NE times where NE is the number of elements in the system. On the Ith time through the loop the transfer matrix for the system up to the exit of the Ith element is computed. This matrix may be used to carry out any of the tracking jobs mentioned in section 3 .1.1 . If trajectory plotting or a beam envelope trace is required then another DO loop nested within the previous one computes the transfer matrices at points within each el ement so that either of the two tracking jobs mentioned in section 3 .1. 2 can be performed . 3.4 . 3 Subrout ine ASSIGN: This subroutine takes the current values of the system element parameters and computes the horizontal and verticle plane matrix components for elements N to M inclusive where Nand M must be specified before entering the subroutine. Quadrupole matrix components are computed using equations 11-21, 11-22 and bending magnet matrix components are calculated from equations 111-26, 111-27 (except that components T13, T23 have been multiplied by 100.0 because of the change in units as explained in Appendix VI). Drift space matrix components are found using equat i ons 1-5, 1-6 except that L ha~ been replaced by IL l. This avoids matching solutions with negative drift lengths. 27 · 3 ·4.4 Subroutine VA04A : This subroutine attempts to find the minimum of a function of N variables using an iterative . procedure developed by M. J. Powell. For the complete details see the reference, "An Efficient Method for Finding the Minimum of a Function of Several Variables Without Calculati ng Derivatives", Applied Mathematics Group, Atomic Energy Research Establishment , Harwell , Berkshire, 1964. Thi s subroutine was written by Powell and has been used without making any significant changes. To use this subroutine a number of variables must first be specified. This is done in subroutine MATCH and they are set as indicated below: N (no. of variables) This is set equal to the number of elements in the matching section with variable parameters. ESCALE (maximum step size during minimization) This is set at 100000. Lower values were tried and it was found that too many function values were being calculated. Higher values have not been tried. IPRINT (print out control) If IPRINT = 1 information is printed out after each function evaluation. If IPRINT = 2 information is printed out only after each iteration. This is set at 2 as a setting of 1 prints out too much information. As shown on page 128 the print out consists of the number of iterations completed, the number of function values calculated, and also the values of the function and the variables at the completion of the last iteration. MAXI T (maximum number of iterations) This is set at ~O. E(I ) (accuracy to which variables are to be determined) This is set as follows: - for quadrupole field gradients - for bending magnet fields - for drift lengths 0.1 Gauss/cm . 0 . 1 K Gauss 0.001 meters If on successive iterations the variables do not change by more than the values given above then the iteration procedure stops. XC I ) (initial values of variables) 28. These are set to the variable element parameters of the initial guessed system . 3 . ~.5 Subroutine MATCH: This subroutine determines those elements within the matching section which are to have variable parameters. It then defines the variables listed above for VAO~A. Next subroutine VAO~A is called to carry out the matching job. On return from subroutine VAO~A the results of the matching attempt are printed out. 3 . ~.6 Subroutine CAlCF: This subroutine takes the current values of the system element parameters and defines and calculates an error function which is to be minimized by subroutine VAO~A in solving a matching problem. From the matching routine numbers IA and IE one of the mathematical conditions listed in the table in section 3 . 2. 1 or 3 . 2. 2 is chosen for the horizontal and vertical plane. The square root of the sum of the squares of those quantities which are to be set to zero consti tutes the value of the error function. CALCF calculates this and then returns to subroutine VAo4A. 29 · 3.5 Conclusion The digital computer program, TRIUMF, has been tested successfully on a problem involving .5 quadrupoles and 2 bending magnets which was studied by Paul (1961) . The output from this problem appears in Appendix VIII . Other programs such as TRAMP (Gardner and Whiteside) and TRANSPORT (Moore et all have been written 30. to solve tracking and matching problems . The TRIUMF program differs from existing programs mainly in that it uses the minimization subroutine of Powell (1961) to solve matching problems . The advantage gained by using this new method is that the iteration procedure will converge to a solution even if the initial "guessed" system is not close to the solution system. The TRIUMF program could be made more versatile by using general 6 x 6 transfer matrices to represent beam handling elements as is done in the TRANSPORT program. This would enable ellipse tracking for the case 12 ~ 0 to be p done and would also allow second order tracking to be incorporated in the program. Another program modification would be to include more types of beam transport elements. The velocity separator and non-constant field bending magnet as well as a general matrix read in by components (which could represent the effect of the fringing field of an accelerator) would be useful additions. This program is to be used as an aid in the design of a beam transport system for t he proposed "Tri-Univers ity Meson Facility" (Vogt et aI, 1966). REFERENCES Banford, A. P. 1966 . The Transport of Charged Particle Beams. (E. and F. N. Spon Ltd. , London). 31. Blackstein, F. P. 1967. "The Fundamentals of Quadrupole I on Optics". Chalk River , Ontario, FSD/ ING - 9'+ . Blackstein, F. P . and Otter , A. J. 1967. "Beam Transport System for the ING Thermal Neutron Fac i lity -Preliminary Design". FSD/ING - 80 . Courant , E . D. , Livingston, M. S. and H. S. Snyder. 1952. "The Strong-Focussing Synchotron - A New High Energy Accelerator". Phys. Rev. 88, 1190. Gardner , J. W. and Whiteside, D. 1963. "F ortran Version of Tramp". Rutherford High Energy Lab., NIRL/M/ltlt. Gardner, J . W. and Whiteside, D. 1963 . "Tramp Tracking and Matching Program". Rutherford High Energy Lab . , NIRL/M/21. Hansford, R. N. and R. J. Aspley. 1967. Preprint No . 3 , liThe Second International Conference on Magnet Technology" . King, N. M. 196'+. "Theoretical Techniques of High Energy Beam Design" . Progress in Nuclear Physics .2., 71. Lobb, D. E . 1 963. Saskatchewan Accelerator Laboratory Report No . 2. Lobb , D. E. 1966. Ph.D. Thesis, University of Saskatchewan. 32 . Livingood, J. J. 1961. Principles of Cyclic Particle Accelera tors. (D. Van Nostrand Co. Inc., Princeton) . Livingston, M. S . and Blewett, J . P. 1962. Particle Accelerators. (McGraw-Hill Book Co. Ltd . ) . Moore, C. H., Howry, S. K. and Butler, H. S. 1963. "Trans-port , A Computer Program for Designing Beam Transport Systems". Stanford Linear Accelerator Center Internal Report. Panof sky , W. K. H. and M. Phillips. 1955. Classical Electricity and Magnetism. (Addison-Wesley Publishing Company, I nc . , Reading, Mass . ) . Paul, A. C. 1964. "External Beams from the UCLA H-Pion Cyclotron" . UCLA Report P-65 . Penner , S. 1961. "Calculations of Properties of Magnetic Deflec tion Systems". Rev . Sci. Instr . ].g, 2 . Powell, M. J . D. 1964. "An Efficient Method for Finding the Minimum of a Function of Several Variables without Calculating Derivatives". Applied Mathematics Group, Atomic Energy Research Establishment , Harwell, Berkshire. Steffen, K. G. 1964. High Energy Beam Optics . (Interscience , New York). Tolman, R. C. 1938. The Principles of Statistical Mechanics . (Oxford University Press). Vogt, E. W. and Burgerjon, J. J . (edito rs). 1966. "TRIUMF Proposal and Cost Estimate" . University of British Columbia . Yagi, K. 1964. Institute for Nuclear Study , University of Tokyo, (1964). 33 · APPENDIX I: DRIFT SPACE TRANSF'ER MATRIX COI1PONENTS The equations of motion for a particle in a region of zero magnetic field are from equation (2 .1. 2) with B"> = 0 mx = 0 and my = 0 I-I I n the horizontal plane we have x dx dx dz , dt = dZ dt = x Z d2x 2 + dx d2z ,,2 x = dz 2 (¥tJ dz dt2 x" + x ' z 1-2 Now z = 0 as there a re no forces in the z-direction and we have rnX° == mx" z2 0 or x " o . 1-3 The solution i s x = Az + B If for z = 0 , x = Xo then B Xo By differentiation x' = A and if at z o , x then A = x ' 0 The effect of a drHt space of length L on a particle is then x x' X'o L + Xo x' o 35. or in matrix notation A parallel procedure leads to the same matrix components for the vertical plane . Si nce a field free region i s non-di spersive we can write ( :'~ = ( ~ : :) (:~) 9J! 001 9J! p p I-4 and (~ ,)= (~ : :)( :~) 9J! 00 1 9J! p p I-5 36 . APPENDIX I I : QUADRU~OLE MAGNET MATRIX COMPONENTS 11. 1 . Magnetic Fields with Quadrupole Symmetry Following the treatment given by St effen (1964) the magneto static potential for a field which has the symmetries of a quadrupole magnet field is derived and compared with the ~otential for an ideal quadru~ole field . With the hard edge model the field in the z-direction is zero and using cylindrical coordinates r (x2 + y2)t , ¢> _1 tan y/x in the xy- pl ane we have <l> <l> (r , ¢» where <l> is a general potential which is independent of z and where the field is iJ> ='V<l> . Then from Maxwell 's equation we have in cyl i ndrical coordinates I f we assume <l> (r , ¢» = u(r) f(¢» and substitute this in the above and then multiply by r2/<l> we get For this to be possible we must have II-I 37 . r a (ru ) 1 a2f m2 U a r f a4>2 = m constant or r d (r ~~) m2u 0 err and d2f m2f 0 - + d4>2 Two solutions are u II-2 and f ~ c cos m~ + d sin m$ II-3 I n equation II-2 as r approaches zero we must have b = 0 if ¢ is to remain finite (m > 0). Rotation of the poles in Fig . 1 by 900 gives the original pole configuration except that the polarities reversed and we have ¢ (r,0) = - ¢ (r, ° + ~) . II-4 Reflection of the poles across the x- axis produces the same results as above hence ¢ (r,0) = -¢ (r, -O) • II- 5 Equation I I- 5 applied to equation II-3 gives that f(0) = - f( - 0) or f(O) 0 and in equation II- 3 we must put 0 Also equa t ion I I - 4 implies that f(0 + ~) - f(0) and from equation II- 3 we must have sin m (~+~) = -sin ~ sin m~ cos m; + cos ~ sin m; . For this to be satisfied for all ~ we need cos ¥ - lor m; = (2n + 1)1T m 2 (2n + 1) n 0,1,2 ... and sin m1T 0 or m1T "2= "2 n1T m = 2n n = 0,1,2 ... hence for both conditions to be satisfied we must take m = 2 (2n + 1) n = 0,1,2 . .. The general solution satisfying the above symmetry conditions is <l> (r,~) L n=O I f we set g/ 2, a r 2(2n+l) sin 2(2n+l) ~ . n for n > 0 then we get the pure quadrupole field potential <l> gr2 sin 2~ = gr sin ~ r cos ~ = gxy . 38 . II-6 II- 7 In any physical quadrupole magnet .the shape of the pole faces do not follow the hyperbolic equipotentials out to infinity. Because of the space required for exciting 39 . coil s, the pole shape must deviate from this theo re tical shape and the potential will contain some higher harmonics. I I. 2 . Matrix Components for an I deal Quadrupole Ma gnet The equation of motion for a po i nt particle of mass m and charge e in a magneti c fie l d is from equa tion (2 .1. 2) I n the x- direction this is This is relativistically exact because m =(J 1 _ v2/c2) - 1 mo is a constant since Iv>1 does not change in a magnetic field . Similarily in the y- and z- directions I f we change to z as the independent variable we have as in equations I-2 II-9 II-IO II- ll 40. and similarily in the vertical plane y y ' z y = y 'I Z2 + y ,'z' II-12 Putting equations II-ll in II-8 gives Xl I z2 1- x"z' &. (Y'zBz - ZBy) m and from 11-10 we get X ,, ~2 + x'z· -me (x ' B 'B ) Y - Y x or From equations 11-11, 11-12 II- 13 and we get X II = mve (1 + x,2 + y,2)t (x'y'B - (1 + x,2) B + y ' B ) x Y z and simi1ari1y making the same kind of substitutions in equation 11-9 gives If we use the paraxial approximation that x ' « 1 , y ' «1 then products of x' and y ' can be negl ected and x' , y' , :::Q mv Substituting for the pure quadrupole field By gx , Bx = gy , Bz = 0 yields x " = ~ gx _ K2x II-14 mv where K2 ~= ill;. II-l 5' mv p and y" _-.f... gy K2y = _ i~2y II-16 - mv The solution to equation II-14 is x = A cos Kz + B s in Kz II- 17 By differentiation x ' -AK sin Kz +KB cos Kz II-l!3 If at z 0 , x = Xo then A = Xo and if at z = 0 x ' x' 0 then KB = X l 0 , B = x'olK and substitution of A , B i n to equations II-17 and II-1B gives x ' x cos Kz + 0 sin Kz Xo K X l - xo K s in Kz + x 'a cos Kz The solution to equation II-16 is y = A cos iKz + B sin iKz = A' cosh Kz + B' s inh Kz . II-19 By differentiation 42 . y' = KA' sinh Kz + B'K cosh Kz II-20 I f at z = 0 , y = Yo then A' at z o , y' = y ' o then B'K y ' o B The equations II-~9 and 11- 20 become y ' y = Yo cosh Kz + ~ sinh Kz y' = +Yo K s inh Kz + Y'o cosh Kz Since the central trajectory is not deflected by a quadrupole t here is no dispersion to first order (Hans-ford and Aspley, 1967) and we can take T13 = T23 = 0 . 0 . If the effective length of the quadrupole is L then in the horizontal plane we can write ~ s i n KL cos KL o and for the vertical plane (Y\ tcosh KL ~r( S~nh KL ~ sinh KL cosh KL o Equations 11-21 , 11-22 agree with those given by Penner (1961). II-2l II-22 II . 3 Thin Lens Approximation Replacing ideal quadrupole magnets by approximately equivalent thin lenses simplifies the analysis considerably and can be used to arrive at a IIguessed" system prior to matching . This section gives the matrix components in terms of the focal length of the equivalent thin lens . These relations are due to Penner (1961). The action of a thin lens on a particle is to change the particle slope without affecting its displacement . Suppose as in Fig . 6 a thin lens at A brings all particles travelling parallel to the central trajectory at any initial displacement Xo to a focus at A' . The change in slope at A must be nxlo = - xo/f and the effect of a focussing thin lens on a particle is given by X l = X l + !Yx o 0 or in matrix form For a defocus sing thin lens f would be negative. A thin lens does not defl ect the central trajectory and we may write ~ A' ------------------~~~--------------~~--~L Fig . 6 . The Thin Lens The transfer ma t rix representing a drift space of length Ll , followed by a thin lens of focal length f and a drift space of length L2 is Ll +L2- Ll L2/f 1 - Ll/f o Comparison of equation 11-24 with 11-21 shows that a 44. II-23 focussing ideal quadrupole magnet has the same effect on a particle as a thin lens sandwiched between two drift spaces if the following equations can be satisfied . - l/f -K sin KL The solution is f 1 K sin KL sin KL --K-II-25 Simil arily comparison of equations 11-24 with 11- 22 gives with the solution -l/f K sinh KL f sinh KL --K--cosh KL - 1 sinh KL -1 K sinh KL A power series expansion of the trigonometri c functions yields for equations 11-25 II-26 and similarily for equations II-2p llf = _K2L (1 + K2l2 + ... ) I n the thin lens approximation it is assumed that K2L2 « 1 and f r om equations 11-27 and 11-28 f ~ 1 K2L fo r a focussing l ens and for a defo cussing l ens . 46 . II- 27 II- 28 APPENDIX III: BENDING MAGNET MATRIX COMPONENTS 111 . 1 Matrix Components for Bending Magnets with Normal Entrance and Exit Angles - Horizontal Plane We consider the motion of an ion in a constant magnetic field B. Cylindrical coordinates (r, 0 , y) are chosen such that the y- axis is parallel to the field B and r and 0 are measured in the plane of the trajectory . is I n cylindrical coordinates the radial accelera t ion ·2 a r = r - r0 . The force in the radial direction i s - e r 0 B . I f we use the approximation r 0 = Z ~ v then the radial equations of motion are 2 mar = m Cr· - vr ) - ev B III-l A possible solution to this equation is a circular path , i . e. r = ro have const. The term r disappears and we or ev B mv .lL eB = eB Following the treatment of Livingood (1961) we consider now a particle wi th a radial displacement at 1II-2 ro + x where x« ro and a small momentum deviation dp 48 . from the previous case represented by equation III- I. A momentum of p + dp implies that the vel ocity and mass a r e sl i ghtly different and equation III- l becomes (m + dm) ..JL ( ) em + dm)(v + dv)2 dt2 ro + x - ero + xl - - e (v + dv)B . 1II-3 Using the approximation __ I_ ra + x and noting that o , we get if we negl ect products of small terms x, dm , dv , x v2 dm -eBdv + 2m ..Y. dv ro ro where equation 1II-2 has been used to reduce the last two terms. 1II- 4 Since p mv, dp mdv + vdm and division by p gives .!ill dv + ill!! p v m and hence equation 1II-4 becomes Changing to as independent variable, we have as in equations 1-2 and the above equation becomes The solution to equation 111-5 is x = A cos ...&.. + B sin ro ...&.. + ~ r (1 - cos ...&.. ) and by differentiation ro p 0 ro X ' If for Z = 0 I X Xo then A Xo and if for Z = 0 x ' = x 'a the .].. x ' or B x ' and the equations ---.Q ro 0 r 0 , above are x Xo cos ...&..+ r x ' sin ~+ ~ r o (1 - cos ro o 0 r p - x ...&.. + ...&.. + x ' ---.Q sin x' cos ro ro 0 ro or with <P = z/ro = L/ro where L length of the magnet and the angle bend of the central convenient ly as the trajectory this matrix equation +ro sin fJ) cos d> o 0 ~ ...&.. sin p ro is the effective <P is the angl e of can be written II1- 5 rZ) 0 III-6 1II- 7 50. Note : The deflection of the beam is concealed in the output as the coordinate system is attached to the central trajectory which is deflected the same amount . I I I. 2 Effect of Rotated Pole Edges Horizontal Plane Fig . 7 shows the exit face of a magnet with the pole face rotated by an angle ~2 > 0 . IS I'~RI>f:.N.\)'c..\,) ..... "R 10 I C.t:N,R,..\... TRI\:rE:c..\oRY I 1>2.~ Fig. 7. Construction for the Calculation of the Effects of Pole Edge Rotation on the Radial Trajectories. 51. The displacement and slope with non- normal exit of the central trajectory are calculated as a separate transfer matrix operating on the displacement and slope vector for normal exit . Referring to Fig. 7 AEB is perpendicular to the optic axis at the exit point. The curve RSTV represents the trajectory of a particle with initial displacement and slope Xo and Xl o For a magnet with normal exit for the central trajectory ~2 = 0 and the segment RST inside such a magnet is the arc of a circle of radius ro + ~ro centered at 0 The fina l displacement of this trajectory at E is xf = ET I and final slope xf ' the angle YTV For the magnet with ~2 ~ 0 (non-normal exit), the segment SUW of the displaced trajectory RSUW lies outside the magnetic field, the final displacement and slope corresponding to pos i tion E on the optic axis are x = x f + TU X' = x lr + WZV Since the sum of the interior angl es of the po l ygon OSZT is 21T and angles OSZ ZTO 1T/2 then TOS + SZT 1T • Since SZT + WZV 1T , angle WZV TOS = arc ST ro + tJ.ro If we use the approximations that the a r c ST t " 2 and I ~ .1... ET tan ~ , 2 = xf an e ro + ~ro ro then X' Xl f + xf tan ~2 -r;;-I f we further consider TU to be sufficiently small that it may be neglected we have approximate effect of particle is given by x' or in matrix notation the rotated pole x Xf tan ~2 x'f + x = Xo and edge on the I n the same manner a similar matrix can be derived to represent the effect on a particle due to cross i ng a rotated entrance face . We have then the where ~l is the angle of rotation of the entrance pol e face. Equations 111-8 and 111-9 agree with those derived by Penner (1961) . 52. III-8 III-9 53· III·3 Effect of Rota t ed Pole Edge s Vertical Plane At the edge of a constant fi eld magnet there is a fringing field approximately a s shown in Fig . 8eA). e,_ I L )l (13) l>LAN Vl iO W Fig. 8. I I r-JlI Fringing Field at the Edge of a Bending Magnet . K. I'IA&N€:T i'OLe. FAC.e. For points not on the median plane ED the field has a component Hz normal to the magnet pole face . If a particle enters the fringe field above or below the median plane it is acted on by this field which can be resolved as shown in Fig. S(B) into a component along the trajectory Hz cos ~l and a component normal to the trajectory Hz sin ~l From the Lorentz force equation the vertical force on a particle at point A is 54. Fy = ev Hz sin ~l 111-10 The total change in vertical momentum for a particle passing into the magnet through point A would be given by II1-11 where B i s some point sufficiently far from the magnet so that Hz = 0 and C is a point inside the magnet where there is no fringe field . Combining equations 111-10 and II1-11 gives LIP = e sin ~l f Hz v dt = e sin ~ l f H ds Y B B z II1-12 where ds is an element of distance along the trajectory . For the static current free region of field that we are considering Maxwell's equati on - > curl If' = j > + aaDt = 0 and from Stokes' theorem To evaluate the integr al in equation 111- 12 we III-13 55 . take the line integral around the closed path BCDEB. Along CB, Ry is perpendicular to the path of integration and does not contribute to the integral. We get rB B L H. cos ill d~ ~ J H cos P ds e ~ C z where we have made the approximation that path CB represents the particle trajectory . Along CD Hz is zero as we are sufficiently far away from the fringe field and the integral becomes JD C H dy = -Yo ( -H) = YoH III-14 III-15 where Yo is the displacement of the particle from the median plane and we have used the same approximation as in equation 111-14 . Along DE, Hz is zero as we are in the median plane and Ry is perpendicular to the path of integration, hence the contribution to the line integral is zero. Along EB we are assumed sufficiently far from the magnet so that H is zero and there is also no contribution from this segment of the path . For the cl osed circuit the net result is from 111-13 D J H cos ~l ds + Y H = 0 C z 0 or III-16 Substituting equation 111-16 in 111-12 56. Substituting equation III-16 in III-12 yields The change in slope of the particle trajectory is given by ~ _ -yeH tan tl Po - mv and from r~ = :~ , III-I? In this approximation the effect of the rotated po l e face is given by y' or in matrix form III-18 A similar effect occurs at the exit face and we can write (:) (~ :) (:) III-19 These matrix components are derived by Banford (1966). 57. 111 .4 Matrix Components for Bending Magnets with Rotated Pole Faces Since the rotated pole faces do not bend the central trajectory there is no firs t order dispersion and we can write from equations 111-9 and 111-18 III-20 and III-21 and similar equation exists for the exit faces wi th ~l repl aced by ~2 . Horizontal Plane The ne t transfer ma trix for a constant field bending magnet with rotated pole faces is then for the horizontal plane 58. c .. · sin C/> tan ~l tan B2 (cos C/> + sin C/> tan ~l) - sin cp + cos !1l tan ~ l ro r 0 ro 0 III-22 ro sin C/> ro (1 - cos C/» ,= ,) sin C/> tan ~ 2 + cos C/> sin C/> + (1 - cos C/> ) 0 1 Using trigonmetric identities some of these components can be put in a simplified form . e.g . Tll = cos C/> + sin C/> tan ~l = cos C/> + sin C/> sin ~l cos ~l Now using cos (C/> - ~l) cos C/> cos ~ l + sin C/> sin ~l gives TIl cos C/> + ____ 1 __ (cos (C/> - ~l) - cos C/> cos ~ l ) cos ~l cos (!1l - ~l) cos ~l and similarly T22 cos (C/> - ~2) cos ~2 Also III - 23 III-24 T21 : (cos ~ tan ~2 + sin ~ tan ~l tan ~2 _ a sin ~ + cos ~ tan ~l) -1 (sin ~ (1 - tan ~l x tan ~2) _ cos ~ ro tan (~l + ~2) (1 - tan ~l tan ~2)) where we have used tan (~l + ~2) This leads to tan ~l + tan B2 1 - tan ~l tan ~2 59 . T21 = - 1 (1 - tan ~ l tan r2) sin (~ _ ( " 1 + "2)) 111-25 ro cos ' ( ~l + ~2) •• where we have used sin (~ - (~l + ~2)) sin ~ cos (~l + ~2) - cos ~ sin (~l + ~2 ) . Putting equations 111-23 , 111-24 and 111-25 in equations 111-22 gives the matrix ~ for the horizontal plane for a magnet whi ch bends the central trajectory to the right. It is cos (d! - rl) cos ~l (I-tan r l tan ~2) sin (~-(~l. + ~2)) cos ( ~ l + ~2 o 60 . r 0 sin <I> ro (1 - cos • J ) cos (!l1 - ~ 2 l sin <I> + (1 cos <1» tan ~ 2 II1- 26 cos 13' 2 0 1 Vertical Plane Since the y- axis was chosen to be parallel to the fie l d B , the Lorentz force equation gives that and the equation of motion in the y- direction is f = 0 y my = 0 The magnet thus acts in the vertical plane as a dri ft space of effect i ve length L = ro<l> Tak ing i nto account the effects due to the r otated po l e faces described by equations 111-20 and 111-21 we get the matrix VR rep r esenting the bendi ng magnet in the ve r tical plane to be II1- 27 C "~ ~l ro <I> :) ·tan tl tan ~ 2 + !l1 tan ~2 tan ~l 1 - <I> tan ~2 - ro - ro ro a 0 61. The matrix components given in equations 111-26 and 111-27 agree with equations ( 30 ) and (33 ) given by Penner (1961) except for component T12 in the vertical plane where Penner fails to include t he term ~ tan ~ l tan ~2 . Plotting at points inside bending magnets gives the correct values for the slope only at the exit of the magnet. This is because the matrix components given in equations III-26 and III-27 assume the action of the two rotated pole faces occur simultaneously whereas the effect of the exit edge should not occur until the exit of the magnet has been reached. If accurate val ues of particle s l ope were required inside bending magnets the program could be modified by splitting the present matrix into 3 matrices, one representing the effect of entrance pole face rotation, one for a magnet with normal entry and exit, and one for the exit face rotation. If these matrices were used in the above order the correct trajectory would result. 111 . 5 Sign Convention for Bending Magnets For a bendi ng magnet which bends positively charged particles to the right (looking in the directi on of beam motion) the angle of bend 0, and the magnetic field are taken as positive . The radius of curvature ro from equation III-2 is then also positive. Comparison of equations 111-20 and III-21 with equation 11-23 shows that the effect of rotating a pole 62 . face through an angle is approximately equival ent to that of having a thin lens of focal length f = ~~~ ~ in the horizontal plane and of f = ~ tan ~ in the vertical plane where as defined above r > 0 o for a bend to the right. The sign convention for is that if the effect of the rotated edge is to produce horizontal defocus sing or vertical focussing ~ > 0 and if the effect of the lens is to produce horizontal focussing or vertical defocus sing then ~ < o . Hence in Fig. 3(A) ~l > 0 and ~< o. To find the sign conventions fo r a magnet which bends positively charged particles to the l eft we note from Fig . 3 that a magnet that bends the optic axis to the left can be obtained from one that bends to the right by rotation about the central trajectory by 1800 • As shown by Penner (1961) the effect of a left bend magnet on a particle can be found by rotating the particle coordinates and left bend magnet through 1800 , using the known matrix components of a right bend magnet to compute the particle position and slope at the exit of this magnet and then rotating the particle coordinates through 1800 again to arrive at the final position and slope . This procedure yields for the horizontal plane cos ~ l = - 1 (l-tan 1 tan B2) (COS (<p - n) :0 cos ~~l + ~2) sin (<P- (~1+~2» r o s in <p -r a (1 - cos .J ) cos (~ - B2) (1 -cos ~2 - sin <p - cos <p) tan ~2 0 1 and fo r the ve r tical plane <p tan ~l (11 -(<p tan ~l tan ~2 - tan ~l - tan ~2) r o o 1 - <p tan ~2 : ) o 63 · III-28 III-29 64. tan (-x) Since cos (-x) = cos x, sin ( - x) = - sin x and tan x we can reproduce the above matrices by adopting the convention that for magnets which bend the central trajectory to the left B, 0 , ~ l , ~2 are taken as having signs opposite of those for magnets which bend the optic axis to the right. Thus in Fig . 3(B) we have that ~l < 0 and ~2 > 0 The table below shows explicitly the sign convention for the 8 possible cases. Pole Deflection Effect of Pole Face of Central Horizontal Vertical Face Trajectory Plane Plane entranc to right focussing defocus sing " " " defocussing focussing " to left focussing defocussing " " " defocus sing focussing exit to right focussing defocussing " " " defocus sing focussing " to left focussing defocussing " " " defocus sing focussing Conven-tion ~l < 0 ~l > 0 ~l > 0 ~l < 0 ~2 < 0 ~2 > 0 ~2 > 0 ~2 < 0 65 . APPENDIX IV: LIOUVILLE'S THEOREM AND PHASE SPACE ELLIPSES IV.I Liouville's Theorem The conservation of the number of particles in phase space is represented by the equation of continuity -> ~ "'V'(pU ) where U> = (x, y, z, Px' Py' pz) current vector and o is the phase space density. From IV-l we have Now consider the terms If Hamilton's equations of motion apply then and x.~ ~ IV- l IV-2 IV- 3 66 . and therefore the terms of IV- 3 are and from equation IV-2 QQ. + \' at L.. i M-dt o Thus in general if the forces acting on a particle can IV-4-be derived from a Hamiltonian function the local density of the representative points in phase space is constant in time. This is valid for both conservative and non-conservative systems provided a Hamiltonian exists for the system (Lobb, 1963). The relativistic Hamiltonian function for a particle of charge e, rest mass me ' in an external magnetic field exists and is well known to be where the canonical momentum is and I V- 5 (Panofsky and Phillips, 1955). From the derivation of Liouville's theorem given above we see that the coordinates used must be a generalized coordinate and its conjugate momentum. In a drift space A) = 0 and the canonical momentum is then the usual momentum - ) mv 67. For the case of particle motion in a magnetic field it can also be shown that both the terms and occurring in IV-3 are zero separately when the normal momentum. Thus from or where we have and from we have .!.) P - ) P o - ) mv is IV-7 68. L . 01\ 3. e E ijk (X j ap + Bk op ) i,j ,k i i The first term is zero as the magnetic field does not depend on the particle momentum and we have from equation TV-7 L ....Q.... (p2 cpo ) e Eijk 1\ oPi + ~o 2c2)"~ i, j,k Since the term in brackets is symmetric with respect to i nterchange of i and whereas the term Eijk is anti-symme t ric with respect to those indices, the sum adds to zero and this gives the desired result We can thus use the six dimensional phase space with coordinates . . . x , y, z, mx, my, mz. Another form of Liouville's theorem is useful in beam transport theory. Consider a region of phase space bV taken small enough so that the density can be regarded 69. constant over its extension. The number of points within this region is bN = pbV . If we follow the motion of thi s region through the phase space allowing the boundaries of the region to be determined by points originally within the region, then d; (bN) = 0 I V- 6 as no points are created or destroyed due to their correlations with mechanical systems and no points can cross the boundaries because of the unambiguous determination of mechanical motions . Different iating equation IV-6 gives p d; ( bV) + bY ~ = 0 IV-7 and we get that h (bV) = 0 . Since we can combine small elements this expression appl i es in the case of l arge phase space volumes providing their boundaries are determined by the same selection of representative points. If the equations of motion in each plane are independent of each other then the dens i ty function can be written as a product p = PxPyPz and Liouville's theo rem holds for each plane. The above statement of Liouville ' s theorem then becomes that the area in each plane is an invariant of the motion.' 'Discussions of Liouville's theorem and its relationship to beam transport theory are given by Steffen (1961 ), Banford (1966) and Lobb (1963). A general treatment by Tolman (1934) was also consulted. 70 . IV. 2 Ellipse Calculations A standard form for writing the equation for a central ellipse is ax2 + 2bxx' + c(x' )2 1 IV- B where a > 0, c > 0 , b2 - ac > ° This ellipse is centered on the origin because if , (xo ' Xo ) satisfies the equation so also does (- xo ' - xo ') . The area A of this ellipse is from calculus If we define then multiplying equation Iv-B by E gives and if we define a b c IV- 9 y _ b2)t a b2) "f _ b2)"f (ac (ac - (ac then we have that 2 a b2 1 . y~ - a b2)t (ac b2 )"f -- --2= (ac - ac - b A normalized form for the ellipse equation i s then where and £ = !l 1T I 71. IV- IO IV-ll IV-12 The maximum value of x is found by differenti-ating equation IV-IO with respect to x ' giving y 2x ~, + 2a (x + x' ~~,) + r 2x ' = 0 At ~, ~~, = 0 and we have 2a~ + r 2x ' 0 or x' = - F ~ and substituting in equation IV-IO 2 " ~" r E ~ (y - 2 ~ + ~) (ry _a 2) r r ~ (E r )"t IV- 13 72. The maximum value of x' is found by differenti-ating IV-lO with respect to x and setting ~; = 0 This gives x' m ::.xx a and substituting in equation IV-B gives X l m = (q) t . The value x' i of x' when x o is easily seen from equation IV-lO to be and similarily when x' = 0 we have x<=+(s.)t ~ y' These resul ts are given by Steffen (1964) . For an upright ellipse (a = 0), the absolute val ues of x' . ~ and xi become the semi- major and semi-minor axis for the ellipse. Also from equation IV- 9 we have yr = 1 and Also for an upright ellipse the ellipse area is given by rr t i mes the product of the semi-major and the semi-minor axis and the emittance becomes with &= rr IV-14 IV-15 IV-16 IV-17 73 · y and x' 2 ---'!l.... X l 2 X l m --'!! x I m"m = "m I V. 3 Unit Determinant of Transfer Matrix I n the horizontal plane an initial phase space ellipse may be written in normalized form as o r or (where Xo ,Eo represent matrices and where XoT i s the transpose of Xo ). Also and from equation IV-12, ITO is the ellipse area . IV- 18 IV-19 IV-20 IV-2l If the transfer matrix for a system is given and QR 0 the final displacement x and slope x' of a p 74 . particle in the beam as computed from equation 2.1 .1 are No information is lost if we write this as (x) (Tll T21) (:~J ill< x' = T21 0 T22 P or in matrix form X TXo ill< o . p IV- 22 We have then IV- 23 and IV- 24 where XT is the transpose of X. To find the final ellipse equation we substitute equations IV-23 and IV-24 into equation IV-20 and get or or (xx I) ( : ~) (~,) IV-25 where the matrix representing the final ellipse has been taken as We see that the final ellipse area will still be equal 75. IV- 26 to rrE if once again the ellipse equation i s in normalized form or det E = 1 . Thus for 1 = det E det (T-l)T Eo T-l and we must have To see observe that the lUlit matrix as the lUlit matrix z det (T-l)T det Eo det T-l det (T- l)T det T-l det (T- l ) det (T-l ) __ 1_ 1 det T det T (det T)2 = 1 det T = ! 1 which of these two transfer matrix T approaches zero . possibilities holds must reduce to the The determinant of i s +1 and since det T cannot change discontinuously we must have det T + 1 . we IV- 27 Iv.4 Transformation of Ellipse Coefficients F rom the previous secti on the final matri x r epre senting the ellipse E is given in terms of the initial ellipse Eo through the matrix equation IV- 26 Since T = (Tll T2l Tl2) T22 and from equation IV- 27 de t T 1 then (T22 - T2l -T12) Tll and ( T22 -T12 - T2l ) Tll We get 76 . ( y a) ( T22 E = a ~ = -T12 - T21)(Y 0 Tll a o - T1 2) Tll 77 . (T222 Yo -(-T12 T22 Yo + 2T21 T22 a + T212 ~ )(-T22 T12 Y + (Tll T22 + T21 T12) o 0 0 (T12 T21 + Tll T22) a o - Tll T21 ~ 0)(T122 Yo - 2Tll T12 ao - T21 Tll ~ o)) a o + Tll2 ~ o) or a = - T12 T22 Yo + (T12 T21 + Tll T22) a o - Tll T21 ~ o or in ma t rix form ( ) (T222 : = - T12 T22 ~ T122 - 2 T21 T22 T12 T21 + Tll T22 -2Tll T12 This matrix equation agrees with the result given by Steffen (1964) . IV-28 78. APPENDIX V : INPUT AND OUTPUT CONVENTIONS V. I I nput Convent ions V. I.I All input data is read in by the main program . The first card of any job contains four numbers specifying the design kinetic energy for the system, the rest energy for the type of particle under consideration, the total number of elements in the system, and a parameter "hich indicates whether the drift lengths (which arc read in later) are to be taken as measured between magnet centers or edges. Thus, the card reads, in format (2FIO.5, 213) . design kinetic energy (Mev) where if particle rest energy (Mev) total number of elements MMM MMM = 0 drift lengths are taken a s being measured from magnet edges . I drift lengths are taken as being measured from magnet centers. V .1.2 Next, in the proper sequence , a card for each element in the system is read in. Each card specifies the type of element and certain element parameters in format (F4.1, FII.4, FII.5). The detailed scheme for reading in the Ith element is shown in the table belo". 79 . Element Type Element Type No . First Parameter DO) Second Parameter ET(I) CO) drift space 1.0 length (meters) quadrupole 2 . 0 effective length field gradient magnet (meters) (gauss/cm . ) bending 3.0 bending angle field magnet (degrees) (K gauss) Note : A card representing a bending magnet (ET(1) = 3 . 0) must be followed immediately by a card specifying the entrance and exit angles of the rota ted pole faces . This card is read in format (2FIO.5) and the angles are assumed to be in degrees. For normal entry and exit this may be a blank card . From equation (2.2 . 2) for positively charged particles horizontally focussing quadrupoles have positive field gradients and horizontally defocus sing quadrupoles have negative field gradients . V·1.3 After the initial system parameters have been read in , the program reads an instruction card to determine which job it is required to perform. This instruction card contains up to six numbers in format (313 , 3FIo . 5) and gives directions in accordance with the table below. 80 . INST IA I E U,V,W Tracking Type of Plane Initi al Conditions Tracking 1 0 trajectory "'1 vert i cal for IA = 0 , 1 track ing plane U = i niti al di s-pl acement ( cm) 1 trajectory -1 hori zontal V = i niti al slope ( rad/100) plotting plane W = momentum devi at ion 2 el l i pse t r acking for IA = 2, 3, lr u = alpha r a d 3 ellipse V = beta (cm/100) Plotting W = emi t tance lr beam (cm f~g) envelope D ~ _ INC ,2.,=-,v..,-- "" trace D,"":>~?'JNC .z 5 matri x components 81. INST I IA IB U,V,W Ma tching Horizontal Plane Vertical Matching Ma tching Routine Matching Routine Section 2 0 'achromatic 0 no routine U = first system I specified element V = last 1 parallel to 1 parallel to element focus focus 2 focus to focus 2 focus to focus 3 parallel to 3 parallel to parallel parallel 4 focus to 4 focus to parallel parallel 5 identity 5 identity system system 6 match to 6 match to 'waist ' 'waist' 7 match to 7 match to specified specified ellipse ell ipse System Changes 3 0 change to - for IA = complete new - 1 system U = new des i gn N change Nth momentum system element - (Gevlc l 1 change to new -design momentum Terminatior of program 4 - - -82. Additional Notes: Some jobs require more information than that which is read in on the instruction card . These cases are listed below, along with a description of the additional information required. a) INST = 1, IA = 3 : An instruction card requesting ellipse plotting must be followed immediately by a card specifying the total number of ellipses which are to be plotted and the numbers of the elements after which plotting is requested. The card is in format (3012). b) INST = 2, IA = 6 or IB = 6 : An ellipse matching to a waist instruction card must be followed immediately by a data card containing the initial ellipse coefficients alpha , beta and the beam emittance in format (}FIO.5). c) INST = 2, IA = 7 or IB = 7 : An instruction card requesting ellipse matching must be followed immediately by a data card containing the initial ellipse coefficients alpha , beta and the beam emittance as well as the final reques ted alpha and beta. This data card is read in format (5FlO.5). d) INST 2, IA = 6 or 7 and IB = 6 or 7 : An instruction card requesting ellipse matching in both planes must be followed immediately by two data cards of the type described in b) and c) with the card for the horizontal plane preceding that for the vertical plane. e) INST = 3, IA = N: An instruction card which requests a change in the Nth element of the system must be followed immedia tely by a card representing the new Nth element. 83· This card is read in according to the same scheme as was outlined in section V.I. 2 . f) INST = 3, IA 0: An instruction card requesting a change to an entirely new beam transport system must be followed immediately by a set of data cards representing the new system. These cards are read in according to the schemes outlined in sections V.I.I and V. I . 2 . v.l . 4 Designation of variable parameters: If matching is to be done for a section of the beam transport system then some of the element parameters within the section must be designated as variable. The convention adopted was to set the fraction part of the element type number ET (I ) to a non-zero value for those elements whose parameters were to be varied. The variable parameter for a drift length is its length, for a quadrupole magnet its field gradient and for a bending magnet its magnet its magnetic field. A possible modification of the program would be to arrange it so certain designated parameters could be varied together . This could be useful, for example, in designing systems containing 'symmetric' quadrupole triplets. 84. V.2 Output Conventions V.2 . 1 The initial beam transport system is always printed out according to the format shown on page12a The calculated particle momentum cor~esponding to the design kinetic energy for the system is printed out on the second line. For bending magnets the effective length L = ro ~ is calculated and printed out in addition to the input parameters ~,B , The column on the left numbers the elements. V. 2 . 2 The output from a trajectory tracking job (INST 1, IA = 0) is shown on pages 123, 124 and 135. The firs t column gives the number of the element and the second colunn gives the distance in meters down the central trajectory to the exit of that element. The next two columns give the particle displacement (cm.) and slope (rad./100) at the distance specified in column 2 . A similar print out is given for trajectory plotting ( I NST = 1, IA = 1) and on the right appears the particle trajectory . The calculated particle displacement is multiplied by 4 . 0 and the nearest integer below this number is plotted as an asterisk as shown on page 125. For displacements greater than 10.5 cm. in absolute value no asterisk is plotted. As seen from column 2 displacements are plotted at every 20 cm. along the optic axis. This increment could be adjusted by changing the value of DI in subroutine TRACK. The ellipse tracking output (INST = 1, IA = 2) is shown on page 126. The first column specifies the element 85. number and the next 5 colums give the values of (rad./) ( rad y 100 cm . ,a, ~ cm. / roo·), ~(cm.) at the exit of this element . The print out from a beam envelope trace is shown on page 127 . Columns 1 and 2 give the element number and distance in meters along the optic axis . The next columns contain the ellipse parameters y, a, ~ and and x ' m On the right is a graph of the beam envel ope . The maxi mum di splacement ~ is multiplied by 10 . 0 and the nearest i nteger bel ow this number i s plotted as an asteri sk as shown . A pl ot of a phase space ellipse is shown on page 132. This is done by solving equati on 2.3 . 1 fo r x as a double val ued function of x ' i.e. x and then l ett i ng x' run through its range of val ues . Each val ue of x obtained is rounded to the nearest i ntege r bel ow it and plotted as an asterisk . V. 2 ·3 The output from a matching problem is shown on pages 133 and 13~ . The print out from subroutine VAO~A on page 128 depends on the parameter I PRINT as descri bed in secti on 3.~ . ~ . I f the iteration procedure has been unsuccessful because the function being minimized has 86. not decreased on successive iterations the subroutine prints out 'vAo4A ACCURACY LIMITED BY ERRORS IN F' or if it fails because the maximum number of iterations allowed, MAXIT, has been reached it prints out the value of MAXIT and next to it 'ITERATIONS COMPLETED BY VAo4A' . The format for the print out of the results of a matching attempt is shown on page 129 . On the first line the matching routine numbers are given with the number for the horizontal plane preceeding that for the vertical plane. The final values of the variable element parameters and transfer matrix components are al ways printed out as shown . For ellipse matching to a waist the initial and final phase space ellipse parameters are printed out and ~r matching to a specified ellipse the parameters for the requested ellipse are also printed out . An example of this U shown on page 133. APPENDIX VI: UNITS The input units for the average beam kinetic energy are conveniently taken as Mev. Relativistic mechanics allows us to compute the momentum p in terms of energy . From where Eo is the particle rest energy, we get Expressing the total particle ener gy sum of the rest energy and kinetic energy T E = T + Eo and substituting in equation VI-l p = 1. (T2 + 2T E )t c 0 If T and Eo are expressed in Mev p as the so that gi ves we have Gev c Momentum P is calculated by the program and stored in units of G~V and is used subsequently in computing the quadrupole constant K and the radius of curvature r for bending magnets. Since the effective o VI-l VI-2 length of a quadrupole L is read i n in meters K must 88. be in inverse meters. We have from Appendix II, equation II-15 1. 6 x 10-19 [ caul ] g [ gauss ] ill:. --rciiiJ p = -----p-[ G-e-v-/-c-]--=~-and we know thus and 10- 4 [w:~ersJ = 1 [gauss l l [G~'} 109 ev 1. 6 x 10- 19 [~l 2 . 9978 x 108 [s:cJ t -m2J 1.6 x 10- 10 kg sec 8 m 2.9978 x 10 sec 1 . 6 x 10 kg ~ -10 ~ J 2.9978 x 108 sec Putting equations VI- 4 and VI- 5 in VI-3 1. 6 x -2 ryebers 11 10-19 [ caul] g 10 L m2 mJ 1.6 x 10-10 Ikg - ~ p 2 .9978 x 108 [ sec VI-3 VI-4 VI-5 89 . [ webers l J .0029978 K caul m2 m p ~sec VI- 6 From the Lorentz force law we find that l-we~er~ = ~ newta~ ~ = ~g ~ ]= LkJ': 1 m J coul --- coul ~ ~sec sec VI-7 and putting equations 11-7 in VI-6 gives . 0029978 ~ - ~2 J VI - 8 Al so the radius of curvature for bending magnets i s assumed to be in meters. We have from Appendix III , equa tion III-2 1 = eB _ 1.6 x 10- 19 [ coull B [K gauss] ro p - p [Gev/c] and from equations VI-4 and VI-5 1 . 6 x 10-19 [ caul] B 10-1 [~ 1.6 x 10- 10 p 2.9978 x 108 [~] sec .029978 ~ p and from equation VI-7 t ~J coul m kg - sec = . 029978 ~ [~ J Since the particle slope is physically always small we can use the approximation that Xl = tan Q = Q (where Q is the angle the trajectory makes with the optic axis) and measure slopes in radians. The units for equations 2 .1.1 are as shown below. Because of the small displacements and slopes i t is convenient to use units of cm. and rad/IOO. This entails no changing of the numerical value of matrix 90. components T12, T21 as 1 meter 1 em ~ = 1 rad/IOO However the components T13, T23 must be multiplied by 100 . 0 to convert from meters to cm. and from radians to r ad/IOO respectively. The equation for the phase space ellipse is y x 2 + 2a xx 1 + ~ x 12 with the displacements x in cm . , the slopes X l in rad/IOO. and where the emittance is taken to have units of cm . rad/ IOO . The units of the ellipse coefficients are then I rad l Y Li oo/cmJ a 91. 92 . APPEIlDIX I'II: PROGRAM LIST I NG MAIN PROGRAM o Ir-1ENS ION ET (30) .OC 30).C (30) .H j 1 (30) tH12{ 30) ,H21 (30) ,H22( 30) . tV!1 (30) .VI2(30l,V21 C30l.V22(30) .H13(30) .H23(30l .XO( 10) .SO(10l DI MEN SION BE TAl (30)tBETA2(30),W{440).X(20l . E(20) .T( lO) DIMENSION NEL(3 0 ) . IPLOTC85 ) COMMON E T t O,C t HlltH12.H21,H22tVll t V12.V21tV22tH13,H23 . ANtW , X . E CO~lMON VG. VG I . VGF. VA. VA I. VAF .VBt VOl . VBF t HG. HG I t HGF . HA t HA 1 ,HAF. HB COM MO N T.SO,H9ItHBFtHEPr . VEP l tSETAl t 8ETA2. ESCALE tFtP,UtV,Z CO MMON N,M,NN , MM,MMM,ME,INSr, I A,IO,I P R IN T , MAX I T , NEL CO M . ...,ON ~E, I TERC. r E TRACKING AND MATCHING PROGRAM SETTING UP INITIAL BEAM HANDLING S YSTEM 98 READ 61 .ENERGY ,REN,NE"W.'M 61 FQRMATC2FIO.5.213l CAL C ULAT I ON OF PART I CLE f!.OMEN T UM p=saR T (ENERGV**2+2.0*ENERGV*REN) / lOOO.O 62 FOR MA TC14HIDES!GN ENERGV.F12.5.4H MEV / 21H PARTI CLE RES T ENERGY . F IO 1.5.4H MEv . 9 H MOMENTU~.FIO . 5.6H GEV / C/ 16H NO . OF ELEMEN TS . 13) PR!NT 5 5 FOR MA T(26H INITIAL SY$T:::: M PARA ME TSRSl PRINT 50 50 FOR MA T C 6H UN 1T$/ 14H LENGTH - .... 'ETERS / 24H FIELD GRAD t EN T- GAUSS/Clvl/ 16H IFtELD - KILOGAUSS / 14H AN GLE- DEGREES) C READING IN INI T IAL SYSTEM PARAMETERS L = l K=NE 99 DO 9 I=L.K READ 13.~TCI)tQC!ltC(rJ 1 3 FORrtI AT{F4.1 tFll.4. F ll.51 rV=ET( I) GO TO(3 1 .32.34), IV 31 PRINT 4 1.1.0CI) 41 FCRMATCIX.13.15H DR!PT SPACE C (J) ==DC I) GO TO 4S 32 IF(C( I 1 )33.52.52 52 PRINT 42,1.0(1).C(1) .10H LENGTH 42 FO RMA TC IX.I 3tI5H OUADRUPOLE - FH .10H EF LENGTHtFIO.4 . 15H FIELD GRAD 1 !ENT, F12.S) GO TO 45 33 PRINT 43.I,oeIl,C(I) 43 FORMAT(IX,I3.15H OUAORUPOLE - DH ,10H EF LENGTH.FIO . 4.15H FIELD GRAD lIENT.F12.5) GO TO 45 34 RAO:P / (.02997s*ce l» ANG =D C I 1 OCI1=RAO*O CI1*.017453 93 · PRINT 44. I .o{ I) . CC !) .ANG 44 FORMAT{lX. !3.15H BENDI NG MAGNET. IOH EF LENGTH,FIO.4.15H FIELD 1 .F 12.5.14H BENDING ANGLE,FIO . S) 4 8 READ 49.BETAICI). SE TA2Ctl 49 FOR MA T c2FI0.S) 46 PR!NT 51.BETAI (I) . BE T A 2C I ) 51 FORMA T( 4 X.15H ENTRANCE ANGLE,FIO.5/4X,15H EXIT ANGLE 4 5 CONTINUE 9 CONTINUE 77 N=L M=K C COMP UTATION OF BEAM ELEMENT MATRIX COMPONENTS c IF(MMM164.22.64 64 PRINT 63 63 FORMAT(45H DRIFT LE NGTHS MEASURED TO CENTERS OF MAGNETS> 22 CONTINUE CALL ASSIGN 6 MMM =O lE=1 C READING I NSTRUCT ION CARD TO DETERMINE JOB C FOR IN5 T=1.T RACKING C FOR INS T=2.M ATCH tN G C FOR INS T= 3. SYSTEM CH ANGE C FOR INST=4.TERMINAT!ON OF PROGRAM c READ? INST. lA . 18.U.V.Z 7 FCRMAT(3t 2 .3FIO.5) GO TOCl . 2.3.4 1,INST I F C t A- 3 l 400 ,401.400 C J ELLIPSES ARE TO 8E PLOTTED AF TER ELEMENTS NELlK* 401 DO 500 ! = l.NE c 500 NE LCI)= O READ 1398.J. ( NELCKl,K=1,J) 1398 FORMA T (3012) 400 CALL TRA CK GO TO 6 2 IFCYA - 6) 3 10.301. 302 C READING IN ELLIPSE PARAMETERS FOR ELLIPSE MATCHING C HORIZON TAL PLANE 301 READ 305.HAI.HBI.HEPI 305 FORY.AT(3FIO.5) HAF=O . O GO TO 300 302 READ 306 .HAy.H8I.HEPI .HAF.H8 F 306 FORMATC5FIO.5) 300 HGI =(1.0+HAI**2 )/HSI IE =O .FIO.S) c c VERTICAL PLANE 310IFCIB - 6)210.201.202 201 READ 205,VAJ.VSI,VEPI 205 FORMA T(3FIO.5) VA F= O. O GO TO 200 202 READ 206,VAt.VBI.VEPI.VAF.VBF 206 FORMAT(5FIO.5) 200 VGI =(1. O+V AI**2)/VBI IE=O 210 CONTINUE C ALL ,..,A TCH GO TO 6 3 J F ( J A) 94.98 t 89 89 PRINT 97 97 FORMA TC 14HlSVSTEM CHANGE) 93 L= IA K=JA GO TO 99 94 P=u PRINT 92.P 92 FORMA T( 13HINEW MOMENTUM, F IO.S) L=l K=NE GO TO 77 4 CALL EXIT END 91.;. . SUBROUTINE ASSIGN OI~ENS!ON ET(30).D(30).C(30).Hll(30)'H12(30).H21(30).H22C30). I V11 (30 ) ,V12(30) .V21 (30) .V22( 30) .H13(301 . H23(JO) . XO( 10) .SO( 10) OI.'v1ENS!ON BE TA 1 (30) 'BETA2 (30) .h'( 440) ,X(20 1.E (20) . T (10) DIMENSION NEL ( JO).IPLOTCS5) CO;\i,\10N ET.D~C . Hl1.H12tH21 . H22.Vll,V12tV21.V22.H13.H23 . AN.,,Ij . X t E COMMON VGtVGI.VGF,VAtVAI.VAF.V5.V81.V8F . HG.HGI.HGF . HA ,H AItHAF t HB COMMON T ,SO.H6I.HBF.HEPltVEPI,BETAl . BE TA2. ESCA LE.F,P.U.V,Z CO~MON N.MtNN.MM.MMM.ME , INS T. IA.I8 . IPRI NT . MA XITtNEL COMMON NE.ITE~C , rE C ASSIGN c C CALCULATES (I.',ATRIX COMPONEN TS F~OM SyS TE i·..., PARAME TERS FOR BE AM C ELEMENTS N TO M C c c C C c c 101 111 124 130 129 133 131 132 DO 106 K=N,M !K=£T(K) CHOOSES APPROPRIATE SECT ION DEPENDING ON ELEMENT TYPE GO TO ( 101 , 102.105) , ! K CALCULATING DRIFT SPACE i'-1ATRIX COMPONENTS CONTINUE IF C MMM 1132.132,111 CONVERTS DRIFT LENGTHS FROM CENTER TO CENTER TO EDGE TO EDGE !P=::ET (K - l) IF(tP - l) 130.129.130 C(K)=::CCK} - D(K - l)/2.0 !FCM - Kl133,132.133 !P=ETCK+l ) IF ( I P - I ) 131 .132.131 C(K)=CCK) - O(K+l) / 2.0 CONTINUE CK=ABS(C(K) ) DCK)=::CK HI1 (K) =::1 00 H12(K'=OCKl H21 (K)=::Q.O H22(K)=1 .. O HI3(K)=0 .. 0 H23{K'=OwO Vll (K) =1 wO V12CK)=::OCKl V21 (Kl=O.O V22CK'=1.0 GO TO 106 CALCULAT!NG aUADRUPOLE MA T RIX COMPONENTS 102 CK=A9SCC(K» EK=SORTC.0029978*CK /P) XK=EK*OCK) CX=COSCXK) 5X=SIN'XK) EX=EXP(XK) REX=!.O/EX CHX=O.5*CEX+REX) 5HX=O .5';"~ C EX - REX) IF(CCK»104,I03tl03 C QUADRUPOLE-FOCUSING IN HORIZONTAL PLANE 103H l1{K) =CX H12(K)=5X/EK H2! (K) =- EK*SX H22{K)=CX H13(K}=0.O H23(K}:=O.O VI! CK)=CHX V12(K)=SHX/EK V21 (K) =EK*SHX V22(K) =C HX GO TO 106 C OUADRUPOLE - DEFOCUSING IN HORIZONTAL PLANE c 104 H11(K)=CHX H12(K)=SHX/EK H21 (K) =EK·;:· SHX H22(K)=CHX H!3(K)=0.O H23(K)=O.O Vll(K)=CX V!2(K)=sx/EK V21 (K) =-EK*SX V22(K)=CX GO TO 106 C CALCULATING SEND!NG MAGNET MATRIX COMPONENTS 105 Sl =. 017453*8ETAl(K) 82=.01 7453*8ETA2(K) RAD=P/C.02997S*C(K» ANG=O(K)/RAD CA=COS cANG) SA=SIN CA NG) SSl =S!N (Bl) CSl =cos (81) SB2=SIN (B2) C82=COS (82) T91=S81/CBl TS2 =S B2/CB2 Hl1(K ) =COS CANG- BI)/CBI H12CK)=RAO*SA 96 . 97 · HZ l CK)= - 1.O* Cl . O- TB l * T8 2)*SINCANG - B t - 8 21/CRAO * COSC B l+82» H22(K) = COS (AN G- B2) /C B 2 H13(K, =RAD*(1.O - CA1*10Q.Q H23(Kl=CSA + ( ! . O- CA)*TB21 *100.0 VI 1 (K ) = 1 • O- ANG* T B 1 V 12(K} =RAD*ANG V21CK) =- 1. O* ( TBl + TB 2 - ANG*T Sl*TB2l/RAD V22(K' = 1 .0 - ANG * T6 2 106 CONT INUE RETURN END 98 . SUBROUTINE TRACK DIMENSION ET (30).0 (30) .C(30) .HIt (30) .Ht2( 30) ,H21 (30) .H22(30). tV11 (30) ,V12(30) ,VZl (30) .V22{ 30 1 ,HI3 (3D> tH23(30, . XQ( 10) . 50 (10) DIMENSION BE TAl(30)'SE TA2 C30).W(440) . X(20) t EC20, . TClO) DIMENSION NEL(30),YPLOT C85) CO MMON ETtO t C ,Hl1.H12,H2ItH22.Vll,V12tV2 1,V22tH13 t H23 , AN,W , X, E CC r.'r,'vlON VG,VGI,VGFtVAtVAl.V/...F,VS,VSI . V8F , HG . HGr , HGF,HA t HAI , HAF , HB COM~ON T,SO,HBttHBFtHEPI,VEPI,eETAl.8ETA2 .ESCALE , F , P , U , V, Z CQr-'IMON N.M,NN.MM.MM .... 1,1\1E, INST , lA . 1St I P R I N T . MAXI T, NE L COMMON NE.!TERC,tE c DA T A INULtIDOT,rSTAR/' '.'.' , '*' / C C PRINTING HEADINGS FOR T RACKING RESUL T S D1=0.0 IP=l i IFCI8)232.2 3 2t233 232 PRINT 203 203 FOR MA T C17HIHORIZ0NTAL P LANE) GO TO 2000 233 PRINT 204 204 FORMAT ( 15HIVERTICAL PLANE) 2000 CONTINUE C lA =O FOR TRAJECTORY TRACKING C IA = 1 FOR TRAJECTORy PLOTTING C lA =2 FOR ELLIPSE TRACKING C IA=3 FOR ELLIPSE PLOTTING C IA=4 FOR BEAM ENVELOPE TRA CE IG = IA+l GO TO ( lOt I 1 t 1 2. 12 t 12 t 13) • I G 10 PRINT 201.2 201 FORMA T (29H TRA J ECTORY TRACKING AT DP / P =.F7 . 3> PRINT 208 DISTANCE DISPLACEMEN T PRINT 42.D!.U.V 42 FORMAT(4X.FIO.5.4X.2FIO.5) GO TO 241 11 PRINT 200.Z 200 FOR MA T (29H TRA J ECTORY PLOTT I NG AT DP / P = .F7 . 3) PRINT 198 198 FORMA T ( // . 3 8H lORY PLOT) IP=O GO TO 241 12 EP=Z Z= C 1 • o+u-:..;:;-2 1 /V XM =SQ RT (EP-lI-V) SM=SORTCEP*Z> IFCIA - 3)22.241.24 DIST ANCE DISPLA CEMEN T SLOPE ) $ LOP E.35X. 15HTRAJE CT c 22 PRINT 309,EP 309 FORMA T (17H ELL IPSE TRACKING/IIH EM ITTANCE ,FIO.5) PRINT 1382 1382 FORMAT(57H IX) 25 PRINT 1301 ,Z.u.V.XM,SM 1301 FOR MA T (9x.6FIO. 5) GO T O 241 24 PRtNT16D6.EP GA MMA ALPHA BETA 1606 FORMAT C20H ~~AM ENVELOPE TRA CE/ IIH EMI TTANCE .FIO.5) PRINT 1600 1600 FQRMA T C95H I X IP = Q GO TO 241 13 PRINT 1700 GAM MA ALPHA SEAM ENVE LOPE) 17 00 FORMA T(27H TRANSFER MATRIX COMPONENTS/6tH T2 1 T22 T13 T23) BETA T11 99 . DMAX C INITIALIZING MATRIX MULT I PLI CATION BY SETTING UP UNIT MATRIX 241 011=1.0 DI2=O,O D21 =0.0 022 = 1.0 D13:::0,O 023 =0,0 01 =,,20 EI = .O D15 T= 0.0 015 =-01 KM=l SMA SMA TI2 C THI S LOOP COMPUTES TRANSFER I'I,A TR IX. THEN DOES REQUESTED TRACKING .JOB 00257 L= 1 ,NE IFe IP)271.249.271 C IP=O FOR PLOTTING AT POINTS INTERIOR TO MAGNETS 249 OD=O( L l IV=ET(L) 0027 0 K= l.lOO B =K EL=( B- l.Ol*OJ+EI OV=EL - OD KM=K IFCOV1270.271.2 71 270 CONTINUE 271 00272 .J=loKM IFCIP)266.101.266 101 RR =J IFC.J - KM1 220.221.221 2200(Ll=(RR- l.0)*OI+EI DIS= D I S + D I GO TO 222 221 D(L)=DD 222 IV=ET(L) IF(IV - l )8887,8889,8687 8889 C (L ) =0 (L ) 8887 CONTINUE N=L M=L CALL ASSIGN 266 1F(!B)244.244 , 248 C MATRIX MULTIPLICATION - HOR I ZONTAL PLANE ~ 244 Cl1=Hl1(L)*Dll+H12CL)*021 C 12:Hl1(Ll*D12+H12(L)*D22 C21=H21(Ll*011+H22CL1*D21 C22=H21(Ll*D12+H22{Ll*022 C13=Hll (Ll*D13+H12{Ll*D23+H13CL) C23 : H21 (Ll*D13+H22( L l*D23+H23< L l GO TO 250 C MATRIX MULTIPLiCATION- VERTI CAL PLANE 248 Cl1=VllCL1*Dll+V12c L l*D21 C12=Vll( L l*DI2+V!2CL1*D22 C21=V21(Ll*Dll+V22(Ll*D21 C22=V21C L 1*012+V22( L l*D22 CI3=0.0 C23=0.0 250 CONTINUE IF (IP l 104.290.104 290 IF(J- KM1297.272.272 29700291 1=1.85 291 I PLOT ( I 1 = I NUL 104IFC!A - 111250,1250.t300 1300 IFC!A - 511353.1800.1800 C C TRANSFER MATRIX COMPONENTS c 1800 PRINT 1801,L,Cll.C12.C21.C22.C13,C23 1801 FORMATCIX.I2.6F10.5) GO TO 272 C CALCULATION OF ELLIPSE PARAMETERS C 1353 GA MM A=C22**2*Z-2.0*C21*C22*U+C21**2*V ALPHA= _ C12*C22 * Z+(Cll*C22+C12*C21>*U - Cll*C21*V BETA=C I 2 **2*Z- 2 . 0*Cll*C12*U+Cll**2*V XM=SQ RT(EP-l:- BETA) SM=SORTCEP*GAMM A) IFCYA - 3l390.39S.1500 C BE AM ENVELOPE PLOTTING 1500 XM=tO.O*XM 100. IFeXM - 3 0 .0l1390.1390,172 1390 NX=Xr-l GO TO 173 172 NX=80 173 XM=.1*Xt>1 I PLOT C 1 ) = I DOT IPLOTCNX)=ISTAR 101. 1391 PRINT 1392, L tOIS.GAMMAtALPHA.BE TA, XM,SM,( IPLOTCKKl , KK = l t 30) 1392 FORMATCIX,I3,F5 .1. 5FIO.S ,20Xt30Al l IPLOT CNX) = tNUL GO TO 272 c , C ELLIPSE PLOTTING 398 CONTINUE 00 t 399 I 1 = 1 • NE IFC L-NELCII»1 399 .1397.1399 1/399 CONT! NUE GO TO 265 1397 CONTINUE N2=1 Nt = ! DO 350 r =1 .85 350 IPLOT(!)=INUL IFCXM - SMl322.322,323 322 TM= SM GO TO 324 323 TM=XM 324 TM = 2.0·~ T M VI :::TM/ 25. 0 H! =TM/ 42.0 120 FORMATC!H!.I3.SH GAM MA, FtO.5.8H ALPHA.FtO.S.7H BETA,FIO .S/ tO IH EMITTANC E.F tOtS'ISH MA X. D ISPLA CE MENT,FtO.5_11H MAX. SLOPE.FtO.S 2 ) PRINT 32S,Hl .Vl 325 FORMAT(6H UN I TS/ 23H ABSCI SSA - ONE DIVISION .F IO.S . 3H e M/23H ORQINAT IE-ONE DIVISION .FIO.S. 8H RAD/lOOl DO 399 K=1.51 !PLOT(43l=IDOT tF(26 - K)307.308.307 30800 319 J=1. 85 319 IPLOTeJ) = IDOT 307 RK=26 - K s=eTM*RK)/25.0 0=4. O-~ALPHA~·-'1:·2*S**2 -4. O*GAMMA* C BE T A*S**2 - EP) IFeO)301.392.392 392 O=SORT CO) Xl=e - 2.0*ALPHA*S+0) / C2.0*GAMMAl X2=( - 2.0*ALPHA*S - O)/(Z.0*GAMMAl c Nl=Xl/TM*42.0+ .~ N2=X2 /Ti-'l*42. 0+; 5 ':' Nl=43+N1 N2::= 4 3+N2 IPLOTC N! }=ISTAR !PLOTCN2l=ISTAR 301 PRINT 305.CIPLOTeJJ) .JJ= 1.85) 305 FORMA T C1X.85Al) I PLOT C N 1 ) = I NUL IPLOTCN2)=lNUL rF(26-K)399~362.399 36200363 J=1.85 363 IPLOTeJ)=INUL 3 99 CONTINUE GO TO 272 C i ELLIPSE TRACK!NG 390 PRINT 31So L .GAiv',MA.ALPHA.BE TA,XM.SM 315 FORMATCIX . I345X.5FtO.5l GO TO 272 C CALCULAT ION OF PARTICLE DISLACEMEN T AN D SLOPE 1250 R=Ct1*U+ C1 2*V+C13* Z S =C 2t*u+C22*V+C23*Z IFCIP)2520400.252 c C TR AJECTORY TRACK ING C CALC ULA T !ON OF SYSTEM LE NGTH 252 DIST=DIST+OCL) c 274 FORMA T CIX. I3.FIO.5.4X.2F10.5) GO TO 272 C TRAJECTORy PLOTTING 400 IPLOT(43) = IDOT Y=ABSCR} IF(Y - IO .S)t200.!20 0 .272 1200 R=4. O-:;::-R NX =R+43 .. 0 R=.2S*R 1202 IPLOTC NX)=ISTAR PRINT 292.L.DIS.R.S. (tPLOT{KK) .KK=l . 85 ) 292 FOR MA T(!X.I3,FIO.5.4X.2FIO . S.85Al) IPLOTC NX) = INUL 272 CONTINUE EI=OV 265 Dll=Cll D12=C12 021 =C 21 102 . D22=C22 D13=C13 D23:::C23 257 CONTINUE RETURN END 103 . 104. SUBROUT!NE MATCH DIMENSION ET(30),DC30)'C(30)tHIIC30). H12(30).H21C30) .H22(30), 1 VII (30)' V12 (30) . V21 (30) ,V22 (30) .HI3 '3D) ,H23(30} .XQ! 10) .50 (10) DIMENS!ON BE TAIC30" SETA2(30).W(440).X(20) , E{20).TCIO) DIMENSION NEL(30).IPLO T C851 CO MMON ET.O' C . HI! .H 12.H21 ,H22.Vll ,V12,V2ItV22.H13.H23.AN.t'J.X.E COMMON VG , VGI,VGF.VA.VAItVAF.V8,VBI,VBF.HGtHGI,HGF.HA ,H AI ,HAF,HB CO MMO N T t 50, HB! tH BF ,HEP! ,VEP I t BET A 1 .SET A2 .ESCALE. FtP tU,V , Z COMMON N,M.NNtMM,MM~'ME .INST.IA.IB.IPRINT,MAXIT.NEL CO Mr1 0N NE,I TE RC.JE C MATCHING IS TO 8E DONE FOR ELEMENT NN THROuGH TO ELEMENT MM 400 NN=U C DETERMI NATION OF VARIABLE PARAMETERS c ME=O 00410 !=NN,MM !V =ET (1) ES=IV EEE=ET ( I ) - ES IF (EEE) 401 .4 10.401 401 ME =ME+l NEL{ME)=I 410 CONTINUE C DEF INlNG XCI) AND E(I).IPRINT.ESCALE,MAXI T. N FOR VA04A DO 1 402 t = 1 • t-1E c CO~~~~~~~~ OF XCI ) ARE THE INITIAL SYSTEM VARIABLE PARAMETERS xn )=CCK) IV=ET (K) IF(IV - 1)499.498.499 C ERROR ALLOWANCE FOR DRIFT LENGTHS 498 E( r )=.001 GO TO 1402 C ERROR ALLOWAN CE FOR OUADRUPOLES 499 E (I) = 0 1 c c c c 1402 CO NTINUE IPRINT=2 ESCALE=100000. 0 MA XYT=40 N = fl.1E VA04A ATTEMPTS TO FIND MINIMUM OF ERROR FUNCTION(DEFINED IN CALCF) CALL VA04A PRI NT OUT OF RESUL TS OF MATCH ING PRINT 9999.IA.JB 9999 FORMAT(17HIMATCHING ROUTINE.213) PRINT 496,NN,MM 496 FORMAT(30H MATCHING SECTION FROM ELEMENT ,I 3 , 3H TO.13) PRINT 1401 . CNELCKK).KK=I, ME ) 1401 FORMATC18H VARIABLE ELEMENTS.9I3) PRINT 900 900 FORMAT(36H FINAL VALUES OF vARIABLE PARAMETERS ) 00 1403 !=l.ME K=NEL ( I ) IK=ET{Kl IF( tK - l )20 0.200.202 202 CCK)=XC I) GO TO 1403 200 CCK) =ABS(X(I}) 1403 PRINT 1404.K.C(K) 1404 FOR~AT(lX'I3.FIO.3) PR I NT ! 1 11 ,SO ( 1 ) ,SO (2) ,SO C 9) • SO (3) • SO C 4) • SO ( 10) 11.11 FORMA T (24H FINAL MATRIX COMPONEN TS/17H HORIZON TAL PL ANE /3F15.5//3F 11505) PRINT 1112 .S0 CS),SO{6),SOC 7).SOCS) 1112 FORMATCISH VERTICAL PL ANE / 2F15.5//2 F 15 .S) IFe 1£)70. 7 1. 70 71 PRINT 72 72 FORMATC19H ELLIPSE PARAMETERS.tSX,48H GAMMA ALP J HA BE TA EM) 70 CONTINUE IF! IA - 6)600.601 .601 601 PRINT 602.HGI.HAy,HBI.HEPI,HG,HA, HB 602 FOR~AT(34H HORIZONTAL PLANE INITIAL.I4X.4FIO.5/26X.6H FIN 1 AL , 16x ,3Fl 005) IF(tA-7 )600~700.600 700 HGF = ( I 0 0+HAF';::'*2) /H8F PRINT 70I.HGF.HAF.HBF 701 FOR~A T (26X.I0H REQUESTED.12X.3FIO.5) 600 IFCTB - 6)603.604.604 604 PRIN T 605.VGI.VAI,VST .VEPI .VG.VA.VB 605 FORMAT(34H VERTI CAL PL ANE INI T IAL.14X.4FIO. 5 /2 6X . 6H FIN 1 AL .16X .3Ft 0.5) IFC!B - 7)300 .S0 0 .300 SOD VGF=( 1 oO+VAF';H:'2}/V8F PR!NT 80t.VGF,VAF,VBF 801 FORMA T( 26X .IOH REQUESTED.12X.3FIO.5) 603 CONTINUE 300 CONTINUE ITERC = ITERC - l PRINT 1000,ITERC.F 1000 FORMATCIX .IIH ITERATIONS.I3 . 6H ERROR.FI2.8) RETURN END 106. SUUKLJJT! "..IE VA04A [) I .",t ,\J$ ! UN ET (30 ) , IJ ( 30 I ,C ( 101 1 H 11 ( 30) ,.-l12 ( 30) , HZ 1 (30) , liZ 2 ( 30 ) , IVii( 30) ,V1 2 ( 30 1 ,VZ1l3()} , V2.Z(30),H13 (3 0 } , H23 (3 0) , XQ( 10) , SO ttO} D I ~c;\lS10'\i GtTAl(301 , i)ETAZ(30) , h( 440) ,X(20) , E{ZOI ,Tt 10) O I i-1E.\lS I ON r\t:L (30), I PLUT{tlS l CC~~ON ET, D,C,H ll, H12 , H2 1, H22 , Vll , V12 ,V21,V22,H13,H23,Ar!, W,X, E COM~a\ VG,V~I ,VGf,V A . VA I ,V ~F,VO ,V G I,V B F, HG,HGI , HGF , HA ,H~I ,HAF , H6 CO~~l]N T,S O,Ha! ,H 3F,HEPI ,VEP1, dE TAl,BETA2,£SCALE , F , P , U, V, l COM~)~ N , ~,N~ ,~M , MMM , ~E ,I N ST,IA,IB,IP~INT , MAX IT , NEL CO.'-l~10~ NE,lTER C,IE PkINT 2001,N,lPI~INT,M~XIr,ESCA L E 2001 fORMAT{2Hl~,I3,7h IPRINT,I3,6H MAXIT,I3,7H ESCALE , FIZ . ll OD.'lA G=O.l"ESC ALE sce"=O.OS/ESCALE JJ-=N~":,\+N AA.lJ.A -=3 . K= N+l ~ FCC=l 00 1 I-= 1 , N DO 2 J-= 1, N .. ~ (K) = 0 . IF{I - J}4,3,4 WI K l=E I r) \.;I! I=ESCA LE 4 K-= K,..l 2 CO~T!NUE 1 CO.\T! NU E lTERC=l I SGR,\O=2 CALL CALCF ITO i>l E=l FP=F SU .~ "O. IXP"JJ 00 6 1·=1, 1\ IX P=IX?+l >il lXP I=Xll 1 6 CONTINUE IDI RI\J =N+l ILl:,E"l D.~;'X = ·,} I I LI NE 1 DACe =O J\lAX * SC ER GO TO ( 70,71),ITGN= 70 D~AG=AM T N l{JOMAG , O .l*DMAX ) OMAG=AMAXl(OMAG,20 . 0*OACCl OL =O. G=D MA G FPR"V =f I S=5 DD.'I~ X= I O . "D,'~AG f-A=F O~=JL OD =C- DL OL =G Sci K= IDI,,'J Oil 9 I = I , N x{] )=X{] )+DD*I/{K ) K,. :::K+l 9 CO~TINUE CALL CALCF NFCC=NFC C+I GO TO tlO,ll,lZ,13,14,961,IS 14 IF{F- FAl15,16,24 16 IF(G-O~AX)17t17t18 17 G=G+ G GJ TO 8 18 PRINT 19 107. 19 FORMAT (5X , 44HVA04A MAX I MUM CHANG E DUE S KO T ALTER FU NCT ION) GO TO 20 08 =G GD TO 2 1 24 f5 =FA DB =OA FA=f OA -=G 21 GO TO (S3,23),]SGRAO 23 G=llH+llS - OA IS=I GO TO 8 83 G = O .S*{DA+Db - {FA -F6)/{D~-DB» I S=4 ]F{ (DJI- G)"IG- D3) )25, 8,0 25 ] S= I ] F (AdS{ G- DB ) -DD:~AX)3 ,8,26 26 G= U3 +SIGN{ODMAX , Dd - DA ) IS=l DO~AX = DDMAXt DDMAX IF{DO~AX-DMAX ) 8,B ,27 27 DDMAX =DMAX GO TO 8 13 ]F{F - FA)2 8 , 23,23 28 Fi: =FB DC =Dd 29 FB=f DB =G CO TO 30 l2 1f'IF- FB I28,2d,3l .)1 FA=F GO TU 30 11 IFIF- F3132 ,1 0 ,1 0 32 f'A=F d OA=Jtl GO TO 29 7l OL =l. DD,'-L\X ; 5 . FA-=fP OA =- I . FG=FHOLD 08=0 . G= 1. 10 FC =F OC=G 30 AL=I OB- OCI*IFA - FCI ~= IOC-DA I *IFB-FC) IF I I Al + 8 ) * l OA- DC 1 ) 33 , 33 , 34 3 3 FA =F8 DA=D8 FG =FC Od =OC GO Tn 26 34 G=0 . 5'IAZ*1 03 +0CI+ G*IOA +OCII /IAZ+31 Dl =DG FI =F3 IF{Fd- FC)44,44,43 43 DI =DC Fl =FC 44 IF (AeS{G- Dl } - DACC) 41,41,93 93 IF IAaSIG- DII - O.03*AtlSIGII 41,41,4 5 45 IF I IDA- ilC)*IOC - GI) 47 , 46,46 46 FA -= FB D,\ =Jil FG =FC DB =DC GO TU 25 47 15 =2 I I' I I Od- G) * I G- OC 1 14 8 ,8 , 8 48 I S= 3 GO TO 3 41 F=Fl G=DI - OL OO =SQRTIIOC- DG)*IO C- DAI*IDA- DBI/IAZ +B» 00 49 1 = 1 , N 108 . XI I I=XI I I+G>;H lOIRNI ~\'(IOI-l.\Jl=I)[H~J {I DIRJ\) 101 ,',C\r= I f) 1 RN+ L 49 CONTI" lUE hi! L I :,,, I = \': I III NE I 1 00 Ill~E=ILlNHI ! F ( I ?i{! NT - i) 51 ,50 t 51 50 PRI.'JT52, ITERC,NfCC,F,{X( 11 ,1 = 1,~ ) 52 FO~MATIIX , 9rlITERATION,I5,I15,16H FUNCTION VAL UE S, IIOX.3HF =.EZI.I'./15EZ4 . 141 1 CO TO{51,:;3) ,I P.'INT 51 CD L.i 155,38l,ITONE 55 1~IFPMEV- F - SUMI94.g5.95 95 SU,~ =FPREV- F JIL=Ill NE 94 IFIIJIRN- JJI7.7. 84 84 FHOLO=F IS =6 I X P= J J DO 59 I = l,N IXP= IXP +l h' IIXP)·=X( l) - W(IXP) 59 CONTINUE 00 =1. GO TO 58 96 G=O.5/I FP+F- 2.*FHOlOI IFIGI92.92.57 ,57 IFISJMOGOIFP - FI •• Z- IFP - SUM- FHOLOI··2137.92.92 92 J = J!L*>~+l IFIJ - JJ 160.60.61 60 DO 62 I=J.JJ K= [ - N WIKI=,JlII 62 CONTINUE DO 97 I =JIL, N ,,( I- l)=I, I!l 97 CO NT INUE 61 IDI~N = ID I RN- N lTONE=2 I SGRAD=2 K = IllIR~ IXP=JJ AAA =O. DO 65 I = I.N IXP = IXP+I i-. (K) =\..j { I xr 1 I ~ I IlAA- 1I ~ S I ,II K liE I II 1 166. 67.67 661\IIA=ARSIWIKI/EIIII 109. 67 r,.;:K+l 65 CO.~T I.'WE D:)."'iAG= 1 • filNI~ESCALE!AAA I LlNE~,~ GO Tn 7 37 IXP~JJ AA,l·= O . F~f-HOLD 00 99 1;I . N IXP=!XP+l XIII ; XIII - HIIXPI IF{.l.~A*E( II - AoS{I",I{ IXP) l )98,99 , 99 93 AAA;ABSliH IX?I!EI]JI 99 CONTINUE GO TO 72 38 AIA ~ AAA"1 1.+011 72 IF(IP~INT-2)53 , 50,50 53 I TERC~lTERC+ 1 IF{ l\/I.;:'- 2 . }8Y,8<J,76 t\9 IF(A.\I\A - 2 . ILO , 20 ,76 20 r{[TU4.i~ 76 IFtF - FPI35,73,7d 78 ?RI~T 80 dO FGR~AT (5X , 37HVA0 4A AC CURACY LI MITED av E~RORS I N F) GO TJ 20 35 DD~AG~0.4.SQRTIFP- FI ISGHID:l Af:,.AA~4.t1.,A IFIITERC - MA XITI5.5.81 81 PRINT 82.MAXIT 82 FORMATII5.30H ITERATIONS COM? LETED BY VA04AI GO TO 20 f::ND 110 . c 111. SUBROUTINE CALeF DIMFNS ION ET (30) , 0 (30).C (30) . HI t (30) tH12 (30) ,H21 ( 30) tH22 (30). tVt 1 (3D) .V12(30) .V21 (30) .V22(30) .H13(30) .H23(30) .XO( to) . SOC 10) DtMENS tON BE TAt (30) . BETA2 ( 30) . W(440) .X(20).E (201. T (10) DIMENSION NEL(301 .IPLOT(85) COMMON ET.D.C.Hll,H12.H21.H22.Vll . V12.V21.V22.H13.H23.AN,W,X.E COM:>10N VG.VGI .VGF.VA,VAI , VAF.V B ,V8 1 ,V8 F,HG, HGI ,HGF,HA,HAI ,HAF,HB COMMON T,SO,HBI,HBF.HEP I ,VEPI.BETA I ,BE TA2. ESCALE.F,P.U.V,Z CO MMON N.M,NN.MM,r·~MMtr-1Et !NST. lA. lB. IPRINT,MAXlT,NEL COM MO N NE.ITERC.!E C CALeF DEFINES AND COMPUTES ERROR FUNCTION TO 8E MINIMI ZED BY VA04A c C CALC UL ATION OF IVlA TR Ix C OMP ONEN TS FOR VARIABLE ELEI'\r1ENTS USING C CURRENT VALUES OF VARIABLE PARAMETERS c DO 635 JJ=l.ME K=NELfJJ ) CCK)=XC")J) 625 N=K M=K CALL ASSIGN 635 CO NTINUE N= ME C MATR!X MULTIPLICATION OF MATRICES IN MATCHING SECTION XO ! 1 }=1 .. 0 XQf2'=0 .. 0 XO(3' =0.0 XQ(4}=1.0 XQfS)= 1 .. 0 XOC6} =O .. O XOf7' =O .. O XO (8) = 1 .. 0 XOf9' =0 .. 0 XO( 10 ,=000 00416 L =NN.MM SO (1) =H l1 (L) ~"'XO C 1 ) +H12 f L )-i:'XO (3) SOC21=HIICL'*XOC2l+ H12 CL1*XO(4) SOC31 =H21 (Ll';:'XOCl 1+H22{ L, *XOC31 SOC41=H21CL'*XO{21+ H22CLl*XO(4) SOCS1=VIIC L1 *XOCS1+V12 CL1*XO(7) SOC6, =VIIC L )*XOC6}+V12CL1*XO C81 SOC7l : V21( L' *XOCS'+V22(Ll*XO(71 SO(81 =V21CL,*XO(6)+V22CL1*XO(B) SOC91 =Hll(Ll*XO(91+H12C L1*XO( 101+H13( Ll SO(lO)=H21(L}*XOC91+H22(Ll*XO(lO)+H23(L) 00430 J=I,10 430 XO( ")l= SO C") 416 CONTINUE 112 . NC =l DEFINING ERROR FUNCTION FOR MATCHING ROUTINE SPECIFIED BY IA,ta COMPONENTS OF T VECTOR ARE QUANTITIES THAT ARE TO BE SET TO ZERO IFCIA - 5'300.301.302 300IF(!A)10 . 1!.lO C FOR IA=O TRIES TO FIND DISPERsrONLESS SYSTEM 11 T( NC)=SO(9) NC=NC+t T (NC ) =50 ( 10) GO TO 305 FOR IA=1.2.3.4 TRAJECTORY f./',ATCHING 10 TCNC1=SO{ IAl GO TO 305 FOR IA=5 TR I ES IO FINO IDENTITY SYSTEM 301 TCNC) = SO( 2) NC=NC+l TCNC)=SOC3) NC=NC+! T (NC) = 1 .. O- ASS (SO (1 ) ) GO TO 305 C CALCULATION OF ELLIPSE PARAr""ETERS FOR ELLIPSE MAT C HING P 302 HG =XO(3)**2*HBI - 2.0*XO(3)*XO(4l*HAI+XQ(41**2*HGI HA= - XQCl '*XO(3l*HBI+(XO(ll*XO{4'+XO(2l*XO(3J)*HAI - XO(2l*XO(4l*VGr H8=XQ(!l**2*HBJ - 2 .. 0*XOCll*XO(2l*HAI+XQ(2l**2*HGI tFCIA - 6)303.303.304 C FOR IA=6 TRIES TO SET ALPHA TO HAF=O.O C FOR !A=7 TRIES TO SET ALPHA TO HAF.BETA TO HBF 304 TCNC)=HB - HSF NC=NC+I 303 T( NC 1=HA - HAF I F IB =O NO MATCH!NG IS DONE IN VERTICAL PLANE 30S IF(tB)12,40S.12 12 NC=NC+1 IF(IB - S}400.401t402 C FOR la=1.2.3.4 TRA~ECTORY MATCHING 400 T (NC) = SO(18+~) GO TO 405 ~ FOR 18=5 TRIES TO FIND IDENTITY SYSTEM 401 TCNC1=SO(6l NC=NC+l T(NC1=SO(7) NC= NC+l T CNC1 =1.0-ABSCSO(S,) GO TO 405 C CALCULATION OF ELLIPSE PARA~ETERS FOR ELLIPSE MATCHING 402 VG=XOC71**2*VBI-2. 0 *XO(7l*XOC81*VAT+XOCB1**2*VGI VA= _ XOCSl*XO(7l*var+(XO(Sl*XOCS1+XO(61*XO{7)*VAI - XOC6l*XO(B, *VGI V8 =XOCSl**2*V8I-2.0*XO(Sl*XO(6l*VAI+XO(61**2*VGI IFC IB- 6 )403.403.404 C FOR 18 =6 TRIES TO SET ALPHA TO VAF =O.O C FOR 18 =7 TRIES, TO SE T ALP HA TO VAF. BE TA TO V8F c 404 T (NC ) =VB- VBF NC=NC+l 403 T CNC)=V A- VA F 405 CONT INUE ~ ERROR FUNCT I ON I S THE LENGTH OF THE T VECTOR 6 26 ER ::: O.O DO 627 J L ::: 1 .NC A::: T(JL ) p2 7 ER ::: ER+ A**2 ER=$Q RT ( ER) F::: E R RETURN END 113· 114. APPENDIX VIII: SAMPLE PROBLEM The sample problem chosen illustrates all of the facilities available in the TRIUMF tracking and matching program. A list of the input data cards appears on page 118 Data cards 1 to 17 specify a 14 element 300 dispersionless bending system described by A. C. Paul (1954) . The information contained on these cards is read in according to the schemes outlined in sections V . 1.,1 and V.!. 2 and is printed out on page 120 . Data cards 18 and 19 request a print out of the transfer matrix components at the exit of each of the 14 elements in the vertical and horizontal planes respectively. The results are shown on pages l21and 122. I nspection of the matri x components for the vertical plane shows that the system sat i sfies the parallel-to-parallel condition (T2l = - 0 . 00086) at the exit of element 14 and of course is dispersiouless in this plane (T13 = T23 = 0 . 0) . These matrix components agree to 3 significant figures with those given by Paul as is shown below. Component TRIUMF Results Paul's Results T11 -0.99558 - 0.996 T12 10 . 21587 cm/rad 0.402 in/ mr = 10.21 C'¥'toad 100 T2l - 0.00086 r~1Ycm -0.018 mr/ in = 0.001 r~1Y cm T22 -0.99558 - 0.996 115. I n the horizontal plane we see that the system is dispersion-less to a high degree of accuracy as T13 = 0 . 03839 and T23 = 0.01048. Data card 20 requests trajectory tracking in the horizontal plane for a particle with initial displacement . 5 cm. and initial slope . 5 rad./IOO and zero momentum deviation . The output is shown on page 123. The second column gives the distance in meters al ong the optic axis to the exit of each element in the system so that we see the total length of the system is about 7.88 meters. Data card 21 requests the same job as above except that dp/p = 0 . 01. The results are shown on page 124. Comparison of the final displacement and slope (-1. 57012 cm . , - 0.97872 ;aodo ) wi th those on page 123 (-1 . 57050 cm ., - 0.97883 ; aodo ) shows that the system is effectively dispers i onless for this momentum deviation . Data card 22 requests a plot of the same trajectory as above and the output is shown on page 125. Data card 23 requests ellipse tracking in the vertica l plane for a phase space ellipse with initial coefficients a o = 0.0, ~o = 33 . 866 cm./rad . / lOO, and an emittance of . 01493 cm . The output is on page 126. Columns 5 and 6 give the maxi mum displacement DMAX (cm.) and maximum sl ope SMAX (rad./lOO) of any particle in the beam. These results agree with those given by Paul for the exit of the system. His results are a final maximum displace-ment of 0.29 i n = 0.74 cm . and final maximum slope of 116 . 0 . 21 mr = 0 . 021 r ad./100 as compared to 0 . 73648 cm . and 0 . 02091 rad./100 f or the TRIUMF program. Data card 24 requests a beam envelope trace for the same initial ellipse as above and this is shown on page 127 . Data card 25 r equests matching to a dispersionless system in the horizontal plane and matching to a parallel -to - parallel condition to the vertical plane . The print out from subroutine VA04A which always precedes the print out of the matching results is shown on page 128. Page 129 shows the results of the matching attempt. Because the initial beam transport system essentially already satisfied the matching requirements the iteration procedure quickly converged (3 iterations) to the solution shown . Data card 26 r equests a change to a completely new beam transport system. Data cards 27 to 36 specify an initial gues sed system of fixed length 40 meters and of design energy 500 Mev as shown on page 130 . Data card 37 requests matching to an identity system . The result on page 131 shows that the iteration procedure found the solution minus one times the unit matrix in both planes. Data cards 38 and 39 request the graphing of one ellipse at the exit of the 9th (last) element of the system . The initial ellipse coefficient are ao cm. /r~go and emittance .022 cm . ~~g · - 2 . 0 , ~o = 2 . 0 As expec ted for 117. an identity system the results on page 132 show that the f inal ellipse is practically identical with the initial ellipse . Data cards ~O, ~l and ~2 r eques t ellipse matching to a waist or bust in the horizontal. plane and ellipse matching in the vertical plane to an ellipse with requested coefficients a r = 2 .0 , ~ r = 2 . 0 cm. /r~go In both planes the initial ellipse is taken to have coefficients ao = 0 . 0, ~o = ~.O cm. /r~go and an emittance of . 022 cm. f~g· Thus with the identity system as an initial guessed system the program after 7 iterations arrived at the solution shown on page 133 Data card ~3 requests that the design momentum of the system be changed to 0 . 95423 Gev. / c (corresponding to an energy of ~OO Mev .). Data cards ~~ to 51 request that the drift lengths between the quadrupole magnets be changed to 7 . 0 meters so that the total system length becomes 30 meters. Data card 52 requests matching to an identity system in both planes. The resul t shown on page ll~ is that the program created a 30 meter identity system f or ~OO Mev . particles . Data card 53 requests trajectory tracking in the vertical plane. The result is shown on page 135· Data card 54 reque sts termination of the program. The time f or compilation and execution of the program is given as 5.~6 minutes. us . DATA CARDS FOR SAMPLE PROBLEM 550.0 938.2 14 a 3.0 14.9 15.7 2 . 0 .0 3 1.0 .3048 4 2.0 .4318 - 548.622 5 1.0 • 301 8 6 2.2 .4318 400.197 7 1.0 1.3208 8 2.1 .4 064 422.4409 9 1.0 1.3208 10 2.2 .4318 400.197 II 1.0 .3048 12 2.0 .4318 - 548.622 13 1.0 .. 3048 14 3.0 14 .9 15.7 15 .0 . 0 16 1 . 0 . 6096 17 5 1 18 5 - 1 19 1 0 - 1 .5 .5 .0 20 1 0 - 1 .5 .5 .01 21 1 1- 1 .5 .5 ,01 22 2 1 .0 33.866 001493 23 1 4 1 .0 33.866 .01493 24 2 0 3 1.0 14.0 25 3 26 500 . 0 938. 2 9 2 7 , 2.3 .25 - 100.0 28 1.0 9.5 29 2.2 .50 100.0 30 1.0 9.5 31 2.2 .So - 100.0 32 1.0 9.5 33 2,,2 .50 100.0 34 1 .0 9.5 35 " 2.3 .25 - 100,,0 36 2 5 5 1.0 9.0 3 7 1 3 1 - 2.0 2 . 0 . 022 38 1 9 39 2 6 7 1.0 9.0 40 0.0 4.0 .022 41 0.0 4.0 . 022 2 . 0 2 . 0 42 3 - 1 095423 43 3 2 . 44 1.0 7.0 45 3 4 46 1.0 7. 0 47 3 6 48 119 . 1 . 0 7.0 49 3 8 50 1 . 0 7.0 51 2 5 5 1.0 9.0 52 1 0 1 . 5 .5 . 0 5 3 4 54 DE S I GIJ UIEP,G Y 550.00000 i'l [ V PARTICL E REST ENERGY 938.19995 MEV MO~ENTUM NO. OF I:lEHEN1S l it 1 .15521 GEV/C I NITIAL SYSTEM PARA 4~ T ER S U,\ IT S L[NCIH-MEHRS FILLD GRAD I EN T-GAUSS/CM t-I El D-KILO GAUSS ANGLE-DEbREES I BENDING MAGNET EF LENGTH ENTRANCE ANGLE 0.0 EXIT ANGLE 0.0 2 DR IFT SPACe LENGTIl 3 QUAOMUPOLE-DH [F lFNGTH DR I fT SP AC E LENG TH QUA DRUPOLE- Fil Ef l ENGTH 6 OR I F T SPACE l ENG Til 7 QUAD RUPO LE-FH EF LENGTH 8 DR I FT SPACL LENGTH 9 QUAiJRUPdLE-FH FF LENG Til 10 DR IfT SP ACE LENG TH II QUADRUPUlE-OIl EF l ENGTH 1 2 URIFT SPAC E l ENGTH 1 3 BEND I NG MAGNEI EF LE NGTH ENTRANCE ANG LE 0.0 EXIT ANGLE 0.0 14 DRIFT SPAce LENGIH 0.6383 FIELD 15.70000 BE10 l NG A~GLE 0.3048 0.4 318 FI ELD GRADI EN T -5 /, 8 .621 83 0.3040 0.~310 FI ELD G~AU I EN T 400. 196·'0 1. 3200 0.406'< FIFLD GRAO TCNT 422. 1''10 67 J .3<'0 3 0 .~3 1 8 FI ELD GRADIENT 40 0 .1 9670 O .. 3()/I B 0.431 8 F1Ll D GRAD IENT -548.621 83 0 .. 30/, a 0.63 03 .I ELO 15.100 00 !~END IN G ANGLE 0. &096 1/,. 9,)00') 14. 90000 I-' I\) o VE RT ICAL PLANE TKA~S~( R MATRIX CO~PUNEN 1 S Tll 1 12 T 2 1 1 1 .00000 0.63 829 0.0 2 1 .00000 0.9',309 0.0 3 O.d7019 1. 23361 -0.587')[ 4 0.6 9099 1.32985 -0.58791 5 0.4968'> 1 . 6 01't7 -0 .32579 6 0.0 6654 2.87285 -0.32579 7 -0.06377 3 . 53997 -0 .32518 8 -0. 't i)327 6.670n -O.32~13 9 -0.6 8679 8.38307 -0.58558 10 -0.86528 10.1l788 - 0 .. 5B558 1 1 -O.99 /·t77 11.. 15 /t80 -0.OOOH6 1 2 -0.99503 10.0513 / .. -0.00086 13 -O.99~58 1 0.215U7 - 0.00036 14 -0.~9611 9.60u97 -0. 00086 T22 Tl 3 1. OOJOO 0.0 1 .00000 0.0 0.3 157'-\ 0.0 0 .. 3157', 0.0 0.96258 0.0 0.961;' 8 0 .0 2 .• -16990 0.0 2.36990 0.0 5.69164 0.0 5.691 6' .. 0.0 -0.99558 0 .0 -0.995 58 0.0 -0.99558 0.0 -0 .99558 0.0 T23 0.0 0.0 0.0 0.0 0.0 0.0 0 .0 0.0 0.0 0.0 0.0 0.0 0. 0 0.0 f-' I\} f-' II[)RIlONTAL PLA~E rRANSF[R MATR I X COMPONENTS T I I T1Z T21 I 0.96639 0.63ll2 -0.10 /,76 2 0.934 't5 0.92567 -0.1 0't76 3 1.01397 1. '+8726 0.4 8 123 '. 1.16065 2.00300 0.48l23 1. 25123 2.5 194·6 - O.06S45 6 1.1(,082 3.39)00 -0. Q()tSf.t5 7 1.03032 3.3.,1 19 -0.56 /-+04 8 0.2U533 2.20999 -0. 56 /-t04 9 0 . 0223" 1. 63330 - 0.63'117 10 - 0. 11 09 1 1.10762 -0.63 ltl7 II -0.4 8022 o. ',72',l -0. 81000 12 -0.73370 0.036.,B -0. 83000 13 - 1.B?3!! -O.715~5 - 0.72523 14 -1.67'+51 -1./,6&50 -0.72528 T72 0.9663B 0.96638 1.6()206 1. 6nOo 0.66 137 0.661.17 -0. 8M02 -0.96'+02 -1.7 4 106 -1 .74 106 - 1 .2 6587 - 1. 2658 7 - 1.23218 - 1 .2323H TI 3 T23 8.25263 25.7l2t)/{ 16.0B'J89 25 .71 284 29.87360 39 • .,3630 ,+ 1.92'126 39.53630 ~I.t . tt56~O 1 7.57 063 7L 66377 17. 57063 77.66563 - 17. 56 1,,5 54.47034 - 17.56 155 41.q~055 -39.53407 29.39056 -39 . 53407 16. 11 0 15 -25.69937 B.276Qq -?~.69937 0. 03200 O.010 1iC) 0.03839 0.01048 I-' I\) I\) HOR I l ONTIIL PU,N E TRA J LC TURY T ~ACK IN G AT DP / P~ OrSr ANCE 01 SPLACUlcNT 0.0 0.50000 0.6-1829 0 . 7 9875 O.9 /t 309 0.93006 1. 37't89 1 .. 2506 t 4 1 . 6 "19 69 1 .513182 5 2.111 't9 1 .. R8535 6 3.4322 '1 2.<76'11 7 3. 8 3 869 2.1 9075 5 .. 15948 1 .24766 9 5 . 50128 0. 83034 10 5.8 9608 0.4 6835 11 6.32738 -0.00 390 1 2 6.632 68 -0.32331 1 3 7.27 097 -0.9738 1 1 4 7 .88057 -1.57 050 0.0 SLO PE 0.500 00 0.4 308 1 D./dO Rl 1 . 0866'+ 1 .08664 0 . 29646 0.29 6'1-6 -0. 714 03 -0 . 71'10 3 -1.18"161 -1.1 876Z - 1 .O't793 -1.0479 3 -0.07 d83 -0. 9 7 083 I-" I\} W H[)R I Z0,~TAL I'LhI~ E T RAJEC T O~Y TRACKING AT OP / P= DI STANCe [) I SPLACE'IENT 0. 0 o.~oooo 0.63829 0.8B127 O. 9 t.3Q9 1. 09096 1. 3H89 1. 54935 " 1. 6 7%9 2.0 0106 5 2.111"9 2." 2991 6 1. '13229 3.05355 7 3.03869 2 . 9671ol R 5. 1 51)/t 8 1 .79<36 9 5.59 128 J .. 2 /,97', 1 0 ? 8960o 0 .76 7 26 II 6 . 32788 0.15720 1 2 6 . 63268 - 0.2"054 1 3 7.27 0n -0.973 /,9 [I, 7. dlJ057 - 1 .57012 0.010 SLOPE 0.50000 O.6S-(Y't 0. 68 7 ~4 1.Lt 3201 1./~ 8201 0.47216 0." 7216 -0.88965 -0 . 88965 - 1 .58296 - 1. 5829J -1.30',93 - 1 .30"93 -0.97tl72 -0. 'J7872 f-' '" .r HOR l lmJT Al PLANI: THA J EC TUR Y PLU TTI NG AT Dr/ P= 0.0 l O D1 STANCE or SPLACE~EN T SL OPE TK!\ J FC10 RY PL OT 0.0 0.,0000 0 . 5 0000 0.20000 0. 60 6 3 7 0 . ') 6315 o. (,0000 0.7 250 l 0 .622 51 0.60000 0. 85 ~ 13 0.677 86 0 . 80000 0 .997':>2 O.6H 7 94 I . 00000 I . l 3265 0.777 <)'1 1. 20000 1 .322 1't l . l 2 581 l . 4 0 000 t . 5B657 1 . /t BZOI 1 . 6 0 000 l . g82~7 1. 1, 820 1 1 . HOOOO 2.l 6300 1. 2 214 H 2 . 00000 2 .36 17 2 O.7 't(J05 6 2. 20000 2. It 717 0 0 .'17 21 6 * 2 .'i OOO O ~ . 5eb lIt O.'t 71.. 16 * 2 .60000 2. &605 7 0 . 1,72 16 2 . 80000 2 . 7 51:>00 0 . ' , 7 2 16 3. 000JO 2 . B',9',) 0 . ' , 7 2 1 6 3. ZaDOO 2. 9't3 8 ! o . 't 72 1 6 3. 1, 0000 -~ .03830 0.4721 6 3 .6000 0 3 . 0853 7 -0 .09362 3. 80000 Z. 9'./93B -0 . 7 63 10 I,. 00000 2 . H7 390 - o. 889 6 5 4 .20000 2 . 6 459 7 -O. 889 b ? " .le OOOQ 2.46flO', -0. 80 9 6 ') It . 6 0 000 2. 29011 -0. 88965 1, . 80 0 00 2.lI 2 l 8 - C. 8d9 65 5.00 0 00 1 .9-~425 -0. 8806 5 5 . 20 0 00 1 .7 5 /, 8 0 -0 . <) &4211 9 ~ ." O OOO 1 • 52 696 - 1 .3062 8 1 0 5.60 00 0 1 .23; 9 5 - 1. 582 9 6 10 5 . 80000 0 . 91 936 -1.5 8 296 Il 6 .00000 O. &00 2 5 - 1. 4 B13't I-' I l 6 .2000 0 0 . 376 5 7 - L. 3'di8 <.1 ." I\} I I 6 . Y) 999 0. 063 10 - 1 . :~ O ',9 3 . ~ 1 2 b . ~ 999<J -0 .1 9 7 8 9 - 1. 30'193 ' . l 3 6 . 7 999<) -0 . It ~2'1/. - 1. 2271 l . 13 b.9<)9<]9 -0. 6[1 7 95 - 1 . 126 (,It • 1 3 7 . J <)999 -0. 9 0 260 - 1 .01 869 . I '. 7 . ·3<)1)99 - 1. 0 99 77 - 0. 9 7 8 7 2 * 1'. 7 . 599<.}9 -1. ZQ552 -c. C;7 H72 1'. -' . 1 9999 - l. le91 2 6 -0. q 7 B7 2 VERT ICAL PLANE EL LIP SE fRl,CK I NG [rlITTANCE 0.014 93 GANMA ALPHA 0.02953 0.0 0. 02953 -0 . 01885 0.0295 3 -0.02785 1 1.7082 0 17.31 31)5 4 1 1 .70820 13.7/+5 30 5 3.621 8 7 5.43 63 1 6 3 .62 18 7 O.65 25{t 7 3.7', 69't -0.95002 8 3.74 694 -5.89898 9 1 2.5694~ - 1 5.0289] 1 0 12.56945 - I S.SoODS I I 0 . 02n9 0.29886 1 2 0.02929 0.2 8993 1 3 0.02n9 0. 27 1 ZIt I '. 0.02929 0 .25338 BE T A mJ,AX 33 .86600 0 . 71107 33. 87802 (). 71120 3~. 89226 0.7 11 V. 25.68<)09 0.61'130 16.22223 0.4 92 1 4 8.43082 0 .. 35 /,89 0. 39367 0 . 07666 0.50776 0.O87 ()7 9.55392 0.37768 18.0/,92 J. 0.519 11 2l:l . 378?7 0.650'12 37. 1 8683 0.7',512 31.007,,-( 0 .. 7 /t332 36.64917 0. 7 39 71 36.37936 0.7364(1 SMA X 0.02100 0. 02100 0.0 2 100 0 . 41. 809 0.4 1 809 0 .. 23 254 0.23254 O .. ?]652 0 . 2] 652 0 .'13320 0 .',3320 0 .0209 1 0. 02091 0.0 2091 0.0 209 1 f-' I\J '" V[RT 1 CAL PLA NE HEAM ENVELOPE TRACE 011 Tr ANCE 0.01',93 GAMMA ALPHA BETA OMAX SMX OEA'~ Et.V£LO;'lf 0 . 0 0.02 953 -0.0 33.fl6610 0.7 11 07 0.02100 0.2 0.02953 -0.0 059 1 33.06717 0.711 0'1 0.021 00 0./, 0.02953 -O.O ll B l 33.87071 0 .7 ll12 0 .02100 0.6 0.02903 -0.OU72 33. 8 7662 0 . 7111 B 0 .02100 O.H 0.02953 -0.02362 13. 88 /td9 0.7[1 2 7 0.0 2 100 1. 0 0.7'170[,' 2" 7Q (l 4!, 33.73946 0. 709 7', 0. 06073 1 .2 ~- .4 0 162 11 .60'-t /t7 30 .82127 0.67835 O.Z5(>3 5 1.l, 11 .70 820 17.01991 2 ',_ 82636 O.60 &B2 0.', l HO,) 1 .6 11 .70820 J ' t .&7829 I B. 't H/23 0.52537 O.ld OOl") 5 1. S 8.67023 l O.6905-~ 1 3.2969 /-t o ./f /tS'i6 0.3597 9 5 2.0 5.05 20<) 6.96966 9 . 81300 0.38276 0.27't 64 6 2.2 3.621fl7 5.11 573 7.501 03 0.33 1,&7 0. 23251., 6 2.4 3.621U7 ' .. 39 135 5.60Ql tZ 0.2891.& O.23 2 1)ft .* 6 2 . f) 3.62 18 7 3.66698 3. 911875 0.24',03 O . Z32 ~ /1 .* 6 2.8 3.621 8 7 2.9', 261 2. 66603 O.199?4 0.232 5 ', • 6 3.0 3 .62187 2.21823 1. 6:-\467 0. 15&n O. 2325 t, & 3 . 2 3.62187 1. 4<)386 0.8Y225 o. 11 ~'12 0.2325', 6 3 . /1 3.62 1 8 7 0.76(..)119 0.',3<)58 G.Okl01 0.232 54 7 3. (, 3.50323 -0.00067 0.2 B~'t5 0.06528 0 .22870 7 3. B 3.673 33 -0.706 /17 0 . /t /t 06 1 O.O 1l 111 0.23'ti9 8 '1.0 3.7't694 - 1. 554't5 0.911 ( & 0. 11 667 0.2365 2 8 'i.2 3 .74694 -2 . 3038't 1. 683'. 2 0.15 8~4 0.23652 8 ',. '. 3 .74 69 /, -3.05323 2.7 'J'I B3 0.202JO 0.23 652 . * 8 ',. 6 :1.7'i694 -3 . 80261 4.12 600 0.2', 820 0.236 "2 . * 8 (I. a 3. 7't 69't -4.55 200 5. -( 9692 0 . 29419 0 .23652 . l." 8 5 .. 0 3.74&94- -5.301 39 7 .-(6 760 0.34 0S', 0.23652 9 5.2 ',. 26717 -6. 1, -(3 ' ,7 1 0 . 0~485 0.387 /,5 0.25 2 41 . 9 5.'t 7 .65094 - 10.042dl 13.31313 0.',45 33 0.337 98 * 10 5 . & 12.56945 - 1 5 .1 384 4 18. 31203 0. 5223 7 O. {. 3320 10 5. 8 12.5694 5 - 17 .65230 2' • • 870 1 B 0.60930 0. 1,3320 11. 6 . 0 7.471 89 -15.420 6 1 3 1 .959 12 0.69076 0.33', 00 I-' 11 6.2 1.1 44 6 7 -6.3-(7 30 36.403 /,0 0.73723 0 .1 10r1 . '" 1 2 6.'1 0. 02929 o. 2967~ r l . l',3 !\B 0.7',1.,69 0 .02 0 9 J • "" 12 6 . 6 0.0292 9 0.290 89 :n.026 35 O. -( 4351 0 . 0209 1 13 6.8 0.0 2929 0.28503 3& . 9 111 6 0 .7 423 5 0.02091 13 7. 0 0.02929 0.27918 36. -' 9832 0.7 /,12 t 0.02091 1 3 7 . % 0.02929 0.27332 3 6 . 687B/, 0.7 /,010 0. 0209 J 1 4 7. 4 O.O292l) 0.2 &74 6 3 6 .57967 o. 73 9U 1 0 . 020'71 1'. .,. b 0 . 07.929 0.26160 3 6.47J~5 0. 7 379 /, 0.0209 1 lit 7. d 0.02929 O~2 5 57', 36. -l70]9 0.73 &89 0.0209 1 N 3 I PIU NT 2 MAXIT 40 ESCAL E 100000.0 I H RA T!U N 1 43 FU NC TI ON VALUES 0.40053466796875E 03 O.42243 969 7265 62[ 03 I T[RAIION 2 59 FU \JC lI ON VhLU ES 0. 4 0034033203125E 03 0.422426 5 13 6 71 8 7E 01 1 TER /\ T I Ufl} 3 70 FU NC TI ON VALUES O.4003576660156ZE 03 0 .422424 80 46875 0l 03 F = 0. 7252637296915IE-02 0.4002026 36 71 8 75[ 03 F = 0.145 3 72236 14752[-02 O.400350S R5Y3750( 01 F = O. 1 151 9 44 510638 7 ~-O2 O.40035 03 t, J 7968 7t 03 I-' '" ex> MA TCHING ROU TI NE t1ATCIlIIIG SECTION F RlJl·l ELEMENT J TO 1'. VARIAULE ELEME~TS 7 9 fINAL VALUES Of VAK I AB LE PARAMETERS 5 40 0.358 7 '. 22.425 9 400.350 F I NAL HATR IX COMPONENTS II OR I lONTAL PLANE - 1 . 6750 1 - 1 .46 02 1 -0.00 143 -0.7 2')33 VERT I CAL PLANE - 1.2327] -0. 99546 9 .6130 9 -0. 00099 -0.99500 I TERA TI UNS 3 ERROR 0.001151 94 0.00023 I-' '" -0 OLSIGN ~NERGY 500.00000 MEV PARflCLE RES T ENERG Y 93H.19Y95 MEV MOMENTUM NO. Of ELEMENTS 9 1. 0900'. GEV / C I UITI~L SYSTEM PARAMEIERS UNITS LENGTH-,'IETERS F I ELD G~A0 I EN T-GAUSS/CM F I ELD-KILOGAUSS AtIGLE-DEGREES I QUADRUPLlLE-OH EF LENGTH 2 DH I FT SPACE LENGTH 3 QUADIIUPOLl-FH Ef LENGTH DRIFT SPACt LENGTH QUfdJRUPOLc-OH EF LENGTH 6 D~ I FT SPACE LENGTH 1 QUADRUPOLE-FH EF LENGTH o DR I FT SPACE LENGTH 9 QUADi~UPDLc-DH EF LENG II I 0. 2500 FI [LD GRAD IEN T - 100.00000 9.5000 0.5000 FJELD GRADIEN T 100 . 00000 9 . 5000 0.5000 F I ELD GRAD I ENT - 100.00000 9 . 5000 0.5000 FJELD GNADIENT 100.00000 9.5000 0.25)0 FI FLD CRAD II NT -100.00000 I-' W o ;-1A 1CHI-'lG ROUTI NE ,·IATCIl I NG SE CTI ON FR O,'l ELEMEN T 1 TO VAR!4HL~ f LEMfN TS y F I NAL VALUES OF VA ~ I AULF PARA~ETEI(S 1 -10',.302 3 t O/i.60b 5 - 104 . 60 7 7 10't.&07 9 - 10 /t.9 14 FI NAL MAT~IX C OMPO~EN TS HURl zu;n AL PL ANE -1.00003 0.0001 6 0.0 -0.0000 1 VCRT 1(f,L PLANE - 0.ry9995 - 0.9 99lJ6 0.000 75 0.00000 -1. 00005 IT ERAT I UNS 17 ERRUR 0. 00009J36 0 .0 I-' W I-' N 0 0 00 ~~ NCo o o "-a z < w oe ~ ~ 00 00 z z 0:0 co w UJ « zz '7 ~o :'!:JJ ! I <!u <.u (,!) z V) ~ < <.Ii< I-I/) ...... z ,..... I-U __ O' - ...... VlO ::;:~cDu: i.W:::'I<::: * ;, . . ;} * . * 132 . * . * * * * ~. /-IATC III NG ROUTINE M/,TCIlING SECT ION FRO,~ ELEI1ENT 1 Tll 9 VAR I ABLE [LEI 'EN TS 1 3 5 7 9 FINAL VALUES OF VARIAdLE PARAMETENS 1 -679.31't 3 9 /, .. 690 - 10 tl.075 1 0 1 .99 /t " -883.2")2 F I NAL MATRIX COMPONENTS HO RI ZCNTflL PLI\NE -0.01224 2.09062 -O./t-(006 VERT ICAL PLA NE -0.67661 0.779&0 EL LIP SE PA RAME TERS HORllOIH AL PLANE VERT I CAL PLANE -0.04463 -0.U2419 -0.52833 INITIA L FIN AL I NITIAL FINAL REQUESTED I TERATIONS ERKOR 0.00013674 0.0 0.0 Gfd>1 j"1/J. ALP/I ,\ 0.25000 0.0 O.9Ud)O -0.00 00 '1 O.?50 00 0.0 2.500 8 7 2.00107 2.50000 2.00000 UEH 4.00000 1. 09327 4.00000 2.001 02 2.00000 E ,·1 0.02200 0.02200 f-' W W ,~ ATC I II NG RUU 1I NE HATCH I NG SeCT ION FROM ELEMENT 1 TO 9 VARIAHLE ELE MENTS 3 7 9 FI~AL V.LUES OF VARIA OLE PA~AMETERS I - 123 .001 3 I U.BIO - 122.808 I n . B06 9 - 122.663 FINAL MATR I X COMPONEN TS IIORIZ ONT"L PL!,NE - 1.0 0005 0.00005 0.0 -0.00004 Vt RTICAL PLA!,,[ -1 . 00002 -0.99995 0.00050 0.00004 -0.99 998 I TERATIO NS 20 ERRUR 0.00010545 0.0 f-' W .. VERTICAL PLANE T RA J ~C 1 0KY TKACKING AT UP/P= 0.0 DI STANCE 01 SPLACc;1ENT SL OPE 0 . 0 0 .50000 0.'>0000 0.25000 0 .6 1 84 7 O.(t/~5H7 2 -( .25000 3.73<:15't O./t 't~e7 3 7.75000 4 .l't 787 1 .200S9 4 1.'1. 750UO 12 .551 9 7 1 .2 0059 5 15.25000 12.5' .. 2 17 - 1. 23')46 6 22.25000 3. 86596 -1. 2 3946 7 22.7'>000 3. 1,2 1-+ 16 -O.54lY l 29.75080 -0.3 6924 -0 . 5't 191 9 30.00000 -0. 1 .. 997 3 -O./t99(H 1 (. ELA PSED TI ME = 0005.446 MINUTES I-' Lv ~ Surname : TAUTZ Given Names: MAURICE FRANCIS Date of Place of Birth : VICTORIA, B.C. Birth : OCTOBER 29, 1941 Educational Institutions Attended, with Dates of Entering and Leaving : UNIVERS I TY OF VICTORIA 1960 to 1964 Degrees, Diplomas, Etc., Awarded, with Dates and Names of Institutions: B.Sc. 1964 UNIVERSITY OF VICTORIA, VICTORIA Honours and Awards: Publications : THE UNIVERSITY OF VICTORIA LIBRARY MANUSCRIPT THESIS AUTHORITY TO DISTRIBUTE AUTHOR: This thesis may be lent or microfilm copies made available : (signature of the author in one of the spaces below) (a) Without restriction (b) With the restriction that, for a period of five years (until ) the written approval of the following is required : (1) The Dean, Faculty of Graduate Studies (2) The Author (3) both the Dean, Faculty of Graduate Studies, and the Author BORROWERS : The borrower undertakes, by signing bel ow, to give proper credit for any use made of the thesis, and to obtain the consent of the author if it is proposed to make extensive quotations, or to reproduce the dissertation in whole or in part . Signature of Borrower Address Date 

Cite

Citation Scheme:

        

Citations by CSL (citeproc-js)

Usage Statistics

Share

Embed

Customize your widget with the following options, then copy and paste the code below into the HTML of your page to embed this item in your website.
                        
                            <div id="ubcOpenCollectionsWidgetDisplay">
                            <script id="ubcOpenCollectionsWidget"
                            src="{[{embed.src}]}"
                            data-item="{[{embed.item}]}"
                            data-collection="{[{embed.collection}]}"
                            data-metadata="{[{embed.showMetadata}]}"
                            data-width="{[{embed.width}]}"
                            async >
                            </script>
                            </div>
                        
                    
IIIF logo Our image viewer uses the IIIF 2.0 standard. To load this item in other compatible viewers, use this url:
https://iiif.library.ubc.ca/presentation/dsp.51833.1-0314569/manifest

Comment

Related Items