\section{Nonlinear transfer maps for charged particle beam transport}
\subsection*{Introduction}
Charged particle beam transport can be described with a Taylor map
which, in the linear case, coincides with the familiar beam-transfer
matrix. Traditional accelerator design codes, such as {\tt TRANSPORT}
of K.~Brown and {\tt MAD}, developed by CERN, utilize the next
(second) order map while methods to construct maps of higher order
and use them for nonlinear analysis were developed in the 80s by
Dragt, Forest, Irwin, Berz and others. Such are the Lie-algebraic
method, which fully accounts for the Hamiltonian (symplectic) nature
of motion, or the Differential Algebra method, where the map is
extracted directly from the equations of motion. In terms of
mathematical apparatus, both these approaches, and especially the
second one, require extensive numerical manipulations of polynomial
functions. For this, the techniques of the truncated power series
algebra (TPSA) are applied (also called
\href{http://en.wikipedia.org/wiki/Automatic_differentiation}
{automatic differentiation}).
At present, increased power of analytic computational systems (such as
{\tt Mathematica}) provide the flexibility and speed needed to
implement all the map-building methods described above. Nonlinear
problems can then be studied with dedicated notebooks in a local
environment. Work in this direction, pursued also by researches in
many accelerator laboratories, has recently been initiated at
TRIUMF. We have developed two packages -- {\tt LieMath} and {\tt
DARK} possessing many features and functions of two well
established codes: {\tt MARYLIE} of A.~Dragt and {\tt COSY} (of
M.~Berz).
% the direct tracking of particles as the alternative and often a suplement
%to any map calcIn its modern version: ``symplectic integrator'', it also relies on Hamiltonian
%description of the optical elements and on Lie-algebraic description of groups of
%elements. Future development of the packages is envisaged to include
%symplectic integrator routine.
%\subsection*{Timeline} Work was started in 2004.
\subsection*{Results and progress}
\paragraph{Lie-algebra applications:}
{\tt LieMath} (2004-2005) is a code we wrote which builds a symplectic 6
dimensional map in either Lie-factor, or Taylor form. The input to
the code is a beam-line of optical elements written in the most
popular MAD-input format. The code provides nonlinear optimization
and normal form analysis to octupole order. As of 2006, a TPSA module
is installed to speed up operations on polynomials.
In 2004, an early version of LieMath was used to produce 7-th order
off-momentum map for the basic cell of the Fixed Field Alternating
Gradient accelerator (FFAG); it is in full agreement with the
corresponding map generated by {\tt COSY-$\infty$}.
In 2006, Lie-algebraic theory was applied (2005) to test and refine
the existing CERN program for multipole correction of the LHC
interaction-region quadrupoles (so called triplet correction).
In 2007, Lie-algebraic treatment of weak-strong beam-beam interaction
produced the effective Hamiltonian in the case of an arbitrary number of
collision (or interaction) points (IPs). This is related to the
long-standing question whether the beam-beam resonances may be
canceled by choosing some appropriate betatron phase advance
between the two main IPs of the LHC -- Atlas and CMS. Such
resonances, manifesting themselves as dips in dynamic aperture
positioned dangerously close to the LHC tune working point, were
clearly seen in the tracking data. As a result we found that not all,
but only some kinds of resonances would be canceled and the conditions
for cancellation are rather stringent. The idea to tune the machine to
a specific phase between the IPs has been, at least for now,
abandoned.
\paragraph{Differential algebra applications:}
{\tt DARK} (Differential Algebra $+$ Runge-Kutta) is a Mathematica
package that applies the TPSA method to compute
the transfer map for arbitrary equations of motion describing an
optical system. It has the same interface as LieMath, so the Taylor
maps produced by these two codes can be compared directly, but it can
also tackle the case when the focusing strength of an optical element
is not constant along its axis, i.e.\ the case of fringe fields. The
algorithm used is very similar to the one used in the code {\tt
COSY}-$\infty$.
In mathematical terms, DARK is a differential algebra integrator -- a
numerical solver of the complete variational equations describing an
optical system.
The code has been tested against numerical integration of individual
trajectories and, for magnetic quadrupoles with fringe fields, against
high-order maps generated with {\tt COSY}-$\infty$.
Possible applications are: nonlinear optimization of beam-lines,
FFAG, a Linear Collider Interaction Region, existence of Third Order
Achromats etc.
DARK was used recently to study fixed points and transition to chaos
of the Duffing equation.
\subsection*{List of Institutes}
There is incidental interaction with University of Maryland. CERN is
involved only in the application of the codes.
\subsection*{TRIUMF role}
In 2005, the LieMath package was added to the web-based dynamic
accelerator physics software repository
(\href{http://oraweb.cern.ch:9000/pls/hhh/code_website.disp_code?code_name=LieMath}
{CARE HHH European Network}).
Currently DARK is being used to study fixed points and transition to chaos
of the Duffing equation. This is intended for
Section 18.11 (Taylor Approximations) in the book of Prof. Alex~Dragt
(\href{http://www.physics.umd.edu/dsat/dsatliemethods.html}{link}).