Numerical Simulations
摘要
Several of the numerical simulation exercises proposed in the following chapters require step-by-step raytracing through the optical elements concerned, for diverse reasons, depending on the problem. The raytracing code Zgoubi is used and provides the necessary tooling for this numerical solution of particle and spin motion in electric and/or magnetic fields, and to account for random events such as in-flight decay or photon emission. Generalities regarding the interest of the stepwise integration method, as well as the code and its input and output data files, are introduced here.