\documentclass{JAC2003}

%%
%%  Use \documentclass[boxit]{JAC2003}
%%  to draw a frame with the correct margins on the output.
%%
%%  Use \documentclass[acus]{JAC2003}
%%  for US letter paper layout
%%

\usepackage{graphicx}
\usepackage{booktabs}

%%
%%   VARIABLE HEIGHT FOR THE TITLE BOX (default 35mm)
%%

\setlength{\titleblockheight}{27mm}

\newcommand{\comment}[1]{}
\newcommand{\degree}{$^\circ$\ }

\begin{document}
\title{Extending the Energy Range of 50Hz Proton FFAGs}

\author{S.J. Brooks\thanks{stephen.brooks@stfc.ac.uk}, RAL, Chilton, OX11 0QX, UK}

\maketitle

\begin{abstract}
Using an FFAG for rapid-cycling proton acceleration has the advantage that the acceleration cycle is no longer subject to constraints from the main magnet power supply used in an RCS. The RF can be used to its maximum potential to increase the energy range in a short 50Hz cycle as proposed for multi-MW proton driver projects. The challenge becomes an optical one of maintaining a stable lattice across a wide range of beam momenta without magnet sizes or the ring circumference making the machine prohibitively expensive for its purpose. Investigations of stable energy ranges for proton FFAG lattices in the few GeV regime (relativistic but not ultra-relativistic) are presented here.
\end{abstract}

\section{DESIGN PARAMETERS}

The application considered is boosting the power of the proton beam from ISIS \cite{ISIS}, which is a 50\,Hz proton synchrotron, by increasing its energy in an additional ring.  The existing machine powers its dipoles from a 50\,Hz resonant circuit, giving a periodic variation of central energy for the ring with a 10\,ms long rising edge during which acceleration can take place.  Adding additional harmonics can extend this period but moving to a fixed field accelerator makes the full 20\,ms cycle available for acceleration.  This is important because high energy rapid-cycling synchrotrons (RCS) are limited by RF gradient determining the energy rise achievable in the distance the beam travels ($<ct$), rather than strong space charge considerations as in the lower energy ring.

The existing ISIS second harmonic RF cavities \cite{RF} have some of the highest gradients available in their frequency range of 2.6--6.2\,MHz, containing two 12\,kV gaps in an installed length of 1.9707\,m.  The theoretical upper bound $ct(2V)/L=73$\,GeV must now be multplied by a practical RF packing factor (30\%) and the average RF phase factor and relativistic beta ($\langle\cos\phi\rangle\sim0.7$, $\beta\ge0.84$), these reduce the bound to 12.9\,GeV, so the top energy of the new ring was set at 12\,GeV.  These RF cavities are $h=4$ in the ISIS ring, which contains two bunches; the larger higher energy ring will need to fit these into exact buckets so the radius is set at 52\,m, double the ISIS radius, with an $h=8$ RF system operating at 6.2--7.3\,MHz.  This would need a mean bending field of 0.83\,T at the top energy, or 4.14\,T in magnets filling 20\% of the ring.  Superconducting magnets are a natural fit with fixed field machines and give the opportunity for a smaller ring, as opposed to RCS where normal conducting magnets mean the ISIS megawatt upgrade ring \cite{ISISUpgrade} is larger at only 3.2\,GeV.

\comment{
\u{A}
\^{A} \^{I}
\c{S} \c{T}
}

\section{TRACKING}

The Muon1 code \cite{Muon1} was used to track protons through a cell with its $4^\mathrm{th}$ order Runge--Kutta ($\delta t=10^{-11}$\,s) algorithm.  An additional module was written to supply the FFAG magnetic fields and some extra code logic added to find closed orbits and optics.  The existing genetic algorithm optimiser could then be run to improve the figure of merit derived for the entire cell, as detailed below.

\subsection{Magnetic Fields}

\newcommand{\B}{\mathbf{B}}

As the magnets are nonlinear and will have fringe fields, fully Maxwellian magnetic field models are desirable.  Analytic solutions in 3D are rare but a flexible series solution exists if the vertical field $B_z(x,y,0)$ is specified on the mid-plane, assuming symmetry around this plane so $B_x=B_y=0$ there.  Maxwell's equations in free space, $\nabla\cdot\B=\nabla\times\B=0$, can be rearranged to give
\setlength{\arraycolsep}{3pt}
\[\partial_z\B = \left[\begin{array}{ccc}0&0&\partial_x\\0&0&\partial_y\\-\partial_x&-\partial_y&0\end{array}\right]\B
= \left[\begin{array}{cc}0&\nabla_{x,y}\\-\nabla_{x,y}^T&0\end{array}\right]\B
, \]
from which a Taylor expansion in $z$ yields
\[ \B_{x,y}=\sum_{n=0}^\infty \frac{z^{2n+1}}{(2n+1)!}\nabla_{x,y}\left(-\nabla_{x,y}^2\right)^n B_z(x,y,0) \]
\[ B_z=\sum_{n=0}^\infty \frac{z^{2n}}{(2n)!}\left(-\nabla_{x,y}^2\right)^n B_z(x,y,0). \]
Specifying the mid-plane field as a product of three linear ramp functions
\[ B_z(x,y,0)=\prod_{i=1}^3\phi_i\left(\left(\left[\begin{array}{c}x\\y\end{array}\right]-\mathbf{c}_i\right)\cdot\mathbf{g}_i\right) \]
allows the off-plane field to be evaluated using precalculated coefficients $K_{abc}$ and repeated derivatives of $\phi_i$ at the relevant point as follows:
\[ B_z= \sum_{n=0}^\infty\ \sum_{a+b+c=2n} z^{2n} K_{abc}\ \phi_1^{(a)}\phi_2^{(b)}\phi_3^{(c)} \]
...and similarly for $\B_{x,y}$.  The module in Muon1 evaluates these until the sum converges with $n$ to a given tolerance.

In this paper, $\phi_1$ and $\phi_2$ provide the fringe field falloff and are the cumulative density function of the Gaussian distribution, thus the 2D vectors $\mathbf{g}_1$ and $\mathbf{g}_2$ point normal to the magnet faces with magnitude reciprocal to the fringe extent.  The function $\phi_3$ controls the field magnitude variation across the magnet.  Various choices are possible with the restriction that they must be infinitely differentiable and not produce impractical $|\B|$ values close to the mid-plane.  So far polynomials (a multipole model) and a spline that is a linear combination of Gaussians have been implemented.

\comment{
-(fig) Example 2D field plot and/or magnet cross section?
}

\subsection{Closed Orbit Finding}

With generalised magnetic fields there is no explicit formula for the location of the closed orbit, so it must be found numerically as a root of the equation $\mathbf{s}_\mathrm{out}-\mathbf{s}_\mathrm{in}=\mathbf{0}$ for the phase space vector $\mathbf{s}=(x,x',y,y')$.  As $\mathbf{s}_\mathrm{out}$ is a relatively smooth function of $\mathbf{s}_\mathrm{in}$, its first derivatives may be calculated, allowing the root to be found using multidimensional Newton-Raphson iteration.  That is the method used here, with a finite difference of $\delta=10^{-6}$ to calculate the derivatives.  Note that the equation may have zero, or many, solutions corresponding to closed orbits and these may appear or disappear as parameters such as particle energy are changed.  Newton-Raphson converges very rapidly when near a solution but is less stable further away, so where possible the initial value for the iteration was taken from a closed orbit `adjacent' in energy to the one being sought.

\section{OPTIMISATION}

This paper describes first attempts at optimising the magnetic cell for a large proton energy range.  Two different ranges of designs were considered: a `FODO' cell with two drifts each at least long enough to hold two RF cavities ($\ge3.9414$\,m) and a `doublet' cell with two magnets separated by a short (possibly zero) drift and a long drift holding up to four cavities ($\ge7.8828$\,m).  Polynomials were used for the transverse field profile in each magnet, with the coefficients of the $x^n$, $n\le6$ terms being the variables (allowed range $-$5 to 5\,T/m$^n$).  Further parameters included the fringe field extent (10--30\,cm), number of superperiods (range 15--33) and the bend in each magnet, which affect the angles in the cell.

The Muon1 optimiser starts off with random designs within the allowed range and recombines or mutates the best of these repeatedly to increase the overall score.  For each cell being tested, closed orbits are searched for at energies starting at 12\,GeV and decreasing by 5\% steps, with linear transfer matrices (and optical stability) determined from the finite differences of the orbits made by the Newton-Raphson algorithm.

\subsection{Figure of Merit}

If stable closed orbits exist from 12\,GeV down to an energy $E$, the score for the cell is a positive number proportional to $\log(12\mathrm{\,GeV}/E)$.  However the initial random designs will not always have stable optics to begin with, so if a lattice is unstable in either of the $x$ or $y$ planes, its linear transfer matrix $M$ is examined to determine the degree of instability.  The cell phase advance in plane $i$ given by $\cos\mu_i=c_i=\frac12\mathrm{Tr\ } M_i$, so in unstable cases where some $|c_i|>1$ the figure of merit is $-\max\{0,|c_x|-1\}-\max\{0,|c_y|-1\}$.  Finally, cells in which the Newton-Raphson iteration cannot find a closed orbit at all are assigned a score of $-$999.

\section{FODO LATTICE}

The FODO optimisation reached a design with stable optics down to a low energy of 3.46\,GeV, with orbits shown in figure \ref{fodocell}.  The field in one of the magnets has become entirely negative (figure \ref{fodofields}), which is what would happen in a scaling FFAG lattice where defocussing elements must have negative bends.  The polynomial space of field profiles in this optimisation can however only approximate the $x^k$ scaling law for most values of $k$.  A disadvantage of the polynomial space also becomes clear in that the field magnitudes can become very large ($>$10\,T) when only the coefficients of the polynomial are bounded.  The spline field profile would solve this problem but optimisation using that is still in progress.

\begin{figure}[htb]
   \centering
   \includegraphics*[width=82.5mm]{FR5PFP025f1.eps}
   \caption{Orbits through the FODO cell, from 3.5\,GeV (bottom) to 12\,GeV (top).  Grids are 1\,m square.}
   \label{fodocell}
\end{figure}

\begin{figure}[htb]
   \centering
   \includegraphics*[width=82.5mm]{FR5PFP025f2.eps}
   \caption{Magnet field profiles in the FODO cell, the beam sweeps from the left to right end of the graph with increasing energy in both cases.}
   \label{fodofields}
\end{figure}

\begin{figure}[htb]
   \centering
   \includegraphics*[width=82.5mm]{FR5PFP025f3.eps}
   \caption{FODO cell tune variation with energy and matched beta function at the end of the `BD' magnet.}
   \label{fodotunes}
\end{figure}

Despite the smooth looking field profiles, this lattice exhibits peculiar tune behaviour around an energy of 4.7\,GeV (figure \ref{fodotunes}), which corresponds roughly to the place where the derivative of the field profiles is zero.  Running energy orbits at a 1\% separation showed the lattice in fact has two stable energy ranges separated by a very small gap.

\section{DOUBLET LATTICE}

The doublet optimisation found a cell with stable orbits down to 2.70\,GeV.  Figure \ref{doubletcell} shows these orbits as well as a test orbit produced while iterating.  The field used in this lattice (figure \ref{doubletfields}) are more reasonable than the FODO cell but there is still a cusp in the horizontal tune where it goes very close to 180\degree in the region of 3.4\,GeV, as shown in figure \ref{doublettunes}.

\begin{figure}[htb]
   \centering
   \includegraphics*[width=82.5mm]{FR5PFP025f4.eps}
   \comment{\caption{100\% beam sizes from 800\,MeV (left) to 12\,GeV (right) in the doublet lattice at the start of the long drift space.  Orbit excursion is roughly 60\,cm (cm scale shown).}}
   \caption{Orbits through the doublet cell, from 2.7\,GeV (bottom) to 12\,GeV (top).  Grids are 1\,m square.}
   \label{doubletcell}
\end{figure}

\begin{figure}[htb]
   \centering
   \includegraphics*[width=82.5mm]{FR5PFP025f5.eps}
   \caption{Magnet field profiles in the doublet cell, the beam sweeps from the left to right end of the graph with increasing energy.}
   \label{doubletfields}
\end{figure}

\begin{figure}[htb]
   \centering
   \includegraphics*[width=82.5mm]{FR5PFP025f6.eps}
   \caption{Doublet cell tune variation with energy and matched beta function at the start of the long drift space.}
   \label{doublettunes}
\end{figure}

Both of the magnets have some positive field part in this cell, which is advantageous for making high energy rings smaller because there is no reverse magnet whose bending has to be entirely undone by others around the circumference.  The horizontal orbit excursions are still very large here, of the order of a metre.  Reducing the magnet widths alone will keep the dipole bending the same but increase the quadrupole component to the point where it overfocusses in a long drift.  It may then be useful to consider a shorter focussing period length, for instance with a small doublet where each magnet of the FODO would have been.

\comment{
\section{OPTICAL CONSIDERATIONS}

? Perhaps merge with following sections
? Mention it's a non-scaling FFAG
- Don't want scaling (negative bends), why 3 magnets per cell may be better (Ref. Grahame?), why shrinking horizontal excursion overfocusses
}

\section{SUMMARY AND FUTURE WORK}

This paper has described an integrated way of finding and testing new FFAG cell lattices, with early runs producing machines stable over more than a factor of 3 in momentum.  The optimisation results are highly dependent on how the space of potential accelerators is specified, so later work will use spline descriptions of the magnetic field that bound its magnitude.  \comment{Notably 3.2\,GeV is the output energy of the currently envisioned ISIS upgrade so an FFAG machine similar to the ones described could be used as a booster ring.}

\begin{thebibliography}{9}   % Use for  1-9  references
%\begin{thebibliography}{99} % Use for 10-99 references

\bibitem{ISIS} \emph{Spallation Neutron Source: Description of Accelerator and Target}, ed. B. Boardman, Rutherford Appleton Laboratory technical report RL-82-006 (1982).
\bibitem{RF} \emph{Progress on Dual Harmonic Acceleration on the ISIS Synchrotron}, A. Seville \emph{et al.}, Proc. EPAC 2008; and \texttt{www-accps.kek.jp/Low-Impedance\_Cavity/2RF.pdf}
\bibitem{ISISUpgrade} \emph{ISIS Megawatt Upgrade Plans–--Neutrons and Neutrinos for Europe}, C.R. Prior \emph{et al.}, Proc. PAC 2003.
\bibitem{Muon1} \emph{Quantitative Optimisation Studies of the Muon Front-End for a Neutrino Factory}, S.J. Brooks, Proc. EPAC 2004.

\end{thebibliography}

\end{document}
