Beyond the Limits of 1D Coherent Synchrotron Radiation

An understanding of collective effects is of fundamental importance for the design and optimisation of the performance of modern accelerators. In particular, the design of an accelerator with strict requirements on the beam quality, such as a free electron laser (FEL), is highly dependent on a correspondence between simulation, theory and experiments in order to correctly account for the effect of coherent synchrotron radiation (CSR), and other collective effects. A traditional approach in accelerator simulation codes is to utilise an analytic one-dimensional approximation to the CSR force. We present an extension of the 1D CSR theory in order to correctly account for the CSR force at the entrance and exit of a bending magnet. A limited range of applicability to this solution, in particular in bunches with a large transverse spot size or offset from the nominal axis, is recognised. More recently developed codes calculate the CSR effect in dispersive regions directly from the Lienard-Wiechert potentials, albeit with approximations to improve the computational time. A new module of the General Particle Tracer (GPT) code was developed for simulating the effects of CSR, and benchmarked against other codes. We experimentally demonstrate departure from the commonly used 1D CSR theory for more extreme bunch length compression scenarios at the FERMI FEL facility. Better agreement is found between experimental data and the codes which account for the transverse extent of the bunch, particularly in more extreme compression scenarios.


Introduction
The emission of coherent synchrotron radiation (CSR) on curved trajectories can present a significant issue for short electron bunches, such as those used in free electron lasers (FELs) [1][2][3][4][5]. CSR can degrade the quality of electron bunches through an increase in projected and slice emittance, and energy spread. As FEL facilities push for more exotic lasing schemes, and the requirements for drive bunches become more stringent, there is an increasing demand for accurate techniques to both measure and simulate the bunch properties throughout the accelerator.
The theory of CSR, and its influence on the electron bunch properties, has been an active area of interest [6][7][8][9], particularly due to the effect of CSR on the beam emittance [10][11][12][13][14][15][16]. We present some new insights on the theory of the 1D CSR transient field at the edges of dipole magnets, based on the interactions between the velocity and acceleration components of the Liénard-Wiechert field. This work suggests novel compressor designs for the minimisation of this instability. A new CSR feature of the General Particle Tracer (GPT) [17] tracking code was developed specifically for this study, which does not use the small-angle or ultrarelativistic approximations.
A number of other codes exist which are capable of simulating the effects of CSR [18,19], some of which utilise a 1D approximation, based on [6,8], and others which extend the model to incorporate 2D and 3D effects [20][21][22]. While previous studies have shown good agreement between results from some of these simulation codes and experimental data [3,4], there is a point at which the 1D approximation is no longer valid, as shown in [23], which suggests that projecting the bunch distribution onto a line may overestimate the level of coherent emission, particularly when the bunch has a large transverse-to-longitudinal aspect ratio. An aim of this study is to determine if, during strong bunch compression, or for bunches with a large transverse-to-longitudinal aspect ratio, the limits of the 1D approximation could be found. This is achieved through comparing analytic results with simulation codes that incorporate the transverse bunch distribution, and with experimental data. The projected emittance of the electron beam was measured in parameter scans at the exit of the first bunch length compressor of the FERMI FEL [24,25].
The paper is organised as follows. In section 2 we derive the longitudinal CSR force in three regimes: the entrance transient regime, in which the entire bunch has not yet entered the magnet; the steady-state regime, when the entire bunch is travelling through the magnet; and the exit transient regime, at which point the head of the bunch has left the dipole, but the tail is still radiating. In section 3 a numerical simulation of the 1D CSR force is performed and the results are compared with analytical predictions. A further examination of the impact of the transverse extent of the bunch with respect to the CSR force is given in section 3.2, demonstrating the impact of projecting the particle motion entirely onto the longitudinal dimension on the evaluation of the CSR field. The FERMI facility is briefly outlined in section 4 along with details of the parameter scans undertaken to measure the projected emittance of the bunch as a function of compression, longitudinal distribution and matching. A comparison of the codes used for validating the simulation of CSR is given in section 5, and a comparison between theory, simulation and experiment is discussed in section 6. Finally, we summarise our findings in section 7.

Calculation of CSR force
This section will provide an extension of the 1D CSR force first calculated in [6], and subsequently expanded on in [8], by deriving new expressions for the CSR force at the entrance and exit of a bending magnet. We first consider the situation of a bunch of electrons on a curved trajectory at time t through a bending magnet of bending radius R and bending angle f m . The electromagnetic field acting upon any particular electron in the bunch is comprised of the fields emitted by electrons at earlier times t′<t on this curved path. In the following derivation, the subscripts 0 and 1 will refer to the emitting and receiving particle, respectively, and a prime indicates retarded time or position; that is, the point at which the field was emitted. To calculate the total field, we first consider the field emitted by a single electron at position r 0  ¢ inside the magnet at time t′ and observed by another electron at position r 1  at time t. For simplicity, in this section we neglect the transverse extent and energy spread of the electron bunch, and thereby assume that all electrons travel exactly along the reference trajectory. The electromagnetic field at r 1  due to the electron at r 0  ¢ is given by the well-known Liénard-Wiechert field [26] at time t: where e is the electron charge, ò 0 is the vacuum permittivity, c is the speed of light, γ is the relativistic Lorentz factor, 0 b  ¢ is the velocity of the emitting electron (normalised to c), 0 b  ¢ is the normalised acceleration of the emitting electron, r r 1 0 r =  - ¢ | | is the distance between the emission site and point of observation, and n r r . From now on, the first term of equation (1), which does not depend on 0 b  ¢ , will be referred to as the 'velocity' or 'Coulomb' field, and we will refer to the second term as the 'radiation' field. Conventionally, several regimes of CSR forces are identified according to the positions of the emitting and observing particles [6].
Initially, the particle in front is inside the magnetic field of the dipole and the particle behind has not yet entered it, in which case 0 0 b  = and only the first term of equation (1) contributes, known as the 'entrance transient' regime. When both particles are inside the magnet, both terms in equation (1) contribute to the CSR field, and this is known as the 'steady-state' regime. Finally, when the emitter is still in the magnet and the receiver has exited it, this is known as the 'exit transient' regime. Equation (1) describes the electric field due to a single point particle, and so to calculate the entire CSR field requires a convolution of this expression with the charge density of the entire bunch, using the general expression for the longitudinal CSR wake E || at a given position z: where N is the number of particles in the bunch, e the electron charge, λ(z) is the longitudinal charge distribution, with the normalisation condition s s d 1 , and w z z -¢ ( )is the parallel component of the field in equation (1) at position z in the bunch due to a particle at position z′ in the bunch.

Steady-state regime
As shown in [6,23], the electric field observed at position z for a line charge λ(z) due to the motion on a circular arc of radius R is given by: where f is the angle from the entrance of the magnet to the observation point, z u R u u 2 sin 2 b D = -( ) ( ( )) and u is the retarded angle between the emitter at time of emission and the observer at time of observation. A schematic of this scenario is shown in figure 1. Note that both the position of the emitting electron at time of emission r 0  ¢ and at time of observing r 0  have been drawn, reflecting the fact that the bunch travels a considerable distance during the time required for the electromagnetic field to travel from emitter to observer. This formula is valid for a rigid line charge, using the ultrarelativistic approximation (β≈1). This model also does not take account of any effects due to dipole fringe fields. The transition to the steady-state regime takes place at a distance D SS from the entrance to the magnet [6]: with σ z the rms bunch length.

Entrance transient regime
In this regime, the condition D SS has not been reached, and a significant portion of the emitting particles have not yet entered the magnetic field. This means that their contribution comes entirely from the velocity field of equation (1). For the full derivation of the total CSR field in this regime, see appendix A. The resulting expression for this field is: where y y Ry R 2 sin 4 sin 2 2 22 with y the distance between the emitting particle and the entrance of the magnet, and d the length of the drift before the magnet taken into account for the calculation of the CSR field. A representation of this regime is shown in figure 2. The contributions to the field from E SS || arise from the radiative emission of particles on the curved trajectory, while the other term comes from particles which have not yet reached the magnet at the time of emission. Both terms of equation (5) partially cancel, and the net CSR field has a lower amplitude than either term. In the limit of the drift before the bend d  ¥, in the small-angle and ultrarelativistic approximations [6], this field reduces to: However, without taking this limit, that is, if d is small, the contribution from the velocity term is smaller than expected from equation (6) and the radiation term dominates.
This result-that the velocity component of the Liénard-Wiechert field can provide a non-negligible contribution to the CSR field in the entrance transient regime, even in the ultrarelativistic limit-can be understood in the following way, as illustrated by figure 3. The Coulomb field of a particle on a straight trajectory is confined to a narrow disk, and it appears to be produced instantaneously by the electron at position r 0 , at time t 0 to an observer, whereas in fact the field was produced at a retarded time t 0 ¢ ( figure 3(a)). Even if the electron subsequently moves onto a different trajectory between t 0 ¢ and t 0 , this will not change the field at the observation point, and the Coulomb field is still travelling along the straight path ( figure 3(b)). For a bunch of electrons beginning to enter a curved path, the electrons at the head will observe this Coulomb field generated by the tail of the bunch, as the field from the tail has been able to 'catch-up' with the head, which has taken a longer time to travel the same longitudinal distance along the initial axis (figure 3(c)). This model suggests that, for a given angle f into the magnet, there exists a characteristic drift length d c needed to generate Coulomb fields at that position -that is, to have an entrance transient effect ( figure 3(d)). This distance can be estimated by calculating the required distance in front of the magnet that the field would need in order to be observed by the observing electron, giving: Depending on the length of the drift section preceding the bend, the effect of the entrance transient will have a varying effect, and so it is necessary to take d c into account in order to correctly account for this. For our benchmark case (see section 3), and taking . Distances of the order of tens of metres can be incorporated into simulations of bunch compressors for linear machines, but this cannot be done for bends in circular accelerators due to the higher concentration of dipoles. This means that errors can be made if the formula equation (6) is applied in these scenarios, or if a sufficient drift is not taken into account before the entrance to a dispersive region.

Exit transient regime
Consider the situation at time t which an electron bunch has travelled through a bending magnet of bending radius R and bending angle f m and is currently a distance x c past the exit edge of the magnet. The electromagnetic field acting upon any particular electron in the bunch is comprised of the fields emitted by electrons at earlier times t′<t when they were still inside the magnet. To calculate the total field, we first Figure 2. Geometry of CSR interaction between an emitting electron at r 0  ¢, at a distance y before the magnet and a receiving electron at r 1  within the magnet. ψ is the angle between the emitter at time t′ and the receiver at time t, and ξ is the angle between b  and n  .
The distance d gives the drift before the entrance of the magnet from which the CSR computation begins. The distances and angles shown in this schematic are derived in appendix A.
consider the field emitted by a single electron at position r 0  ¢ inside the magnet at time t′ and observed by another electron at position r 1  past the magnet at time t. The geometry of this case is sketched in figure 4.
For the full derivation of the total CSR field after the exit of the bending magnet, see appendix B. Defining the following quantities: x Rsin cos , with ψ the angle between the emitting electron at retarded position r 0  ¢ and the exit of the magnet, we obtain the following expression for the radiation field: In this expression, x=x c +z is the position of the evaluation point with respect to the exit edge of the magnet, with x c the distance from exit edge to bunch centroid and z the position relative to the bunch centroid. In the integral, the charge density should be evaluated at z′, which from equation . The corresponding expression for the velocity field is: In the integrand of equation (12), ψ(z) is defined implicitly by the relation: Here, it has been taken into account that source points positioned after the exit of the magnet do not contribute to the CSR radiation, and the first two terms arise because equation (12) is the result of an integration by parts. We can now follow a similar procedure to calculate the velocity component of the field given by equation (11). The kernel is strongly peaked around ψ=0, and so we can assume that λ(z) is constant over the relevant range, and apply a small-angle Taylor expansion, resulting in: This term cancels with one of the boundary terms in equation (12), resulting in the following expression for the total CSR exit transient field: This is equivalent to the expression for the exit transient field given in [8]. However, we have provided a full explanation of how both the velocity and radiation components of the Liénard-Wiechert fields complement each other to produce this result. A comparison between equations (10), (12) and the full formula (15) is given for a benchmark case in the following section. For a schematic representation of the CSR velocity field during rectilinear motion, motion on an arc, and the transition regime upon exiting a curved trajectory, see figure 5. A physical description for the underlying mechanism behind the interaction of both the velocity and radiation fields can be understood as follows. The contribution from the velocity field is significant only within a very small range ψγ −1 =1. The field lines corresponding to the velocity field of a relativistic particle are confined in a very flat pancake perpendicular to the direction of motion. An important property of the velocity field is that the field lines point away from a virtual source point that moves with velocity βc in the direction that the emitter had at the time of emission. In the figure the retarded position of the emitter is shown, and the apparent, instantaneous source of the velocity field is also indicated. For a bunch moving in rectilinear motion (figure 5(a)), this apparent source point remains coincident with the instantaneous position of the emitter. Two particles that are longitudinally next to each other barely feel each other's field due to the pancake effect. The field lines of the upstream particle are always behind the downstream particle.
In case of an arc (figure 5(b)), the path of the observer curves away from the direction that the emitter had at time of emission (denoted the 'z direction'). Therefore the z component of the velocity of the observer becomes lower than βc during the transit time in which the field travels from emitter to observer. Therefore, at time of observation, the 'pancake region' of dense field lines is in front of the observer. In either the rectilinear or arc case, the upstream particle observes a very small field. However, at the end of the arc (figure 5(c)), the geometry must pass from a situation with field lines in front of the observer to a situation with field lines behind the observer. Hence there must be a point where this field passes over the observer, giving a spike of CSR force. This effect is the exact analogue of the entrance effect sketched in figure 3, in which the geometry transits from a case with the velocity field behind the observer to a situation with the field in front of it.
The above mechanism may also explain why the contribution of the velocity field is only significant in the very final angular range 0<ψ<γ −1 of the arc, as detailed in the previous section. This is simply the angular extent of the pancake field that needs to pass over the observing particle. It should also be noted that the field line patterns sketched in the figures are not entirely realistic, because there will only be a thin radiation shell of thickness Δs/β generated from the path element Δs, and only in this thin shell the drawn pancake field line pattern exists. The subsequent path element will generate another radiation shell, and the corresponding 'pancake field' inside that shell will be slightly differently oriented due to the different orientation of the path element. The total field line pattern will be the sum of all such infinitesimal shells-with-pancake-fields, in which the concept of a pancake field will be hard to recognise at all. The main point is, however, that with any path element there is an associated region of dense field lines. Near the end of the arc, there is a point where this region will pass over the upstream particles, creating a brief but intense spike of CSR force. A similar effect has been observed in simulations of a chicane with codes based on Liénard-Wiechert retarded potentials [22]. The field lines due to the velocity field of the emitting particle (A′) are behind the observing particle (A) during rectilinear motion. (b) On an arc trajectory, the velocity field lines of the emitter are in front of the observing particle. (c) In the exit transition regime, there is a small range over which the observing particle experiences a sharp spike in the CSR force due to the emitter.

Numerical validation
In order to validate the analytical results of sections 2.2 and 2.3, we have numerically calculated the electromagnetic field distribution in an electron bunch in both the entrance and exit transient regimes using the GPT code [17]. GPT is a particle tracking code that integrates the equations of motion of a large number of charged particles in the presence of electromagnetic fields. We have made a dedicated upgrade to the code in order to include the computation of the retarded Liénard-Wiechert fields of the tracked particles. Because this involves the storage of the trajectory of the particles and solution of retardation conditions, calculation of Liénard-Wiechert fields is computationally expensive. To reduce the computational cost, we avoided evaluating the field of each tracked particle, but instead the particle bunch is represented by a number of bunch slices (see figure 6). Each bunch slice is represented by either four or sixteen off-axis particles that are spaced according to the rms transverse size of the slice in order to capture the impact of the transverse extent of the bunch. While integrating the equation of motion of a tracked particle, GPT evaluates the Liénard-Wiechert field resulting from the stored history of the past trajectory of each of the representative particles at the longitudinal position of the tracked particle, based on a stored history of the bunch trajectory.
It is important to note that GPT uses the exact expression for the Liénard-Wiechert fields based on the numerically obtained coordinates of particles in the bunch, and does not apply any analytic approximation or presumed trajectory of the bunch. The parameters used in the simulation are listed in table 1. We deliberately chose artificially small energy spread and transverse bunch size, and used hard-edged magnet fringes in the exit transient simulations to match the analytic case as much as possible. Figure 6. Representation of particle bunch adopted by GPT to calculate CSR forces. The particle bunch is discretised and represented by slices. The CSR force is then calculated and projected onto the bunch.

Entrance transient effect
The CSR field was initially calculated by GPT at a point 24 cm into the magnet in order to simulate the entrance transient field. This distance is only half that of the steady-state condition D SS (equation (4)), and so it is expected that the general expression of equation (6) will be required to calculate the fields. In this simulation, the drift before the magnet was set to 50 m. The results from the simulation are in good agreement with equation (6), as seen in the right-hand plot of figure 7. However, if the simulation is run again, but with the drift before the bend set to 10 cm, the GPT result effectively reduces to equation (5), and thereby differs from the usual approximation of [6]. The second term on the right-hand side of equation (5) is suppressed by lowering the integration boundary, showing that the approximation of an infinitely long drift before the entrance to a bending magnet may not be valid for some cases. As shown in the left-hand plot of figure 7, the GPT simulation reflects this behaviour.

Exit transient effect
Next, we numerically validate the analytic results for the CSR forces in the exit transient regime derived in section 2.3. Because the net CSR field experienced by the bunch involves cancellations between radiation term and velocity term, as is discussed in section 2.3, it proves to be of interest to study in turn both the full CSR field and the radiation term separately. Figure 8 shows the longitudinal component of the electric field as a function of longitudinal position in the bunch, evaluated at 5 mm past the bending magnet. The full CSR field is represented by the orange line (analytic result equation (15)) and the blue dots (GPT simulation). Clearly, equation (15) gives an accurate approximation to the full CSR field in the exit transient regime. This means that, at least in the  studied parameter regime, the 1D, ultrarelativistic and small-angle approximations underlying equation (15) do not lead to any significant deviations from the exact CSR force. However, an interesting 3D effect may be observed when studying the radiation term separately. In figure 8, this term is plotted according to the analytic result based on 1D approximation equation (12) (brown curve) and according to the GPT simulation (black dots). Clearly, equation (12) significantly overestimates the magnitude of the radiation term. We found that this overestimation of the radiation field is due to the underestimation of the retarded distances between emitting and observing particles associated with the 1D approximation. Namely, the impact of the finite transverse bunch size could be roughly quantified by including a vertical offset of the emitting electron (i.e. out of paper in figure 4) in the derivation of the CSR force. Figure 9 gives a side view of the resulting configuration. Due to the offset, the distance σ from emitter to observer becomes: In addition, the angles θ, η and ξ are stretched somewhat, such that their cosines become smaller by a factor cos d r s = . Re-evaluating equation (B.7) with these modifications shows that the electric field is still given by equation (10) after the substitution ρ→σ. The red curve in figure 8 shows the resulting radiation field after including such a transverse offset of the emitting particles equal to the rms bunch size in the simulation. Using the bunch parameters in table 1, an offset in y equivalent fo the rms bunch width was implemented, equal to 4.5 m y y Indeed, the radiation field is reduced to roughly the magnitude observed in the simulation. This shows that the finite transverse extent of the bunch is responsible for the discrepancy between the 1D description (equation (12)) and the simulation, and thus that a 1D description is inadequate when treating the radiation or velocity term in the exit transient regime in isolation. We have checked that, analogously, also the velocity term is overestimated by its 1D approximation equation (14). Remarkably, the 3D effect is esentially absent in the full CSR force due to the cancellation between the radiation and velocity terms observed in section 2.3.

Parameter scans used in simulation and measurements
A schematic of the FERMI linac is shown in figure 10. The emittance was measured at the exit of the first bunch compressor, BC1, as a function of Linac 1 RF phase (i.e. energy chirp, that is, a longitudinal energy-to-position correlation along the bunch), chicane bending angle, and the strength of the last quadrupole before the entrance to the bunch compressor. The first two scans implied a scan of the bunch length compression factor (that is, the ratio between the bunch length at the entrance to, and at the exit of, the compression chicane) in the range 20-64 and 8-60 for the Linac 1 phase and chicane bending angle scans, respectively. The scan of quadrupole strength was done at the fixed compression factor of 36. The compression process was kept linear during the scan by virtue of an X-band RF cavity, which allows to approximately preserve the current shape through the chicane, as shown later in figures 16(a) and (b) [27,28]. During the phase scan, the accelerating gradient of Linac 1 was scaled in order to keep the mean bunch energy constant at the entrance to BC1. Measurements were taken using the single quad-scan technique [29], by varying the strength of one quadrupole magnet (Q_BC01.07), located in the section directly after BC1. The machine was operated with a constant bunch charge of 100 pC, and a mean energy of approximately 300 MeV at BC1. The main accelerator parameters for this experiment are given in table 2. For each set of scans, the two other scanning parameters were kept constant. During the experimental run, the following scans were performed: • Linac 1 phase-vary between 70.5°and 73.3°(nominal is 73°).
At the diagnostic stations, both yttrium aluminium garnet (YAG) and optical transition radiation (OTR) screens are available. Estimates of the resolution for these screens are, respectively, 45 μm for a pixel width of 31.2 and 25 μm for a pixel width of 19.6 μm [30]. The majority of the measurements were initially taken with OTR screens, but coherent effects were suspected to be having an effect on the measured emittance as the bunch approached maximum compression, and so some measurements were repeated with YAG screens, whose performance is expected to suffer much less from coherent emission. The typical emittance measurement procedure consists of taking at least 5 images for between 10 and 30 settings of Q_BC01.07, and the single quadscan technique (see, for example, [29]) is applied to calculate the transverse emittances and Twiss parameters.

Simulation setup
Simulations of the FERMI injector (up to the exit of the first linac, see figure 10) have been produced using GPT. In order to accurately match the simulation to experimental conditions, the measured transverse and longitudinal profiles of the photo-injector laser were used as input parameters to the simulation (shown in figures 11 and 12), along with geometric wakefields from the injector linac Full 3D space-charge effects were also included. The injector linac phase was optimised for minimal energy spread-as is done in the routine procedure of linac tuning-and good agreement was found between the simulated and experimentally measured bunch properties at the exit of the injector. From this injector simulation, the bunch was then tracked using the ELEGANT code [31] up to the entrance of BC1, including the effects of linac wakefields, the laser heater, which is a tool aimed to suppress the so-called microbunching instability that otherwise develops as the bunch propagates through the accelerator [32,33], CSR and space-charge models. From this point, three particle tracking codes have been used to compare the emittance measurement results with simulation: ELEGANT, CSRTRACK [34] and a modified version of GPT which utilises the CSR model outlined above in section 3. In the 1D CSR simulations, ELEGANT applies the calculation of Saldin et al [6] to calculate the energy change due to coherent radiation in a bend, and the subsequent transient effect some time after the bunch exits the dipole, based on [8]. In the ELEGANT calculation,  the dipole is split up into pieces, and the bunch is tracked sequentially through each piece. At each point, the bunch is projected onto the reference trajectory and the electric field of the bunch is computed. The projected (1D) method of CSRTRACK divides the bunch up into Gaussian 'sub-bunches', smooths the distribution, and calculates the CSR field from a convolution of the distribution with a kernel function describing Liénard-Wiechert fields across the bunch trajectory [35]. At the exit of the bunch compressor (including a drift to account for transient CSR effects), the CSRTRACK output is then converted back into ELEGANT, and tracked up to Q_BC01.07, the measurement point.
As described above in section 3, the CSR routine in GPT does not employ the 1D approximation, but calculates the retarded Liénard-Wiechert potentials directly by slicing up the bunch longitudinally, and it does not directly project the radiating particles onto a line. Each slice contains a number of radiation emission points (typically four), and the full history of both the fields and the particle coordinates are stored for each time step. This code does have the option to include CSR shielding effects by adding mirror charges, but these were not included as these effects are negligible for the bunch regime and machine parameters used in this study [1]. The 3D routines in CSRTRACK also calculate the radiation fields directly, but in a slightly different manner. For our simulations, we have utilised the csr_g_to_p method, in which the particles are first replaced by Gaussian 'sub-bunches', and the radiation field is calculated via a pseudo-Green's function approach [35], with each subbunch having an effect on each particle in front of it.
It should be mentioned that the number of bins used for the density histogram in the CSR and longitudinal space-charge (LSC) models of ELEGANT, in addition to the smoothing applied on the bunch, can have an impact on the final results [36]. Following a convergence study, by varying the number of CSR bins between 100 and 5000, and performing the parameter scans for 10 6 , 5×10 6 and 10 7 macroparticles, we have determined that 500LSC and CSR bins for an ELEGANT simulation of 10 6 macroparticles is sufficient. Following previous studies [16], we set the sub-bunch size for the CSRTRACK calculations to be 10% of the rms bunch length. A similar set of simulations was run in GPT in order to achieve convergent results, for input distributions of 10 5 , 10 6 and 10 7 macroparticles. To determine the significance of the Coulomb term outlined in sections 2.2 and 2.3, GPT simulations were also run with this term deactivated. Since dipole fringe fields are included in CSRTRACK by default, the parameter scans were also simulated with dipole fringes in the other two codes. This should also provide the most realistic benchmark with the experimental case.

Results
During the experimental run, the parameter scans detailed in section 4 were performed, and the emittance was measured by quad-scan using the FERMI online emittance tool. Plots comparing the emittance measurements with simulation results from the two codes are given in figures 13(a), 14(a) and 15(a). The CSR-induced emittance growth in these regimes has also been calculated, based on the 1D analytic theory given in [37]. The emittance growth corresponding to the longitudinal and transverse CSR wake with the entire bunch travelling on a circular orbit (i.e. the steady-state regime) are given as [37,38]: We also provide calculations of the ratio σ v [23], indicating the validity of the 1D CSR approximation in figures 13(b), 14(b) and 15(b). For the analytical calculations to be valid, the following condition should be fulfilled: with σ ⊥ the transverse beam size. If this condition is not fulfilled, the 1D CSR approximation can be violated approaching maximal compression or in cases where the transverse beam size is large. The values for the σ ⊥ and σ z are taken from ELEGANT simulations with CSR switched off. As seen from the plots, there is a general agreement between the measurement procedure, simulation results and analytic calculations, at least in terms of the trends. For the quad scans ( figure 15(a)) in particular, some post-processing was necessary in order to crop some of the images-for a strongly mismatched bunch, some of the bunches were barely visible above the noise. The discrepancy between simulation and experiment in the peak around 71.6°-72.1°in figure 14(a) can be attributed to coherent OTR emission (COTR). It has been demonstrated elsewhere [39,40] that intense COTR emission can lead to an underestimation of the transverse beam size, and thereby to lower measured emittance values. In both sets of experimental data for varying compression factor, there is a slight dip around the point where a peak in emittance is seen in simulation. This interpretation is supported by the observation that the largest mismatch between the ELEGANT simulation and the two sets of experimental results for this data set occur where the bunch length is around 40 fs or less-this is  the point where coherent emission is expected to be maximised. We observe a similar apparent overestimation of emittance growth for the bunch compressor angle scan in figure 13(a) for the ELEGANT simulation. GPT and CSRTRACK 3D are able to capture both the emittance trend and its absolute value more accurately over the entire range of bunch lengths.
The simulated current profiles for the bunch compressor and linac phase scans are shown in figure 16. For the linac phase scan, the largest discrepancies between the experimental data and the CSRTRACK and GPT simulations occur between linac phase settings of 71.6°-72.1°-in this range, the maximum current is greater than 1.3 kA, and the compression factor varied from 63.5 to 52.3. Comparing the results from simulation and experiment with σ v , we observe the most appreciable overestimation of the effect of CSR in the 1D simulation and analytic calculations when σ v is greater than 2.5 at any point across the chicane. When the value σ v is smaller than this value, as during configurations with more moderate compression as in figure 13(a), the agreement between all of the simulation and experimental results is good.
The differences between the ELEGANT results and those from CSRTRACK and GPT simulations are also noteworthy. It appears that, when the bunch undergoes maximum compression (as seen from the minimal bunch length in figures 13(a) and 14(a)), the discrepancy between the 1D and 3D codes is largest, with ELEGANT returning an emittance value around 40% larger than CSRTRACK. GPT does return a slightly higher value for the emittance than CSRTRACK and the experimental data around maximal compression. In order to rule out LSC in ELEGANT accounting for this difference, the parameter scans were simulated with LSC switched on and off in ELEGANT, with only a maximum reduction of 5% in the projected emittance without LSC. Little variation was seen in the GPT results with space-charge switched off. Comparisons between CSR simulations and experimental data have been studied previously [2][3][4], but only for moderate compression factors (up to around 15 at a given bunch compressor). Indeed, at moderate compression factors-up to around 15-20, at which point the bunch length approaches 100 fs, we see relatively good agreement between the codes and experimental data to within 10%. It can also be seen that the ELEGANT simulations reproduce the analytic estimates for emittance growth in figures 13(a) and 14(a), suggesting that the code accurately reflects the predictions of the 1D theory; however, this also shows that the 1D theory may be inadequate for describing the effect of CSR in more extreme bunch compression scenarios. The fact that the codes which calculate the CSR fields directly from the retarded potentials give a closer agreement with experimental data further suggests that there are limits to the applicability of the 1D CSR approximation.
As the compression factor is increased-up to a maximum value of 64-more significant discrepancies between the simulation results appear. It appears that there is an overestimation of the effects of CSR in ELEGANT. By comparing the simulated slice properties for various compression factors, we can try to observe where the discrepancies arise. In order to isolate the effects of CSR, the parameter scans were run in ELEGANT and CSRTRACK 1D with CSR switched off (see figures 17(a) and 18(a)). The agreement between the codes in this case is good, and from this we can conclude that CSR is the dominant process causing the projected emittance growth. It is also clear that the CSR-induced emittance growth is largest in the central portion of the bunch, due to the greater density of particles in this region.  18(b)), it can be seen that, towards maximal compression, the ELEGANT simulation returns a higher value for the horizontal slice emittance in the central portions of the bunch as compared with the results from the CSRTRACK 1D simulation. This is the region where, for a bunch with a Gaussian longitudinal distribution, the steady-state CSR wake is largest. Slice emittance values at lower compression values (on either side of the maximum) show good agreement between the codes. The vertical emittance and current profiles are almost identical in all compression scenarios.
Another noteworthy effect of the Liénard-Wiechert potentials in strong compression scenarios is revealed by the GPT simulation. Our results have shown that neglecting the Coulomb term across the entire compression chicane can have an effect on the final output for stronger compression factors, or for bunches with a large horizontal size. Plots comparing the final projected emittance as simulated by GPT for the three parameter scans are shown in figures 19(a)-(c), with the Coulomb term switched on and off. It can be seen that, approaching  maximal compression, or largest transverse bunch size, the Coulomb term can have a significant impact on the final CSR-induced emittance growth. In the case of a larger bending angle in the chicane, this can be understood as the catch-up distance for the Coulomb term being shorter, and similarly for a bunch with minimal chirp around the linac phase for maximal compression. When the bunch has a larger transverse size due to the focusing into the chicane, the radiating cone is also larger, and so the Coulomb interaction between the tail and head of the bunch will also make a larger contribution. It is also likely that this neglected term will have a more significant impact for accelerator configurations with a higher density of bends, such as in arcs in energy recovery linacs (ERLs). These results give further evidence of the importance of correctly simulating CSR effects in dispersive regions.

Conclusions
By extending the 1D CSR theory, we have found that the longitudinal electric field as observed in the CSR interaction before the entrance to, and after the exit of, a bending magnet has a qualitatively different behaviour than is commonly assumed. In particular, the contribution to the CSR field from the Coulomb field of the Liénard-Wiechert potential cannot be neglected when calculating entrance transient effects, and in order to correctly model this interaction, these fields must be taken into account. The importance of the transient effects of CSR are significant in terms of minimising the projected emittance growth in bunch compressor systems, and therefore in optimising the accuracy of beam optics matching to the undulator line for high-gain UV and x-ray FELs [41,42]. The observations of this paper are interesting technologically because they suggest that it may be possible to design an optimised magnet (or system of magnets) in which the CSR impact of the magnet itself is partially cancelled by that of the drift directly after it, thereby reducing adverse effects like emittance growth and microbunching gain, particularly in more complex transport systems such as compressive arcs in ERLs. It may also be possible to extend our analytical treatment in the case of two bending magnets limiting a straight drift, providing an extension of the validity range of the formulae.
We have also detailed a comparison between experimental measurements and simulation results to determine the effect of CSR on projected emittance growth, and have shown some agreement with ELEGANT, GPT and CSRTRACK simulations. Good agreement between the simulations and FERMI measurements is seen when the compression, rf parameters, and matching are closest to nominal. As the compression ratio increases, the differences between the simulation methods become more clear. As expected, the 1D simulation results diverge more significantly both from the experimental data, and from simulations results with codes which take the transverse extent of the bunch into account in situations where the condition equation (19) is strongly violated, and the 1D CSR approximation breaks down. The breakdown of this condition has been studied experimentally; the theory suggested that the condition is valid only in the parameter regime σ v =1, whereas it has been demonstrated that up to σ v 2, the 1D CSR approximation remains valid, and so this condition can be relaxed. Future high brilliance FELs gain from total control of emittance in multi-bend lines, referring both to magnetic compressors and to high energy switchyard lines. A more accurate and realistic prediction of beam brightness degradation/preservation, also in proximity of points of full compression, would allow an optimised design from the very first stages. )and D R sin f = ( ), and therefore the distance ρ between the emitter at the retarded position r 0  ¢, at a distance y before the entrance to the magnet, and the receiver at r 1  is: The time taken by electromagnetic signals to travel from emitter to observer is t t c r -¢ = . During this same time, the bunch must have travelled a distance Rf+y−Δz along the path in order to have the observing electron at the position sketched in figure 2   x h f These inner products can be expressed in terms of the angle f as follows: This is the field observed by a single point particle at an angle f into the arc, produced by another single point particle at a distance y before the entrance of the arc. In order to obtain the field due to a bunch of particles, the bunch with a charge density Neλ(z) should be thought of as a number of point particles at positions s=s c +z, each with charge Neλ(z)dz, where s is the absolute position along the path, z is the position within the bunch relative to the bunch centroid and s c the position of the centroid. Summing up the contributions from all the fields of these point particles gives: where the first term represents the field contribution at the position of the receiver due to the part of the bunch that is still before the magnet entrance at the time of emission, E SS || is the contribution to the field due to the part of the bunch that is inside the magnet at the same time, and z max is the position in the bunch giving the boundary between these two parts. In order to evaluate equation (A.14) directly, an explicit relation between the current position of the emitter z′ and its position at the time of emission y is required. This can be done by changing the integration variable from z′ to y, and so we can use equation ( where Δ(y)=y+Rf−βρ(y), and d the length of the drift before the magnet taken into account for the calculation of the CSR field. The upper integration boundary of this expression arises due to the finite length of the straight section before the entrance to the magnet.

Appendix B. Derivation of CSR exit transient
This derivation will parallel that given above in appendix A for the entrance transients. To evaluate equation (1), we first calculate a number of lengths indicated in figure 4. The angle ψ is the angle between the emitter and the end of the arc.
where x is the distance from the exit edge of the magnet to the observing electron. The time taken by electromagnetic signals to travel from emitter to observer is t t c r -¢ = . During this same time, the bunch must have travelled a distance Rψ+x−Δz along the path in order to have the observing electron at the position sketched in figure 4 at time t, where z z z D = -¢ is the instantaneous distance between both electrons.
Since we are interested only in the component of the field parallel to the direction of b  , we take the inner product E b   · . As it turns out, both the radiation term and the velocity term of the Liénard-Wiechert field make a significant contribution, even in the ultrarelativistic limit. Expanding the triple vector product in the radiation term of the field (equation (1) The superscript PP indicates that equation (B.7) gives the field of a point particle. We can calculate the inner products in this expression as follows: Substituting these expressions into equation (B.7) and separating the first and second terms into the velocity and radiation components, respectively, results in the single-particle longitudinal components of the CSR field: These are the contributions of the velocity and radiation terms to the field observed by a single electron at distance x after the exit of the arc, produced by another single electron at angle ψ before the exit of the arc. Which particular electron of the bunch distribution actually is at angle ψ at the required time of emission is governed by the retardation condition equation (B.2). One may be tempted to neglect the velocity term E ,vel PP || in the ultrarelativistic limit on account of the factor γ −2 . However, the radiation term contains an additional small factor sin 2 y ( ) in the numerator, and so in the end both terms are comparable in size. The combined field E due to all electrons between the tail of the bunch and the observing electron is obtained by adding the fields E PP of the individual particles. This results in:   give the Liénard-Wiechert field of a bunch exiting a circular arc, without any ultrarelativistic or small-angle approximations. However, through applying these approximations we can arrive at a simpler form for these fields. Given that the integrands in these expressions are strongly peaked around a small range of ψ=1, approximations can be made using Taylor expansions-although it should be noted that the approximation ψ=x/R cannot be used, as the post-bend distance x may also be small. First, we re-evaluate the distance ρ (equation (B.1)) between the emitter at the retarded time and the receiver at the current time:   . Firstly, the velocity field is suppressed by a factor γ −2 , so in many cases this field is negligible with respect to the radiation field. However, the integrand of the radiation field also contains the factor ψ 2 , which suppresses this field at small angles. Therefore, there is a small part of the integration interval ψγ −1 in which the velocity field dominates, rather than the radiation field, and vice versa for the regime ψγ −1 . Secondly, in both the velocity field and the radiation field individually, the same two regimes can be distinguished when considering the importance of the terms proportional to γ −2 against those proportional to ψ 2 . Therefore, in the regime where the velocity field dominates, the significant terms are N 1 and D 1 , and in the regime with the dominant radiation field, the significant terms are N 4 and D 2 . Combining these results, we can make a further approximation: