An Alternative to Classical Real-time Magnetic Field Measurements
using a Magnet Model
F. Caspers, W. Heinze, J. Lewis, M. Lindroos, T. Salvermoser
CERN, PS Division
CH-1211 Geneva 23, Switzerland
Abstract
Longitudinal and transverse beam control in circular
accelerators depends critically on a reliable real-timeknowledge of the magnetic bending field. Traditionally
this is achieved with a long-measurement coil placed in areference magnet. In the CERN PS Booster, such ameasurement generates a 1 Gauss step-size train with anabsolute precision of 0.1%. Modern magnet control can bedone with a precision of 0.01%. Consequently, asynthesised magnetic field train based on a reliablemagnet model could potentially yield a 10 times better
result. The PSB will become a part of the injector chain
for the future Large Hadron Collider (LHC). Therefore themain power supply of the PSB has been upgraded to fulldefine the complete magnetic cycle with an application
program in physical units. The Main Power Supply (MPS)
control unit receives a vector array with

L didtas afunction of time, and executes the cycle with a precisionof 0.01 %. A theoretical magnet model has beendeveloped which makes it possible to predict the magnetic
field throughout the machine cycle from the available

L didt vector array with twice the measured precision of
the present long coil B-train generation system. This
information is distributed through software channels toprovide magnetic field information directly in application
programs and to create a synthetic B-train.

dicycle L dt
control. This has made it possible to follow

2 Mathematical model magnet of the PS Booster

the entire magnetic cycle with a refined model, and tosynthesise a real-time magnetic field train from a newly
developed programmable pulse generator. We will discuss
the general design concepts and the first results.

The feedback loop of the PSB main power supply
control (Fig. 1) determines the current to be supplied toPrecise knowledge in real-time of the magnetic field in
the main bending magnets in synchrotrons as a function oftime is important for longitudinal and transversal beam
control. In addition, many measurement applications
depend critically on such information for the correct
evaluation of acquired data. The demand on precision andresolution varies with application and machine. The PS
Booster (PSB) has 4 superimposed rings using 4-gap
bending magnets. In this machine, the most severe
demand on the B-field measurement comes from thedigital longitudinal beam control system which requests
0.3 Gauss precision and 0.1 Gauss resolution.
The magnetic field in the PSB bending magnets iscurrently measured with a long coil in a reference magnet
that is powered in series with the main dipoles. The data
is distributed in real time with an incremental pulse train
with 1 Gauss resolution (B-train). Any system in need ofthis real-time information simply has to count the numberof pulses from a timing signal marking the start of themagnetic cycle. A pre-burst before the start of the field
increase assures that all counters initially are set to anoffset corresponding to a low field reference formed fromthe field at bottom current and the remanent field.
Within the LHC project, the main power supply of the
PSB is being renovated. The accelerator operator can now

the cycle editor application program, and the bottom
current value Ibottom with a precision of 0.01% (10-4)
VoltageFeedback

Ldi/dt1 Introduction

the magnets based on the L difunctions programmed by
dt

Current
I(t)

Time
Ref V
Voltage
Controller
DigitalReference
Converter

Current
Controller

Main
Power
SupplyMagnetRef I

I BottomVoltageV(t)Current
Feedback

Fig. 1: Main Power Supply control feedback loopof the PS Booster
Small correction functions are used to ensure that the
integral of the magnetic field around themachine∫ Bdl seen by the beam is the same in each of

the four PSB rings. As the geometry and relative
permeability µr of the magnets are nearly constant, and no
significant core saturation occurs, even at the highest fieldvalue (0.8 T), then a linear relationship between current I
and the resulting field B can be assumed. In this case thesimple model illustrated in Fig. 2 [1], which models theB(t ) function from ( dB
∝ L dtdi )dt(Bbottom ∝ I bottom ) , is a useful approximation.

resulting

and

dB/dt

dB/dt
Programmed
WARNING
Over Voltage

Control loopdelay
1/(T1.z+1)

Time
L/K1

V > VMAX?

DelayedV

Ldi/dtLdi/dt1
di
LL ∫ dt+ Plus+ PlusR
ResistanceBres
Residual field

iR

K1
1/K1

i

+ Plus+ Plus3 Calibration
Over a period of a few hours, the magnet parameters
may drift significantly enough to make it necessary to recalibrate the model. The needed calibration data is
obtained from two Nuclear Magnetic Resonance (NMR)
probes operated in “peaking strip mode”. [2]. In thismode, the probes are operated with fixed radio
frequencies corresponding to two chosen fixed field values
close to the bottom and top field values (Fig. 3). During
the cycle ramp as the field passes these NMR set points,
the resulting resonance signal triggers the production oftiming pulse events. The time at which the NMR produces
these field crossing events is compared with the model
prediction, and if the mean of the difference exceeds a
pre-set threshold value, new offset and scale factors arecalculated.

Sum+ Plus+ Plus- Minus

Flat top for
extraction

8000
Gauss
MNR HIGH
Set point

K2
Eddy Currents

Remnant +Bottom field

B(t)
Time

Fig. 2: Mathematical magnet model

K1 =µ0 * N
ℜgap
×gapℜgap + ℜcore

Magnetic flux density from 0 to 0.8 Tesla

Eddy current influencein Tesla

B field

I bottomB bottomModeledmagnetic field

Real magnetic
field

MNR LOW
Set point
Injectionplateaux
MNR
plateaux
Correction of models scale
factorℜ ⇒ Magnetic ReluctanceT 1 ⇒ Time constant lag of regulation loop

Time from start cycle t(0) to end cycle at 1.2 Seconds

An ideal magnet and power supply respond perfectly to
the L didt control function in zero time. This model takes
such an idealdB
dt function

function L diand the bottom current Ibottom
dt

which

represents the MPS control loop response to the ideal.
delayed

×

1200
ms

Fig. 3: Calibration using NMR low and high markers

and the bottom field value

Bbottom programmed from the cycle editor as input. It uses
a first order recursive filter to calculate the delayed

L didt = dB
dt

Correction of models
offset value [B-res]

BbottomL’ and I bottom =K1
K1

The control voltage that must be applied to the magnet
is given by V(t ) = L didt + Ri(t ) which must be checked
not to exceed the maximum voltage limit Vmax that thepower supply can deliver.
The first order eddy current influence appears as a time
lag of the final field that can be expressed as theadjustment value Beddy = − K 2 × L di
dt

This adaptive model can thus be described as a guided
interpolation through the NMR set points, based on thecontrol function and the magnet and control loop
parameters. These NMR set points are point likemeasurements made in the central field region of thereference magnet, and correspond to the chosen high andlow fields with a precision of better than 0.1 Gauss. This
NMR precision limitation is a consequence of using it in
the peaking-strip mode [2] There may also be small
differences between the field in the reference magnet,
located outside the beam tunnel and without the beam
pipes, compared with those bending the beam.
4 Hardware and software layout
Fig. 4 shows the layout of the measured and synthetic BTrain components. The maximum ramp dB
dt obtainablefrom the MPS is limited by the maximum driving voltage

(Vmax = 4000 Volts), implying 4 T/s. A 0.1 Gauss
incremental B-Train thus requires a maximum gridfrequency of 400 kHz.

5. Comparing the measured and synthetic B-trains
against the NMR at the high field value set point

Each time a PSB cycle L di
dt function is modified, themodel must be run again. The resulting B(t ) function isconverted into two bitmaps, B-up and B-down, in which
each bit represents a 0.1 Gauss increase or decrease infield, on a time grid of 1/400ms. The bit maps are loaded
into two specially developed VME pulse generator
modules [3], which produce the synthetic B-trains. These
modules are shift registers clocked at 400KHz, and started
at the beginning of the cycle. The two resulting output bit
streams are the synthetic B-Trains, B-up, and B-down,
and the value in an up-down counter clocked by thesetrains is the value of B at each instant in the cycle.
The measured B-train derived from a long coil in thereference magnet produces only a 1 Gauss resolution B-up
train, which is useful only if the field during the first halfof the cycle continually increases with an error less than 1
Gauss. A B-value counter clocked by the measured BTrain is sampled at a frequency of 1KHz, by a Dual PortRAM (DPRAM) VME module [4], and the samples are
kept in memory. The contents of the DPRAM thus
represent the sampled magnetic profile of the cycle
B(t)measured, which can be compared with the model. Any
unexpected differences (Fig. 5) between the two estimatesof the field profile indicate problems either with the MPS
control or with the measurement system.

Magnetic cycle editor
Ldi/dt function

Ldi/dtfunction

The measured B-train system has been improved bytriggering the start of the measurement from the NMR low
field event. The initial burst offset value is set tocorrespond to the NMR low field set point. Comparisonswere made of the variation between the measurement withand without NMR triggering against the synthetic train at
0.6849 T near the flat top of the proton acceleration cycle(Fig. 6). The deviation of the synthetic train from the
NMR is caused by the control loop error.

0.8

B-field (T )0.7
M easured B-train

0.6
0.5
Syntethic B-train

0.4
0.3
0.2
0.1
0
D ifference (x 1000)

T im e ( s )-0.1
0Fig. 5:

0.2

0.4

0.6

0.8

1

1.2

Typical difference between the measured andsynthetic field estimates

1Khz clock

Function
generator
softwarecontrol module

Function
generator
moduleproducing
control
voltage+10V..-10V

ReferencemagnetVoltage to frequency
convertercore

Ldi/dt function
Data base ofmagnetic cycle
functions

Dual portRAM
module Start cycle
stocks thecountedvalue of B
for eachclock tick

Long coilmeasures dB/dt

Main Powersupply1 Gauss train

NMR Low field

Model software
control module

Pulse shaper

low = start measure

L, H, R etc
Magnetconstants for
model

Offset field,
and scalefactorNMR High field
Modeled B(t)highCalibration
functionHigh and low field times

Calibrated B(t)B Train
Generation
hardware driver
Start cycle

1Khz clock

Synthetic
B-Traingeneration
moduleDual portRAM
modulestocks thecountedvalue of B
for eachclock tick

Bit map
Synthetic B-Train (UP+DOWN)
1 or 0.1 Gauss

400 KHz Clock

Fig. 4: Hardware and software layout

Timingsurveillance
modulemeasures time of
low and highfield with respect
to the start pulse

Start cycle
10 MHz Reference
ClockStandard deviation (G)
1.03
0.82

Synthetic(Control)Measuredwith NMR
Trig

0.59

Measured

1.2
1
0.8
0.6
0.4
0.2
0

Fig. 6 : Comparison of the measured and synthetic

6 Conclusion
It is simpler to maintain a model of the magnetic field
than to perform the corresponding real measurement. In
providing a synthetic B-train, the control loop itself is thelimit on precision, the model assumes the control works.
Nevertheless, a measurement is essential because there
can be cases when the control is incorrect, and hence thedifference function between
thesynthetic andmeasurement trains [Fig. 6] is a very useful diagnostic.
The repeatability and lack of noise of the synthetic train
often simplifies hardware and software processing of the
field data. The adaptive model following the NMR set
points is able to follow slow drifts such as those induced
by temperature changes.
7 Acknowledgements
The authors would like to thank J.D. Schnell who
implemented and maintains the current B-train
measurement system, and G.H. Hemelsoet for the
implementation of the BTG equipment access softwaremodule.
8 References[1] T. Salvermoser, “Graphical Magnet model”, CERN
internal note PS/PO Note 96-16, 1996.
[2] F. Caspers, M. Benedikt, D. Cornuet, W. Heinze, J.
Lewis, M. Lindroos, T. Salvermoser, “Operational
Experience Using NMR Markers for Precision B-train
Generation”, presented at "International Magnet
Measurement Workshop 10", FNAL, Oct 13-16, 1997
[3] W. Heinze, “User Manual for the B-Train Generator
VME Module (BTG)”, CERN internal note
PS/CO/Note 96-49, 1996
[4] W. Heinze, “User Manual for the DP-RAM”, CERN
internal note PS/CO/Note 94-49, 1994

Filename:
VP086.DOC
Directory:
D:\NPAPER97\ZRY
Template:
C:\WINWORD\TEMPLATE\NORMAL.DOT
Title:
Title Title Title
Subject:
Author:JIANG MINGBAO
Keywords:
Comments:
Creation Date:
01/12/98 4:18 PM
Revision Number:
4
Last Saved On:
01/12/98 4:29 PM
Last Saved By:
chuyp
Total Editing Time:
10 Minutes
Last Printed On:
01/19/98 4:28 PM
As of Last Complete Printing
Number of Pages:
4
Number of Words: 1,612 (approx.)
Number of Characters: 9,194 (approx.)