Utilizing the N beam position monitor method for turn-by-turn optics measurements

The N beam position monitor method (N-BPM) which was recently developed for the LHC has significantly improved the precision of optics measurements that are based on BPM turn-by-turn data. The main improvement is due to the consideration of correlations for statistical and systematic error sources, as well as increasing the amount of BPM combinations which are used to derive the β-function at one location. We present how this technique can be applied at light sources like ALBA, and compare the results with other methods.


I. INTRODUCTION
Linear optics from closed orbit (LOCO) [1] is the standard method for optics measurements and corrections at the ALBA synchrotron [2].Turn-by-turn measurements can provide faster optics measurements than LOCO and are of great interest also for other light sources [3][4][5][6].Recently, efforts have been put in developing optics measurements based on beam position monitor (BPM) turn-by-turn data at ALBA.However, first measurement attempts of the βfunction using the phase information of turn-by-turn data were futile.The precision was notably worse compared to the β-functions that were inferred from the amplitude information which showed a discrepancy of 4%-10% to LOCO measurements [7].Improvements of the BPM electronics, their timing setup and synchronization were a prerequisite for an advancement in the calculation of the βfunction from the turn-by-turn amplitude information [8].
Also at SOLEIL significant discrepancies were observed when comparing the β-beating from turn-by-turn measurements to LOCO and an optics correction study at SLS found an inferior performance of turn-by-turn measurements compared to LOCO.Studies in ESRF [9,10] show that the model which arises from a fit to the phase advances from turn-by-turn data is comparable to their standard orbit response matrix (ORM) based model.
Inferring the β-function from the phase information requires the phase advance of the betatron oscillation ϕ i;j ¼ ϕ j − ϕ i between three BPMs [11,12], where M mnði;jÞ are the model transfer matrix elements in between the BPMs.The phase advance can be derived from the BPM turn-by-turn data while an oscillation has been excited on the beam.Previous attempts of optics measurements from turn-by-turn data at LHC and SOLEIL used only neighboring BPMs for the analysis, because the effect of systematic errors for larger ranges of BPMs would quickly deteriorate the results.The N-BPM method overcomes the limitation of using only neighboring BPMs by performing a detailed analysis of systematic and statistical errors and their correlations [13].This allows us to consider more BPM combinations for the analysis, and therefore, to use more information when probing the β-function at one BPM position.
Optimal phase advances in between two BPMs are 45°þ n 1 • 90°, and phase advances of n 2 • 180°, ðn 1 ; n 2 Þ ∈ N 2 should be avoided.The phase advances of consecutive BPMs are shown in Fig. 1 for the nominal ALBA lattice.Especially in the vertical plane there are many consecutive BPMs with a small phase advance, and considering BPMs combinations within a larger range of BPMs would allow for better phase advances for the measurement.In the N-BPM method, a range of N BPMs is selected for deriving the β-function at one location, cf.Fig. 2. The amount m of possible combinations of three BPMs, out of N BPMs with one fixed BPM, is The measured β-function at the probed BPM position is a weighted average of the m β-functions with the weights w i .The values of the weights depend on the statistical and systematic errors, and their correlations among the different combinations of three BPMs.They can be derived from the covariance matrix V ¼ V statistical þ V systematic as shown in [13] The essential ingredient of this method is the use of model uncertainties to decide on the weight for the different BPM combinations.As BPMs are further apart, model uncertainties add up, rendering the β from phase method less accurate.

II. MEASUREMENT UNCERTAINTIES
In this section we study the effect of systematic and statistical errors for optics measurements using the N-BPM method and LOCO.
A. Systematic errors in the N-BPM method For the N-BPM method it is crucial to consider the effect of model uncertainties and their correlations for the β-function measurement, in order to derive the covariance matrix for the systematic errors V systematic , which is used in Eq. ( 4).It can be computed for example in a Monte-Carlo simulation where the error sources are varied within their uncertainty and the impact on the measurement is observed.The calculation of systematic errors is based on the uncertainties of magnetic measurements and alignment uncertainties, which can be found in Table I.The derivation of the β-function from phase is neither sensitive to BPM calibrations nor to roll errors of the BPMs, as the phase is derived only for an oscillation of a certain frequency, in this case the two tunes.Furthermore, coupling is a second order effect for this measurement method and is assumed to be negligible.The Monte-Carlo simulation was performed for 1,000 iterations and the error sources were varied randomly following a Gaussian distribution.
One can perform the Monte-Carlo simulations additionally separately for each contribution to study how much each error source is contributing to the total systematic error, cf.Fig 3 .The dominant contribution comes from quadrupolar gradient errors and transverse misalignment of sextupole magnets.In contrast to the vertical plane, in the horizontal plane the dipole b 2 errors have a negligible effect.This is because β y is much larger at the dipole magnets than β x .
The systematic errors can furthermore be assessed separately for different BPM combinations.In Table II the average systematic error of the measured β-function is shown for different BPM combinations.The lowest error is in both planes achieved for neighboring BPMs, if the BPM

B. Precision and accuracy of the N-BPM method
The uncertainty of the β-function measurement depends additionally on the statistical error of the phase measurement, which is expressed by the covariance matrix V statistical .A simulation of the turn-by-turn measurement was done to assess the overall uncertainty of the N-BPM method.500 lattices were created by randomly adding errors to the nominal model according to Table I.For each lattice, 5 measurements of BPM turn-by-turn data with 1000 turns each were simulated.In simulations the noise which is applied to the turn-by-turn data, e.g. a Gaussian noise, would be cleaned too efficiently with the singular value decomposition (SVD) technique which is used for noise cleaning in real measurements [14,15].Instead of applying an empirical noise value to the data, the BPM noise and the beam excitation amplitude were adjusted to reproduce the standard deviation of the measured phase advance as it is observed in a typical measurement.For the measurements which are analyzed here, the average uncertainty of the measured phase advances in units of 2π are 8.2 × 10 −3 for the horizontal and 7.8 × 10 −3 for the vertical plane.To achieve similar uncertainties in the simulation, a Gaussian noise of 14 μm =13 μm (horizontal / vertical) was applied to the turn-by-turn data, while the beam excitation amplitude was set to 1 mm (peak to peak) at a β-function of 12 m.No additional cleaning with SVD was performed.This ensures that the calculation of the β-function in the simulation is using phase advances with similar random errors as they are in measurements.It should be noted that the real turn-by-turn data may likely have larger noise before cleaning than the 13 to 14 μm, which were used to reproduce the observed phase uncertainty after cleaning using SVD.
The β-functions were derived using the N-BPM method for different ranges of BPMs.Furthermore, instead of using all possible m combinations of three BPMs, cf.Eq. ( 2), j combinations were used with 0 < j ≤ m.For each BPM, FIG. 3. Contribution of the uncertainties from Table I to the total variance of the derived β-function.The average value over all BPMs is shown for the case of probing the middle BPM of neighboring BPMs, as it is the combination which has the smallest systematic error.The top bar is for the horizontal plane (H) and the bottom one for the vertical plane (V).Quadrupolar errors are shown in blue and misalignment uncertainties in red. the deviation of the measured β-function to the β-function of the perturbed lattice was fitted with a Gaussian distribution.The mean value of this distribution is the accuracy of the measurement, as it indicates a bias toward larger or smaller values.The width of the distribution is the precision and describes how much the measurement spreads.Figures 4 and 5 show for the horizontal plane the evolution of the average precision and accuracy for all BPMs for different ranges of BPMs (N) and different number of BPM combinations (j) that were analyzed together.One can see how a larger number of BPM combinations will increase the precision and accuracy of the measurement until they saturate, as the information from further BPM combinations is negligible.The different BPM ranges start at a different value for the precision and accuracy as the order of the BPMs is not the same in every case.However, if enough BPMs are used, a larger range of BPMs will result in a better precision and accuracy as more information is used to derive the β-functions.Table III shows the precision and accuracy that can be achieved for using different BPM ranges.The precision of the vertical β-function saturates already for a 7-BPM range, whereas in the horizontal plane benefits are still visible up to a range of 13 BPMs.

C. LOCO measurement uncertainties
The precision of the LOCO method at ALBA has been studied in simulations [16].A set of perturbed lattices was modeled by randomly varying magnetic misalignments and strengths.Using these lattices, simulated measurement data was produced as an input for LOCO.A Gaussian noise of 0.25 μm was added to the BPM readings.As this measurement is sensitive to the calibration of BPMs and corrector magnets, further uncertainties were added, cf.Table IV.
LOCO has been used to fit the simulated measurement data, including noise and calibration errors, from the perturbed lattices to an optics model.This fitted model is then compared to the initial perturbed lattice to assess the precision of the LOCO fit.From these simulations for the ALBA synchrotron, the precision of the β-function measurement with LOCO is expected to be 0.89% in the horizontal and 1.06% in the vertical plane.

III. MEASUREMENTS
The ALBA synchrotron is equipped with 120 BPMs and turn-by-turn data was acquired using the moving average filter acquisition mode (MAF) [8].The value of the β-function at the BPM positions varies approximately between 4 m and 13 m.For the excitation of the betatron oscillation, a pinger magnet was used.The peak-to-peak value of the amplitude for the betatron oscillation was 1 mm in the horizontal plane and 1.4 mm in the vertical plane, for BPMs with a β-function of 12.7 m (both planes).40 measurements were performed, from which only 31 were used in the analysis, since some cases needed to be excluded due to BPM synchronization problems.The analysis was limited to 1024 turns, where the oscillation amplitude decreased by a factor of 2 in the horizontal plane, cf.Fig. 6, The analysis was performed separately for using five different start turns, and averaging the results, to avoid distortions due to decoherence effects.A correction formula, which can also be used to mitigate the decoherence effects is presented in [17].A cleaning of the turn-by-turn data was performed using the SVD technique and keeping only the 12 strongest modes.Nonlinear errors in the BPM calibration have been studied in [18], and are for oscillation amplitudes of 0.5 mm expected to be 2 μm.Nonlinear effects due to sextupoles are assumed to be negligible as well for these oscillation amplitudes, as they were included in the tracking simulations where an accuracy of below 0.3% of the measured β-function was achieved, as shown in Fig. 5.These assumptions are supported by analyzing the frequency spectrum in Fig. 7, where no cubic distortions are visible, as it was for example the case in [3].
Figure 8 shows the β-beating as computed from the phase of the betatron oscillation with the method in comparison with the results obtained with LOCO.The error bars for the N-BPM method contain systematic and statistical uncertainties, whereas the error bars for LOCO account only for the reproducibility of the results.
There is a good agreement for many data points between both methods, however in general the deviations from LOCO to the nominal model are smaller, as shown in Table V.Another method which can be used to obtain the β-function uses the amplitude information of the betatron oscillation.A prerequisite for this method is the knowledge of the kick action, as well as the gain of the BPMs.Instead of assessing these values, a normalized β-function was computed [8].The β-beating from the amplitude method is compared to the N-BPM method in Fig. 9.The rms β-beating to the nominal model is for each method shown in Table V.Furthermore, in the second part of Table V, the results which are obtained by the different methods are compared pairwise, by computing the rms deviation of the β-function between two methods.
The amplitude method shows the largest deviation from the nominal model.Using the normalized β-function on the one hand does not suffer from uncertainties of the computed kick action or BPM gains, but on the other hand introduces further systematic errors.For the computation of the β-function from amplitude, the LOCO model could not be used to refine the BPM gains, as both measurements are performed in two operational modes of the BPM electronics, and different errors may occur.
Since the N-BPM method uses model transfer matrix elements, it was also tested to run the analysis not with the ideal model, but the model that has been fitted with LOCO.The idea is that if the LOCO model is closer to the real  machine, then using the LOCO model for the N-BPM method should also provide a result that is closer to the LOCO result.There is an improvement of the rms β-beating from the N-BPM method to LOCO of 20% in both planes.These results are in excellent agreement considering the estimated uncertainties of the N-BPM method of in this case 1.01% horizontally and 0.66% vertically for a linear addition of the systematic and random uncertainties in comparison with the LOCO uncertainties from Sec. II C.

IV. CONCLUSION
Large efforts for optics measurements from turn-by-turn data at ALBA resulted in great step forward in both cases of using either amplitude [8] or phase (N-BPM) of the betatron oscillation.Deriving systematic errors and correlations in the N-BPM method successfully increased the optics measurement precision.The agreement with LOCO is now at a level of 1%.For the first time turn-by-turn data and LOCO show the same level of in the measurement of β-functions at light sources.

FIG. 1 .
FIG. 1. Phase advances of consecutive BPMs in the nominal model.Many phase advances close to 0°impair the calculation of β-functions when using only neighboring BPMs.

FIG. 7 .
FIG. 7. Frequency spectrum of the horizontal (H) and vertical (V) turn-by-turn oscillations.The two peaks correspond to the tunes Q x ¼ 18.15 and Q y ¼ 8.36.

TABLE I .
Uncertainties which are considered in the computation of systematic errors.Quadrupolar errors are specified relative to their main field (quadrupoles), respectively relative to their quadrupole component (dipoles).

TABLE II .
Systematic error of the measured β-function for using different BPM combinations.The five best combinations are shown for each plane.
FIG. 5. Accuracy of the derived horizontal β-functions from simulations for different ranges of BPMs and different amount of BPM combinations.

TABLE III .
Achievable precision and accuracy of the measured horizontal (H) and vertical (V) β-functions for using different BPM ranges.

TABLE IV .
Assumed uncertainties for BPMs and corrector magnets, as they were derived from LOCO fits on real measurements.

TABLE V .
The first part shows the rms deviation of the β-function to the nominal model as computed from the different methods.The second and third part compares the deviation of the β-functions which are obtained by two different methods.In the third part for the N-BPM method the LOCO fitted model was used in the analysis instead of the ideal model.