Caustic-based approach to understanding bunching dynamics and current spike formation in particle bunches

Current modulations, current spikes, and current horns, are observed in a range of accelerator physics applications including strong bunch compression in Free Electron Lasers and linear colliders, trains of microbunching for terahertz radiation, microbunching instability and many others. This paper considers the fundamental mechanism that drives intense current modulations in dispersive regions, beyond the common explanation of nonlinear and higher-order effects. Under certain conditions, neighboring electron trajectories merge to form caustics, and often result in characteristic current spikes. Caustic lines and surfaces are regions of maximum electron density, and are witnessed in accelerator physics as folds in phase space of accelerated bunches. We identify the caustic phenomenon resulting in cusplike current profiles and derive an expression which describes the conditions needed for particle-bunch caustic formation in dispersive regions. The caustic expression not only reveals the conditions necessary for caustics to form but also where in longitudinal space the caustics will form. Particle-tracking simulations are used to verify these findings. We discuss the broader implications of this work including how to utilize the caustic expression for manipulation of the longitudinal phase space to achieve a desired current profile shape.


I. INTRODUCTION
Caustics are a common occurrence in optics, describing the bright lines seen in a well-lit coffee cup, or the dancing networks of light at the bottom of swimming pools on a sunny day [1,2]. They are a form of "natural focusing" [2] which possess stability with respect to perturbations in the system leading to their formation. Figure 1 shows an image of visible-light caustics forming at the bottom of a coffee cup. The previously mentioned property of structural stability here manifests itself in the fact that any small continuous distortion or reorientation of the cup merely shifts the "naturally focused" caustic lines without altering their form.
Electron trajectories forming caustics in particle trajectories could be considered a corollary to caustics found in geometrical light optics [3,4]. In both cases, particle trajectories and light rays, the mathematical description of caustics lies within the broader field of catastrophe theory [1]. Figure 1 shows a common example of optical causticsthe bright lines of reflected light in a coffee cup. These bright caustic lines are the envelope of a family of rays reflecting from the curved inner surface of the cup [see Fig. 1(b)]. The intensity of the light rises sharply as the inverse square root of the distance from the caustic [5] [see Fig. 1(c)]. This sharp rise in intensity is reminiscent of some peaked current profiles often observed in accelerator physics.
Some examples of where current spikes are observed in an accelerator physics context are illustrated in Fig. 2. Figure 2(a) illustrates current spikes emerging at the head and tail of a particle bunch typical of strong bunch compression in Free Electron Lasers (FELs) and linear colliders [6][7][8][9]. These current spikes are referred to as current horns in some publications. High-current portions of the bunch can produce intense coherent synchrotron radiation (CSR) and result in CSR-induced emittance growth [10,11]. Another example of current spikes is microbunching instabilities, illustrated in Fig. 2(b). Small continuous current and energy modulations initiated by collective effects can result in current density modulation as a particle bunch passes through a dispersive region [12][13][14][15].
Published by the American Physical Society under the terms of the Creative Commons Attribution 3.0 License. Further distribution of this work must maintain attribution to the author(s) and the published article's title, journal citation, and DOI.
Current spikes can also be intentional [16] as shown in Fig. 2(c), where strong wakefield-induced energy modulation results in regions of enhanced current. Trains of microbunches can be used for producing coherent terahertz radiation [17][18][19], and resonant excitation of the wakefields in plasma and dielectric wakefield accelerators [20]. Finally, Fig. 2(d) shows an intermediate step toward obtaining a linearly ramped current profile through controlling the second-order longitudinal dispersion via sextupoles [21]. This current profile is also reminiscent of single-spike profiles found at some FEL facilities [22][23][24] or ramped profiles produced using a superconducing radio frequency linear accelerator operating at two frequencies [25].
Examples of each of the current profiles mentioned above and schematically illustrated in Fig. 2, can be found in the following literature: (i) for double-horned current profile, see Fig. 7.7 in [6]; (ii) for microbunching instabilities see Fig. 3 in [12] or Fig. 3 in [26] for experimental data; (iii) for trains of microbunches, see Fig. 6 in [27]; (iv) for ramped current profiles, see Fig. 5(a) in [21].
In this paper we discuss how these intense current spikes result from the coalescing of electron trajectories forming singularities known as caustics. A brief outline of caustics is presented in Sec. II, followed by a detailed analysis of how caustics can appear in accelerator physics applications in Sec. III. This includes derivation of a caustic expression which describes where in longitudinal position caustics in a particle bunch will form and under what conditions. Section IV compares the analytical results with particletracking computer simulations calculated using the "Electron Generation and Tracking" (ELEGANT) software toolkit [28]. Section V gives an application of this work to current pulse shaping. Finally, Sec. VI discusses some of the broader implications of the present work, including how we may be able to utilize this knowledge of caustics to avoid current horn formation in strong bunch compression.

II. CAUSTICS
Families of smooth electron trajectories, each of which may be straight or curved, can exhibit caustic behavior at points where infinitesimally separated adjacent trajectories cross. The locus of such crossing points gives an envelope to the family of trajectories which specifies the caustic region. At any point where an electron trajectory within the family of trajectories that comprises the caustic, touches the caustic surface, it will be tangent to that surface. See Fig. 1(b) for the visible-light analogue of this where a family of photon trajectories (shown in blue) generates the caustic region sketched in red. In the vicinity of the caustic line the density of trajectories is greatly enhanced as depicted in Fig. 1(c).
Let us return to the case of electron trajectories. When tracing such trajectories through a dispersive region, caustics can be seen in the s-z plane, where z is the longitudinal position with respect to the center of the bunch and s is the position along the accelerator. This is visible in Fig. 3 where the density of trajectories intensifies near the edges of the bunch after propagating some way through the dispersive region. This can be regarded as a cusp caustic, being comprised of two fold caustics that are stitched together at the point of the cusp [29].
The example shown in Fig. 3 is of a standard 4-dipole chicane where T 566 ¼ −3=2R 56 and U 5666 ¼ 2R 56 with R 56 , T 566 and U 5666 being the first-, second-and third-order longitudinal dispersion values respectively [30]. Despite the current being of uniform distribution at s ¼ 0, by the end of the dispersive region, electron trajectories have coalesced, creating the increased density of particles in z, at the head and tail of the bunch. These caustics create the double-horned cusp-shaped current profile witnessed at many FEL facilities [6,10].
The second panel of Fig. 3 shows the curvature in the longitudinal phase space distribution, typical of strong bunch compressors. When projected onto the z-axis, it becomes clear how the bifurcation leads to intense current spikes. These folds in phase space are introduced by higher-order effects in dispersive regions. This will be examined in more detail in Sec. IV.

III. CAUSTIC FORMATION IN PARTICLE TRAJECTORIES
Understanding the current profile through the lens of caustics, allows us to predict the sharp rise in the current in the vicinity of caustics when they arise, and also allows us to determine analytically where and under what conditions caustics will form.
Throughout this paper, the transfer matrices mapping a particle from some initial coordinates, Xð0Þ ¼ ðx; x 0 ; y; y 0 ; z; δÞ, to their final coordinates Xð1Þ, have been used. This matrix formalism can be expressed as [31,32], where R, T, and U are the first-, second-, and third-order transfer matrices, respectively. In this section we consider an example case of an electron bunch passing through a bunch compressor chicane or dogleg defined by the first-, second-, and thirdorder longitudinal dispersion values of R 56 , T 566 , and U 5666 . We consider this example of a bunch compressor in deriving the conditions for caustics to form, which can then be extended to any relativistic particle bunches traveling through a dispersive region.
Denoting the relative energy deviation by δ, the final longitudinal position can be calculated by, where z i is the initial longitudinal position of any one particle. Here geometric terms have been omitted as chromatic terms will dominate the transformation for beams with small transverse emittance and large energy spread [33]. This will be the case for bunch compressors where a large energy spread is introduced. For other cases, where chromatic terms do not dominate, geometric terms (e.g., R 51 and R 52 ) should be included.
From here we can approximate how the electron trajectories evolve with position along the compressor, s, with initial longitudinal positions, z i . This leads to the equation where the final longitudinal position z f is, where s bc is the location of the end of the compressor. Figure 3 shows Eq. (3) evaluated for a range of initial z i values. This expression assumes that the longitudinal dispersion remains constant over the compressor, which is unlikely. However when evaluated this expression will produce the same distribution at the compressor exit when compared to an expression that includes how R 56 varies with s. Therefore whilst Eq. (3) is simply a "smooth approximation" to how z f varies with s, it accurately predicts z f at the end of the dispersive region s bc , and when plotted provides an intuitive snapshot of the caustic formation. Furthermore this approximation does not impact the derivation of the caustic expression in the following section.
An energy chirp correlated with z i , is usually established by the rf voltage and phase of the accelerating section and harmonic cavity upstream of the compressor [34,35]. This creates a relative energy deviation of any particle with respect to the reference particle, expanded to third-order in z i of, where E i;0 and E f;0 are the central energy before and after acceleration respectively, δ i is the initial uncorrelated energy spread and h 1 , h 2 , and h 3 are the first-, second-, and third-order energy chirps respectively. The first-, second-, and third-order energy chirps are established by the rf voltage and phase of the preceding accelerating cavities but are also influenced by collective effects such as wakefields, space charge forces, or other non-linear effects [11,36]. To create a more realistic example that includes these effects, we have written an ELEGANT simulation [28] that traces particles through an FEL linac. The linac is comprised of an S-band injector followed by an X-band harmonic cavity to mitigate the second-order effect of compression [34,35,37], followed by a 4-dipole chicane (labeled BC1) and an X-band linac. The bunch distribution taken just before a second bunch compressor (BC2), includes the high order effects longitudinal wakefields impart on the longitudinal distribution. A high-order polynomial was fit to this distribution, capturing the effect of nonlinear forces on the longitudinal phase space. The distribution and polynomial fit Fig. 4. Whilst the fitted distribution in Fig. 4 appears predominately linear, small deviations from a linear distribution lead to large features in both the longitudinal phase space distribution and current profile at the end of the compressor. This sensitivity to small continuous perturbations is a common feature of catastrophe theory [1]. Figure 4 emphasizing the nonlinearity. This derivative also appears later in Eqs. (7) and (8).

A. Expression for the caustics
In our treatment, a caustic is the envelope of the family of particle trajectories coalescing through a dispersion region, in this case defined by R 56 , T 566 , and U 5666 . As previously mentioned, this is analogous to geometrical optics where the caustic is defined by the "family of rays" reflected or refracted by an optical element.
Consider the particle trajectories in s-z space described by Eq. (3). Two trajectories infinitesimally spaced at the beginning of the compressor (s ¼ 0), may cross on a caustic at some point P, as shown in Fig. 5.
Each trajectory evolves as a function of the initial longitudinal position z i , where the z i position will have a corresponding energy deviation, due to the chirp imposed onto the bunch mainly by the rf phase and voltage. The family of trajectories will have an envelope curve, namely a caustic. The caustic line is tangent to every trajectory forming the family of trajectories. The points which make up the envelope consists of the limit points of two neighboring trajectories as one approaches the other.
Take two trajectories labeled T 1 and T 2 , shown in Fig. 5. T 1 and T 2 , can be can be defined as the implicit curves, To find the coordinates of the caustic point P (in Fig. 5), we recognize that the envelope of trajectories lies on the limit of intersections of two members of the family, T 1 ðR 56 ; T 566 ; U 5666 ; z i Þ and T 2 ðR 56 ; T 566 ; U 5666 ; z i þ dz i Þ, as dz i approaches zero. Equating Eq. (5) and Eq. (6) gives, Assuming we are only concerned if caustics form by the end of the dispersive region, we can set s ¼ s bc . Finally, the parametric form for the set of caustic points (z,R 56 ), parametrized by z i is, where δðz i Þ is the shape of the initial longitudinal phase space or chirp and δ 0 ðz i Þ is the derivative with respect to z i . Equation (8) defines the location in z and R 56 space where caustics will form, and hence identifies the regions of greatly enhanced current. The caustic expression [Eq. (8)] is plotted in Fig. 6 along with the electron trajectories which had the initial distribution shown in Fig. 4. Note, our use of the word trajectories is not referring to trajectories traveling through physical space, but rather between z and R 56 coordinates. Note also that, for the particular parameters used here, the caustic in Fig. 6 has the morphology of a cusp, this being one of an infinite hierarchy of possible caustics as classified by catastrophe theory. All of these caustic morphologies are describable by Eq. (8), albeit with polynomial expressions for δðz i Þ that are in general of higher than cubic order in z i . Examples of other caustic morphologies, besides the previously mentioned fold and cusp, include the swallowtail, elliptic umbilic, hyperbolic umbilic, parabolic umbilic, and butterfly [1]. Each such caustic morphology will leave its own characteristic caustic motif or fingerprint on the associated current distribution.

IV. COMPARISON WITH ELEGANT SIMULATIONS
The caustic nature of the current profile and the caustic expression in Eq. (8), have been verified using ELEGANT simulations, which performs 6-D particle tracking of the vector X ¼ ðx; x 0 ; y; y 0 ; z; δÞ. This illustrative example is of an X-band linac based on designs presented in Refs. [38,39]. However it should be noted that the caustic expressions derived in Sec. III are more broadly applicable to relativistic bunches traveling through a dispersive region.
In the following illustrative example we use a typical FEL accelerator layout [38,39], consisting of an S-band injector, followed by X-band harmonic linearizer, with two-stage bunch compression. The two bunch compressors were separated by 50 meters of X-band linac allowing longitudinal wakefields to affect the energy distribution along the bunch. Whilst this example uses a predominately X-band linac, caustics can be found to be the underlying mechanism behind strong compression resulting in current spikes for any frequency choice. The longitudinal chirp at the entrance to BC2, as best described by a high-order As previously mentioned, a polynomial fit of third-order or higher is needed to see the emergence of the caustic analytically. Here we have used a quintic fit, whereas previously in Sec. III, we opted for a cubic. The quintic allows for more intricate caustic patterns to be revealed that would not be visible with just the cubic fit. The cubic fit however, is often sufficient to see the main structure evolving, e.g., a current-horn in strong compression, because thirdorder effects dominate the process when second-order effects have been mitigated through harmonic linearization.
A series of conditions is presented showing the analytical solution of the caustic expression [Eq. (8)] alongside the 6D particle tracking simulation results. This is shown in Fig. 7. The conditions that were varied were the values of R 56 , T 566 , and U 5666 of the second bunch compressor (BC2), and the results shown are taken at the end of BC2.
The second row of Fig. 7 shows the histogram of current density obtained by projecting the electron trajectories onto the z axis at the R 56 value indicated by the gray vertical line in the trajectory plots (top row of Fig. 7).
The third and fourth row of Fig. 7 shows the ELEGANT simulation results using a compressor matching the longitudinal dispersion values listed in the caption. Good agreement can be seen between the analytical expressions and the ELEGANT simulation results. The histograms produced from the analytical approach show slightly more pronounced caustics. This is because in the ELEGANT simulations, and predictably in any experimental results, the caustics are smeared out due to: (a) nonzero transverse position to longitudinal position mapping (i.e., nonzero R 15 , R 25 , R 35 , R 45 as well as higher-order terms), (b) chromatic variations from the fit of δ as a higher-order polynomial in z i , and (c) the uniform initial current distribution that was assumed in the analytical approach. It should be noted however that the position of the peaks in rows 2 and 3 of Fig. 7 is very consistent, despite the smearing out of the caustics due to the above mentioned reasons.
The three columns of Fig. 7 illustrate three scenarios where caustics are present. The first column shows the iconic double-horned current profile often associated with FEL bunch compression. Another current profile reported at FEL facilities is the single-spike profile [22][23][24] shown in the second column of Fig. 7. This was achieved here through varying the T 566 parameter, however it could also be found through varying the initial distribution chirp described by δðz i Þ. It can also be shown that varying T 566 can alter the relative heights of the two current peaks in Fig. 7(a). Finally, the last column of Fig. 7 shows the flexibility of this approach whereby unusual and intricate current profiles can be predicted through the caustic expression and emulated with the ELEGANT simulations.
Earlier, Fig. 3 showed trajectories in s-z space assuming linear trajectories. This assumes a constant R 56 over the chicane, which is an inaccurate assumption. Fortunately this assumption could be avoided in Sec. III through switching to z-R 56 space. However for completeness, we used ELEGANT simulations to show how the trajectories are more likely to evolve over the chicane in physical s-z space, where R 56 is no longer considered constant. This is shown in Fig. 8, where R 56 varies across the chicane, with most of the compression occurring in the dipoles. Note in this context, that the possible caustic morphologies (fold, cusp, swallowtail, etc.) are identical for both linear and nonlinear continuous trajectory families [2]. coordinates at 45 slices through the chicane and linearly interpolating between those slices. A beam distribution of constant x, x 0 , y, y 0 was used, leaving only variation in the longitudinal position z and the energy spread δ. Conversely, the ELEGANT simulations plotted in Fig. 7 were created with realistic bunch distributions.
Zooming in on the last dipole in Fig. 8(b), we can see the caustics forming at the head and tail of the bunch. Ten slices through the final dipole were used to create Fig. 8(b).

V. CURRENT PROFILE SHAPING
We can determine the shape of the current profile through first determining an expression for the local compression ratio, C l , which indicates the degree to which the electron trajectories are compressed as a function of longitudinal position z. Figure 9 shows a sketch of two trajectories through a chicane, for two particles that are infinitesimally separated in the longitudinal direction. The ratio of the length a to b is the local compression ratio, C l , where a is the separation of the trajectories at the beginning of the compressor and b is the separation of the trajectories at some distance s along the compressor.
At the beginning of the chicane, the two trajectories in Fig. 9 are separated by some small distance, dz i . The length a, that separates the two trajectories at s ¼ 0, is simply, The length b can be found through evaluating the longitudinal positions for each trajectory [Eq. (3)] and finding the difference to be, where s 2 is some arbitrary position along the accelerator.
The compression ratio, C l , which is equal to the ratio of a to b can be found to be, Substituting in an initial longitudinal distribution of δðz i Þ, and calculating the ratio at the end of the compressor (i.e., setting s 2 ¼ s bc ), we find the variation in C l with z i . This is shown in Fig. 10 for a standard chicane where R 56 ¼ −11.8 mm (and T 566 ¼ −3=2R 56 and U 5666 ¼ 2R 56 ). The three branches indicate the bifurcation points in Fig. 3, corresponding to where the electron trajectories fold around on themselves.
Mapping the initial longitudinal positions, z i , to the final longitudinal position, z, we obtain an expression that closely resembles the current profile, but has multiple branches relating to the folds in phase space introduced in the compression. The mapping is defined by Eq. (3) and results in the parametric form for the compression ratio (z, C l ) in the s-z plane, parametrized by z i ,  Figure 11 shows the parametric expressions of Eq. (12). Each branch contributes to the current profile and therefore the branches need to be added in a correct manner, to obtain an accurate current profile expression.
Three sets of z i data were used to produce the three branches visible in Fig. 11. These three data sets come from the three regions visible in Fig. 10 separated by asymptotes. The position of the asymptotes can be found through expanding the denominator of Eq. (11), truncating to second-order in z i , and finding the values of z i which result in the denominator going to zero which is where Eq. (11) will be undefined at the asymptotes. These asymptotes were found to be located at, and The most straightforward way to add the three branches visible in Fig. 11 would be to bin the data generated by the parametric equations, then add the binned data at the same z positions. This would allow the branches to be combined, despite the different initial z i that gave rise to the multiplicity in C l . However this approach, whilst being accurate would mean we lose the analytical expression. In the following section we reattain an analytical expression albeit at the cost of some further approximations.
After binning the data and adding the three branches, the final step to achieving the current profile, is to determine the scaling factor required to convert from the local compression ratio C l , to current, I. The scaling factor can be determined if the total bunch charge Q is known. Setting Q equal to the sum over all C l data points calculated after the binning, multiplied by the consistent spacing between the data points in units of time, Δt, and the scaling factor f, we obtain, Equation (12) assumes that the initial current profile is flat. If this is not the case, the initial current distribution can be taken into account through multiplying every occurrence of x i in Eqs. (13) and (14) by ρðz i Þ, where ρðz i Þ is the density of the initial bunch distribution.
Incorporating the scaling factor the final current profile is able to predict the double horn current profile. This is shown in Fig. 12. A small step in the current profile can be seen at z ≈ −11 μm. This is due to the flat initial current profile. As the edges of the bunch folds around upon itself (see Fig. 6), this results in a step in current density when the trajectory density is projected onto the z-axis. Figure 11 shows the initial edges of the bunch shown in blue and green, folded in to result in the step in the current profile at z ≈ −11 μm.

A. Retaining an analytical current profile expression
We can incorporate some approximations in our approach in order to retain an analytical expression of the current profile, with the cost of possible reduction in accuracy. This section of the paper will present an analytical expression for current profile that is applicable when caustics are present as well as when they are not.
The majority of the bunch is comprised of electrons from the middle section of Fig. 10, which we will refer to as the core of the bunch. This section corresponds to the portion of the bunch that does not fold over on itself in longitudinal phase space (see Fig. 3). This is also shown by the orange data points in Fig. 11. In the example case shown in Figs. 10 and 11, the middle portion of the bunch describes 73% of the total bunch. Therefore if we could consider only this middle portion of the bunch, we could develop an expression for the current profile comprised of electrons from the core of the bunch which makes up the majority of the bunch charge. Furthermore, when a nonuniform initial current profile is used, for example a Gaussian distribution, the current populating the noncore fraction of the bunch would be even smaller.
Considering only the core of the bunch we find that the current profile behaves as, Iðz i Þ ¼ where z i lim 1 and z i lim 2 are defined in Eqs. (13) and (14), and calculate the z i position of the asymptotes seen in Fig. 10. For the case where only one or no caustic folds are present, Eqs. (16) and (17) still hold and the limits of z i lim 1 and z i lim 2 can be ignored. The magnitude of the current expression is taken because in the case of an overcompressed bunch, where the head and tail swap position, C l becomes negative and so the subsequent expression for the current, I, needs to be made positive.

B. Linearly ramped current profiles
Using the caustic formation information presented earlier we can investigate the possibility of producing current profiles of specific shapes, which may be optimal for different purposes. One such example is the desire to achieve a linearly ramped current profile for optimal drive beams in plasma-based accelerator schemes [21,25,40]. England et al. showed experimentally that a linearly ramped profile could be obtained through using sextupole magnets located in a dispersive section, imparting nonlinear correlation in the longitudinal phase space [21,33]. In this section we derive an analytical approach to gain insight into generating a linearly ramped profile through altering the T 566 and U 5666 of the dispersive region, which could be achieved through sextupoles and higher-order multipole magnets [33,41,42].
Expanding Eq. (17) and grouping terms together, we can write out an expression for the current profile in terms of these newly defined parameters, FIG. 12. Current profile calculated with the parametric equations, Eqs. (16) and (17). where The aim is to force Iðz i Þ [Eq. (18)] to be linear in z f (not z i ). As Eq. (16) is not easily invertible, we can instead force Eq. (18) to be cubic in z i which should result in the current profile being linear in z f .
Taylor series expanding Eq. (18) results in, To obtain a linearly ramped current profile, we need to obtain a set of parameters for which the following expressions are close to zero, Equations (21), (22), and (23) can be used with an optimizer code to minimize the square of the right-hand side of each expression. An example which used this method is shown in Fig. 13. This illustrative example shows how one can determine the values of R 56 , T 566 , and U 5666 required to achieve a mostly linearly ramped current profile for a given initial bunch distribution.
In this example, we take an arbitrary electron bunch with initial longitudinal distribution parameters of c 1 ¼ 81.06, c 2 ¼ 5929.08, and c 3 ¼ 1.302 × 10 8 . This bunch, with a positive energy chirp (lower energy at the tail and higher energy at the head of the bunch) can be sent through a dispersive region to obtain a linearly ramped current profile. Through the analysis described above, we find we need the dispersive region to have the properties of R 56 ¼ −16.6 mm, T 566 ¼ 0.130 m, and U 5666 ¼ −1.153 m.
The resultant current profile calculated using Eqs. (16) and (17), is shown in Fig. 13. Figure 14 shows the electron trajectories with a gray vertical line indicating the nominal value of R 56 ¼ −16.6 mm. Figure 15 also shows electron trajectories, varying with position along the dispersive region. This figure shows the bunch moving beyond the position of maximal compression, resulting in the overcompressed bunch where the electrons originally occupying the head of the bunch have swapped position with the electrons in the tail. Figure 16 shows a histogram of the electron trajectory density along the vertical gray line (indicating the end of the compressor) in Fig. 15. This histogram corresponds to the current profile shape, and agrees well with the current profile calculated in Fig. 13.
The longitudinal phase space distribution that exhibits the linearly ramped current profile is shown in Fig. 17. In order to achieve the linearly ramped profile, the longitudinal phase space distribution is curved, such that projection onto the horizontal axis creates more current at the head of the bunch (negative z values) and less toward the tail. This result was found through overcompressing the bunch where caustics are less likely to form. A ramped current profile can also be achieved while undercompressing the bunch however this is more likely to result in a ramped, cusplike profile. Figure 14 shows that for values of jR 56 j < 14 mm which result in undercompression, the caustic expression (shown in red) is present at the head of the bunch. When jR 56 j > 14 mm, which corresponds to overcompression, the caustics do not form.

VI. DISCUSSION
The third-order term in the δðz i Þ distribution (i.e., c 3 ), is often cited as the root cause of current horn formation [11,36,43,44]. Generally it is the third-order effects (both those imprinted onto the longitudinal phase space by the rf curvature, longitudinal wakefields and other collective effects as well as the third-order effect encountered in the dispersive region) that lead to the greatly enhanced current at the head and tail of the bunch. However the caustic theory presented in this paper reveals that the cubic chirp is not solely responsible for the current horn behavior. In fact, Eq. (7) shows the conditions where current horns can form even with no cubic or higher order term in the energy chirp. This is due to the longitudinal phase space distribution, δðz i Þ, being squared and cubed in Eq. (7), producing the higher order perturbations necessary to result in the double horn current structure. The analysis presented in this paper reveals that it is a combination of properties of the chirp and compressor that determine if current horns will be present, and the degree of severity (i.e., the height of the current horns) that will result.
As mentioned in Sec. III, small continuous perturbations in the chirp δðz i Þ, can lead to dramatic local rises of the associated current profile. Controlling these slight variations in the phase space distribution of the bunch entering a dispersive region would be challenging. However it would be possible to control the evolution of the trajectories through the dispersive region using higher-order magnets. With the insight provided by the caustic condition, namely Eq. (7), R 56 , T 566 , and U 5666 could be chosen to create conditions under which caustics do not form. Multipole magnets can be included in the dispersive region to obtain the required values of R 56 , T 566 , and U 5666 , as demonstrated in [33,41,42].
Many variations of the caustic pattern and corresponding current profile are achievable, beyond the three cases shown in Fig. 7. Understanding how the current profile is influenced by caustic lines may provide another perspective on the challenge of tailoring current profiles. Applications of current profile shaping include creating linearly ramped current profiles for optimal plasma acceleration [21,25], current profiles shaped for suppression of coherent synchrotron radiation induced emittance growth [45], and optimal current profiles for free electron laser applications [43], to name a few.
Section V illustrates one way to create a linearly ramped current profile. It has been shown before that sextupole magnets can be added to a dogleg to create a linearly ramped current profile [21]. This work extends upon this concept through providing the analytical underpinnings, in Eqs. (16) and (17).
In addition to the above-mentioned current-shaping applications, consideration of the underlying caustics may give insight into the conditions leading to microbunching. Equation (8)  to investigate how microbunching evolves, so long as the initial energy distribution takes into account the energy modulation needed for microbunching to occur. Figure 3 shows electron trajectories forming a cusp caustic. However we have seen in Fig. 7 that higher-order catastrophes can also be produced. Indeed, the three panels in the top row of Fig. 7 give three different unfoldings of the butterfly catastrophe [29]. To witness these high order catastrophes, a high order polynomial fit of the initial distribution δðz i Þ is required. Using only up to cubic fit in z i , the highest order catastrophe produced analytically is a cusp.
A surprising result of Eq. (8) is that it is applicable for all high-order catastrophes such as cusps, swallowtails, elliptic umbilics, hyperbolic umbilics, etc. [1,2] provided the initial distribution δðz i Þ is a polynomial to sufficiently high degree, in z i . A hierarchy of motifs (cusps, swallowtails, butterflies, elliptic umbilics, etc.) will be generated, each displaying higher-order complexity, but all being governed by the same equation, Eq. (8).
Whilst the main examples detailed in this paper refer to the longitudinal plane, the concept of caustics appearing in electron trajectories is not limited to the longitudinal plane, and could be easily considered in the transverse plane. This would be done by instead considering the final transverse position x f (or y f ) in Eq. (2) with the transfer matrix elements relevant to the situation being studied.
The examples presented all show a bunch being undercompressed. It is interesting to note however that caustics (and the associated current spikes) are much less likely to form in an overcompressed bunch. This can be seen from the plots in the top row of Fig. 7. For example the maximum compression for the case shown in the first column of Fig. 7 is often calculated by equating (1 þ R 56 c 1 ) with zero [see Eq. (3)]. For this case, R 56 ¼ −1=c 1 ¼ −12.13 mm. For R 56 values greater in magnitude than 12.13 mm, the bunch is overcompressed. It can be seen from the top left subplot of Fig. 7 that at considerably smaller values of R 56 caustics no longer begin to form. Local increases in trajectory density can be seen for these small values of R 56 near the vicinity of the caustic, however the greatly enhanced current spikes will not appear.
Caustics by their very nature are discontinuities that result from small continuous perturbations of an input and reliably produce dramatic changes in the corresponding output-in this case in the current. Here, use of the word reliably, refers to the mathematical stability of caustics, whereby continuous small variations in the control parameters (e.g., R 56 , T 566 , etc.) will still see the caustics forming, although the location of the caustic may vary. Because of this, caustics could become a useful diagnostic tool, allowing us to indirectly measure small variations that consistently and reliably produce a large measurable change. For example, measuring the second-and third-order chirp of a particle bunch is extremely difficult at present. However measuring the relative heights of current peaks at a number of R 56 and T 566 values would allow us to extract these chirps.
Finally, it should be noted that whilst the examples detailed in this paper all involved electron trajectories, this work is applicable to any particle beam traversing a dispersive region.

VII. CONCLUSION
We have identified the current spike formations often seen in FELs as caustic formations of electron trajectories. However these caustics are also witnessed in a wide range of accelerator applications, and the methods presented here are easily adapted to such scenarios. Within the detailed example of strong bunch compression, a butterfly catastrophe was found to be the underlying mechanism behind the associated double-horned current profile.
The main result of this paper is the caustic expression for relativistic particle bunches traversing a dispersive region. This expression reveals where in longitudinal position and under what conditions caustics will form, allowing us to predict how caustic formation changes with R 56 , T 566 , and U 5666 and the influence of this on the current profile. An analytical expression for the current profile has also been derived. This opens up the possibility of either amplifying or avoiding caustic-induced current modulations present in a wide range of accelerator applications.