1 / 16

Computation of Taylor Maps and Applications to Accelerator Physics

Computation of Taylor Maps and Applications to Accelerator Physics. Six lectures with emphasis on examples and their computer implementations Etienne Forest Soken Dai December 2004/January 2005. A TPSA Package. Computes approximate Taylor maps. Makes Taylor Code look ordinary.

acton
Download Presentation

Computation of Taylor Maps and Applications to Accelerator Physics

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Computation of Taylor Maps and Applications to Accelerator Physics Six lectures with emphasis on examples and their computer implementations Etienne Forest Soken Dai December 2004/January 2005

  2. A TPSA Package Computes approximate Taylor maps Makes Taylor Code look ordinary • What is the original “DA” package? • What does it do? Why is it useful? • What is “Operator Overloading”? • Taylor Polymorphism? • “Lie/Differential Algebra”? • Normal Forms? • What is a integrator based code? • What is a matrix based code i.e. Cosy-Infinity? • What is the difference between polymorphism in a compile form (my stuff) and interpreted code (Cosy language)? • And all these things, can I use in my own code? Delays choice between Taylor and Real at execution time Vector fields of the theory: allow perturbation theory Various Canonical (i.e. special) forms of the map useful in periodic systems These are the questions which we will answer in the 6 lectures using examples as much as possible rather than theory!

  3. Demystifying AD-DA Lecture 1 Automatic Differentiation (AD) is based on a Truncated Power Series Algebra (TPSA) not on a Differential Algebra (DA) DA which involves useful vector fields will be discussed in future lectures.

  4. Basic Questions for Lecture 1 The Basic Questions of the first lecture: • What is the original TPSA (i.e. DA) package? • What does it do? Why is it useful? • What is “Operator Overloading”? These questions are nothard unless couched in the abstract mathematical lingo Berz loves.

  5. How do we cut through the nonsense? • Simple: we write a small fully functional toy TPSA package for this class! • Only 400 lines of code including the blanks! • Fully overloaded and fully automatic • Restricted to 2 variables and third order Of course, it is not Berz package and there are a lot of issues about overloading Berz’s package that can be neglected in the small example. The purpose here is to demystify these techniques and not to bother you with ultimately nearly irrelevant technicalities.

  6. Look at TPSA through our toy TPSA Package • A basic TPSA-package is a tool to expand what you compute on the computer in a Taylor Series in the variable you choose. • In Optics and Accelerators, it permits the computations of maps for perturbative calculations and also sometimes simulations. • Operator Overloading brings us closer to Automatic Differentiation rather than Computational Differentiation: the code that computes the Taylor expansion is almost identical to the code that computed the original quantity. Perturbative calculations : Transfer Matrix, Lattice functions (Twiss), tunes, damping, amplitude dependent tune shifts, aberrations in optical systems, resonance driving terms, synchrotron integrals, etc…It is here that differential operators and hence Lie/Differential algebras (DA) will come into play.

  7. 卍Download Toy TPSA and Gun/FODO cell application main program here! 卍 Why we want Taylor Series: Example 1, shooting… Before we start, why do we want Taylor series? Or perhaps accelerator physics?

  8. Example 2: 10 FODO Cells One dimensional Quadrupole FODO Cells

  9. TPSA-Addition/Subtraction

  10. Multiplication

  11. Inverse : Nilpotency comes in

  12. Functions: Exponential Again one isolate the constant part to create a nilpotent DT

  13. Ignore Nilpotency? Sometimes OK This is used in COSY-Infinity techniques where DT is a vector field acting a polynomial. For this reason, please reflect carefully why this series works! It is implemented as TPSA_EXP in the toy TPSA and N=n_tpsa_exp.

  14. Conclusion • We implemented a Truncated Series Algebra on the Computer. The original “DA” package of Berz is only that. • For the mathematically oriented people, this TPS Algebra is simply a ring (環). • The concept of Differential Algebra does not enter in TPSA. It is of no relevance at this stage.

  15. Future Lectures • Perturbation theory will be discussed from a very geometrical point of view: invariants, Twiss functions and nonlinear distortions. • The geometrical picture will be translated into an operation derived from the Taylor map. • My own FPP library will used. In these lectures I will emphasize the “canned library” aspect of FPP. We will not go into the mathematical details but just assume that the library does what it advertises. • We will see that FPP manipulates Vector Fields associated to the Taylor map. These Vector Fields form a differential Lie algebra. But that is not too important: focus on the geometrical aspect please. • Lecture number 2 will start with some very traditional computations and will end with an introduction to the Geometrical Point of View. • 注意 Other mathematical objects in Berz’s lectures, such as Levi-Civita fields (体), non Archimedean fields, are interesting (but so is ancient Greek and classical Chinese), but really of virtually no relevance to our work. Do not get distracted.

  16. Problem The function ArcSin(x) or asin(x) cannot be easily separated into a constant part and a nilpotent part. Can you find an algorithm to evaluate asin(x) when x is a polynomial? Program this algorithm using the Toy TPSA routines. Your algorithm should not be explicitly limited to cubic polynomials.

More Related