## research papers

## Numerical optimization of spherical variable-line-spacing grating X-ray spectrometers

^{a}Swiss Light Source, Paul Scherrer Institut, CH-5232 Villigen-PSI, Switzerland, and ^{b}UPMC University Paris 06, CNRS UMR 7614, Laboratoire de Chimie Physique – Matière et Rayonnement, 75321 Paris Cedex 05, France^{*}Correspondence e-mail: vladimir.strocov@psi.ch

Operation of an X-ray spectrometer based on a spherical variable-line-spacing (VLS) grating is analyzed using dedicated ray-tracing software allowing fast optimization of the grating parameters and spectrometer geometry. The analysis is illustrated with optical design of a model spectrometer to deliver a *L*-edge). With this energy taken as reference, the VLS coefficients are optimized to cancel the lineshape asymmetry (mostly from the coma aberrations) as well as minimize the symmetric aberration broadening at large grating illuminations, dramatically increasing the aberration-limited vertical acceptance of the spectrometer. For any energy away from the reference, corrections to the entrance arm and light incidence angle on the grating are evaluated to maintain the exactly symmetric lineshape. Furthermore, operational modes when these corrections are coordinated are evaluated to maintain either energy-independent focal curve inclination or maximal aberration-limited spectrometer acceptance. The results are supported by analytical evaluation of the coma term of the optical path function. This analysis thus gives a recipe for designing a high-resolution spherical VLS grating spectrometer operating with negligible aberrations at large acceptance and over an extended energy range.

Keywords: resonant inelastic X-ray scattering; X-ray optics; X-ray spectrometers; spherical VLS gratings.

### 1. Introduction

RIXS (resonant inelastic X-ray scattering) is a synchrotron-radiation-based photon-in/photon-out spectroscopic technique, which gives information about charge-neutral low-energy excitations of the correlated electron system in solids, liquids and gases over the charge, orbital, spin and vibrational ). The availability of high-brilliance synchrotron radiation sources and recent progress in RIXS instrumentation (Ghiringhelli *et al.*, 2006) allowing a *E*/Δ*E* of better than 10000 has extended RIXS experiments from the energy scale of charge transfer, crystal field and orbital excitations to that of magnetic and vibrational excitations (see, for example, Schlappa *et al.*, 2009; Braicovich *et al.*, 2010; Hennies *et al.*, 2010).

Scientific progress in the field of RIXS is closely connected with progress in instrumentation. It pursues two main goals: improvement of the energy resolution towards progressively smaller energy scale of various charge-neutral excitations and, in view of low ) as single optical element combining the dispersion and focusing actions. Although these instruments suffer from relatively small angular acceptance, their advantage is to deliver high-energy resolution at downright simplicity. The first and still most widely spread high-resolution instrument of this type (Nordgren *et al.*, 1989) uses a constant-line-spacing spherical grating. In order to cancel the coma aberrations it operates in the Rowland circle geometry. This geometry is characterized by grazing inclination of the focal curve (FC) which results in the necessity of large detector displacements with energy and, most important, small grazing angles of incidence on the detector incompatible with the modern directly illuminated CCD detectors. These disadvantages can be resolved with spherical variable-line-spacing (VLS) gratings (Osborn & Callcott, 1995; Cocco *et al.*, 2004; Ghiringhelli *et al.*, 1998, 2006; Tokushima *et al.*, 2006) which allow formation of any desired inclination of the focal plane towards upright as well as cancellation of the coma aberrations. The spherical VLS grating (SVLSG) is used, in particular, in the spectrometer SAXES (Ghiringhelli *et al.*, 2006) of the ADRESS beamline (Strocov *et al.*, 2010) at the Swiss Light Source, Paul Scherrer Institut. This instrument delivers *E*/Δ*E* above 11000 at 1 keV photon energy, presently the highest achieved resolving power.

The optical design of the SVLSG-based spectrometers is more complicated compared with the simple Rowland conditions and includes numerical computations. The optimal design should ensure minimal optical aberrations (and thus maximal resolution) at maximal angular acceptance (and thus spectrometer transmission). Here, we demonstrate the optical design of a model SVLSG spectrometer with *E*/Δ*E* above 20000. The grating parameters are optimized for a reference energy *E*_{ref} of 930 eV (Cu *L*-edge, important, for example, for the physics of correlated cuprates) to cancel the lineshape asymmetry coming mostly from the coma aberrations as well as to minimize the symmetric line broadening piling up at large illuminations. Furthermore, following our preliminary technical report (Strocov *et al.*, 2008), we evaluate adjustments of the spectrometer geometry upon variation of energy necessary to maintain the symmetric lineshape and constant focal curve inclination or maximal aberration-limited acceptance for any energy away from the reference.

### 2. Numerical procedure

Our evaluation of the grating parameters and spectrometer geometry described below used the dedicated software package *TraceVLS* written in MATLAB. The package is based on an effective numerical ray-tracing scheme devised to achieve maximal execution speed for further uses in optimization loops. Briefly, the ray-tracing is performed in two dimensions restricted by the dispersion plane of the spectrometer, shown schematically in Fig. 1. The rays from a point source are propagated towards the ideal spherical VLS grating. To deliver symmetric illumination of the grating relative to its center, the situation taking place when aligning the spectrometer in a real experiment, the angular range of the rays is slightly asymmetric relative to the central ray. The rays diffract off the grating with the local groove density

where ω is the coordinate tangential to the grating surface in the center, according to the grating equation

where λ is the wavelength corresponding to the energy *E*, *k* is the diffraction order (positive for the internal), α is the incidence angle on the grating and β is the diffracted beam angle (positive notation) relative to the surface normal. From the grating the rays propagate towards the detector whose position is defined by the focal equation

where *r*_{1} and *r*_{2} are the entrance and exit arms, respectively, and *R* is the grating radius. The line profile is calculated as a histogram of the rays in the detector plane. This profile contains all optical aberrations such as the coma. Its further Gaussian broadening is due to the finite source size Δ_{S}, grating slope errors Δ_{SE} and spatial resolution of the detector Δ_{D}. Their contributions to the total linewidth are, respectively,

hereinafter all widths being FWHM. {We note in passing that our expression (5) is equivalent to its known form = (Howells, 2001), where the denominator can be replaced according to the grating equation (2) and the trigonometric functions sum (difference) appearing in the nominator (denominator) is transformed to their product.} The angle γ in (6) is the detector inclination relative to the central ray, which allows improvement of Δ*E*_{D}. The total Gaussian line broadening is then simulated by convolution of the ray-tracing calculated (bare) line profile with a Gaussian whose width Δ*E*_{G} is taken as the vector sum = + + . By virtue of this simplified computational method and extensive vectorization of the MATLAB code, a ray-tracing run with *TraceVLS* for a given set of parameters with a few thousand rays takes less than a tenth of a second on a low-end PC. Note that owing to involving only the rays in the dispersion plane this procedure omits the `smiley' line distortion in the perpendicular direction (see, for example, Tokushima *et al.*, 2006) which is, however, normally compensated by post-processing of the data.

The *TraceVLS* package was further used to optimize the grating parameters to deliver the narrowest symmetric profile at *E*_{ref} (see §3) as well as to adjust the spectrometer geometry to keep such a profile when going away from *E*_{ref} (§4). The principal obtained results were verified with generic ray-tracing codes *PHASE* (Bahrdt *et al.*, 1995) and *RAY* (Schäfers, 2008). The popular code *SHADOW* (available at http://www.nanotech.wisc.edu/shadow/) returns identical results starting from the year 2010 release which has fixed a bug on treatment of SVLSGs.

### 3. Optimization of the grating parameters at reference energy

The basics of the optical design procedure for SVLSG spectrometers are described, for example, by Ghiringhelli *et al.* (2006). Here we follow a somewhat different route. We start with a definition of the following parameters: *E*_{ref}, *a*_{0}, *k*, α, Δ_{S} and Δ_{D} introduced above, the total spectrometer length *L* and the FC inclination angle γ to match the optimal detector inclination angle. Then the *r*_{1} and *r*_{2} entrance and exit arm lengths are obtained by minimization of Δ*E*_{G} under the constraint *r*_{1} + *r*_{2} = *L*. With Δ*E*_{SE} being independent of *r*_{1} and *r*_{2}, this is equivalent to minimization of + , where Δ*E*_{S} (4) decreases with *r*_{1} and Δ*E*_{D} (6) increases with *r*_{1} = *L* − *r*_{2}. Equating the derivative of this sum with respect to *r*_{1} to zero takes us to the condition

Compared with the seemingly obvious condition of balance of the Δ*E*_{S} and Δ*E*_{D} contributions (Ghiringhelli *et al.*, 2006) the condition (7) improves the total Δ*E*_{G} (in our case by ∼3000 in *E*/Δ*E*) and displaces the grating towards the detector, requiring larger grating length for the same vertical acceptance of the spectrometer. The grating radius *R* and the linear VLS term *a*_{1} are then calculated as the analytical solutions of a system of two equations, which are the condition (3) on the focus to be at *r*_{2} plus the condition imposed on the FC inclination,

It should be noted that the possibility of controlling the FC inclination is an important advantage of the SVLSG spectrometers over the plane VLS ones.

For our model spectrometer we have accepted realistic parameters of *E*_{0} = 930 eV, *a*_{0} = 3500 lines mm^{−1}, *k* = 1 (internal), α = 88°, Δ_{S} = 2 µm, Δ_{SE} = 0.47 µrad (corresponding to 0.2 µrad r.m.s. which is the present technological limit for spherical optics), Δ_{D} = 24 µm, γ = 20° and *L* = 5000 mm. The above procedure yielded *r*_{1} = 798.7 mm, *r*_{2} = 4201.3 mm, *R* = 43241 mm and *a*_{1} = 0.6377 mm^{−2}. Ray-tracing calculations using *TraceVLS*, performed with the above parameters and a realistic grating illumination of 120 mm, yielded the results shown in Fig. 2(*a*) as the bare line profile as well as the Gaussian broadened profile. The profile is highly asymmetric owing to aberrations dominated by the (primary) coma. With the Gaussian linewidth broadening Δ*E*_{G} = 45.4 meV in our case, the aberrations deteriorate the spectrometer resolution to 84.8 meV.

The line asymmetry can be corrected by the *a*_{2} coefficient of the VLS expansion. First, we should try to cancel the coma aberration predominantly contributing to the asymmetry. Evaluation of the optical path function (Howells, 2001; Peatman, 1997) and setting the *F*_{30} (primary coma) term of its Maclaurin expansion to zero yields the condition

which allows analytical calculation of *a*_{2} to cancel the coma. In our case it yields *a*_{2} = −0.975 × 10^{−3} mm^{−3}. The results of ray-tracing performed with this *a*_{2} at the 120 mm illumination are shown in Fig. 2(*b*) (dotted lines). The line asymmetry is greatly reduced, remaining only in some asymmetry at its foot.

However, the applicability of the analytical coma-free condition (9) is limited only to the coma aberration term and vicinity of the central ray, where the optical path function is derived. A numerical procedure should be applied to optimize *a*_{2} taking into account the asymmetric aberrations of all orders as well as realistic grating illuminations. We used the *TraceVLS* ray-tracing procedure in an optimization loop to determine *a*_{2} delivering the symmetric line profile as identified in the strict mathematical sense of zero skewness of the histogram. The optimized *a*_{2} is obviously somewhat illumination-dependent, but in practice the value found for large illuminations ensures that the line asymmetry stays negligible also with small illuminations, because all aberrations scale down with a power of two or stronger. In our case we performed the optimization with the above 120 mm illumination, which has returned *a*_{2} = −0.995 × 10^{−3} mm^{−3}. The results of ray-tracing with this *a*_{2} in Fig. 2(*b*) (solid lines) show a perfectly symmetric profile. Strictly speaking, this does not ensure that all asymmetric high-order aberrations vanish, but combine in a symmetric profile. We have checked that in the limit of vanishing illumination our optimization procedure returned the *a*_{2} value identical within the numerical accuracy to the above analytical coma-free one. It should be noted that the difference between the analytical and optimized *a*_{2} is only ∼2%, well within the practical manufacturing accuracy. Interestingly, the analytical formula for *a*_{2} from Osborn & Callcott (1995) returned a notably different value of −4.82 × 10^{−3} mm^{−3} yielding an asymmetric profile for all illuminations. While our optimization procedure allows full cancellation of the line asymmetry, the profile in Fig. 2(*b*) still shows notable symmetric broadening and a broad foot owing to higher-order aberrations piling up at large illuminations. In our case this deteriorates the spectrometer resolution from the Δ*E*_{G} = 45.4 meV Gaussian limit to 60.0 meV.

The remaining symmetric broadening can be reduced by optimization of the *a*_{3} coefficient. Owing to a slight cross-talk of *a*_{3} back to *a*_{2} (in fact, separation of the line profile distortion into specific aberrations connected with particular *a*_{i} coefficients is artificial and works only in the vicinity of the central ray; their crosstalk increases with illumination) the optimization of *a*_{3} with the highest accuracy should be performed under re-optimization of *a*_{2} at each iteration step to keep the profile symmetric. For our model case with the 120 mm illumination this optimization returned *a*_{3} = 2.02 × 10^{−6} mm^{−4} at almost the same *a*_{2} = −0.986 × 10^{−3} mm^{−3}. The corresponding ray-tracing calculations in Fig. 2(*c*) show that the line profile has shrunk essentially to a delta-function (although with some structure on the meV scale) whose width is negligible compared with Δ*E*_{G}. The spectrometer resolution has thus reached the Gaussian linewidth limit, delivering the *E*/Δ*E* = 20420. No attempt has been made to optimize VLS expansion coefficients higher than *a*_{3} because they can hardly be realised with sufficient accuracy in a realistic manufacturing process.

The grating illumination is limited by increase of aberrations. In fact, this limit increases with *r*_{1} in such a way that the corresponding vertical acceptance Δα stays roughly constant. In other words, the situations of small illumination of a grating close to the source and large illumination of a grating far from the source are roughly equivalent from the aberration point of view. We will therefore characterize the illumination by the corresponding Δα as a parameter more universal upon variations of *r*_{1}. The effect of *a*_{3} on the aberration-limited spectrometer acceptance is illustrated in Fig. 3 which shows the total (aberration and Gaussian) linewidth as a function of Δα calculated without and with the optimized *a*_{3}. The low-aberration plateau, where the aberrations stay insignificant compared with the constant Δ*E*_{G}, increases its extension from ∼2 to 7 mrad. The optimization of *a*_{3} allows therefore operation of the spectrometer at much larger Δα.

Compared with the presently most advanced spectrometer SAXES (Ghiringhelli *et al.*, 2006), the simulated spectrometer of the same dimensions promises an increase of *E*/Δ*E* by a factor of ∼1.8 and the aberration-limited Δα by a factor of ∼3.5. It should be noted that the spectrometer transmission can be further improved by another factor of ∼3 by installing a collector mirror in the sagittal geometry in front of the grating to increase acceptance in the horizontal plane. Further increase of the angular acceptance may be achieved with optical schemes of Hettrick-Underwood (Hague *et al.*, 2005) or collimated-light plane grating (Agåker *et al.*, 2009) though compromising on resolution and transmission at higher soft-X-ray energies.

### 4. Optimization of the spectrometer geometry for variable energy

#### 4.1. Lineshape dependence on the spectrometer geometry and angular acceptance

With the grating parameters optimized for certain *E*_{ref}, one can maintain the exactly symmetric line profile for any energy away from the reference by variation of the spectrometer geometry. We illustrate this in Fig. 4 (top) which shows, for our simulated spectrometer with the grating optimized for 930 eV, the ray-tracing calculated Δ*E* linewidth depending on *r*_{1} and α for an energy of 530 eV (O *K*-edge). The illumination varies with *r*_{1} and α over the plot to keep the Δα vertical acceptance constant and equal to a moderate value of 3 mrad. It should be noted that these simulations always keep the spectrometer in focus, *i.e.* *r*_{2} varies with *r*_{1} and α over the plot according to the focal equation (3).

The resolution plot shows a prominent valley. Fig. 4 (bottom) illustrates the evolution of the lineshapes upon crossing the valley by variation of α along the marked line of constant *r*_{1} = 600 mm through the points *A*, *B* (bottom of the valley) and *C* separated by 0.075°. The point *B* is characterized by the symmetric lineshape (again, the asymmetric high-order aberrations may not exactly vanish at this point but yield a symmetric combination) whereas in the points *A* and *C* the asymmetry is already significant. Therefore, the best spectrometer resolution in the bottom of the valley corresponds exactly to the symmetric profile (SP) lineshape. Note that upon crossing the valley the asymmetry tail flips from the left to the right side, which ensures there must exist a point where the asymmetry becomes exactly zero in the mathematical sense of zero skewness of the line profile. Therefore, the asymmetry can be not merely minimized, but totally *cancelled for any energy* away from the reference.

The resolution plot shows that the asymmetry cancellation can also be achieved by variation of *r*_{1} for α = constant. Therefore, for every energy there are *two* alternative ways to maintain the SP spectrometer operation: either by optimizing the grating position along the beam to change *r*_{1} or by optimizing the pitch of the grating to change α.

For *E*_{ref} the resolution plot has the same pattern, *i.e.* the spectrometer can deliver the SP lineshape with *r*_{1} and α different from the reference values (although with some increase of the symmetric aberration broadening and Δ*E*_{G} optimized for the reference geometry). This degree of freedom also allows compensation of certain manufacturing errors of the *a*_{2} coefficient.

It is instructive to follow changes in resolution with increase of the Δα vertical acceptance. Fig. 5 shows the same resolution plot as in Fig. 4 but with Δα increased to 6 mrad. Similarly to the previous figure, the panels at the bottom illustrate the evolution of the lineshapes upon crossing the valley. The valley center again corresponds to the SP lineshape. With increase of Δα the valley becomes narrower, a consequence of the aberrations scaling up. This makes the spectrometer more sensitive to alignment. It is interesting to note a tiny bump appearing exactly in the valley center (*i.e.* the exactly symmetric profile has slightly larger FWHM) and a spike of FWHM piling up at the right-hand border of the valley near the point *C* (owing to formation of a double-peak structure in the line profile).

The effect of Δα is further illustrated in Fig. 6 which shows Δ*E* plots calculated for a series of Δα. They correspond to two cross sections of the above resolution plots, along the *r*_{1} = 600 mm line as a function of α (*a*) and along α = 88.2° as a function of *r*_{1} (*b*). As we have already seen in Fig. 5, with an increase of Δα the valley narrows, a spike of FWHM gradually forms on the right-hand side of the valley, and a notable bump at the bottom piles up at large Δα. A very slight displacement of the SP point can be noted. Most important, however, is that the Δ*E* degradation in the SP conditions stays insignificant, allowing the spectrometer operation at the highest transmission. Furthermore, the plot in Fig. 6 gives us an estimate of the practical accuracy of the spectrometer settings. The curve for Δα = 4 mrad, for example, shows that if we accept a tolerance of 5% on degradation of Δ*E* relative to its minimum the corresponding tolerances on α and *r*_{1} are about ±0.02° and ±8 mm, respectively.

#### 4.2. Evaluation of the symmetric lineshape spectrometer settings

Corresponding to the resolution plot valley, the SP trajectories in the (*r*_{1}, α) coordinates or the corresponding ones in the (*r*_{1}, *r*_{2}) coordinates define the spectrometer settings to maintain the SP lineshape. We have calculated these trajectories for our model spectrometer in a range of energies from 430 to 1230 eV. First, we evaluated the SP trajectories using the analytical coma-free condition (9). These `analytical' trajectories are displayed in Fig. 7 (dotted lines). Second, we used the *TraceVLS* ray-tracing procedure in an optimization loop similarly to the above determination of *a*_{2}. Δα in these calculations was kept at 5.2 mrad corresponding to the illumination used in the calculations at *E*_{ref}. These `numerical' trajectories are shown in Fig. 7 (solid lines). Obviously the coma-free condition (9) gives an excellent approximation to the SP trajectories. Nevertheless, the full ray-tracing analysis, taking into account the finite illumination and higher-order aberrations, introduces notable corrections, especially at the low-*r*_{1} end. On average in the *r*_{1} range displayed in the plot the corrections are about 0.011° in α and 22 mm in *r*_{2} resulting in an increase of *E*/Δ*E* by about 1200. The SP trajectories in the (*r*_{1}, α) and (*r*_{1}, *r*_{2}) coordinates, calculated over a range of energies, determine the required ranges of the *r*_{1}, α and *r*_{2} mechanical motions.

It should be noted that prerequisite to maintaining the SP lineshape under energy variations is a mechanical flexibility of the SVLSG spectrometer to vary at least two of the three parameters *r*_{1}, α and *r*_{2}. The beamline monochromators in general do not enjoy such a flexibility because of the fixed slit position. In (exactly focusing) spherical-grating monochromators (Peatman, 1997) variation of α + β with the pre-mirror keeps the beam focused at the slit under energy variations, but there remain no to cancel the line asymmetry away from *E*_{ref} unless the grating is translated.

#### 4.3. Fixed-inclination and maximal-acceptance operation modes

For any energy one can achieve the SP spectrometer operation by setting different combinations of *r*_{1} and α along the SP trajectories. We will show that this remaining degree of freedom may be used in two ways, to maintain for each energy either fixed FC inclination angle γ or minimal aberrations at large Δα. We will refer to these two operation modes as the fixed inclination (FI) and maximal acceptance (MA) modes.

To evaluate the FI mode we have calculated the dependences of γ defined by (8) along the above `numerical' SP trajectories. Fig. 8(*a*) displays these dependences as a function of *r*_{1}. They show dramatic variations and even jump from positive to negative values of γ, as seen for the lowest energy. It is not practical to follow these variations by changing the detector inclination angle, because this angle should normally stay around its optimal value chosen, on one side, as glancing as possible to reduce the effective pixel size and thus Δ*E*_{D} and, on another side, above the critical angle where the intensity starts to drop owing to shadowing effects and increasing attenuation in the oxide dead layer (the 20° inclination angle adopted in our case is typical of the modern back-illuminated CCD chips).

Although the relatively large focal depth of long spectrometers makes them not very critical on matching the FC to the detector inclination, one can find a mode to operate the spectrometer at fixed (energy-independent) FC inclination. Indeed, Fig. 8(*a*) shows that for any energy the SP trajectories bear one point where the match is exact (crossings with the γ = 20° horizontal line). We have found the *r*_{1} and corresponding α coordinates of these points by numerical solution of (8) under the SP constraint. The corresponding dependences of α and *r*_{1} calculated over a wide energy range are shown in Fig. 8(*b*). In this way our analysis identifies the FI operation mode of the SVLSG spectrometer which maintains over a wide energy range the SP lineshape *and* exact match of the FC to the detector inclination.

Principles of the MA mode are illustrated in Fig. 9(*a*), which shows Δ*E* dependences of *r*_{1} along the `numerical' SP trajectory from Fig. 7 for an energy of 530 eV. Whereas for small Δα these dependences show a monotonous decrease of Δ*E* with *r*_{1}, for large Δα there develops a pronounced minimum at *r*_{1} ≃ 750 mm. In this point Δ*E* is almost independent of Δα. Similarly to the effect at *E*_{ref}, this minimum appears due to the *a*_{3} coefficient. Therefore, for any energy the SP trajectories bear one point where the aberration-limited Δα is maximal, characteristic of the MA operation mode.

We have determined the *r*_{1} and corresponding α coordinates of the MA points in an extended energy range by numerical minimization of Δ*E* under the SP constraint. The results are shown in Fig. 9(*b*). They identify the MA operation mode of the SVLSG spectrometer which maintains over a wide energy range the SP lineshape *and* maximal aberration-limited Δα.

Furthermore, we have investigated how large the effect of *a*_{3} is to increase the aberration-limited Δα away from *E*_{ref}. The two lower curves in Fig. 3 show the total linewidth at 530 eV as a function of Δα calculated in the MA mode with *a*_{3} = 0 and with our optimized *a*_{3}. Although the optimization was performed at 930 eV, this *a*_{3} increases the width of the low-aberration plateau from ∼2 to 7 mrad, an effect as large as at *E*_{ref}.

Finally, we have compared over a wide energy range the FI and MA modes in terms of resolution. The calculations were performed with a large Δα value of 6 mrad. Fig. 10 (solid lines) shows the calculated Δ*E* dependences together with those of the Gaussian resolution limit Δ*E*_{G} (dotted). As expected, in the FI mode the Δ*E* values are generally above Δ*E*_{G} owing to the symmetric aberration broadening at this Δα. The difference rapidly decreases with decrease of Δα and vanishes in the Δα = 0 limit. The two dependences coincide at *E*_{ref} where the *a*_{3} coefficient was optimized to minimize this broadening. In the MA mode, by its design principle, the Δ*E* dependence almost coincides with its Δ*E*_{G} limit, providing better resolution with large Δα compared with the FI mode. Note that the Δ*E*_{G} dependences are slightly different in the two modes owing to different trajectories in the (*r*_{1}, α, *r*_{2}) coordinates (see Figs. 9 and 10). Energy variations of the FC inclination in the MA mode, plotted in the corresponding panel of Fig. 10, are large.

Also shown in Fig. 10 (dashed lines) are the Δ*E*_{S} source size, and the Δ*E*_{D} detector and Δ*E*_{SE} slope error contributions to the total Δ*E*_{G}. The resolution is limited predominantly by Δ*E*_{D}. This demonstrates that improvement of the spatial resolution of X-ray detectors is the factor most important for further energy resolution progress of the soft X-ray spectrometers.

#### 4.4. Software tools

Based on the *TraceVLS* package, we have developed a user-friendly GUI-based program for fast determination of the optimal spectrometer geometry for varying energy, including the FI and MA modes. The GUI is shown in Fig. 11. First, in the box `GRATING' one defines the grating parameters. Then in the box `PARAMETERS' one defines the fixed spectrometer settings, including the detector inclination angle and some of the three geometry parameters *r*_{1}, α and *r*_{2} necessary to calculate the remaining ones according to the focalization conditions defined in the box `FOCUS MODE' below. If one checks the simple focus, the code calculates either α out of given (*r*_{1}, *r*_{2}) or *r*_{2} out of given (*r*_{1}, α) based on the focal equation (3). If one checks for the SP focus, the code calculates (α, *r*_{2}) out of given *r*_{1} or (*r*_{1}, α) out of given *r*_{2} based on two conditions: the focal equation (3) plus zero asymmetry of the line profile as defined by numerical optimization. If one checks the focus in the FI or MA modes, the code calculates all three parameters (*r*_{1}, α, *r*_{2}) based on the two above conditions plus the condition that either γ matches the detector inclination or the symmetric aberrations for given illumination are minimal, respectively. The results of the calculations are displayed in the box `RESULTS' as the calculated bare line profile, Gaussian broadening and the resulting total line profile, as well as numerical outputs such as various contributions to the total resolution and the diffraction angles.

Owing to the fast ray-tracing scheme, the *TraceVLS*-based GUI finds the optimal spectrometer settings for a given energy in less than a second on a low-end PC for the simple or SP focus, and in a couple of seconds for the FI and MA modes. The user-friendly interface allows its use as an online tool in real experiments. It should be noted that similar optimizations using generic ray-tracing software like *SHADOW* would be far more laborious owing to the necessity to manually set up the computational parameters in each pass of the optimization loop. The code is written in MATLAB and is platform-independent. It is available free for academic users by writing to the first author.

### 5. Summary

We have analysed the operation of a spherical-VLS-grating-based X-ray spectrometer using a dedicated ray-tracing software package *TraceVLS*, allowing fast optimization of the grating parameters and spectrometer geometry. The analysis is illustrated with optical design of a model spectrometer delivering *E*/Δ*E* above 20400 at a photon energy of 930 eV. With a reference energy *E*_{ref} chosen at 930 eV, the spectrometer geometry is evaluated to minimize the Gaussian line broadening owing to the source size, grating slope errors and detector spatial resolution. The lineshape asymmetry (mostly owing to the coma aberrations) is cancelled by optimization of the *a*_{2} coefficient of the VLS power expansion. At small illuminations the obtained *a*_{2} becomes identical to that yielded by the analytical coma-free condition derived from the optical path function. Furthermore, the remaining symmetric line broadening at large illuminations (owing to higher-order aberrations) is reduced by optimization of *a*_{3} which allows a dramatic increase of the aberration-limited Δα acceptance of the spectrometer, in our case by a factor of about 3.5. For any energy away from *E*_{ref} the exact asymmetry cancellation can be maintained by correcting either *r*_{1} or α. The corresponding SP trajectories in the (*r*_{1}, α) and (*r*_{1}, *r*_{2}) coordinates are calculated from the analytical coma-free condition and, with better accuracy, by numerical minimization of the line asymmetry. The remaining degree of freedom to set different combinations of *r*_{1} and α along the SP trajectories is utilized to maintain either energy-independent FC inclination (FI operational mode) or maximal aberration-limited Δα acceptance (MA mode) which exploits the effect of the *a*_{3} coefficient to minimize the symmetric aberration broadening. In routine experimental work the optimal *r*_{1}, α and *r*_{2} spectrometer settings can be calculated in a fraction of a second using our ray-tracing code wrapped in a user-friendly GUI. Our analysis thus gives a recipe to design and operate SVLSG spectrometers at large angular acceptance and in an extended energy range without any notable degradation of resolution beyond the Gaussian broadening factors. These properties of the SVLSG optical scheme along with its ultimate simplicity suggest its use in the *hv*^{2} spectrometer (Strocov, 2010) where imaging and dispersion actions in two orthogonal planes are combined to deliver the full two-dimensional map of RIXS intensity with simultaneous detection in incoming and outgoing photon energies.

### Acknowledgements

We thank G. Ghiringhelli, L. Braicovich, Y. Harada, R. Reininger and C. Hague for promoting discussions, and C. Quitmann and F. van der Veen for their continuous support of the RIXS project at the Swiss Light Source.

### References

Agåker, M., Andersson, J., Englund, C.-J., Olsson, A. & Nordgren, J. (2009). *Nucl. Instrum. Methods Phys. Res. A*, **601**, 213–219. Google Scholar

Bahrdt, J., Flechsig, U. & Senf, F. (1995). *Rev. Sci. Instrum.* **66**, 2719. CrossRef Web of Science Google Scholar

Braicovich, L., van den Brink, J., Bisogni, V., Moretti Sala, M., Ament, L. J. P., Brookes, N. B., De Luca, G. M., Salluzzo, M., Schmitt, T., Strocov, V. N. & Ghiringhelli, G. (2010). *Phys. Rev. Lett.* **104**, 077002. Web of Science CrossRef PubMed Google Scholar

Cocco, D., Zangrando, M., Matteucci, M., Bondino, F., Platè, M., Zacchigna, M., Parmigiani, F., Nelles, B. & Prince, K. C. (2004). *AIP Conf. Proc.* **705**, 873–876. CrossRef CAS Google Scholar

Hague, C. F., Underwood, J. H., Avila, A., Delaunay, R., Ringuenet, H., Marsi, M. & Sacchi, M. (2005). *Rev. Sci. Instrum.* **76**, 023110. Web of Science CrossRef Google Scholar

Hennies, F., Pietzsch, A., Berglund, M., Föhlisch, A., Schmitt, T., Strocov, V. N., Karlsson, H. O., Andersson, J. & Rubensson, J.-E. (2010). *Phys. Rev. Lett.* **104**, 193002. Web of Science CrossRef PubMed Google Scholar

Howells, M. R. (2001). In *X-ray Data Booklet*, §4.3. Center for X-ray Optics and Advanced Light Source, Lawrence Berkeley National Laboratory, CA, USA (extended version available at http://xdb.lbl.gov/Section4/Sec_4-3.pdf). Google Scholar

Ghiringhelli, G., Piazzalunga, A., Dallera, C., Trezzi, G., Braicovich, L., Schmitt, T., Strocov, V. N., Betemps, R., Patthey, L., Wang, X. & Grioni, M. (2006). *Rev. Sci. Instrum.* **77**, 113108. Web of Science CrossRef Google Scholar

Ghiringhelli, G., Tagliaferri, A., Braicovich, L. & Brookes, N. (1998). *Rev. Sci. Instrum.* **69**, 1610. Web of Science CrossRef Google Scholar

Kotani, A. & Shin, S. (2001). *Rev. Mod. Phys.* **73**, 203–246. Web of Science CrossRef CAS Google Scholar

Nordgren, J., Bray, J., Gramm, S., Nyholm, R., Rubensson, J.-E. & Wassdahl, N. (1989). *Rev. Sci. Instrum.* **60**, 1690. CrossRef Web of Science Google Scholar

Osborn, K. D. & Callcott, T. A. (1995). *Rev. Sci. Instrum.* **66**, 3131. CrossRef Web of Science Google Scholar

Peatman, W. B. (1997). *Gratings, Mirrors and Slits – Beamline Design for Soft X-ray Synchrotron Radiation Sources.* New York: Gordon and Breach. Google Scholar

Schäfers, F. (2008). *Modern Developments in X-ray and Neutron Optics, Springer Series in Optical Sciences*, Vol. 137, p. 9. Berlin: Springer. Google Scholar

Schlappa, J., Schmitt, T., Vernay, F., Strocov, V. N., Ilakovac, V., Thielemann, B., Rønnow, H. M., Vanishri, S., Piazzalunga, A., Wang, X., Braicovich, L., Ghiringhelli, G., Marin, C., Mesot, J., Delley, B. & Patthey, L. (2009). *Phys. Rev. Lett.* **103**, 047401. Web of Science CrossRef PubMed Google Scholar

Strocov, V. N. (2010). *J. Synchrotron Rad.* **17**, 103–106. Web of Science CrossRef CAS IUCr Journals Google Scholar

Strocov, V. N., Schmitt, T., Flechsig, U., Schmidt, T., Imhof, A., Chen, Q., Raabe, J., Betemps, R., Zimoch, D., Krempasky, J., Wang, X., Grioni, M., Piazzalunga, A. & Patthey, L. (2010). *J. Synchrotron Rad.* **17**, 631–643. Web of Science CrossRef CAS IUCr Journals Google Scholar

Strocov, V. N., Schmitt, Th. & Patthey, L. (2008). PSI Technical Report No. SLS-SPC-TA-2008-309. PSI, Villigen, Switzerland (http://slsbd.psi.ch/pub/slsnotes/spcta080309.pdf). Google Scholar

Tokushima, T., Harada, Y., Ohashi, H., Senba, Y. & Shin, S. (2006). *Rev. Sci. Instrum.* **77**, 063107. Web of Science CrossRef Google Scholar

This is an open-access article distributed under the terms of the Creative Commons Attribution (CC-BY) Licence, which permits unrestricted use, distribution, and reproduction in any medium, provided the original authors and source are cited.