A driven diffusion equation approach for optimization of a digital spectrum stabilizer

A driven diffusion equation approach for optimization of a digital spectrum stabilizer

Nuclear Instruments and Methods in Physics Research B 103 (I995) 89-93 B e a m Interactions with Materials 8, Atoms ELSEVIER A driven diffusion equ...

459KB Sizes 0 Downloads 10 Views

Nuclear Instruments and Methods in Physics Research B 103 (I995) 89-93

B e a m Interactions with Materials 8, Atoms

ELSEVIER

A driven diffusion equation approach for optimization of a digital spectrum stabilizer Chi-Hang Lain a,., C.D. Beling b, EK. Mackeown b, H.L. Au b, S. Fung b a Departnwnt of Applied Physics, Hong Kong Polytechnic, Hung Horn, Hong Kong b Department of Physics, UniversiO, ofHong Kong, Pok Fu Lain Road, Hong Kong

Received 3 January 1995 Abstract The point-mode digital stabilization method for gamma-ray spectrum measurement over long duration is examined. The stabilizer generates a stabilizing bias to reduce the adverse effects of the electronic bias due to fluctuations in laboratory conditions or electronic instability. The stabilizing bias turns out to be a stochastic variable with a time dependent probability distribution following an exactly solvable driven diffusion equation. From the results, we calculate and discuss the optimum setting of the stabilizer for best performance.

1. Introduction The accurate measurement of gamma-ray spectra is often a challenging task. In many experimental situations, a prolonged period of data collection is necessary to average out the random fluctuations in the response of the detectors and the associated electronics. A typical example is the extraction of electron momentum densities from the 511 keV positron annihilation line [ 1]. For such experiments, good control of the laboratory conditions and very stable electronics are essential. This is because the electronic drift caused by, for example, small temperature variations in the iaboratory can considerably decrease the spectral resoiution. In this paper, we discuss the "point-mode" digital stabilization method [2], which is often used in minimizing the effect of the undesired electronic drift. In such a system, when the dc offset of the spectrum suffers from some electronic drift with the system gain remaining stable, the digital stabilizer monitors the movement of an easily identifiable peak in the gamma-ray spectrum. According to the movement, the stabilizer informs its internal amplifier to change its dc offset appropriately in order to generate an effective stabilizing bias to compensate for the drift. This feedback mechanism thus anchors the reference peak at a fixed position. To correct also for any drift in the gain, a similar stabilization can also be made on a reference peak located at the high energy end of the spectrum, feedback being made through small changes in the stabilizer's internal gain controI. Although our discussions will concentrate on the case '~Correspondingauthor.Tel. +852 766 5681, fax +852 333 7629, e-mail [email protected]. 0168-583x/95/S09.50 @ 1995 ElsevierScienceB.V. All rights reserved SSDI 0168-583X(95)00563-3

of simple dc offset stabilization, the resuIts also apply directly to the more general case of full dc offset and gain stabilization. In the following, we thus drop the terms dc offset and gain and simply refer to the correction being made by the stabilizer as the stabilizing bias. The "point mode" digital stabilization method is usually implemented using a pair of adjacent single channel analyzer (SCA) windows as shown in Fig. 1. The reference peak is initially positioned at the center of the window pair. The stabilizer attempts to keep it at the particular position so that both windows gather the same count rates. To do this, whenever the right (left) window acquires a signal, the stabilizer initiates a finite adjustment of the stabilizing bias so that the spectrum is brought towards the left (fight) by a fixed amount. As a result, if the peak is shifted, for example, to the right, the right window receives more counts than the left one. The net adjustment is then towards the left and serves appropriately as the correction. A full description of the hardware design may be found in Refs. [3,4]. The most important parameter in this method of stabilization is the magnitude of each individual adjustment of the bias. It has to be sufficiently big so that the stabilizing bias is mobile enough to catch up with the electronic drift. However, it cannot be too large. Consider the case when the electronic drift is small. The random fluctuations in the difference of the counts received by the two windows indeed induce an undesired random wandering of the bias. This will obviously decrease the spectral resolution. The magnitude of the wandering increases with the step size. Therefore, the step size should be set to an optimum value to compromise between the mobility and the random wandering of the stabilizing bias.

C.-H. Lain et al./Nucl. Instr. and Meth. in Phys. Res. B 103 (1995) 89-93

90

,X

both windows receive identical countrates at x = 0. For small x compared to the width of the peak, the increase of the area of the partition on the right is proportional to hx. In fact, for the normalization scheme explained above, we simply have T_(x) ~_ 0.5 + hx. This is the probability o f x being decreased. It is similar for the probability, T+, that the signal falls into the left window, leading to an increment of x. These probabilities can be summarized as

,f

/:7 / /

\

/ ,/

/

\

T±(x) ~_ 0.5 ~: hx.

(1)

S Fig. 1. The reference peak is stabilized inside the adjacent window pair. The area of the peak inside the windows is normalized to unity and h is the height. The stabilizing bias shifts the peak from the center of the window tO X.

In the following, we will discuss the response of the stabilizer to the electronic drift. We calculate the probability distribution of the stabilizing bias for general forms of the drift. The magnitude of peak broadening is computed. Using these results, we derive the optimum parameters for the best stabilization.

2. Evolution of the stabilizing bias

2.1. Case of no electromc drift

The problem is now reduced to a forced random walk: The bias x wanders randomly with the direction of each individual step depending probabilistically on x. The stepping probabilities as defined by Eq. ( I ) are those of the Ehrenfest random walk [5]. Here we proceed to study this walk using standard methods. Let p (x, t) be the probability distribution of the bias x at time t and a t be the average duration between the arrival of two signals in the window pair. At time t + At, if the value of the bias is x, there are two possibilities. First, the bias was x + ~x at time t and the adjustment was to decrease x by ,Xx. The altemative is that the bias was x - Ax and was increased. Therefore, p(x, t ÷ At) can be expressed in terms of p (x, t) through the master equation:

p(x,t + At) = T + ( x - Ax)p(x-- Ax, t) +T-(x + Ax)p(x + Ax, t).

In the absence of any electronic drift, obviously the stabilizer is unnecessary. The random wandering of the stabilizing bias would even broaden the spectrum. However, we will start our computation on the statistical properties of the bias from this simple case. The results will be generalized in the next section. Without loss of generality, we set the mid-point of the window pair, which separates the left and the right windows, to be at a certain spectral position which for convenience, we label as 0. Assume that the reference peak is approximately symmetrical. The method attempts to stabilize the center of the peak around position 0. Let h be the peak height when the area under the peak inside the window pair is normalized to unity. Thus h is approximately inversely proportional to the width of the peak. If the reference peak is a Gaussian with standard deviation cro, then h = 1/~,/~_~cro. We further define the stabilizing bias x so that the peak is centered at 0 when x = 0 and accordingIy when the bias is x, the center of the peak is shifted from spectral position 0 to x (see Fig. i). When the right (left) window receives a count, x is decreased (increased) by the step size Ax. Note that for the present discussion, it makes no difference whether the bias x is thought of as the stabilizer induced voItage offset or the corresponding spectral position (in channeIs). When a signal falls into the window pair, the conditionaI probability, T- (x), that it is on the right window is proportional to the area of the partition of the peak on the right, which depends on x. In our definition, 7"-(0) = 0.5 so that

(2)

We now substitute Eq. (1) and Taylor expand the distributions about (x, t). After taking the continuum limit and dropping the higher order terms, we get

Op O"p D/30(xp) 0-7 = °Tx~ + ax

(3)

This is a driven diffusion equation, the solutions of which have been discussed by Kohlrausch and Schr~Sdinger [6]. The first term on the RHS is the diffusion term with the diffusion coefficient D = (Ax)a/2Lxt. The second term stabilizes x around 0. The quantity/3 = 4h/Ax is proportional the strength of the stabilization. Assume that x = x0 initially at t = 0. The solution of Eq. (3) is that x follows the time dependent Gaussian distribution:

p(x, t) = (v'7"~ o ' t ) - ' e x p [ - (x - `at)2/2o-~].

(4)

Before further explanations, we recast the result for convenience into the folIowing equivalent form. We put x = o-t( + ,at.

(5)

The random variable ( is a standardized nolvnal deviate following the Gaussian distribution of unit width and zero mean. The time dependent variables o-t and ,at are respectively the rms deviation and the mean of x. We have ,at = xo e x p ( - t / r ) ,

(6)

91

C.-H. Lain et aI./Nucl. Instr. and Meth. in Phys. Res. B 103 (1995)89-93

which shows that the mean relaxes exponentially from the initial value xo to the steady state value 0. Here, r is the relaxation time given by

r = 1~Dr = At/2hAx.

(7)

Initially, x is at xo with certainty, so the width of the Gaussian is 0. As the predictability decreases at later times due to the wandering, the width expands in the form o-t = -,/1 - e x p ( - 2 t / r ) etch,

(8)

where cr~ is the steady state width given by O'¢,a = /~--[/2 =

V/-£7/4h.

(9)

3. Minimization of spectrum convolution From the above analysis, we note that under point-mode stabilization, measured spectra are convoluted with the probability distribution of the total shift s. Therefore, the fluctuation of s is a factor affecting system resolution. In expression (15) for s, the lag term I(t) has been treated as a deterministic quantity depending on the bias v(t). We now describe it statistically by considering v(t) to be a random time series to be determined experimentally. In practice, realizations of v(t) can be estimated by tracing the position of a distinguishable peak without the stabilizer switched on. The lag I(t) can then be obtained by the following numerical transform:

2.2. Case of generaI electronic drift We now generalize the result to the case where there is an arbitrary time dependent electronic bias v(t). Now, the spectrum is shifted by an amount s which is the sum x + v(t) of both the stabilizing and the electronic bias. The probability for a decrement or increment of the bias x now depends on s instead of x. Therefore, Eq. ( i ) is modified to

T±~-O.5-Ths=O.5q:h[x+v(t)].

(10)

The new evolution equation is

Op _ O2p +v(t)]p 8-7 - D-~x2 + DtgO[x 8x

(11)

It can be solved by first transforming back to Eq. (3). The details are given in the Appendix. The solution only differs from the previous one in that Eq. (6) is replaced by a more complicated expression for the mean:

/xt= [ x o + v ( O ) ] e x p ( - t / r )

+I(t) -v(t),

(12)

where t

f

I(t)=

. , , , ~ dv(t')

exp(-(t-r)/r)---dT-dt'.

(13)

J

0

We are interested at the steady state properties such that t >> r. Eqs. (5) and (12) are combined and simplified to

x = cr~,~ q- I(t) - v(t).

(14)

The total spectral shift s is now given by

s = x + v(t) = o'¢~( + I(t).

(15)

We see that s consists of two independent components as was explained qualitatively in the introduction of this paper. The c r ~ ( term corresponds to the random wandering due the fluctuations in the count rates of the windows. It is independent of v (t). The I (t) term corresponds to an averaged lag of the stabilizing bias in catching up the electronic drift. It is due to the finite mobility of the bias and depends explicitly on v(t). Our aim is to find the ideal compromise between these two terms.

I ( t ) = -rl / e x p ( - / ' /r) [ v( O - v( t

-

t')]

d/'.

(16)

0

The range of the integration may be approximated by a finite interval such as [0, 3r]. Eq. (16) is obtained by integrating Eq. (13) by parts using the steady state condition t >> r. It is a more convenient expression because only v (t), instead of its time derivative, is involved. After obtaining sample series of I (t), the rms deviation o-~ of I (t) can be computed. From Eq. (15), the fluctuation of s is due to that of ( and I (t). Since these are independent random variables, the rms deviation o's of s is given by 2 o"2s = o'~ + cr'~7.

(17)

Substituting Eq. (9), we get

O's = [Ax/4h + cr~] :/2.

(18)

We have now expressed o's as a function of Ax and other system parameters. Note that o-z also depends on i x because the transform in Eq. (16) depends on r, which in turn depends on Ax through Eq. (7). These results allow a plot of O's against Ax for the range of a x allowed by the stabilizer. The spectrum suffers from the least convolution when ors is minimized. The step size ( A X ) o p t to achieve this optimum point can be read off from the plot of Ors against Ax. The above procedure determines (AX)opt numerically. Since we have assumed a general form for the electronic bias, analytical formula cannot be derived. We now consider a specific case in which closed form expressions can be obtained. We assume that the rate of change of the electronic bias varies only slowly so that v'(t) = 8v(t)/at is approximately constant over periods of time r. Eq. (13) then reduces to

I(t) = rv'(t),

(19)

which implies GI = TGvl ,

(20)

C.-H. Lain et aL/Nucl, hlstr, and Meth. in Phys. Res. B 103 (1995)89-93

92

F

. . . . . . . .

~

F

. . . . . . . .

,"___\'__C_ i FRONT END g (V/MeV)

-I

!___U STABILIZER X (staNlizmg bias)

ANALYSER a a (channels/V)

Fig. 2. A schematic diagram of a modern gamma-ray spectroscopy system. D = Ge detector crystal, RA. = pre-amplifier, M.A. = main spectroscopy (shaping) amplifier, S = stabilizer unit, ADC = analogue to digital converter, M = memory storage of spectrum, F = digital feedback from ADC to stabilizer.

where crv, is the rms deviation of v'(t) and can be determined from experimental realizations of v (t). Applying Eqs. (20) and (7), Eq. (18) becomes

o-s =

+ \ 2hax /

=

\

/

j

,

(21)

where Go is the rms deviation of the reference peak assuming that it is a Gaussian. The optimum value of the step size Ax is (aX)opt

= (20"~,At2/h)1/3

= ( 2 X / ~ ' ~ o.00.~, A t 2) I/3,

(22)

at which point O-s is minimized to

( O's)opt = 4

( 4o'L,,At/h2) l/3 = --~-('rrO'oO'v,At) l/3 (23)

4. Discussion We have so far computed the probability distribution of the stabilizing bias in terms of the electronic drift. The totai shift of the spectrum due to the combined effects of the electronic drift and stabilizing bias consists of a random component with Gaussian distribution and an electronic drift dependent component corresponding to a lag in the response of the stabilization. In order to minimize the spectral shift, one has to compromise between the two effects. In some situations, this can be done by setting the step size/',x of the stabilizing bias to an optimum value as already described. However, in practice, there may exist additional constraints. Fig. 2 shows schematically the essential elements of a commercial stabilized gamma-ray spectroscopy system. The main components are the solid-state detector and associated charge sensitive preamplifier, the main spectroscopy amplifiers that shape and amplify puIses from the detector, the stabilizer unit, the analogue to digitai conversion (ADC) unit, and the spectrum storage memory. After the main amplifiers the electronic drift voltage v(t) exists. The dc-offset control on the stabilizer unit is, as mentioned

earlier, controlled by the signals feedback from the ADC unit, according to whether a signal fell into either of the window pair. This gives rise to the output s(t) = v(t) + x. From Fig. 2 it can be seen that there are two important gain factors (amplifications) in the system. The first is that of the "front end" of the system, which includes the detector, preamplifier and main amplifiers. Here a certain gamma-ray energy (in MeV) being converted into a voltage (V) gives a variable gain factor g (in V/MeV). The second is that of the ADC, which converts a given pulse voltage into an analyzer position (in channels). This variable gain factor, ai, (in channels/V) is referred to as the conversion gain. It should be noted that the above analysis does not depend on whether we are dealing with a bias expressed in Volts or its equivalent value in channels. In Eqs. (22) and (23), for example the quantities, Ax, o'v,~t, o's and o'o may be expressed in either unit since multiplication of these by ai (i.e. on passing through the ADC) leaves the expressions unaltered. The quality of stabilization is thus not affected by changes in a,.. The same invariance can only apply with respect to the "front end" gain g providing o'o, varies in direct proportion to g. Since there is no a-priori reason for such a relation it must be taken that the optimum setting depends on g in a non-trivial way. With regard to this point, however, it is important to note that for real apparatus we are not allowed the luxury of being able to vary Ax continuously. For some stabilizers ~x can take just one voltage value, whib for others a few values may be selected. We shall see that this fact has important consequences. Under the constraint of a few allowed values of ~x, the one closest to (AX)opt in Eq. (22) should be used to obtain approximate optimization. However, if ~x is fixed or if the choices are too limited, it may be impossible to set Ax _~ (zXx)opt. A second method we may then consider is to adjust the front-end gain g. The limitation of this method will be discussed later. In this scheme, we need to minimize the rms deviation 2', = Gs/g of the spectral shift on the energy scale. (In previous discussions, it makes no difference minimizing 2"s or o-s since g was kept as a constant.) Eq. (21) gives

~=



] 4g

(24)

where 2'0 = o'o/g is the width of the stabilizer peak on the energy scale and is constant with respect to g and ~Xx.However, the rms deviation o'~,, of v'(t) can have a complicated dependence on g. This forbids analytical solution of the optimum setting. Instead, in practice we have to obtain o-~,, experimentally for a number of values ofg covering a range wide enough to contain the optimum point. For each g, o'~,, can be computed from a realization of v(t) taken when the front-end gain is set to g. Using Eq. (24), we can list the values of ors as a two dimensional function of the sampled g's and allowed Ax's. The optimum setting ((g)ovt, (~x)opt) can thus be read off.

C,-H. Lain et al./NucI. Instr. and Meth, in Phys. Res. B 103 (1995) 89-93

An important fact that comes from the above analysis is that some variation of the parameter i x is clearly desirable on a commerciaI stabilizer. Without this flexibility, the front-end gain, g, have to be set to a specific value (g)opt to give optimized stabilization. This value may turn out to be in conflict with other experimental requirements. One obvious example is if (g)opt is tOO large then it may well be impossible to record two neighboring gamma-ray lines simultaneously. There are also cases in which maximizing the system dispersion is desirable, such as deconvolution of the Doppler broadened positron annihilation line where information on line shape is to be maximized. We note that if cry is the rms deviation of v (t) during the whole period of the experiment, then without the stabilizer, spectrums measured are convoluted with the distribution of v(t) of width o-~. This can be much bigger than the optimum convoIution (O's)opt with the stabilizer. The difference is most noticeable in the case of v(t) varying at a constant rate so that the time derivative v'(t) is a constant. In this case o'~ is proportional to the duration of the experiment and can be very large, while from Eq. (23), (o-s)opt is zero. A constant drift oniy causes a constant Iag in the respond of the stabilizer. This results in no fluctuations in the shift of the spectrum and does not induce convolution of the spectrum. Therefore, in circumstances like this, the stabilizer is indispensable. The analytic formula for optimization in Eq. (23) summarizes several rather expected points about decreasing the convolution, which is expected to hold qualitatively also in other general cases discussed above. First, the deviation cr'o of the rate of change of the electronic drift have to be minimized by the best environmental control Here it is noted that what is really required, is not that there be no environmental change, but that such changes should occur slowly (with respect to ~-). In practical terms this suggests that one should employ large thermal masses around the electronics to damp temperature changes in preference to a fast feedback temperature control system. Methods should also be employed for damping out fast fluctuations in the line voltage. Second, the mean duration At between signals should be decreased by increasing the count rate failing into the window pair to a maximum. This maximum in most applications is likely to be determined by considerations of pulse processing, since with any practical gamma-ray spectroscopy system resolution aIways degrades as count rate is increased. The above analysis would tend to suggest that there is little merit in increasing the count rate to the degree that the degradation of system resolution is greater than that imposed by o',. Finally it is noted that the peak should have as narrow a width, o'0, as possible. In this respect side peaks produced by highIy stabilized electronic pulsers are often used for stabilizing gamma-ray spectra as these produce significantly narrower lines than those produced by reference gamma-rays.

93

Appendix A By a change of variable, the evolution equation (11) for the case with electronic drift can be reduced to Eq. (3) corresponding to the case with no drift. Without the drift, the stabilizing bias x wanders around the value 0 with a dispersion in the form of a Gaussian. In contrast, with a drift v(t), the expected value of the bias is time dependent. For proper stabilization, the bias must be driven towards - v ( t ) so as to compensate for the drift. We attempt to isolate this time dependence of the mean value of the bias from our problem. We define

u(x,t) = x +v(t) - I(t),

(A.1)

where I(t) is to be determined. By changing the variable from x to u, Eq. (11) is transformed to

Op 02p d p 0-7=D77 + Dt3&~p a , , - [ 57 ( v - z ) - n ~ z l a07'

(A.2) where the probability distribution has been reparameterized to p(u, t). We seek for I(t) such that d

(v - I) - DfiI = 0.

(A.3)

This equation can be solved easily and a solution is given in Eq. (13). We have thus found the desired transformation expressed in Eqs. (A. 1) and ( 13 ). The last term on the RHS of Eq. (A.2) is now eliminated. The equation thus reduces to Eq. (3) with the known solution now expressed in term of u. A transformation back to x using Eq. (A.I) gives the solution of Eq. ( 11 ).

References [1] Y. Kong and K.G. Lynn, Nucl. Instr. and Meth. A 302 (1991) 145. [2] For a recent review, see: G.E Knoll, Radiation Detection and Measurement, 2nd ed. (Wiley, New York, I989). [3] M. Yamashita, Nucl. Instr. and IVleth. II4 (I974) 75. [4] RJ. Borg, R Huppert, EL. Philips and EJ. Waddington, Nucl. Instr. and Meth. A 238 (1985) 104. 15] P. Ehrenfest and T. Ehrenfest, in: P. Ehrenfest's Collected Scientific Papers, Ed. M. Klein (North Holland, Amsterdam, 1959) p. 128. [6] K.W.E Kohlrausch and E. Schrodinger, Phys. Z. 27 (1926) 306.