se o wals functidt hiwthwfn w3902

8
TECHNICAL LIB9ARY IEEE TRANSACTIONS ON COMPUTERS, VOL. C-23, NO. 3, MARCH 1974 SINGER COMPANY SIMULATION PRODUCTS DIVISION se o Wals Functidt HiWthWfn W3902 Analysis of Nonlinear Systems ANDREW S. FRENCH, MEMBER, IEEE, AND EDWARD G. BUTZ Abstract-A powerful means of analyzing nonlinear systems is provided by the Wiener functional expansion. However, this technique has not been implemented widely in experimental situations because of the difficulties associated with measuring the kernels of the system, which constitutes the analysis problem. A new method of measuring the kernels is described here in which the Walsh functions are used as the set of orthogonal functions with which the kernels are expanded. The multiplicative properties of the Walsh functions and the fast Walsh-Fourier transform make the measurement scheme very efficient. Index Terms-Dyadic kernels, nonlinear system analysis, Walsh function expansion, Weiner functional expansion. I. INTRODUCTION tIENER'S analysis of nonlinear systems [1] depends upon representing the output y(t) of an unknown system as a sum of complete orthogonal functionals Gn [Kn, y(t) =E G n [K n ,x(t)](1 n=0 in which 1Kn4 is a set of kernels characterizing the nonlinear system and x(t) is the input. The functionals Gn [Kn, x(t)] are orthogonal in the sense that if the input to the unknown system x(t) is Gaussian white noise then: (Gn [Kn, x(t)] Gm [Km, x(t) =O, n A m (2) where 0) signifies an ensemble average. The kernels Kn may be determined by constructing a set of parallel filters whose impulse responses form a complete system of orthogonal functions jFn(t)[ The unknown system together with the set of parallel filters is driven by a Gaussian white noise input x(t) and the corresponding output y(t) of the unknown system is multiplied by the outputs of the parallel filters. This product is then passed through a device which evaluates ensemble averages and the output of this averaging device, if there are n parallel filters, is a coefficient C in the expansion of the nth order kernel Kn(ul, u2, -, u,) as a sum of n-fold products of functions F1(u1): 00 00 co K~UlI 21.. n)= -- C ~ F P U =0 p2=0 pn=0 Pn Pi (" Pn(Un). (3) Manuscript received December 27, 1972; revised May 23, 1973. A. S. French is with the Department of Physiology, University of Alberta, Edmonton, Alta., Canada. E. G. Butz is- with the Department of Mathematics, University of Alberta, Edmonton, Alta., Canada. Wiener proposed that the Laguerre functions Ln(t) were an appropriate set of orthogonal functions with which to analyze an unknown system since filters with such an impulse response are physically realizable using a relatively simple electronic circuit. An excellent review of Wiener's theory has been presented by Harris and Lapidus [2]. Unfortunately, the enormous computational difficulties associated with this scheme has discouraged the application of Wiener's theory to experimental situations. A modification of Wiener's measuring scheme has been proposed by Lee and Schetzen [3], in which cross-correlation functions replace the Laguerre functions of the original method, considerably reducing the required computation. The rediscovery of the fast Fourier transform by Cooley and Tukey [4] has made transformations between the time and frequency domains so efficient that the fastest route to a correlation measurement is usually via complex multiplication in the frequency domain. We have described a new and more efficient means of measuring the Wiener kernels of a nonlinear system which employs the fast Fourier transform [5]. This new method may be viewed as equivalent to the cross-correlation technique of Lee and Schetzen with the correlation performed in the frequency domain. Alternatively the scheme may be viewed as similar to the original Wiener method with the complex exponential functions as the set of orthogonal functions which are used to expand the kernels. We have also investigated the use of Walsh functions [6] as a set of orthogonal functions with which to expand the Wiener kernels. In the Wiener measurement scheme the outputs of the orthogonal filters are multiplied together before carrying out an ensemble average, and since Walsh functions form a closed set under multiplication, there are obvious computational advantages in their use. It must be emphasized that the Wiener functional expansion does not produce a unique description of a nonlinear system because the kernels are defined in terms of a particular set of orthogonal functions. The cross-correlation kernels of [3] and [5] may provide a more useful description of many systems because of their close relationship to traditional linear systems analysis. The first two kernels Ko and K1 of the cross-correlation scheme provide an identical description of a linear system to that of the convolution integral or the Laplace transformn. However, there are great difficulties associated with measuring the cross-correlation kernels by the use of Walsh functions. These difficulties arise from the complex cross-correlation behavior of Walsh functions [7]. The analysis scheme presented here produces a description 225

Upload: vuongminh

Post on 13-Feb-2017

217 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: se o Wals Functidt HiWthWfn W3902

TECHNICAL LIB9ARYIEEE TRANSACTIONS ON COMPUTERS, VOL. C-23, NO. 3, MARCH 1974 SINGER COMPANY

SIMULATION PRODUCTS DIVISION

se o Wals Functidt HiWthWfn W3902Analysis of Nonlinear SystemsANDREW S. FRENCH, MEMBER, IEEE, AND EDWARD G. BUTZ

Abstract-A powerful means of analyzing nonlinear systems isprovided by the Wiener functional expansion. However, this techniquehas not been implemented widely in experimental situations because ofthe difficulties associated with measuring the kernels of the system,which constitutes the analysis problem. A new method of measuringthe kernels is described here in which the Walsh functions are used as

the set of orthogonal functions with which the kernels are expanded.The multiplicative properties of the Walsh functions and the fastWalsh-Fourier transform make the measurement scheme very efficient.

Index Terms-Dyadic kernels, nonlinear system analysis, Walshfunction expansion, Weiner functional expansion.

I. INTRODUCTION

tIENER'S analysis of nonlinear systems [1] dependsupon representing the output y(t) of an unknown

system as a sum of complete orthogonal functionals Gn [Kn,

y(t) =E Gn [Kn,x(t)](1n=0

in which 1Kn4 is a set of kernels characterizing the nonlinearsystem and x(t) is the input. The functionals Gn [Kn, x(t)] are

orthogonal in the sense that if the input to the unknownsystem x(t) is Gaussian white noise then:

(Gn [Kn, x(t)]Gm [Km, x(t) =O, n A m (2)

where 0) signifies an ensemble average.

The kernels Kn may be determined by constructing a set ofparallel filters whose impulse responses form a completesystem of orthogonal functions jFn(t)[ The unknown systemtogether with the set of parallel filters is driven by a Gaussianwhite noise input x(t) and the corresponding output y(t) ofthe unknown system is multiplied by the outputs of theparallel filters. This product is then passed through a devicewhich evaluates ensemble averages and the output of thisaveraging device, if there are n parallel filters, is a coefficientC in the expansion of the nth order kernel Kn(ul,u2, -, u,) as a sum of n-fold products of functions F1(u1):

00 00 co

K~UlI 21.. n)= -- C ~ F

PU

=0p2=0 pn=0 Pn Pi

(" Pn(Un). (3)

Manuscript received December 27, 1972; revised May 23, 1973.A. S. French is with the Department of Physiology, University of

Alberta, Edmonton, Alta., Canada.E. G. Butz is- with the Department of Mathematics, University of

Alberta, Edmonton, Alta., Canada.

Wiener proposed that the Laguerre functions Ln(t) were an

appropriate set of orthogonal functions with which to analyzean unknown system since filters with such an impulse response

are physically realizable using a relatively simple electroniccircuit. An excellent review of Wiener's theory has beenpresented by Harris and Lapidus [2].

Unfortunately, the enormous computational difficultiesassociated with this scheme has discouraged the application ofWiener's theory to experimental situations. A modification ofWiener's measuring scheme has been proposed by Lee andSchetzen [3], in which cross-correlation functions replace theLaguerre functions of the original method, considerablyreducing the required computation.

The rediscovery of the fast Fourier transform by Cooleyand Tukey [4] has made transformations between the timeand frequency domains so efficient that the fastest route to a

correlation measurement is usually via complex multiplicationin the frequency domain. We have described a new and more

efficient means of measuring the Wiener kernels of a nonlinearsystem which employs the fast Fourier transform [5]. Thisnew method may be viewed as equivalent to thecross-correlation technique of Lee and Schetzen with thecorrelation performed in the frequency domain. Alternativelythe scheme may be viewed as similar to the original Wienermethod with the complex exponential functions as the set oforthogonal functions which are used to expand the kernels.We have also investigated the use of Walsh functions [6] as

a set of orthogonal functions with which to expand the Wienerkernels. In the Wiener measurement scheme the outputs of theorthogonal filters are multiplied together before carrying outan ensemble average, and since Walsh functions form a closedset under multiplication, there are obvious computationaladvantages in their use. It must be emphasized that the Wienerfunctional expansion does not produce a unique description ofa nonlinear system because the kernels are defined in terms ofa particular set of orthogonal functions. The cross-correlationkernels of [3] and [5] may provide a more useful descriptionof many systems because of their close relationship totraditional linear systems analysis. The first two kernels Koand K1 of the cross-correlation scheme provide an identicaldescription of a linear system to that of the convolutionintegral or the Laplace transformn. However, there are greatdifficulties associated with measuring the cross-correlationkernels by the use of Walsh functions. These difficulties arise

from the complex cross-correlation behavior of Walshfunctions [7].

The analysis scheme presented here produces a description

225

Page 2: se o Wals Functidt HiWthWfn W3902

IEEE TRANSACTIONS ON COMPUTERS, MARCH 1974

of the nonlinear system in terms of a set of kernels whichcontain the dyadic convolution operation [8]. This scheme isprobably the most efficient means of performing the Wienerfunctional analysis which has yet been discovered. The valueof these dyadic kernels in describing a particular nonlinearsystem will depend upon the nature of the system beingstudied. There has recently been a dramatic increase in theapplication of Walsh transform and dyadic convolutiontheories to a diverse range of situations. These applicationsinclude image processing, acoustic signal analysis, radio andtelephone signal multiplexing, seismic investigation and speechsynthesis [9]. Many of these systems demonstrate nonlinearbehavior and an efficient, general, nonlinear analysis schemesuich as that described here appears to have wide potentialapplication.

II. WALSH FUNCTIONS

It is convenient in defining the Walsh functions [10], toconsider first the Rademacher functions [ 1]. TheRademacher functions .o j(t) form an incomplete system oforthogonal functions and are defined by:

+ 1(t) OSt<

00(t) =-11 < t<

0(t + 1) = 00(t)f¢) (t) = (to (2nt) n = 1, 2, ...n~~n

The Walsh functions, {I ,4 are then given by:

Q0(0 = 1

Ajn1(t)=2n (t)Onr(t) *n (t)

discrete number of data points may be decreased by the use ofa fast Walsh-Fourier transform algorithm which is closelyanalogous to the fast Fourier transform [7]. The fastWalsh-Fourier transform is significantly more efficient tocompute than the fast Fourier transform because eachoperation involves only addition or subtraction compared tothe complex multiplications necessary for the fast Fouriertransform. The fast Walsh-Fourier transform may also begeneralized to more than one dimension in a similar manner tothe fast Fourier transform.

Since the Walsh functions are defined as products ofRademacher functions, it follows that they form a closedsystem under multiplication, a very attractive property for ourpurposes. To determine the product of two Walsh functions itis necessary to consider the operator @, addition modulo 2,defined as follows [7]. Let p and q be written as binarynumbers, they are then added according to the rule:

OQ) 1 = 1 @O= 1

0@0= 0

1 e 1 = 0 (no carry) (8)

e.g., 5 e 6 = 3. In particular for any real number r, r @ r = 0.Then the multiplication rule for Walsh functions is expressedas:

Jn (t) m (t) = Pnem(t).(4) (9)

Further important properties are [ 10]:

(5)

for n 2n' + 2n2 + + 2nr, where the integers n, are

uniquely determined by the condition n+l <n.Harmuth [7] uses a different numbering system for the

WalIsh functions which depends upon the number of signchanges in a fixed-time interval or "sequency." This schemealso involves a separation into alternately odd and evenfunctions. A method of deriving the Walsh functions from theRademacher functions and at the same time retainingHarmuth's nomenclature has been discussed by Henderson[12] and Lackey and Meltzer [13].

Walsh showed that lln(t)4 form a complete orthonormalset. Every periodic function f t) which is integrable in thesense of Lebesgue on (0, 1) will have associated with it aWalsh-Fourier series [7]:

f(t) ao + aI41(t) +a2 2(t) + (6)

where the coefficients an are given by:

(7)

4n(t D S) = n(t)On(s)

| W(ft QD s) dt = an P (s)

where an is the Walsh-Fourier coefficient of f(t).Equations (10) and (11) imply:

T iP(t)f(t e s)dt = |f (t s)ft(t) dtn 0

which is a property analogous to the convolution integral:

r ff009WAgtf- dt = g(s -t)f(t)dt.

(10)

(1 1)

(12)

(13)

This analogy, as well as a corresponding analogy to theWiener-Khinchine theorem [7], [141, form the basis of our

proposal, that for the purposes of digital computation, an

appropriate set of parallel filters in the Wiener theory areWalsh filters, where we define a Walsh filter as a device whoseoutput y(t), for input f t), is given by:

(14)

orThe time required to compute the Walsh-Fourier series of a

226

1

y(t) = .n (u)f(t ED u) du1

an = .n (t)f(t) dt4

(n = 0, 1, 2, ---).

y(t) = an .Pn(t)- (15)

Page 3: se o Wals Functidt HiWthWfn W3902

FRENCH AND BUTZ: USE OF WALSH FUNCTIONS

(16)

In the case where the input to the filter f(t) = x(t) is whiteGaussian noise with zero mean and variance A, the coefficientsan of the filter output have Gaussian distributions withensemble parameters given by:

(ana)= m(a a )=An m nm

where 6nm is the Kronecker delta function.Further, since (x(t1) x(t2) . x(tn)) = 0 if n is odd and

(x(t1)x(t2) X(t )) = E Jl (X(t1)x(t.)) ij

ii I(17)

where the sum is over all combinations of pairwise products[1], [15] it follows from (7) that:

(a a -aP )0=P1 P2 Pif n is odd

expansion. That is, let:

00

H1(U)= E ek Qk(U)k=0

00 c0

H2(u, v) = E Z d4iiu)ij(v)hO0jO0

(21)and if the unknown system is probed with Gaussian white

if n is even noise input x(t) where:

00

x(t) = E ak4/k(t)k=0

(22)

then the output y(t) may be expressed, by substituting (20),(21) and (22) into (19), as:

(a a * a,) = XHa ai56PI P2 .ni P Pi 1)

if n is even. (18)

Ill. DETERMINING KERNELS BY THE USEOF WALSH FILTERS

Following Wiener [1 ] we assume that the output y(t) forany input x(t) to an unknown nonlinear system may beexpressed as:

00

y(t) = E Gn [HnGHx(t)]n=O

(19)

where {Gnt are a system of orthogonal functionals, similar toWiener's except that instead of being expressed as convolutionintegrals, we use the operator ED. For n = 0, 1, 2, 3 we havethat:

GJH ,x(t)] = H

G1 [H1, x(t)] = HI (u)x(t E u) du

0 00 00

y(t) = Ho + X akck4k(t) + X E aa1d#i(t)tk(t)k=o i=o j=o

00

-A X d.. +±-j=o

(23)

The important feature in (23) is that it allows exploitation ofthe multiplicative property, (9), of the Walsh functions, sothat the output y(t) of the unknown system may be expressedas:

(24)00

y(t) =Y. bgkk(t)k=o

where, by equating coefficients of 4k(t), k * 0,

b =a c + , a.a.d.. +-k k k Ii 1i j

and the asterisk in the summation denotes that the double sumis over only those values of i and j such that:

i@3j = k. (26)

(25)

G2 [H2, x(t)] = LH2(u, v)x(t ED u)x(t e v) dudv

L 1-A H.(u,u)du.

G3 [H3,X(t)] = JjH3(u, v, w)x(t ED u)x(t e v)x(t ® w)

dudvdw -3A 1 J H3(u, v, v)x(t a) u) dudv. (20)

The kernels JHn4 are determined by expanding each in aWalsh-Fourier series and then measuring the coefficients of the

Since we have assumed that k # 0, from the definition of theoperator ® this implies in particular, i * j. For k = 0, we have:

00 00

b0 =H0 +a0c0 + X a3d..-A X d. +"1=o i=o

(27)

A. Determining HoConsider Fig. 1, which states that Ho is obtained from the

equation:(bo) =H. (28)

This follows from (27) where

00 00

(b0)=H0 +(a0)c0 + S (a2)d-. -A E d,+-.± (29)oiO I o

227

Page 4: se o Wals Functidt HiWthWfn W3902

IEEE TRANSACTIONS ON COMPUTERS, MARCH 1974

H

Gaussianwhite noise

Fig. 1. Scheme for evaluating the zero-order kernel of an unknown system.

x(t)

Gaussianwhite noise

unknownsys tem

Fig. 2. Scheme for evaluating the first-order kernel of an unknown system.

2A2dnm + A<b O' nm

n

m

Fig. 3. Scheme for evaluating the second-order kernel of an unknown system.

From (16), (ac)= 0, so that the second term on the right-handside (RHS) of (29) vanishes. The third and fourth terms in(29) cancel each other since, from (16), Qai2) = A. Theremaining terms in (29) cancel in a similar manner.

B. Determining Hl(u)Consider Fig. 2, which states that the Walsh-Fourier

coefficients of H1 (u) are obtained from the equation:

(a b )n n

C =-n A (30)

fy(t)z(t) dt = anbn.

And from (25), n * 0:

(a bn=(a a )c (a a.aU)d. +-

so that applying the ensemble relationships (18),

(a2)=A

(a.a.a 0=Oz J n

(a a.a a )=i I p n

(33)

(34)

To prove (30), consider the output z(t) of the Walsh filter, 413J.From (15):

z(t) = an n(t)' (31) leads to

therefore,

J1 oo 1

y(t)z(t)dt = EZ bkafn k(t) ln(t) dt. (32)k=0 0

Since llk(t)} are orthogonal over (0, 1), then:

(abn)b=Acn

which proves (30). Note that agipad vanishes because itappears in a summation of the type ZiIjIp which is over allvalues of i, i and p such that i e i e3 p = n. Since we are

assuming that n 0, this implies that either i (Di : p, or i D p= j, or j ( p i. This constraint assures that at least one ofthe Kronecker deltas in each of the products in (18) is zero.

x(t)

228

0- Acn

Page 5: se o Wals Functidt HiWthWfn W3902

FRENCH AND BUTZ: USE OF WALSH FUNCTIONS

x(t) w(t) z (t) y(t)

f(t) -g(t)

Fig. 4. The general second-order system has input x (t) Walsh-filtered with the function f(t), squared and then Walsh-filteredwith the function g(t).

C Determining H2 (u, v)

Consider Fig. 3, which states that the Walsh-Fouriercoefficients ofH2 (u, v) are given by:

(aab ) a (b) 1nm nOM 0d _ _ __I- J * (35)nm 2 A2 A nmJ

To prove this result, consider the output z(t) of the twoparallel Walsh filters iP,, and im. By definition:

z(t) = anamnPn(t)41m(). (36)

Applying the multiplicative rule to (36) and using theorthogonality of the Walsh functions:

1

y(t)z(t)dt = namb DI

For n # m, substituting (25) in (37) yields:

(anam bn @Dm)= (anamanem)cn em

+ E (a ama.a)d. + *-- (38)

where the double sum in (38) is over all i and i for which i @j= n s m. Applying (17) to the ensemble averages of thecoefficients Iakl in (38) leads to:

(anmb Y Z F (anam)6m (a.a.)6..+((a a.jI .(a a.t6,1n z nL m i mJ

+(anaj)8ni(amad56mi dii (39)

Since n # m, 4nm = 0 and the- remaining Kronecker deltas,6nij 5mj,. reduce the summation to two terms. Therefore,

(anambn.m) =(an2) (am 2)dnm + (an2)(am 2)dmn . (40)

(37)

(an 2ai2) = (an 2)(ai2) + 2(anai)28niSubstituting (43) into (42) results in:

(a 2b )=(a,7)Ho +(an2) E (aZYd.10

+2(an2)2d( -A(a2) E dii.1=0

Since Ho =(bo), and (a)=A, (44) reduces to:

(an2b0) = (an)2bo) + 2(an2)2dnnor

(a 2b0)

A2

(bo)A

(43)

(44)

(45)

(46)

which verifies (35) for all n, m.

IV. EXAMPLES OF SYSTEM ANALYSIS

The most general second-order system to which Wiener'stheory applies is that of a linear filter, followed by a squaringdevice, followed by another linear filter. In the present theory,the most general second-order system is a Walsh-like filter,followed by a squarer, followed by another Walsh-like filter.That is, for the system in Fig. 4 we have that the output y(t) is

y(t)= g(s)z(t EDs) dsl (47)

where

z(s) = w2(s)

and

(48)1

w(s) = f(u)x(s ED u) du

so that y(t) may be represented as

However, the kernel may be chosen symmetric [1] so thatdnm = dmn, and since (a,n2) = (am2> =A, it follows that:

(anambnom)2d = n

nm A2n#m. (41)

For the case m = n, we consider (a2b0). From (27):00

(an2b0 = (an)H±+ E (an2ai2)d1H-A(an7) Z d11. (42)i=O i=0

Also, from (17):

y1 1 1

y(t)= g(s)ffs s U)ffs (D V)X(t s U)X(t s V)-Uv U -Uv - dsdudv. (49)

A second-order kernel may be extracted from (49) if we set:

H1

~~~~H(u, v) = -g(s)f(s ID U)fS ED v) ds.2(50)

Since Ho = (bo) and since (bo) = (y(t)) it may be shown that:

Ho =A f H2(u,u)du. (51)

229

Page 6: se o Wals Functidt HiWthWfn W3902

IEEE TRANSACTIONS ON COMPUTERS, MARCH 1974

(a)

x(t) ww(t) y(t)f(t) w2

(b)Fig. 5. Two special cases of the second-order system. (a) Signal is

squared and then passed through a Walsh filter. (b) Signal isWalsh-filtered and then squared.

Fig. 6. Perspective view of the second-order kernel computed from a

computer simulition of the system shown in Fig. 5(a). Functionte-5t was used for the filter g(t).

Therefore y(t) may be represented as a sum of orthogonalfunctionals:

ry(t)= Ho + LH2(u v)x(t@u)x(t V) dudv

-A H2(u,u)du. (52)

There are two special cases of interest, 1) fit) = 5(t) and 2)g(t) = 5(t) for which we present computer calculations of thesecond-order kernel. In the case fit) = 5(t), the system in Fig.4 reduces to that of Fig. 5(a) and the kernel of (52) reduces to

H2(u, v) = g(u)5(u - v)

where 6(u - v) is the Dirac delta function. Thus thesecond-order kernel is zero everywhere except along thediagonal u = v, where it has the same form as the filterfunction g(u). This situation was simulated on a digitalcomputer using the filter function g(u) = ue-5U and a

pseudo-random Gaussian white-noise algorithm.Fig. 6 illustrates a two-dimensional perspective of the

computed kernel which has the expected form. For the case

g(t) = 5(t), the system of Fig. 4 reduces to that of Fig. 5(b),and the kernel of (52) reduces to:

H2(u, v) = fu)fv).

5

230

Page 7: se o Wals Functidt HiWthWfn W3902

FRENCH AND BUTZ: USE OF WALSH FUNCTIONS

Fig. 7. Perspective view of the second-order kernel computed from acomputer simulation of the system shown in Fig. 5(b). Functionte- St was used for the filter f(t).

This situation was also similated on a digital computer usingthe filter function 1(u) = ue- u. Fig. 7 illustrates atwo-dimensional perspective of the computed kernel.

V. CONCLUSION

The Wiener functional analysis of nonlinear systems may beimplemented using the Walsh functions as a set of orthogonalfunctions with which to expand the kernels. Two properties ofthe Walsh functions which make them suitable for this purposeare their closed nature under multiplication and the efficiencyof the fast Walsh-Fourier transformation. The kernels whichare obtained from this measuring scheme do not have anysimple relationship to the linear cross-correlation kernels ofearlier schemes. However, the increasing interest in systemsemploying dyadic convolution operations suggests that suchanalysis may be of value in the future. The number ofoperations required in the measurements and the efficiency ofthe fast Walsh transform indicate that this scheme representsthe fastest means of obtaining a Wiener functional expansionyet devised.

REFERENCES[1] N. Wiener, Nonlinear Problems in Random Theory. New York:

Wiley, 1958.

2] G. H. Harris and L. Lapidus, "The identification of non-linearsystems," Ind. Eng. Chem., vol. 59, pp. 66-81, 1967.

[3] Y. W. Lee and M. Schetzen, "Measurement of the Wiener kernelsof a non-linear system by cross-correlation," Int. J. Contr., vol. 2,pp. 237-254, 1965.

[4] J. W. Cooley and J. W. Tukey, "An algorithm for the machinecalculation of complex Fourier series," Math. Comput., vol. 19,pp. 297-301, 1965.

[5] A. S. French and E. G. Butz, "Measuring the Wiener kernels of anon-linear system using the fast Fourier transform algorithm,"Int. J. Contr., vol. 17, pp. 529-539, 1973.

[6] J. L. Walsh, "A closed set of normal orthogonal functions,"Amer. J. Math., vol. 55, pp. 5-24, 1923.

[7] H. F. Harmuth, Transmission of Information by OrthogonalFunctions. Heidelberg, Germany: Springer-Verlag, 1970.

[8] T. H. Frank, "Implementation of dyadic correlation, applicationsof Walsh functions," IEEE Trans. Electromagn. Compat., vol.EMC-13, pp. 111-117, 1971.

[9] "Applications of Walsh functions," 1972 Proc. Naval Res. Lab.,AD-744 650, 1972.

[10] N. J. Fine, "On the Walsh functions," Trans. Amer. Math. Soc.,vol. 65, pp. 372-414, 1949.

[11] R.E.A.C. Paley, "A remarkable series of orthogonal functions,"Proc. London Math. Soc., vol. 34, pp. 241-279, 1932.

[12] K. W. Henderson, "Some notes on the Walsh functions," IEEETrans. Electron. Comput. (Corresp.), vol. EC-13, pp. 50-52,1964.

[13] R. B. Lackey and D. Meltzer, "A simplified definition of Walshfunctions," IEEE Trans. Comput,, vol. C-20, pp. 211-213, 1971.

[14] J. E. Gibbs and H. A. Gebbie, "Application of Walsh functions totransform spectroscopy," Nature, vol. 224, pp. 101 2-101 3, 1969.

[15] R. Deutsch, Nonlinear TRansformations of RandomProcesses. Englewood Cliffs, N.J.: Prentice-Hall, 1962.

231

Page 8: se o Wals Functidt HiWthWfn W3902

IEEE TRANSACTIONS ON COMPUTERS, VOL. C-23, NO. 3, MARCH 1974

Andrew S. French (M'72) was born in Devon,England, in 1943. He received the Associate-ship of the Royal Institute of Chemistry in1965 from the University of Salford, Lancashire,

0 England, and the M.Sc. and Ph.D. degrees fromthe University of Essex, Essex, England, in1966 and 1968, respectively.

In 1968 he joined the Department ofPhysiology at the University of Alberta,

A:8a0- Edmonton, Alta., Canada, and was appointed asan Assistant Professor in 1970.

Dr. French is a member of the Canadian Physiological Society andthe Royal Institute of Chemistry.

Edward G. Butz was born in Toronto, Ont.,0 Canada, on May 29, 1942. He received the B.

Sc. degree in pure and applied mathematicsfrom the University of Toronto, Toronto, andthe M. A. degree in applied mathematics fromthe University of Waterloo, Waterloo, Ont., in1964 and 1965, respectively, and also the Ph.D. degree in theoretical biology from theUniversity of Chicago, Chicago, Ill.

From 1971 to 1973 he was a PostdoctoralFelow in mathematics at the University of

Alberta, Edmonton, Alta., Canada. He is currently a Visiting AssistantProfessor in the Mathematics Department at the University of Alberta.

Design of Weighted Counters with RationalScale Using Continued Fraction Expansion

ERIC J. VAN LANTSCHOOT, SENIOR MEMBER, IEEE, AND JOOS P. VANDEWALLE, STUDENT MEMBER, IEEE

Abstract-Modulo qi scalers or counters are one-input Mooremachines whose state set contains a unique subset (called cycle) ofstates which occur in cyclic succession.

We consider first a set of n modulo qi scalers which areinterconnected through inhibition gates and show that the overall scaleis a continued fraction with the qi as partial quotients.

We then introduce a counter which counts modulo qi or modulo qi+ 1 depending upon the state of a control variable. We show how anyrational scale can be implemented by interconnection of counters ofthis type, with the' additional feature that the pulse counts on all signallines can be found by properly weighting the states of each counter.

Some applications are discussed.

Index Terms-Continued fractions, counters, cycles, digital functiongenerators, piecewise linear approximation, scalers, smooth pulsesequences, weighted codes.

I. INTRODUCTION

Tr HE application of the theory of continued fractions toTthe design of a digital circuit which produces a smoothoutput pulse sequence at a rate ml which is a fraction A/B(A and B positive integers, A <B) of the input pulse rate mohas been considered [1] - [6] .

In this paper we extend the application of continued

Manuscript received March 7, 1973; revised July 30, 1973. Theoriginal version of this paper was presented orally at the InternationalCoUloquim Conception et Maintenance des Automatismes Logiques,Toulouse, France, September 27-28, 1972.

E.J. Van Lantschoot was with the Department of ElectricalEngineering, University of Notre Dame, Notre Dame, Ind. 46556. He isnow at Celestijnenlaan 63/65, Heverlee, Belgium.

J.P. Vandewalle is with the Department of Electrical Engineering,Catholic University of Louvain, Louvain, Belgium.

fractions to the design of a digital circuit which, in addition tothe properties already mentioned, gives at any moment andunder the form of a weighted code the number xo (t) of inputpulses which have been supplied to the circuit, and the numberxl (t) of output pulses which the circuit has produced. For thesake of brevity we will refer to this circuit as "weightedrational scale counter" (WRSC).

WRSC's seem to offer some promise as the basic unit in adigital function generator, because they offer a straightforwardsolution to the problem of approximating a straight line.Indeed, if we plot xl (t) against xo(t) we obtain a staircasecurve, which approximates y = (A/B)x. WRSC's have alreadybeen used for computer-generated displays of phasor diagrams[7] and could be used for the generation of half-tone pictures[8].

II. DESIGN OF A SCALER WITH RATIONAL SCALE

Definition 2.1: The Cartesian grid is the set of straight lines

x = k(k: integer)y = r (r: integer). (2.1)

Grid points are the points (k, r) with integer coordinates.'Definition 2.2: A straight line on a Cartesian grid is any

straight line connecting two grid points.For the sake of simplicity we will consider only the

approximation of straight lines connecting (0,0) and (B, A)where both A and B are positive, and A < B. AU othersituations can be dealt with by appropriate scaling and/orshifting.

232