NUCLEAR
INSTRUMENTS
AND
METHODS
I2 4
(I975)
429-435;
©
NORTH-HOLLAND
PUBLISHING
CO.
T H E O R Y OF D I G I T A L F I L T E R I N G I N C O R R E L A T I O N T I M E - O F - F L I G H T SPECTROMETRY R. A M A D O R I and F. HOSSFELD*
Institut fiir Festk6rperforschung, Kernforschungsanlage Jiilich, Jiilich, Germany
Received 10 October 1974 After a brief outline of the main features of the correlation time-of-flight method a digital fi~ering technique based on the additional use of an uncorrelated pseudo-random binary sequence is quantitatively discussed with respect to the parameters controlling the gain factor. This technique turns out to be useful in cases where a huge nuisance peak is present in the system response. 1. I n t r o d u c t i o n
The theoretical principles of the correlation method for time-of-flight (TOF) spectrometry have been discussed extensively1-5); especially the gain factor describing the superiority of the correlation method over the conventional method has been analyzed with respect to the various parameters which determine the magnitude of this gain factor. It may be recalled that - except for high background - the magnitude of the gain factor increases due to increasing relative signal height. This feature of the correlation method is disadvantageous in cases where portions of low intensity in the T O F spectrum are to be studied in the presence of one or more huge peaks which may be of no primary interest for the experimental investigation. The basic idea of filtering techniques designed so far in connection with the correlation method in T O F spectrometry is to eliminate those irrelevant large peaks, thereby decreasing the average signal height and in turn increasing the relative signal height of the low intensity portions of the spectrum and consequently increasing the gain factor for measuring them by the correlation technique. This idea is illustrated in fig. 1: the dotted line represents the boundary between regions where the correlation method is of advantage (at + ]? > 1 ; for the definition of ar and/?, see section 2 below) or disadvantage (a~ + fl < 1), respectively. In the upper part of the figure, the small peaks of interest are inside the region where the correlation technique gives no advantage over the conventional technique; in the lower part of the figure, due to the elimination of the large peak, the boundary line is shifted downwards and the small peaks are inside the region of advantage. One method of filtering large peaks in neutron T O F spectrometry is to use crystal filters°). The merits of this
.
.
.
.
.
t]TA-A-........ Fig. 1. The effect of filtering on a TOF spectrum. * Now at the Zentralinstitut fiir Angewandte Mathematik, Kernforschungsanlage Jiilich, Jt~lich, Germany. 429
430
R. A M A D O R I
A N D F. H O S S F E L D
method have been discussed theoretically in ref. 1 and shown to be substantial if appropriate filter crystals are available. In order to avoid this limitation, or in addition to this technique, a purely electronic filtering technique seems to be challenging. In this paper, a rigorous analysis and extension of a digital filtering technique proposed in ref. 7 is presented yielding quantitative criteria for the efficiency region of the method with respect to TOF spectrometry.
2. Summary of univariable correlation technique without filtering In this section a brief outline of the univariable correlation technique without filtering ~' 2) is given in order to facilitate comparisons with the filtering technique. If a monochromatic primary beam is periodically modulated by any chopper according to a pseudo-random binary sequence (PRBS) (at), the~tiscrete time distribution of the scattered particles is given by
Zk = l
/
)
~
Siak_,+b ,
\i=0
(1)
where St (i = 0, 1. . . . . L s - 1) is the system response equivalent to the discrete time-of-flight spectrum of the scattering sample (S i = 0, i _> L~), and b is the constant background per time channel (of width 0) in the particular experimental arrangement. The parameters of the PRBS (a~) are denoted by N (period of the PRBS, N _> L~) and m (number of 1-states of the PRBS); c = ( m - 1 ) / ( N - 1 ) is defined as the duty cycle of the chopper, l is the total cycle number during the experiment. The autocorrelation function (ACF) of the PRBS (at) is N- 1
Ca~(v) = ~
a~ai+~ =
i=o
[m,
for v = 0(rood N),
/h,
for all other values of v.
(2)
The integer value of h is given by the necessary condition: h ( N - 1 ) = re(m-1)2). Cross-correlation of Z k with (a0, N-1
Ls-i
K, = Z Zkak-, = l Z k=O
S~C,~(r-i)+ Ibm,
(3)
i=0
yields the desired spectrum
1 ~ ~ Sr
=
~
(ak-r-c'~
k=o
b
(4)
m
r = 0, 1. . . . . L s - 1 . With ~=
1 Ls-1 --
Y~ s~,
Ls /=o
~ = s,/g,
B = b/X,
(S)
the gain factor of the correlation method over the conventional method (using one pulse per period L~) is defined as the ratio of the statistical variance of Sr as obtained with the conventional experiment,
(42 s,) .... = ( s t + b)/(ZN/Ls),
(6)
to the variance of Sr
(A2Sr) . . . . ~-I(1-2c) Sr~-¢LsS-~-(1-~)bl/E[m(1-c)],
(7)
as obtained with the correlation method using the same total measuring time T = INO, yielding gZ(o'r,
fl, N, C) = (A2gr)conv/(A2Sr). . . . =
For simplicity, N = L~ is assumed in the following.
ar+fl lrn(1-c) IN/L~ (1 - 2 e ) ~, + cL~ + (1 - e / m ) fl
(s)
THEORY
OF DIGITAL
431
FILTERING
3. Filtering technique using the triple-correlation function There seems to exist a very simple way of achieving the filtering of the unwanted Si for a specific index i, say i -- e. Following this idea, one just has to " a s k " whether, at any given time tk = kO, the unwanted Se may be involved in the sum eq. (1), i.e. elk_ e = 1, and if so, to prevent the detector from accumulating Se in the multichannel analyzer. This could be done by generating the appropriate delayed versions of (a~) and by gating the multi-channel analyzer correspondingly. This would be reflected by rewriting eq. (1) as Zk = l
S~ak_i+b
(1--ak_e),
k = 0, 1. . . . . N - 1 . .
(9)
\i=0
Cross-correlation with (a~) in order to obtain St, yields N-1
Kr = ~ k=O
N-1
Zkak_ r = l ~
(10)
S~[Caa(r-i) -- Caaa(r-i, e - i ) ] + l b [ m - C a a ( r - e ) ] .
~=0
This is similar to eq. (3), and if the triple-correlation fianction N-1
C~a~(u,v) = ~
(11)
aia¢+aa~+~
i=0
of the PRBS (ai) did possess only three levels in analogy to the two-level autocorrelation function eq. (2) of (a~), S, would be eliminated from the sum in eq. (10), since Ca~a(U, O) = Caaa(O, u) = h regardless of u + 0. It has been established 5) by explicit calculation that all known PRBSs with ACF according to eq. (2) and N ~< 1023 do not possess a three-level triple-correlation function as would be required for a simple and straightforward calculation of S~ from eq. (10). At best, Caa, is four-valued (for maximal-length linear shift register sequences and Singer sequences). Therefore, a system of linear equations would have to be solved in order to calculate S~ from eq. (10), posing difficult problems as the K~ are derived from Zg which are measured quantities affected with statistical errors. Due to these difficulties, the filtering technique utilizing the triple-correlation function has been discarded. It should be mentioned, however, that there do exist pseudo-random p-nary (p > 2) sequences with triplecorrelation function identically zero, and three-level autocorrelation function (see ref. 5 and references quoted therein).
4. Filtering technique using uncorrelated PRBS The digital filtering technique proposed in ref. 7 is based on the use of an additional chopper with a PRBS (d~) uncorrelated with the original chopper sequence (ai). Let (Nd, mg, Ca) be the parameters of the "filtering" PRBS (all), and (Na, ma, ca) the parameters of the "modulating" sequence (ai). (ai) and (d~) are uncorrelated if and only if Na and Na have no common factor, which is denoted by
(12)
(Na, Na) = 1
in number-theoretical nomenclatureS), and if the cross-correlation is performed over the period L = Na If these conditions are met,
Na
2, 5).
L--1
Cad(v) =
~
a~di+ v = m a m a,
for all v.
(13)
i=0
Eq. (9) is now replaced by Z~k= I
__ S i a k - l d k - ~ + b \i=O
)
(1--dk-e),
k=0,1 .... ,L--1. [The period of Z~ is L in contrast to N in eq. (9) due to (Na, Na) = 1.]
(14)
432
R. A M A D O R I
AND
F. t t O S S F E L D
Cross-correlation over the period L yields for r = 0, 1. . . . . L - 1 Kr ~
L-1 Na-1 2 Ztkgk-r ~ - l Z k=0
S; Caa(r-i) [Cda(O) -- Cad(e--i)] + lbrn,(Na-ma),
(15)
i=0
using Na Nd-- 1
CaadAU, V, W) =
y,
aia;+.d~+~d~+w = Ca.(u) Cda(W--V),
(.16)
i=0
Na Nd-- 1
Coaa(U, 0 =
2
i=O
a;ai+,,di+~ = Ca,(U) Cdd(O) = Ca~(u)me,
(17)
valid for PRBSs with coprime lengths5). Eq. (15) exhibits close similarity to eq. (3). In practice, cross-correlation is not performed over the period L, but Z~ is accumulated modulo N,:
Zk =
~
Z'k+jN~, =
j=0
~ j=0
1
S~ak_t+jNodk_z+jN+b
(1--dk_~+jN.)
k = 0, 1. . . . , N a - 1 .
(18)
\i=0
Due to (Na, Nd) = 1, each value of subscript of (d0 is sampled exactly once if the summation is done over j, in effect performing the autocorrelation Cad. Thus, eq. (18) reduces to Na-- 1
Zk = 1 ~: S~a~_~[Cdd(O)- Caa(e-i)] + I b ( N d - m a ) .
(19)
i=0
Cross-correlation is now operated on Z k as obtained in eq. (19), of course yielding the same result as eq. (15). In eq. (15), the term Cdd(0) -- Cad (e--i) effects the desired filtering for i = e. It should be paid attention, however, to the fact that N a + Na. This means Cdd(0) -- Cda(e--i) = 0, if i = e(mod Nd). If N a > Nd, there exists more than one value of i satisfying i = e(mod Nd), since i runs from 0 to N a - 1. In principle, this fact can be exploited to filter more than one channel, leading to more complicated calculations than in case Nd > iV,, which is assumed in the following. But in any case N, and Nd must be coprime otherwise the common factor generates an additional periodicity in the results. In ref. 7, both eq. (12) and the consequences of Na > ?Ca have been ignored. Evaluation of S, from eq. (15) yields _
(S~)f~
lmama(1-Ca) k=o
Zk ak-r--Ca \ 1-c a /
b Na-1 ma m a '
(20)
r = 0, 1, ..., N a - 1 , where the subscript " f c " denotes "filter correlation". Eq. (20) is very similar to eq. (4) and is the starting point for the discussion of the gain factor for the filtering method. Formally, eq. (20) may be obtained by replacing in eq. (4) l by lr = lind (1 - Ca) and b by bf = b (N d - 1)/m d . ~ u e to these replacements, calculation of the statistical variance of (S~)e¢ may be done by transcribing eq. (7) accordingly, under the assumption that the quantities Zk in eq. (20) are random variables subject to the Poisson distribution, as assumed in calculating eq. (7) from eq. (4). Thus, 1 I ( 1 - 2 c a ) S~+caN, g + ( 1 - C - 2 a a ) N d - - 1 b], (A 2 S,)fo = Im.( 1 - ca) m a(1 - Ca) m d
(21)
g =---1 ~ S,, N a i*e
(22)
where
because (S~)f~ = 0.
T H E O R Y OF D I G I T A L
FILTERING
433
In discussing gain factors for the filtering technique, two different experimental situations must be taken into consideration. In the first place, it is assumed that originally a standard correlation experiment has been performed with appropriate values of N a and ea , which may not easily be changed due to the usage of a chopper wheel. An additional chopper wheel, constructed according to adequate values of N d and Ca, would then be needed for the filtering; thus ca and Na remain unaltered. In the second situation, where the modulation may be done by magnetically chopped crystals9), different values of duty cycles may be chosen in the standard correlation experiment (duty cycle ca) and in the filter correlation experiment (duty cycle ca,) due to the versatility of the experimental set-up9). It should be mentioned, however, that for N _< 1023, only for N = 31,133,307 there actually exist PRBSs with two different duty cycles [apart from the duty cycle of the complementary sequence2)]. Therefore, if a different duty cycle ca, is to be used (in the filtering technique), which may be required for achieving the maximum gain factor, also a different sequence length Na, is indispensable. If Na, > Na, this deteriorates the gain factor; see ref. 5 for a discussion of the effect of N > L s in eq. (8). For Ls> 250, this deterioration may be neglected, and Na, = Na is assumed in the following. The gain factor of the correlation technique with filtering over the conventional technique using the same total measuring time [l is replaced by lNa in eq. (7)] is g~ = (A 2 Sr) . . . . / ( a 2 Sr)fo -
me(1 - ce)
(~r + 8) too(1 - Ca)
Nd
(1--2ca) ar+caNaR + (l--ca~me) [(Na-1)/ma] fl'
(23)
in the case that ca has not been changed, and gf2, _ rod(1 --Ca) (cr,+fl) me,(1 -- Ca,) Na (1-2ca') a~+%'Na R + (1--ca'line') [(Na-1)/ma] 8 '
(24)
in the case that the original duty cycle Ca has been changed to ca, in the filtering experiment, and R denoting that fraction of the spectrum which is not affected by the filtering: R = ~/S.
(25)
Unfortunately, there do not exist simple criteria for g2f > 1 and g~, > 1. For Ne >> 1, Ca > 0, ma may be approximated by m e ~ caNe, yielding md(] -- Cd)/~q*d ,~ Cd(1 -- Cd), ( N a - 1)/rna ~ 1~ca.
(26) (27)
ca(1 -ca) is maximal for ca = 0.5. Comparing eqs. (23) and (8), it is seen that eqs. (26) and (27) as factors in eq. (23) deteriorate g~. Keeping all other parameters fixed, R must become so small that it compensates for eqs. (26) and (27) to achieve the same numerical value of eq. (23) as given by eq. (8). It is obvious that this is not possible if fl is large. Therefore, in the case of large values of relative background, filtering will be of no use. This result could have been obtained from a discussion of eq. (8) 5): for large values of fl, g2 is independent of a,, and therefore increasing the value of a~ by filtering is irrelevant. The superiority of the correlation technique with filtering over the correlation technique without filtering is described by the gain factor gf2o = ( A 2 S r ) .... /(A2Sr)fc
- rFld(1--Cd)
Na
( 1 - - 2 C a ) O'r-l-CaNa 2V (1--Ca/rFla) [~ (1-2Ca) a~+caNan + (1-ca~me) [(Na-1)/me] 8'
(28)
in the case that ca has not been modified, and g2¢, _ me(1--Cd) me,(1--ca,) (1--2ca) ar+caN~ + (1--ca/m~) fi 8' Na ma(1--c~) (1--2c,,) cc,.+c~,NaR + ( l - c a , / m , , ) [(ga-1)/me] in the case that the original duty cycle ca has been changed to Ca, in the filtering experiment.
(29)
434
R, A M A D O R I A N D F. H O S S F E L D
~F 3
I
2
3
5
"
4
5
Fig. 2. Contour lines for gain factor g2 [eq. (8)], R = 0.1. Maxim u m value is 5.87.
~r
1
2
3
Z,
5
Fig. 3. Contour lines for gain factor gg [eq. (23)], R = 0 . 1 . Maximum value is 4.30.
1
2
3
/~
5
Fig. 7. Contour lines for gain factor g~ [eq. (23)], R = 0.05. Maximum value is 4.93.
3k .5-< 1
2
3
L
5
Fig. 4. Contour lines for gain factor g~, [eq. (24)], R - 0.1. Maximum value is 6.24.
2
1
2
3
Z,
5
Fig. 8. Contour lines for gain factor g~, [eq. (24)], R = 0.05. Maximum value is 8.55.
1
1 I
\r 1
2
3
4
5
Fig. 5. Contour lines for gain factor g~ [eq. (28)], R = 0.1. M a x i m u m value is 1.24.
1 Fig. 6. Contour lines for gain factor g~c, [eq. (29)], R = 0.1. Maximum value is 1.86.
1
2
3
4
5
Fig. 9. Contour lines for gain factor gf~ [eq. (28)], R = 0.05. Maximum value is 1.59.
1
2
3
4
5
Fig. 10. Contour lines for gain factor g~c, [eq. (29)], R = 0.05 Maximum value is 3.30.
THEORY OF D I G I T A L F I L T E R I N G
435
In calculating eqs. (23), (24), (28), and (29), it should be strongly emphasized that comparison of eqs. (21) and (7) is justified only if optimal values 5) of duty cycles are used: for the correlation technique without filtering, the optimal value o f Ca has to be used, depending upon o-r, fl, N,; then, as the additional filtering chopper is introduced, the optimal value for cd [minimizing eq. (21) if all other parameters - including the previously found ca - are held fixed, in case of calculating eqs. (23) and (28)] is to be applied; in calculating eqs. (24) and (29) that set of Ca, and c a is to be applied which minimizes eq. (21). Violating these principles leads to meaningless results. For example, putting ar = fl = 0, ca = 0.5, in eq. (28) gives rise to fiezc= (4 R) - 1 = 2.5 for R = 10 - ~. But, for o-r = ]? = 0, the optimal duty cycle of the correlation method is zero, i.e. the correlation method degenerates into the conventional method. The application of arbitrarily chosen values of ca and ca in eq. (23) is grossly misleading in evaluating the merits of the filtering technique, as compared to the correlation technique without filtering. This has, for instance, happened in ref. 7, where ca = 0.5 has been used which is by no means a reasonable duty cycle if no background is present as was postulated in the case of ref. 7. Of course, decreasing this inadequate duty cycle by an additional modulation (the "filtering") produces a "gain" which, however, might have been attained without filtering by using the appropriate value of c a in the standard correlation method. Fig. 2 shows contour lines for fi2, figs. 3-6 show contour lines for g2f, ff2f,, fife,2and fi2, in the case that R = 0.1 ; and figs. 7-10 show contour lines for the same gain factors in the case that R = 0.05 (No -- 255, Nd = 263 in figs. 210). The maximum value of the gain factor reached in each diagram is indicated by * and its numerical value is given in the caption. Numerical values of the contour lines are placed on the uphill side of the contour lines. The dotted line in figs. 3-10 indicates the boundary a r + f i = 1 below which the standard correlation technique gives no advantage over the conventional technique. The figures illustrate the restricted area where the filtering technique may be of practical use. Filtering produces an increased value of the gain factor mainly in those regions where the standard correlation gain factor itself is reasonably large. For a r + fl < 1, the filtering technique yields a much smaller increase in gain factor, if any. We should mention that large peaks in TOF spectrometry typically occupy several channels, instead of one if high resolution of the spectrum is required; therefore, in general, values of R small enough to generate a large value of fi2¢ will only be obtained in very special scattering problems. 5. Conclusions
In this paper a rigorous treatment of a digital filtering technique for the univariable correlation time-of-flight method was presented in order to improve the efficiency of this method by the elimination of the disturbing influence due to a nuisance peak within the system response. From the discussion of the gain factor results that the filtering technique will be of reasonable advantage in cases where the ratio of the interesting part of the spectrum to the nuisance peak channel is less than 0.05. For an extension to methods utilizing uncorrelated PRBSs for filtering more than one channel, and to filtering techniques for multivariable correlation methods as discussed in ref. 10 one may refer to ref. 5. It should be mentioned that these digital filtering techniques might also be of interest in applications of the correlation method to other fields of science and engineering. References 1) F. HoBfeld, R. Amadori and R. Scherm, Proc. Instrumentation for neutron inelastic scattering research (IAEA, Vienna, 1970) p. 117. 2) F. HoBfeld and R. Amadori, Jill-Report no. 684-FF (1970). z) W. Reichardt, F. Gompf, K. H. Beckurts, W. Gl~iser, G. Ehret and G. Wilhelmi, Proc. Instrumentation for neutron inelastic scattering research (IAEA, Vienna, 1970) p. 147. 4) G. Wilhelmi and t =. Gompf, Nucl. Instr. and Meth. 81 (1970) 36. 5) R. Amadori, Jtil-Report no. 1050-FF (1974). 6) S. J. Cocking and M. T. Evans, unpublished report (1968). 7) p. Pellionisz, N. Kroo and F. Mezei, Proc. Neutron inelastic scattering (IAEA, Vienna, 1972) p. 787. s) I. M. Vinogradov, Elements of number theory (Dover Publ. Co:, New York, 1954). 9) H. A. Mook, F. W. Snodgrass and D. D. Bates, Nucl. Instr. and Meth. 116 (1974) 205. 10) R. Amadori and F. Hogfeld, Proc. Neutron inelastic scattering (IAEA, Vaenna, 1972) p. 747.