it follows that m
 x i=o
so that indeed an expansion of x is obtained.
Suppose x has two expansions
with 0 5 d , < d < k . From (3.1) we then deduce ( d t ) p = (d,t,)p. Applying (3.1) again we obtain d
+ tp
=
d,
+ t1p
This is possible only if d , = d  1, t p = 0, t l p = 1. Thus t = OfnJ, t , = ( k  l)", and the two expansions of x are exactly those given in (3.3). Setting ZL = (sd)?),n = I sd I we then have x = u/k" as required I A n element s E kLV is ultimately periodic the real number x = sp is rational.
THEOREM 3.2.
if
if
and only
THEOREM 3.3. If an element s E k" is periodic, then sp = p / q with p and q integers such that q is relatively prime to k . Conversely each rational number x = p l q with 0 5 p 5 q and q and k relatively prime admits a
periodic expansion.
XIII. Infinite Words
366 Proofs.
Let
I u I = a,
x = (uv")p,
Iv 1
=
b
Applying (3.1) we obtain
x=
1 kZb
1
' (uv+vv+vv+ kb
ka
. . . + k i1b v v + k i b v ~ p
Thus letting i tend to infinity
Consequently x is rational. If x and obtain
= vmp, then
x=
we may set u = A , a
=
0,
vv kb  1
Since k and kb  1 are relatively prime, x has the required form. Next we prove the second part of Theorem 3.3. Let
First consider the case p = q, i.e., x = 1. Then 1 = .(k  1)" is a periodic expansion of x. Note that the other expansion of x namely . low is ultimately periodic but not periodic. We may now assume p < q, i.e., x < 1. Since [ x ] = 0, Theorem 3.1 asserts that x has an expansion
x=
.s0.91. . .s,. . .
with si
=
[ k i f l x ]  k[kiCx]
for all i E N . Since (4, K) = 1, it follows from a general theorem in number theory that k a  1 modq for some integer a
2 1. T h u s k"
= bq
+1
3. Expansion of Real Numbers
367
for some b E N . Therefore
and thus x = vWwith v = so.. . s , _ ~ . Next assume that x = p / q < 1 is a rational number. Multiplying p and q by a suitable integer we may assume that
x=
1 ka
(r + 
: ' I )
and since x < 1 we have r < ka. There is then u E k" such that I u and U Y = r. By what we proved earlier we have
for some v
E
I =a
k". Thus by (3.1) 1 ka
x =  [UY
+
(V")/A]
= (uv")p
EXERCISE 3.1. For any elements s, t conditions are equivalent :
(i) s p = P for some integers p , q (ii) s, t E u x for some u E Z".
E
E
I
Z*, show that the following
N , p > 0 , q > 0.
Let s = uvm. If I v I = p is smallest possible, and ;f further, assuming I v I = p , I u I is smallest possible, then we say that uv" is the minimal representation of s. Show that ;f uv" is the minimal representation of s and ;f s = u'vfm,then I u I 5 I u' 1. I f , further, I u I = I u' I, then v' E v x . [Hint: Use Exercise 3.1.1 EXERCISE 3.2.
XIII. Infinite Words
368 EXERCISE 3.3.
Given any unambiguous subset A of N and given any
k > 1 consider the element
Show that s.,~is ultimately periodic zf A is ultimately periodic. Deduce that I . .A is a rational set. Show that ;f f 2 i is the generating function of A, then 1
sA4pU,, is a rational number
sAPU, = k f A ( i )
4. Infinite Digital Computation
The function
PROPOSITION 4.1.
p k : kLV+ [0, 11
is continuous and surjective. Proof.
Theorem 3.1 implies that pk is surjective. If s, t (s, t ) e <
i.e., if the first n digits of s and t agree, then s = us',
with I u
I = n.
t
=
ut'
Then by (3.1)
I Spk

T h u s pk is continuous
tpa
1
1
I = __ I S I P k  t'Pk I 5 kn kTi ~
I
Consider a continuous function f: k'v + 1"
with k, 1 2 2. We shall say that f is consistent if ~ 1 ~2,
E
kN,
s1pk
implies SIfP1 =
SdP1
=
s2pk
E
k"' and
4. Infinite Digital Computation
369
This is equivalent to the existence of a function
f‘: [0,11

[O, 11
such that the diagram
k“ f fiv
commutes. We show that f r is continuous. Indeed, since f and p1are continuous, it follows that pi f r is continuous. Since pA. is surjective and continuous and both kLV and [0, 11 are compact metric spaces, the continuity of f is implied by a standard theorem in general topology. I n the case when f is a prolongation f = g A v of a function g satisfying (1.1) and (1.2) a more effective argument for the continuity o f f may be given. Consider the closed interval ; I
I,, with 0
=
[+
’
&]
5 n, 1 5 i 5 kT1.T h e left end point has an expansion s1 =
tOltJ,
t
E
k”p’
while the right end point has an expansion s,
=
t(k

l)cu
with the same t. Further all the points in I,,,have an expansion starting with t. Consequently all the real numbers in the set I,,,f‘ will have an expansion starting out with the word tg. Since I tg I 2 n  1 it follows that diam(I,,,f r ) 5 1 / P
If we now consider two points x,, x2 E [0, 11 such that
I x1  xa I 5 Ilk” then either x1 and x2 are both in some interval I,,,or in the union I,, u I ) 8 ( L +ofl , two consecutive such intervals. Consequently
I Xlf7  X 2 f ‘ I 5 2/11? This shows the uniform continuity of f’ with explicit bounds.
XIII. Infinite Words
370
A sequential machine d ' :k
f
1 is said to be consistent if the function
j"8: kN + 1.'
is consistent. T h e continuous function
f a ' : [O, 11

[O, 11
thus obtained is called the real result of d&. Functions f: [0, 11 + [0, 11 which are obtainable in this fashion are called sequential for the bases
(k,1:. T h e identity function f: [0, 11 + [0, 11 and the function x + 1  x are sequential for the bases (k,k). I n fact, f may be obtained using a very fine morphism p: k" + k". I n the first case ip = i while in the second one ip = k  1  i. EXAMPLE 4.1.

Let k = k,k, with k,, k, 2 2. T h e function (i,j ) + ik, j yields a bijection k, x k, k. Using the inverse of this bijection every s E k" may be written in the form EXAMPLE 4.2.
+
with u , ~E k, , t,,E k,. There result functions nj: kLV+ kiN,
i = 1, 2
defined by 000,.
. .0,,. . .
= tot,.
. . t J J. ..
sn, =
snz
These functions are easily seen to be sequential (and therefore also continuous). However, easy examples show that they are not consistent. PROPOSITION 4.2. I f f : [0, 11 + [0, 11 is sequential f o r the basis (k,I ) , then f maps rational numbers into rational numbers. Proof.
This follows from Theorems 2.2 and 3.2
1
Consider the function f: k"+ k" given by sf = 0s. Show that this function is consistent and yields the function [0, 11 + [0,1] given by x xlk. Show that f is sequential. EXERCISE 4.1. f
5. The Peano Curve
3 71
EXERCISE 4.2. Consider the truncationfunction r : kr + k”dejined hy (is)r = s for i E k, s E k”. Show that T is consistent and yields the function x k x  [ k x ] where [ k x ] is the integral part of kx. Show that this function is not sequential. f
EXERCISE 4.3. Show that an almost positive cgsmachine A:k* + such that the triangle
k ’
“,f
P,
1“
commutes, exists zff k and 1 are multiplicatively dependent (see V , 3 ) . 5. The Peano Curve
I n 1890 Giuseppe Peano published an example of a continuous function
h : [0, 11

[0, I]x [0, 11
which is surjective. This is the “squarefilling curve” of Peano. T w o functions f , g : [O, 11 [O, 13

were defined and
xh
=
(4xg)
T h e functions f and g were described by Peano in a digital manner using base 3. Actually base 9 is used for the expansions of the argument x, however, thanks to the bijection
3x3

9
given by
( i , j )= 3i +  j base 3 notation is used. We shall show that the functions f and g defined by Peano are sequential. We start by considering the csmachine
3x33
XIII. Infinite Words
3 72
with
dJ = (2, 0, A ) Thus there are two states 0 and 1 with 0 as initial state. However, it will be convenient to regard any integer as representing the state congruent to it mod 2. We convert 2 into a right 3x3module by setting
T h e output function
A: 2 ~ 3 x 3  3 is given by
where for n even for n odd
a
a.n={ 2a T h e result f":
(3X3)LV

3'V
transforms
into S f N = COCl.
. .c,, . . .
given by
We show that f" is consistent. For this we must show that if s, s' E (3x 3).y represent the same real number, then so do sfVand s'f". Assume then that
( a p ,b p ) = (0, 0) ( 6 7 ,
for all
p >n
b,) f (0, 0)
(a,', bp') = (2, 2) ( a p ' ,b p ' ) = (a,, h p )
p >n for all p < n for all
5. The Peano Curve
373
T w o cases now must be considered. If b, f 0, then
Setting k
=
+ . . . + b,
b,
we have
for all m 2 n. T h u s c,,, = c,,,' for all ?n 2 n. Since also c,,, = c,' m < n it follows that s l f ~=~ sf If b,, = 0, then we must have a,, f 0 and thus
for
lv.
With k defined as above we then have C,
=
ar, . k ,
cP = 0
'
c ~ , '= (u,, 
k,
cI,' =
1) * k
2 .k
for
p >n
with c p = cp' for p < n. If k is even, then clearly sf$' is the terminating expansion while s'fv is the nonterminating expansion of the same real number. If k is odd, the formulas above yield c,, = 2 c,, =

a,, ,
2,
c,,' =
3

a,,
cl,' = 0
for
p >n
Since a,, f 0 we have c,, = c,,'  1. T h u s in this case s'fv is the terminating expansion while sfv is the nonterminating expansion of the same number. T h u s f" is consistent and defines a continuous function
f =f':
[O, 13 + "1, 11
T o obtain the second coordinate g of the Peano function h, another csmachine ~ i 3: x 3 * 3 is defined by replacing formulas (5.1) and (5.2) by
(5.1')
(5.2')
4(a, b ) = 4 (4, a, h)A = b
*
+a (4
+ a)
T h e function
g": (3x 3)" + 3."
XIII. Infinite Words
374
transforms s given by (5.3) into
~g" = d,d,. . . d , . . given by
T h e verification that the machine &is consistent is similar to the one above and is left to the reader. There results a continuous function g: [ 0, 13 [O, 11. We claim that the resulting function h : [0, 11 + [0, 112 given by xh = (xf,xg) is surjective. Indeed, formulas (5.4) and (5.4') are equivalent with j
an = c, b , = dn
Since, further, a,
s c,
+
*
(b, (a0
+ . . . + b,l),
+ . . + an)
a, = c,
*
and 6, = d , mod 2, the formulas above yield
This shows that s = a,b,a,b,. . .arrbn.. . is uniquely determined by . . and sg" = d,d,. . .d,. . . . I n fact the function
sfw = cocl.. .c,.
(3x3)"
+(
3x3)N
given by the two functions f N and g" is bijective. The two coordinates f and g of the Peano function have many remarkable properties. We first examine the function f from the point of view of differentiability. Consider any x E [0, l ] and let s given by (5.3) be an expansion of x. Choose any integer n 2 0 and let s' be the sequence obtained from s by modifying the value of a,, by a unit (for instance a,' = a,  1 if a, > 0 and a,' = 1 if a, = 0). If y is the real number represented by s', then
If we now consider sf and s'f, we find they will differ only in the nth digit and the difference there will be *l. Thus
5. The Peano Curve
375
Consequently
Ixf~fI  3"+1 IxYI and therefore the function f is nowhere differentiable. T h e same applies to the function g. T h e two functions f and g are also known to be independent in the sense of probability theory. This means that for any two measurable subsets A and B of [0, 13 we have meas(Afl) meas(Bg')
=
meas(Afl n Bgl)
EXERCISE 5.1. Show that for a given ( y , z ) E [0, 112 the equation xh = ( y , z ) has at most four solutions. Describe those pairs ( y , z )for which there are exactly four, three, or two solutions. EXERCISE 5.2. Let
p 2 1 be an integer. Divide the interval [0, 13 into
9p equal intervals and divide the square [0, 112 into 9p equal squares by dividing the sides into 3p equal intervals. Show that h maps each of the 9p subintervals of [0, 13 onto one of the 9p subsquares of [0, 112. Join the centers of squares corresponding to adjacent intervals. Show that for p = 1 the resulting figure i s as shown in Fig.1, Draw the figures for p = 2 and p = 3.
Figure 1
EXERCISE 5.3. The surjective function h : [O, 13 + [0, 112 will produce surjectivefunctions [0, 11 + [0, l]", n > 2 by various iterations. However, one can also proceed by setting up n csmachines
3" + 3 using a method analogous to the one in the text. Carry out these constructions for n = 3 and for a general n. Replace base 3 by any odd k > 1.
XIII. Infinite Words
376 EXERCISE 5.4. Consider the sequential machine
A: 3 ~ 2 + 2 A= (2,0,
dejined as
A)
+a b . (4 + a )
q(a, b ) = 4 (4, a, b ) l =
where for b
= 0,
1
ban={
tpb
for n even for n odd
+
b, Show that i f 3 x 2 is identz$ed with 6 using the mapping ( a , b ) + 2a the csmachine is consistent and defines a function f: [O, 11 [O, 11. Show that this function is nowhere dzfferentiable. Replace in the above, the pair ( 3 , 2 ) by any pair of integers ( p , q ) provided p is odd. For ( p , 4 ) = ( 3 , 3 ) , the second coordinate of the Peano curve is obtained. Draw piecewise linear approximations to the functions obtained above. f
6. The Hilbert Curve
As a sequel to Peano’s 1890 paper Hilbert published in 1891 a short note in which he proposed a different construction. Hilbert’s construction uses base 2 and is geometric. Actually, the construction is not carried out in detail but is suggested by Figs. 24.
Figure 2
Figure 3
Figure 4
We shall construct explicitly a sequential machine that realizes Hilbert’s construction. T h e verification that the machine does what it should is left as an exercise for the reader.
6. The Hilbert Curve
3 77
Let G be the “four group” with elements
up = P(z,
1, u,p,
$=
1 = P’
Actually G is the product Z , x 2, of two cyclic groups of order 2. T h e set 2 x 2 is converted into a right Gmodule by setting
( a , 0)u = (0, a )
( a , b)p = (1

0, 1  a )
We shall also need the function y: 2X2+2X2
(a,b)y
=
(a, I
0
I)
T h e csmachine &: 2 x 2  2 x 2
is defined by setting &?=
g(a,b) =
1
(G, 1, A) ( a , 0 ) = (0, 0) ( a , 0 ) = (1, 1) otherwise
gu gP
if
if
g
(g, a , 0 ) l
=
( a , 0)y
Breaking up the output into its two coordinates yields two csmachines
2x2
,fli:
Using the bijection 2 x 2 regard L&?i as csmachines


2,
i = 1, 2
4 given by ( a , 0 )
di: 4  + 2,

2a $ 0 , permits us to
i = 1, 2
A detailed argument is needed to prove that these machines are consistent. There result two continuous functions

f , g : [(A 11 which yield a function
h : [0, 11 by setting xh
=
[O, 11
[0, 11’
(xf,xg). This is the Hilbert curve.
XIII. Infinite Words
378 References
J. W. Hellerman, W. L. Duda and S. Winograd, Continuity and realizability of sequence trasformations, IEEE Trans. Electronic Computers EC15 (1966), 560569.
Contains the subject matter of Exercises 1.31.5. G. Peano, Sur une courbe qui remplit toute une aire plane, Math. Ann. 36 (1880), 157160.
A pioneering paper, remarkably written. D. Hilbert, Ueber die stetige Abbildungen einer L i n k auf ein Flachenstuck, Math. Ann.
38 (1891), 459460.
A followup paper to Peano’s. H. Steinhaus, La courbe de Peano et les fonctions independantes, C . R. Acad. Sci. Paris 202 (1936), 19611963; also: Sur le courbe Peanienne de M. Sierpinski, Comment. Math. Helv. 9 (1937), 166169.
Probabilistic properties of the Peano and related functions are discussed. A. R. Butz, Space filling curves and mathematical programming, Information and Control 12 (1968), 315320; also: Convergence with Hilbert’s space filling curve, J . Comp. System Sci. 3 (1969), 128146.
CHAPTER
XIV
Infinite Behavior of Finite Automata
In this chapter we investigate the situation when infinite words are tested by finite automata. Surprisingly there is a distinct difference between deterministic and nondeterministic automata.
1. Main Definitions and Results
Given any subset A of L'* we consider all the elements x of L'A"which have infinitely many initial segments on A. T h e subset of Z N thus obtained is called the closure of A and is denoted by 2. Thus x E A iff x = lim,,,, a, for some sequence a, < < . . . < a, < . . . of elements of A. In other words, x E 3 iff x["l E A for infinitely many indices n E N . We note some formal rules of the closure
(1.1) A u B
=
A u B. 
(1.2)
If A is a prefix, then A B
=
AB and A = 0.
Indeed, if x E E" has infinitely many initial segments in A u B , then infinitely many of them must be in A or in B. If x = limn,m anbn with ar,bn< an+,b,+l and if A is a prefix, then necessarily a , = a,,, and b, < b,, Thus setting a = a, and y = lim b,, we have x = ay and Y E
E.
Closely related to the closure follows. For any sequence x: N
A f
is the subset Atu of 2." defined as A n Z+ define y n = xo. . .x,,,, and
379
XIV. Infinite Behavior of Finite Automata
380
let x = limtL+mytl. Then Au is the set of sequences x this manner. 
E
2." obtained in

(1.3) Aw c A+ = A". 

(1.4) If A is a prefix, then Am= A+ = A". (1.5) If A is a prefix, then
=
AB.,. 
Relation (1.3) is clear. T o prove (1.4) assume x E A+. Then x with y o < y, < . . . < yrL< . . . elements of A+. Let
yn = a,.
. .U k ,
=
lim y n
y,,+,= 6,. . .b,
with a , , . . . , a,, b , , . . . , bl E A + .Since ytt < y,,+,and A is a prefix, it follows that k < 1 and a , = b i for 1 5 i 5 k. Thus y,, +, E yr,A+.This Relation (1.5) is clear. shows that x E AUJ. Let = (Q, I , T ) be a 2automaton (not necessarily deterministic) and let x E Ev. An ropath in d with label x is defined as an element p E QLvsuch that for each n E N
Pn
rn
Pni,
is an edge in d. We define In(p) = { q I q E Q and q = p,, for infinitely many n E N } . T h u s In(p) is the set of all states through which p passes infinitely many times. T h e opath p is called successful if
p , I~
and
In(p) n T f
0
T h e set of all labels of successful copaths is denoted by 11 &' 11. This is a subset of z=Y. We shall regard /I JP' / I as a Asubset ignoring multiplicities. PROPOSITION 1.I. For each 2automaton ,d
If ,d is deterministic, then
11 d Ij = I <d I
(1.7)
Let d =((3, I, T ) and let p E Q L be ~ a successful copath with label x E Ev. Then p, E I and p,, E T for infinitely many
Proof.
in
&*'
1. Main Definitions and Results
381
indices n E N . For each such an index n
is a successful path with label x["]. T h u s x"?] E I d 1 for infinitely many values of n and consequently x E I ,w' I. If , w ' is deterministic and x E I ,W' 1, then XI',]E 1 ,W' I for infinitely many values of n. T h u s settingp, = ix[l]for a l l j E N we obtain a successful opath with label x. T h u s x E 11 II I C O R O L L A R Y 1.2. Let ,W' be a deterministic Cautomaton and let dC be its completion. Then (1 M' (1 = (1 < d//r 1
We shall show in Example 4.1 that for nondeterministic automata the equality 1) cd1) = 1 ,W' 1 docs not generally hold. T H E O R E M 1.3.
For any subset A of S* the following conditions are
equivalent : A is in the class Rec of all closures of recognizable sets. There exists a deterministic Zautomaton ,3=( Q , i, T ) such that A = /j ,w' 1 . (iii) A is a finite union of sets B P with B and C recognizable prefixes in S". (i) (ii)
Proof. (i) o (ii). This is a direct consequence of the equality (1.7) in Proposition 1.1. (i) o (iii). Any recognizable subset A of X" has, by IV,6.1, a representation (1.8)
A
=
B,C," u . . . u B,,C,,"
where B , , . . . , B,,, C , , . . . , C,, are recognizable prefixes. From ( l . l ) , (1.4), and (1.5) we deduce
A = B1ClW+ . . . + Bl,Cl,(U Conversely if
D
=
+ . . . + B,C,,LU
B1Clc"
where B , , . . . , B,,, C , , . , , , C,, are recognizable prefixes, then D with A defined by (1.8)
=
2
XIV. Infinite Behavior of Finite Automata
3 82
There exists another more restricted notion of a successful path than the one introduced above. For this we require an automaton (deterministic or not) &'= ((3, I , T) in which T instead of a single subset of Q is a family of such subsets. An wpath p E EVwith label x E EVis called strictly successful if
P,E I
and
In@) E T
The set of labels of all the strictly successful wpaths is denoted by
I d I. THEOREM 1.4. (BuchiMcNaughton) following conditions are equivalent :
For any subset A of 2" the
E.
A is in the Boolean closure R XB of the family There exists a deterministic Zautomaton &' = ( Q , i, T)with a family of terminal sets such that A = I d 1. (iii) There exists a 2automaton &' = ( Q , i, T)with a famiZy of terminal sets such that A = I ,d1. (iv) There exists a Cautomaton &'= (Q, i, T ) such that A = I d 1. (v) A is thejinite union of sets B C w with B and Crecognizable subsets (i) (ii)
of C". (vi) A is thejinite union of sets BC with B and Crecognizable subsets of Z+. T h e proof is given in Section 3 after an important auxiliary result is established in Section 2. In Example 4.1 it will be shown that the classes dealt with in Theorems 1.3 and 1.4 are distinct, i.e., that E c is not closed under Boolean operations. EXERCISE 1.1.
Show that i f B is a prejix, then A  B
EXERCISE 1.2.
Show that Acu= (A+)w =
=
A.
EXERCISE 1.3. Show that for each automaton d there exists an automaton d' with a single initial state such that 1) d 1) = 11 d'I), and that d ' can be constructed to be deterministic i f & is deterministic. Establish a similar result for I d I .
383
2. An Auxiliary Proposition 2. An Auxiliary Proposition
In preparation for the proof of Theorem 1.4 we prove: PROPOSITION 2.1. For each recognizable subset A of 2+ there exists a recognizable subset C of Z+ such that
AUI= A+C Let denote the right congruence of the set A+. Thus s2 iff s;lA+ = silA+. Let s E Z+. A factorization
Proof.
s1
N
N
s = at
of s is called a principal factorization if the following conditions are satisfied :
(2.1) a E A+, s t . (2.2) If s = a't' with a' N
(2.3) If t' 5 t and at'

E
A , a 5 a', and s

t', then a
= a'
and t
=
t'.
t', then t' = t .
Let C be the set of all those elements s of Z+ for which a principal factorization s = at exists. Clearly the principal factorization of s is unique. The proposition follows from the following three statements : (2.4)
c c Am.
(2.5) Aw c A+C.
(2.6) C is recognizable.
c.
To prove (2.4) consider x E Thus x E EVand x = limn+mc, with c, E C and c, < c,+,. Let c, = a,2t,L be the principal factorization. Then a, < a,+, and therefore x = limn+wa,. For each n, there exists p > n such that an 5 C n < a p

Let d = ai'a, so that a, = a,,d. Since t,, 5 d and arltn= c,, t , , it follows that u p = and d. Since up E A+ it follows that d E A+. Thus for each n we have up E a,Af for some p > n. Since a,, E A+ it follows readily that x E A w .

3 84
XIV. Infinite Behavior of Finite Automata
T o prove (2.5) consider
x
(2.7)
=
aOal.. .a,.
..
with
a,, E A+
Suppose for the moment that the sequence {a,,} satisfies also
a,,a,,,
(2.8)

for all n > 0
a,+,
Then by iteration we have (2.9 1

a,* . .an+, a,, t~
From the definition of the set C it then follows that there exist c,, E C such that a,. . .a,, 5 c,, I a,. . .a,+,

Setting c = lim c,, we have c E C and c = a 1 a 2 . ..a,,. . . . Thus x = a,c E A+C. We must now show that given (2.7), the sequence {a,,} can be chosen so that (2.8) also holds. Given integers n, m E N , define n = m if there exists an integer p 2 n, m such that
a,,. . . a p p l
(2.10) or equivalently if

a,,, , . .appl

a[~llla[Pl a[~nlla[pl
(2.11)


Since is a finite equivalence relation in Z*, it follows that is a finite equivalence relation in N . Indeed let uA+ be the cardinality of Z*/and let n,. . .nl be integers with k = 1 uA+. Then for p 2 n , for all 1 5 i 5 k the congruence classes of the elements a[n+la[pl cannot be all distinct. Thus card N /  5 nA’. Since N / = is finite, one of the equivalence classes S of N mod must be infinite. Let k , < k, be the smallest elements in S. Assuming that the elements k, < k, < . . , < k, of S are already defined for some n > 0 define k,,,, as the smallest element of S for which (2.10) [or (2.11)] holds with n, m,p replaced by klIpl, k, , k, t l . Then setting
+
a,.
. .ako, = d k u I
b,
=
6,
= aln, . . . aEnpl=
we have b,,b,,+,

b,,,
u[knllla[knl
for all n > 0 as required.
if
n >0
2. An Auxiliary Proposition
385
I t remains to be shown that C is recognizable. T o do this we employ a general method which may be called "separation of variables." T h e essence of this method is the use of any number of disjoint alphabets El, X,,. . . each of which is in a fixed 11 correspondence with L'. For each subset S of Z*, X iwill denote the corresponding subset of Xi*. Given a factorization s = at of an element s E
Z*, we consider the element ZL =
T h e condition a
E
a,t,
.Zl*.Y2*c (2,u 2,)*
E
A+ then translates into
and this determines a recognizable subset of (XI u S,)". T o express the condition at t in terms of u we proceed as follows: Let ,3 = (Q, i, T ) be the minimal automaton of A+. T h e n the sets

[ql
= i'g,
q6
Q
are the equivalence classes of the relation . T h e condition at may now be written as

t
E
[q]
u E Z,*[ql, n ([4197+)
where p: (El u 2,)" 4 Z*is the very fine morphism which maps each letter of .XI u 1,into the corresponding letter of Z.T h u s we are lead to consider the set
D
=
u Al+[4l, n ([qlp') f/
This is the set of elements zi = a,t, with a E A+, at Condition (2.2) may be reformulated as follows:
(2.2') If t
=
bt', ab
E
A+, and t

t ' , then t
=

t.
t' and b
=
We are thus led to consider factorizations
s = abt' and corresponding elements v
= a,b,t,'
E
Z,*Z,*E,* c (El u Z3u Z2)*
1.
XIV. Infinite Behavior of Finite Automata
386 The conditions
ab E A+,
b # 1,
bt‘

t’
determine a recognizable subset E of (Zl u 1,LJ Z,)*. Imposing condition (2.2) amounts to replacing the set D by
C
 Ey
where y : (Zl u 2, u Z2)+4 (Z, LJ Z2)* is the very fine morphism, replacing each letter of 2, by the corresponding letter of Zl, and leaving alone the letters of Zland C,. Condition (2.3) is handled in the same manner. As a result we find that the set of all elements u = a$, corresponding to elements s = at E C given in a principal factorization is a recognizable subset F of (Zl v Z2)*.Since C = F ~itI follows that C is recognizable I 3. Proof of Theorem 1.4
T h e proof follows the following pattern (i)
(iv)

0 All
(ii) => (iii)
(v)
(vi) => (ii)
(i) o (ii). Let R denote the class of subsets A of Z* for which (ii) holds. We first show that G c c R. Let A E G. By Theorem 1.3, there exists a deterministic 1automaton &’= (Q, i, T ) such that A = 11 &’ 11. Define
T={XIXcQ, X n T f @ ) and let d’ = (Q, i, T). Then I/ d 11 = I d’ I and thus A E R. To prove that K c U c R it suffices to show that R is closed under complementation and intersection. Then let A = I d I with d =(Q, i, T)be a complete (deterministic) automaton with a family T of terminal sets. Let T‘ be the complement of T viewed as a subset of 29. Then setting d’ = (Q, i, T’) we find that I &’’ I is the complement Z*  A of A. Thus 2+ A E R.
3. Proof of Theorem 1.4
387
Let A , , A , E R and let
Aj
I
=
d
I,
j
d
where dj are deterministic for j
=
j
=
( Q j , ij, Tj)
1, 2. Then
=
I dI
x Q 2 , (ii
iz), T)
A, n A, with J/ =
(Qi
9
T = ( X X Y I X E T ~ , YET^} Thus A , n A , E R. To show that R c L c B consider A = I d I with d = (Q, i, T) deterministic. We note the following formulas
A = (J I ( Q , i, T)I TET
I (Q, i, T ) I where
BT =
BT  CT
u 11 (Q, i, t ) 11
te T
CT = 11

=
(Q, i, Q  T )
Thus by Theorem 1.3, A E K c ” . (ii) (iii). Obvious. (iii) (v). Let A = I d I with A = (Q, i, T) deterministic. Let T E T and let t , , . . . , t, be an enumeration of the states in T. Define
BT = I
(Q, i, t n ) I
CT = I ( T , t n , ti)
I
I ( T ,t n  1 , t,) I
Then it is easy to see that
I (Q, i, T ) I = BTC?TW and consequently
uYzl
BiCiWwhere B iand Ci are recognizable (v) =+ (iv). Let A = subsets of 2*. Without any loss we may assume that Cic Z+. Then be replacing B iby B,$( we may also assume that B i c Z+. Let 9i, normalized (not necessarily deterministic) &automata such that I gi1 = B i , I gi I = Ci for 1 5 iC n.
XIV. Infinite Behavior of Finite Automata
388
Construct the automaton &' by the scheme

with T = { t l , . . . , t , } as terminal set. Then JJd 11 = U BiCim= A as required. (iv) (iii). Let A = Jj &' )I with d =(Q, i, T ) . Define
T={XIXcQ, X n T f 0 } Then

I ( Q , i, T ) I = 11
I(
=
A
as required. (vi). This follows from Proposition 2.1. (v) (vi) * (ii). Let A = Ur=l B,C, with B , , C, recognizable subsets of S+.Since the class of sets for which (ii) holds is closed under union, it suffices to consider the case n = 1. Thus A = BC with B and C recognizable subsets of C",and with B c Z+. Let ,9?= (P ,P o , S ) , @ = (Q, 4 0 1 T ) be complete (deterministic) automata such that
I ,9I = B ,
1'8 =C
We shall consider words v in Q*, Such a word v is called simple if no letter in it is repeated. Thus there are exactly 2cardQ simple words. With ant v E Q* we associate the simple word [a]obtained from a by keeping only the leftmost appearance of any letter a appearing in v. Let v = q l . . .q,&be a simple word in Q*. Given a E Z we define
This word need not be simple and therefore we may have I [va] I < n. Let K be the largest integer 5 n such that qla, . . . , qka are distinct. This integer K will be called the index of the transition v + v o and will
3. Proof of Theorem 1.4
389
be denoted by I,,,,. Observe that 1 5 Zv,, 5 I z, I if I z, I f 0. If z, = 1 we define lu,, = 0. We now define a complete 1automaton a’= (R, r o , T) with a family of terminal sets. T h e states are triples
where p E P, v is a simple word in Q*, and 0 5 1 5 I z’ 1 is an integer. T h e initial state is ro = ( P o , 1 , O ) T h e action of Z is defined by
( P , 2.’, 1).
=
{
lu,,)
(P.9
[7301,
(P.3
[(~a>sol, 4p)
if P O $ S if Pa E s
T o define the family of sets T we consider any integer 1 5 k 5 card Q and define
D, = { ( p , z,, I )
E
R I 1 > 0 and kth letter of
z,
is in T }
{(PI 1) E R I k I I} T k = { X l X c E,, X n D k # @} T = T , u ... uT,, n = cardQ Ek =
Q,
To conclude the proof it suffices to show that
(3.1)
I LdI = Bzc
Consider a sequence x: N + 2 and let r : R + Z be the corresponding ‘ and with r i f l == r i x i . To prove sequence with ro the initial state of a equality (3.1) we must prove:
(3.2) x E BC iff there exists an integer k such that r i E E, for all i sufficiently large, and r i E D, for infinitely many indices i E N.
c.
Let ri = (pi, v i , li). Assume that x = by with b E B and y E Let = j . Since B c .2+we have j > 0. I t follows that p j E S and therefore qo is a letter of vj. Consequently qoy[)ilis a letter v ; + ~ ,say the d,th letter counting from the left. Since d,, 2 d,,,, 2 dn+, 2 . . ., it follows that there exist integers k and no such that d,, = k for all n 2 no. From the definition of the action in a’it follows that I,, 2 k for all n > no. T h u s rj+, E Ek for all n > n o . Since, further, y E C it follows that
IbI
XIV. Infinite Behavior of Finite Automata
390
qoy[nlE T for infinitely many indices n 2 no. Thus y j + , , E D, for infinitely many indices n. Conversely assume that an index i , is given such that r i E Ek for all i 2 in and that y i E Dk for infinitely many indices i. Let q be the kth letter in v i , . From the description of the automaton &' it follows that there is a factorization x = a y with I a I = J, 0 < j 5 k such that p j E S and q = q,,y[iOil. I t follows that a E A. For n 2 i,  J , qoy["1is the kth letter of vj,+,. Since infinitely many of these letters are in T it follows that y E c I Show that the construction given in the proof of (ii) applies also in the case B c 2" (rather than B c Z+)provided (vi) the initial state of A is defined as r, = ( p , , q,, 1) whenever 1 E B. EXERCISE 3.1.
4. Examples and Exercises EXAMPLE 4.1.
With C = {a, r } consider the subset
A
=
Z:"ato
of ,ZN.This is the set of all sequences x in ZNin which a appears a finite but nonzero number of times. If we consider the nondeterministic automaton
d : u , r E i ~ . t 3 r then
A
I &' I = 11 d . 1 1 =

Thus by Theorem 1.4,A E Rec". We shall now show that A is not in Rec. This will prove that the class Rec is not closed under Boolean operations. In fact we shall prove that there is no subset B of C" (recognizable or not) such that A = B. Indeed, assume that A = B . For any 0 E C we have sat* E A , and therefore sai? E B for infinitely many integers i. Let (s) be the smallest such n. Consider the elements so = 1,
sntl= ~ , a t ( ' n )
E
B
and let s = limn+ s,. Then s E B, but s E A since s has infinitely many a's. We now proceed to construct a deterministic automaton A?= ( R ,
4. Examples and Exercises yo,
T) such that A A
=
391
I d I. We utilize the representation
=
BC,
and apply the method given in the proof of (vi) complete deterministic automata are .g:
r
E
@:
T
E
j
q
+
L
P
S
3
3

C=
B = Z”O,
T*
(ii). T h e appropriate
o
0
.
T
Note that s is a nonterminal sink state; its presence is needed since 8 should be complete. From the automata R and L? the automaton a’is constructed by the method of Section 3. Only the accessible part of &’is exhibited. +
(i,1 , 0 1 3
l‘
( P , Q, 0)
This gives the following four terminal sets
XIV. Infinite Behavior of Finite Automata
392
T h e terminal sets T,', Ti', and Ti'' contribute nothing since after the states ( p ,sq, 1) or (i,sq, 2) have been reached a return to the state (i,q, 1) is impossible. T h u s T = ( T , , T 2 ) .T h e terminal set T , will yield all sequences containing exactly one (T, i.e., the set z*azw. T h e terminal set T , will yield the set ( t Q o ) ( t * a ) + t w . EXAMPLE 4.2.
Consider the deterministic automaton ,dgiven by
. C P + q 3 r with the family T consisting of the two singletons p and q. T h e n
I ,31 = P z I " This is the set of all words in Z.vin which (T appears only a finite number of times. This differs from the preceding example only by the fact that there (T had to appear at least once. EXERCISE 4.1. Show that for any subset A of S.v the following conditions are equivalent:
(i) A is an open subset of Z.+' (in the topology defined in XII1,l). (ii) A =/ B E v for some B c 1". (iii) A = BEv for some prejix H c 3.
Show that A is open and closed zff in either (ii) or (iii) B may be chosen to be jinite. EXERCISE 4.2.
Assume
A,
=3
A,
3
are open subsets of Ev and let B,,
A,
. ..
3
A,,
for all n E N
Consider the set =
(J B,Z" nsN
and brove that
...
. . . , B,, , . . . be prejixes such
= BJN
C
3
that
393
References
Use Exercises 4.1 and 4.2 to prove that a subset A of is a Gb (i.e., an intersection of a sequence of open sets) zff A = f o r some C c S*. EXERCISE 4.3.
c
References R. McNaughton, Testing and generating infinite sequences by a finite automaton, Information and Control 9 (1966), 521530.
This paper contains the main definitions and results of this chapter, as well as references to earlier work at Biichi (1962) and Muller (1963). T h e history of the subject is neatly outlined. McNaughton did not have Proposition 2.1 and thus had to prove the implication (v) (ii) directly [rather than in steps (v) (vi) (ii)]. This put very heavy demands on the proof. T h e argument given by McNaughton is very informal and to some extent inaccurate (but repairable).


M. 0. Rabin, Automata on infinite objects and Church’s problem, Anrer. Math. Sor. Regional Conference Series in Mothenintics 13 (1972), 122.
Correct proofs of the implication (v) = (vi) 3 (ii) are given and are credited to Y. Choueka (unpublished). ’I’he proofs are virtually identical with those in this chapter that were found independently by M. P. Schutzenberger jointly with the author. €I. I,. Landweber, Decision problems for 0)automata, Math. Svstems Theory 3 (1969), 376384.
This is the source for Exercises 4.14.3.
CHAPTER
xv kRecognizable Sequences
T h e study of krecognizable sets started in Chapter V is continued here. In addition to the notion of a krecognizable subset A of N , the closely related notion of a krecognizable sequence x: N + Z is introduced where 2 is a finite alphabet. 1. kRecognizable Sequences
We shall relate the sequences x : N .Z with the notion of krecognizable sets studied in V,3. A sequence f
x : N+.Z
is said to be krecognizable, where k > 1 is an integer, if for each the set A, = 0xl = {n I nx = CT}
0E
2
is krecognizable. An analogous definition was made in XII1,2 with “krecognizable” replaced by “recognizable.” Proposition XI1 I,2.1 then asserted that the class of ultimately periodic sequences was obtained. EXAMPLE 1.1. Let A bc a subset of N and let x : N acteristic function, i.e., 1 if X E A nx={ if x $ A
+
2 be its char
Then A is krecognizable iff x is a krecognizable sequence. 394
1. kRecognizable Sequences
With each x E relation in N
395
P' (and with k > 1 fixed) we define the equivalence nNZm,
n,mE N
by the condition
(krn +j)x
=
(krm +j)x
for all r
E
0 < j < kr
A',
PROPOSITION 1.1. The sequence x: N Z is krecognizable if and only if the equivalence relation mr in N is finite, i.e., if the quotient set N / w Xis finite. f
Proof. For each u
E
2 define the equivalence relation in n, m
n N,m,
N
N
E
by the condition
(krn +j)x
= uo
(k'm
+ j)x = c
for all r
E
N , 0 < j 5 kr
Then n w Xm holds iff n w0m for all u E 2. Consequently the equivalence wZis finite iff the equivalences o are finite for all u E 2. However, the finiteness of w , is exactly the condition for the krecognizability of the set A, = axI (see Proposition V,3.3) I
A krecognizable sequence x: jective and if for all n, m E N nx
N
= mx
f
Z will be called generic if it is sur
2
n
m
NZ
T h e opposite implication holds for all x E it is surjective and
nx
=
mx

(kn
E".Note that x is generic iff
+ j)x = ( k m + j)x
T H E O R E M 1.2. A sequence x: N i f it admits a factorization
+
for all 0 i j < k
Z is krecognizable
if and only
N L r A Z where T is finite, y is a generic krecognizable sequence, and
CI
is a function.
XV. k Recognizable Sequences
3 96
Proof. Assume that such a factorization is given. Since n u m holds iff ny = my it follows that the equivalence relation n N u m is finite and thus y is krecognizable. Since
ax1
=
aaly1
z
uw  I
a=ya
it follows that x = y a is krecognizable. Conversely assume that x is krecognizable. Then the equivalence relation wZ is finite. Let T = N / w Z and let y: N + be the natural factorization function. Since n mZm implies nx = mx it follows that there is a unique function 01: r 2 such that x = ya. T h e verification that y is generic is left to the reader I
r
f
A generic krecognizable sequence will be called a “kgeneric sequence” for short. They will be studied more intensively in the next section. EXERCISE 1.1. Given a sequence x : N + Z dejine the truncation N + Z by setting nxr = ( n + 1)” for all n E N . Show that is krecognizable zff x is.
XI:
X I
EXERCISE 1.2.
Given sequences xl: N + Z , ,
x2: N + Z z
dejine x: N
+
nx
( n x l , nx2)
Show that x is krecognizable
iff
=
L’,xZ2
both x1 and x2 are krecognizable.
EXERCISE 1.3. Modify the dejinition of the equivalence relation wZ so as to apply to the case of recognizable sequences. Obtain the analogs of Proposition 1.1 and Theorem 1.2.
2. kGeneric Sequences
There are two methods (in addition to the basic definition) of describing kgeneric sequences and a skillful manipulation of these descriptions can be used to prove many properties. Let x: N  2
397
2. kGeneric Sequences
be kgeneric. We convert S into a complete right kmodule by setting
aj = ( k n
+ j)x
for
a
E
S, j E k
provided a = nx
Such an n exists since x is surjective and the choice of n is immaterial since nx = mx implies (kn + j ) x = ( k m j)x. If we set a. = Ox, then we find
+
We assert that S as a kmodule is accessible from
(2.2)
a&"
=
go,
i.e., that
,r
Indeed, let a E Z. Since x is surjective we have a = nx for some n E N . Assume n > 0 and write n = n'k j with n' E N and 0 5j < k and let a' = n'x. Then a'j = a. Since n' < n the argument can be continued by induction. Since j is the last digit in the standard expansion of n at the base k, the same argument also proves
+
(2.3 1
0"s =
( s Y ) ~
for all s E k"
where v : k" + N is the standard interpretation defined in V,2. Conversely if S is given as a complete right kmodule and a. E Z is such that (2.1) and (2.2) hold, then (2.3) can be used to define x: N 4 2. I t is easily seen that x is kgeneric which yields the same kmodule structure on S as the one given at the start. As an application of this module language we prove: PROPOSITION 2.1. For each kgeneric sequence x: N p 2 1 szich that
an integer
(nkp)x = (nk")x for all n Proof.
E
N. We have
(nx)O = ( n k ) x and therefore (nx)Or= (nkr)x
4
S, there exists
XV.
3 98
kRecogn izab le
Seq uences
Since the function f:Z + Z defined by uf = (TO is an element of the finite monoid of all functions Z + Z it must have an idempotency exponent, i.e., an integer p 2 1 such that f p = f 2 p T o introduce the next method for treating kgeneric sequences we consider the morphism
(2.4)
w : Z*+Z"
defined by
(2.51
(nx)w = (kn)x(kn
+ 1)x.. .(kn + k

1)x
= (X[knl)lX[k(n+l)l
or in module notation (TW
=
u01.. .(k  1)
T h e following properties of w are clear
For the iterates of w we then obtain u0wn =
Consequently (To
x[k"l
< (Tow < . . . < (Town < * . .
and
(2.8)
x = lim n+w
dkn] =
lim(uown) n+m
T h e fact that x is surjective implies:
(2.9) There exists an integer n 2 1 such that cown contains all the letters of Z. Conversely, given a morphism (2.4) satisfying (2.6), (2.7), and (2.9),
3. Examples and Exercises
399
formula (2.8) defines a kgeneric sequence x for which ( 2 . 5 ) holds. Thus w and x mutually determine each other. T h e morphism w will be called the generator of x. As a consequence of this discussion we obtain: PROPOSITION 2.2. Each kgeneric sequence x: N + 2 is also kqgeneric for all q > 1. If w is the generator of x as a kgeneric sequence, then wq is the generator of x as a bgeneric sequence I
3. Examples and Exercises EXAMPLE 3.1.
k
=
2, 2 = 2, o0 = 0, o w = 01,
Then
owz
= 0110,
l w = 10 oW3=
oiioiooi
T h e 2sequence x = limOwn = 0110100110010110..
.
nfcu
is known as the “Thue sequence.” An alternative description may be obtained as follows. Let 1: 2” + 2” be the very fine morphism defined by jn = 1  j for j = 0, 1. Then x is defined by the conditions
ox = 0,
X[2n+11
= x[zn~(x[zn~)~
EXAMPLE 3.2. If in the example above we replace lw by 01 (instead of lo), we obtain the sequence x = 010101..
. = (0l)W
Thus x is the characteristic function of the set of all odd numbers in N . EXAMPLE 3.3. Let k > 1 and define x: N 4k by setting nx to be the first digit in the expansion of n at the base k. Thus nx = j iff n = jkp 1 with 0 5 1 < kp. Define w: k + kk by
+
Ow=Ol,..(k1), Then x
=
lim,,,,
jw=jk
Ow” so that x is kgeneric.
for
O<j
XV.
400
K Recogn izable
Sequences
EXAMPLE 3.4. Let x : N + 2 be defined by nx = 1 iff the expansion of n at the base 3 does not contain the digit 2. Define w: 2 + 23 by
lw
=
110,
ow
=
000
Then
x
lim l w n
=
n +m
and therefore x is 3generic. EXAMPLE 3.5.
T h e sequence x
x
=
E
2*v
0110100010
is a 2sequence, though not a generic one. I n fact, x is the composition
with Ou
= la =
0, 2a
=
1, and
y
=
lim Own ntm
ow
= 02,
lw
=
11,
2w
= 21
Then y
ny
=
{
0 2 1
= 0221211121
...
if n = O if n is a power of 2 otherwise
EXERCISE 3.1. Given the generator w: Z* + Z, define its prolongation
f
.Z* of a kgeneric se
quence x : N
and prove that w and wp have the same prolongations. Show that x is the unique solution of the equation XW'V
=x
4. kRecognizable Sequences and Sequential Functions
401
S b e a sequence and let q 2 1 be an integer. EXERCISE 3.2. Let x: N Define the sequence y : N 4 23 by setting +
ny
+
(nq)x(nq 1)x.. .(nq = (x[”ql)lx[( I 1 t l ) l Q
=
+q

I)x
Show that y is krecognizable (resp. kgeneric) zff x is krecognizable (resp. kgeneric ). EXERCISE 3.3. Let x: N + C be kgeneric. Show that for each m, x contains no more than ern distinct segments of length m with c = k(card L’)2. 4. kRecognizable Sequences a n d Sequential Functions
T h e objective here is to extend Theorem XIII,2.2 to krecognizable sequences : THEOREM 4.1. (Cobham) Let f : 2.” FAv be a sequential function. x E 2.” is krecognizable (k > l ) , then so is y = xf E P. f
If
Proof.
Let .,&
=
(Q, i, A): 2 4 T
be a complete sequential machine defining f. Define z
E
Q Aby~ setting
=
T h e n from the definition off it follows that ny
=
( n x , nx)A
In the nest proposition we shall show that z is krecognizable. Since
yyl
= U(qz’
n axl)
the union extending over all pairs (q, a) such that (4, @)A = y , it follows that yyl is krecognizable. T h u s y is krecognizable 1 . be krecognizable and let Q be a PROPOSITION 4.2. Let s: N 4 Y finite complete right Zmodule. Then f o r any i E Q the sequence z: N + Q
XV. kRecognizable Sequences
402 given by
is krecognizable. Proof.
We first show that we may assume that x is generic. Indeed
let X'
A 7 4
a 7 1' + 1
be the factorization of x with x' generic and a a function. Then Q may be regarded as a complete S'module by setting qa' = q(o'a). It follows that ix['I] = ix'["].Consequently x may be replaced by x'. Thus we may assume that x itself is generic. Let oo = Ox and let w : ,Z* S* be the morphism satisfying f
as defined in Section 2. Consider the functions QXX+Z
fjl:
(4, elf,, = q(aw")
for n E N . Since this family of functions must be finite there exist integers 0 5 r < p such that f r = f,.This implies q(sw') = q(swp)
for all q E Q and s E Z*. Since
(4.1)
For each integer t and
E
N there exists an integers such that 0 5 s < p ix[il.ltll
for all n
E
N.
 ix[k~l,1 
4. kRecognizable Sequences a n d Sequential Functions
403
We now define the equivalence relation n = m in N by the conditions
nx
=
mx
and
(4.2)
iX[!dnn]= i X [ k h ]
for all
0 5 t
This equivalence relation is finite since the sets z' and Q are finite. T o prove that z is krecognizable we must show that the equivalence relation Z (defined in Section 1) is finite. This follows from the implication n =m = > n ~ ~ m which we will now prove. We must show that n = m implies
(ktn
(4.3) for all t
E
+j ) z = (Em +j ) z
N and all 0 < j < kt, or equivalently iX[lztn+jl
(4.4)
= iX[klin+j~
Since (n)x = ( m ) x and x is a generic ksequence we have
(ktn for all 0 < j
+ j ) x = (ktm + j ) x
< kl. Consequently (4.4) reduces to i X [ k h l = iX[kbnl
By (4.1)it suffices to consider t < p , and this is precisely assumption (4.2). As an example of an application of Theorem 4.1 we prove: P ROPOSlTlON 4.3. Let
A = (u,
...
...)
be an infinite krecognizable subset of N , and let B be a recognizable subset of N . Then the set AIB = (a, 1 n E B } is krecognizable. Proof. Since A I ( B , u B,) = A I B , u A I B , it suffices to consider the case when B is the arithmetic progression
B=s+pN,
s , p ~ N ,p > 0
404
XV. kRecognizable Sequences
Let x: N + 2 be the characteristic function of A. Then a,x = 1 and ix = 0 for i E N  A. Consider the sequential machine d: 2 + 2 which for s = 1, p = 3 is given by the diagram
n
and let f: 2‘” + 21” be the sequential function that it defines. Then xf is the characteristic function of A 1 B. Since by Theorem 4.1, xf is krecognizable, B is krecognizable References A. Cobham, Uniform
t a g sequences, M a t h . Systems Theory
6 (1972), 164192.
This is the source for all the results of this chapter, though the exposition has been modified.
CHAPTER
XVI Linear Sequential Machines
T h e notion of a linear sequential machine (also called a discretetime linear dynainical system) is obtained from that of a complete sequential machine of Chapter XI by replacing all sets involved by modules over a cornmutative ring K and by assuming that all the functions involved in the definition are Klinear. This produces sufficient variety in the theory so as to warrant a separate discussion, which however ties in well with some of the topics treated in Chapters l r I , V I I I , XI, and XII. T h e treatment is algebraic throughout the chapter, but is particularly so in Sections 813. 1. Algebraic Preliminaries
Let K be a commutative ring. W e shall denote by K [ [ c ] the ] ring of all formal power series in the single variable z with coefficients in K. T h e elements of K [ [ z ] are ] formal power series
with addition and multiplication defincd in the obvious manner. ‘I’he power series k is a polynomial if k,,  0 for all but finitely many n. ‘fhc polynomial ring K[2] is a subring of K[[:]].I n turn h7is a subring of K [ 2 ] provided each element k E K is regarded as a polynomial of degree zero. Let A be a Kmodule. If A is finitely generated, then we shall write [=l:K] m. If this is the case, then we shall denote by [ A : K ] the
405
XVI. Linear Sequential Machines
406
smallest integer r such that A is generated by r elements of A. If = K r , then [ A : K ] = r . If K is a field, then A is usually called a vector space and [A: K ] is simply the dimension of A over K. If A and B are Kmodules, we shall denote by (A, B), the Kmodule of all Kmorphisms (i.e. Klinear transformations) A + B. Since the ring K is commutative, there is no major reason for distinguishing between left and right Kmodules. However we shall stick to the right module notation. This has some bearing later since it determines how matrices are associated with linear transformations. Given a Kmodule A, consider the Kmodule ALvof all functions N + A , i.e. all sequences
A
a
=
(a,, a , ,
. . . , a,, , . . .)
of elements of A. It will be convenient to write a as a formal power series m
a=
C
anzn
n=o
and consequently write A[[z]] instead of A"'. With this notation it is easy to see how to convert A[[z]] into a K[[z]]module. I t suffices to define ak by multiplication of formal power series. Thus with k and a given by (1.1) and (1.2), we have m ..
ak =
C n=O
bnzn
with
I n particular, a z = C;=, anzn+l is the right shift operator transforming the sequence a = (a",a , , . . .) into a z = (0, a,, a , , . . .). PROPOSITION 1.l.Let A and B be Kmodules and
a function. The following conditions are equivalent. (i) (ii)
f is a K[[z]]morphism f is a K[z]morphism
1. Algebraic Preliminaries
407
(iii) f is a Kmorphism and the diagram

commutes.

Proof. T h e implications (i) =>.(ii) (i) needs a proof. Let
(ii)
(iii)
=
C knzn
n=o
C
are clear, so only
m
m
k
=> (ii)
E
u=
K[[z]],
anznE A[[z]]
n=O
We must show that
(4f = (af )k Let p 2 0 be any integer. Write k m = C;I=, k,l+pzn.Then
=
1
+ mzp with 1 = C:ii
knzn and
(ak)f = (aZ+ amzP)f = ( a f ) l + (am)fzP (af)k = ( a f ) l + ( a f ) m z p I t follows that (ak)f and (af)k have the same coefficients in all degrees < p . Since p is arbitrary, it follows that (ak)f = (af)k I Let
f: A
(1.3)
+
Wzll
be a Kmorphism. If a E A , then af E B[[z]] and thus af = C bnzn. Setting af,,,= b, we obtain Kmorphisms f n : A B. We shall write +
or equivalently
(1.5)
f
E
(44Y"zIl
PROPOSITION 1.2. Any Kmorphism (1.3) admits a unique extension to a K[[z]]morphism
(1.6)
f ' : "I1

"31
XVI. Linear Sequential Machines
408
Proof.
Let
m _
C
a=
anznE A[[.]]
n=O
Setting
m
af'
=
C
b,YL
2
apfq
n=o
with bn
=
p t q=n pEn,q>o
is a desired extension. The proof of uniqueness o f f ' is omitted
I
In the sequel we shall not distinguish among (1.3), (1.4), (1.5), and (1.6); we shall simply treat them as four different ways of recording the same mathematical object. Note that the conventions above embody the following identification
(1.7)
(A"z11, B"Z11)K"Zll
= (A,
B)dzIl
It is interesting to see how the composition of K[[z]]morphisms fares under the above conventions. We have PROPOSITION 1.3.
Let
r, B".IlL
A".ll
be K[[x]]morphism with h
=f g .
If
then hn
=
C"z1l
2
ptq=n
fpgq
I
p >o,q 2 0
Thus composition of K[[x]]morphisms can be expressed equivalently by multiplication of power series. 2. Linear Sequential Machines
Let &: A
+B,
A = (Q, i, A)
2. Linear Sequential Machines
409
be a complete sequential machine defined without any finiteness conditions on A, B, and Q. We shall now assume that A, B, and Q are modules over a given commutative ring K, that the functions (2.1) and (2.2) are Kmorphisms (i.e. are Klinear) and that the initial state i is the element 0 of Q. Subject to these assumptions we shall say that . X is a linear sequential machine (or more precisely a Klinear sequential machine). With the assumptions above, (2.1) and (2.2) yield
qa
=
qF
(9, a>A = qff
+ aG
+ aJ
for some Kmorphisms
F: Q+Q, H: QB,
G: A + Q
J: AB
We may combine the functions (2.1) and (2.2) into a single function
and this leads to the notation
for a linear sequential machine. This notation will be favored in the sequel. T h e result of the linear machine is the function
which may be describcd as follows using the sequence notation. Given an input sequence
a
=
( u o , a1, . . . , a , , , . . .)
there corresponds a state sequence
XVI. Linear Sequential Machines
410
and an output sequence b
=
af
=
(b,), b , , . . . , b,, . . .)
given by the formulas
We now prove that
f
(2.5)
is a K[[z]]morphism. T h e fact that f is a Kmorphism is clear from formulas (2.4). We must show that f commutes with the shift, i.e. that (az)f = ( a f ) z . T o see this observe that if we replace a by
az
=
. . .)
(0, a,, a,, . . . , a,,
then it follows from formulas (2.4) that the state sequence is replaced by 91,
('9
' " 9
qJ19
"')
and the output sequence by
bz
(0, b,, b , , . . . , b,, . . .)
=
as required.
We now evaluate f for the special input sequence
a
=
( a , 0, . . . , 0, . . .)
T h e state sequence becomes q
=
(0, aG, aGF, . . . , aGFn,,
. . .)
and the output sequence is
af
=
(aJ, aGH, aGFH, . . . , aGFnlH, . . .)
T h u s in the power series representation off
2 m
f
=
fnz71
ll=O
we have
(2.7)
fo = J ,
f J ,
=
GF"'H
for n > 0
2. Linear Sequential Machines
41 1
Observe that if Q = 0 (the trivial Kmodule, not the empty set!), then automatically F = 0, G = 0, and N = 0. T h e K[[z]]morphism f : A[[z]] + B[[z]] is then the coordinatebycoordinate extension of J : A + B. Thus with the convention of Section 1, we have f = J . T h e machine with Q = 0 will be simply denoted by J : A + B. For any linear sequential machine A: A + B as above, it will be convenient to refer to the Kmorphism J : A 4B (involved in the definition of &) as the direct part of d. T h e machine A is said to be jinite if [Q:K] < 00
I f f : A[[z]] + B[[z]] is the result of a finite Klinear machine A, then we say that f is Ksequential. For any Kmorphism f : A 4 B, the coordinate by coordinate extension f: A[[z]] + B[[z]] is sequential, Indeed, the requisite machine A has Q = 0, J = f. Let Qi
B
be two linear sequential machines with the same direct part J . A staterelation v: Al +A2 is given by a relation P:
Qi
+
Q,
satisfying the following conditions
(2.8) (2.9)
G2
= GlV,
PF2
41P
+ 41'P
= Fly, PH2 = Hl = (Q1+ Q1')Y'
Stated in terms of the graph # y , conditions (2.8) and (2.9) may be rewritten as follows
XVI. Linear Sequential Machines
412
This alternative form of the definition makes it clear that the inverse pl of a staterelation also is a staterelation. It is also clear that the
composition of staterelations is a staterelation. PROPOSITION 2.1. If a staterelation cp: A,+ d2exists, then A1 and k2 haae the same result. Conversely, i f d, and k2 have the same result, there is a maximal staterelation y : Al + d2containing all others. + A2is a staterelation. Since Proof, Assume that cp: d, d2have the same direct part it suffices to show that
(2.10)
G,F,"'H,
=
G2F,"lH2
Aland
for all n > 0
Since these are functions it suffices to show
GaF;;lIHZc GIF;'Hl This follows from (2.8). Indeed,
Conversely, assume (2.10) and define y : Ql + Q2 by setting #y = {(q,, qa) I q l F , i t l l = q2FZiH2
for all i 2 O}
Conditions (2.8.2), (2.8.3), and (2.9') are then clearly satisfied. Condition (2.8.1) follows from (2.10). + A2is any other staterelation, and if ( q l , qz) E #p, then If q : kl it follows from (2.8.2) and (2.8.3) that q l F l i H l = q2F2'H2for all i 2 0. Thus ( q l , Q%)E # y and cp c y as required 1 Note that the maximal staterelation y also satisfies
Note also that condition (2.9) did not yet intervene. It will however be needed in Section 5. T h e staterelation p: A', +=d2 will be called a statemapping if p: Q1 + Q2 is a partial function. If further p is a function (i.e. if Don1 cp = Ql), then we shall say that cp is a complete statemapping.
3. The Free Case; Comparison w i t h Automata
41 3
3. The Free Case; Comparison with Automata
We shall now concentrate on the case when both Kmodules ‘4 and B are finitely generated and free. Thus we may assume that

KP,
A
B
Kr
A Kmorphism y: A B may then be viewed as a pxrmatrix of elements of K, i.e. as a single element of K P X r . A K[[z]]morphism

f : A“,]]
B“z1l
c fnz’l m
f
=
rr=l
may then be regarded as an element of K ~ ~ . ~ [ [ z i.e. ] l , as an infinite sequence of pxrmatrices. However, we shall prefer to regard f as a pxrmatrix of elements of K[[a]]. ‘The components of this matrix will be denoted by f u g for , 1 5 u S p , 1 5 v 5 r. PROPOSITION 3.1. I f f is sequential, then it is the result of a jinite machine in which the state module is free.
Proof. Let KP k” be a finite sequential machine with state module Q and data F , G, H , J . Suppose that [Q:K] = 7n. There is then a surjective Kmorphism pi: KiIL 9. Since Ksf is free and y is surjective, the diagram f


may be completed to a commutative square by some Kmorphisln
F ‘ : A”” Krif.For the same reason we can find G : KP 4 Kr” so that G = G’p. Finally define fZ‘ = FZZ: k”“ + K r . T h e data F ‘ , C‘, H ’ , J yield a sequential machine .A’’: KI1+ k” with KitLas state modules. Clearly p: %,H’+ J?’ is a complete state mapping. ’Thus by Proposition 2.1, JH and 4’ have the same result I Let us now consider a linear sequential machine
.A:KT’

K‘
XVI. Linear Sequential Machines
414
with state module Kmand without a direct part (i.e. with J = 0). T h e data G , F and H of ~d' may thus be regarded as matrices in K of sizes p x m, m x m, and m x r . Consider an alphabet S consisting of a single letter a and define a Kaautomaton d of type ( p , Y) (see III,13 and VI,6) as follows. T h e states of JY' are (1, . . ., m } = Q', and the transition matrix is E = Fa. If we write G as a column
then each row G , E K"1 (1 5 u 5 p ) may be viewed as a Ksubset of Q'. Those are the initial states. Similarly H is written as a row
. . . , H,]
H = [H,,
with each column HI,E Km(1 5 u 5 r ) . These are the terminal states. T h e behavior I d I is a matrix [A,,,]where A,,,,is the behavior of the automaton (Q', G,, H,) and is a Ksubset of as. Let A,,, be the same . Ksubset regarded as an element of K [ [ z ] ]Thus m
Juv =
C
auonzn
n=O
where aur,nis the value of A,,, on an. We have by Corollary VI,6.2
A,,
=
G,EsHv =
2 G,EnH,
n=o m
=
C
G,FnH,a*
n=O
and therefore
aulln= G,F"H,, Since this is the coefficient of znfl of f f L lwe , obtain
(3.1)
fuv =
Auvz
T h e above construction establishes a 11 correspondence between Kaautomata ,d of type ( p , Y) and sequential machines ./& KP Kr without a direct term and with a finitely generated free state module. As a corollary of the above discussion we obtain f
4. Duality
415
PROPOSITION 3.2. A function
viewed as a matrix j = [ fiL,,]of elements of K[[z]] is sequential if each f,L7,is Krecognizable.
if and only
For the proof we only need to observe that A,,, is Krecognizable iff is Krecognizable, and that the matrix f = [ f,,,] is Krecognizable by an automaton of type ( p , Y ) iff each j u tis, Krecognizable 1
a,,,,
We recall that the Krecognizability of j,,, E K[[z]] is equivalent with the rationality of f u r in the sense of Kleene and also with its rationality in the sense of algebra (see VII,3). We shall return to this matter in Section 9 where the questions of rationality will be studied in greater detail. 4. Duality
Given a Kmodule A we shall denote by A^ its dual, i.e. the Kmodule of all Kmorphisms u : A + K. For a Kmorphism p: A + B, the morphism
p: B  A is defined by setting
BQ, = 9iB for each
E
8.Clearly
if p is surjective, then 47 is injective. Also if
w?4, then 9" = p i 2 p i 1 ' If A is a Kfree with a finite basis v l , . . . , v P ,then with a dual basis 8,, . . . , 8, defined by 4p =
V.V.= 1
J
{i
if if
i = j i+j
PROPOSITION 4.1. If K is noetherian and
then so is
A^ also is Kfree
A^ is jnitely Kgenerated,
A.

Since A is finitely generated there exists a surjective morphism A , for some p 2 0. Then y': A^ + I?. KP is injective. Since K is noetherian and is a submodule of a finitely generated Kmodule, it follows that A^ itself is finitely generated 1 Proof.
p:
KP
4
a
XVI. Linear Sequential Machines
41 6
PROPOSITION 4.2.
Let Q
B
be a Ksequential machine with result
M
Then the Ksequential machine
If further K is noetherian and .X is finite, then T h e first part follows from the observation that second part follows from Proposition 4.1 I
is finite.
f,l = I?PnIC. T h e
T h e assumption that K is noetherian is not needed when A = K P , = K7, and Q = Km. If relative to given bases in A , B, and Q we express G, H , and F as matrices, then with respect to the dual bases in A, B, &, the morphisms I?, and P are simply the transposed matrices. Th u s each f , Lalso will be the transpose of fn, when both f n and f,l are treated as matrices.
B
e,
5. Minimization
Given a Kmodule B we consider the Kmorphisms

zl: B[[z]J B[[z]]
nn: B [ [ z ] + ] B
for
0 5n
5. Minimization by setting for b
41 7 =
xzob,,a"
c bn+p, Do
bz1
=
bn,, = b/,
/1=0
We note the following identities
Since the operator z was called the right shift, the operator be called the lejt shift. Let
Q
zl
should
B
be a Ksequential machine. We consider the Kmorphisms
G:
A[a]
+
Q,
Ej: Q
+
B[[z]]
defined by
(az")G= aCF"
a
E
A
all q
E
Q
for all
qR = C qF"Hztl
for
T h e machine . // is said to be accessible (the term reachable also is used) if _C is surjective. T h e machine . J is said to be reduced (the term observable also is used) is €7 is injective. If / i is both accessible and reduced, then ./2 is said to be minimal. These notions require some explanation and amplification. Let 0.l be the image of G. Clearly 0.l is the Ksubmodule of Q generated by the Ksubmodules I
AG, AGF, L4CF2, . . . , AGF", . . . We call Qzi, the accessible part of Q . Since Q;'F c AG c Q:', there results a sequential machine
B

0;i F;l H." : A  B A GiL J
Ql1
and since
XVI. Linear Sequential Machines
418
with F i ,Ga, H'l defined by F , G, H . T h e machine Ail is accessible and is called the accessible part of d. If d is reduced, then A is both accessible and reduced and thus is minimal. Since the inclusion Qll c Q defines a state mapping .&;14A (and the inverse of this inclusion defines a state mapping A + &:I), it follows that .Xa and d have the same result. If d is finite, i.e. if [Q:K] < 00,then it is not necessarily true that [ Q * : K ]< 00. If however K is noetherian, then [Q:K] < 00 implies [ Q " : K ]< 00. Summarizing we obtain For each Klinear sequential machine A the accessible part is an accessible machine with the same result as A. If & is reduced, then A:1 is minimal. Ifd is finite and K is noetherian, then d" is jinite I PROPOSITION 5.1.
Let R
=
Kernel
R
R, i.e. =
{q I qF"H
=
0 for all n 2 0 }
If we replace Q by p = Q I R and define F', G', H r appropriately, we obtain the reduced sequential machine
dd' =
p
Fr H r
: A+B
T h e natural factorization morphism called the reduced quotient of ,d. Q Qr defines a complete statemapping d + d rand we have f
PROPOSITION 5.2. For each Klinear sequential machine A, the re
duced quotient &' is a reduced machine with the same result at d . If & is accessible, then d'is minimal. If Ji is finite, then so is d r I
We shall now consider two Klinear sequential machines Aland .A2 with the same result. By Proposition 2.1 there exist then staterelations
We conserve the notations of Section 2 and denote by staterelation.
ly
the maximal
5. Minimization
419
PROPOSITION 5.3.
Q,*
c Dom p.
Proof. From (2.8.1) it follows that AG, c Dom p. Further (2.8.2) implies that
AC,FlrEc Dom p
for all n 2 0
Condition (2.9) (used here for the first and only time!) implies that
AG,
+ AG,F + . . . + AG1Fr1c Dom p
for all n 2 0. Thus Ql* = I m _Gl c Dom p COROLLARY 5.4.
I
If Al is accessible, then Q1= Dom p I
PROPOSITION 5.5. If =A?.. is reduced, then p is a statemapping (i.e. p: Ql + Qz is a partial function). Proof. Assume q 2 , qzrE qlp, or equivalently ( q l , q2), (ql, q Z r )E #p. From (2.8.2) and (2.8.3) we deduce
q2FziHz= qlFliHl = qztFZiHz Thus (qz  qZr)n2 = 0 and since Azis reduced, qz = qzr
I
is reduced, then p is unique THEOREM 5.6. If A, is accessible and k2 and p: Q, + Q z is a Kmorphism. If, further, ,dl is minimal, then 4p is injective and if Azis minimal, then p is surjective. If both ,dl and =A?.. are minimal, then p is an isomorphism. Proof, By Proposition 5.5, p is a partial function and by Corollary 5.4, Dom p = Q,. Thus p: Q1 + Q2is a function. Since the same holds for the maximal staterelation y and since p c y , it follows that p = y. Since y satisfies [see (2.9) and (2.11)] QlY
+ QZY = + 4Z)YY (Q1
it follows that
and thus p is a Kmorphism.
(QlYP =
(41+fJ
420
XVI. Linear Sequential Machines
If LK?l is minimal, then, by Proposition 5.5, p' is a partial function and thus p is injective. If .d2is minimal, then, by Corollary 5.4, Dom ~ 1  l= Q, and thus rp is surjective 1 C O R O L L A R Y 5.7. Two minimal Klinear sequential machines with the same result are isomorphic I
We now turn our attention to the question of existence of a minimal Klinear sequential machine. We start with an arbitrary K[[z]]morphism
f: A"z1l

f = nc= O
B"z1l
m
We define the Kmorphism
3: A[zI
fizzn

B"xl1
by setting
for all a
E
(5.1)
A. Clearly azf=
afz1
for all a
E
A[z].
Let
Qr = I m a g e r Equation (5.1) implies Qrz' c Q f . We now define the machine
by setting qFf = q2I
for all q
E
Qf
co
aGr = a f =
C
af,1+lz71 for all
a
n=O
qHr
=
qn,,
for all q
Jr = f o
E
Qf
E
A
421
5. Minimization THEOREM 5.8.
..Hfisa mininzal Klinear sequential machine with result f .
Proof. Since qH, sequently, for n 2 1
=
qno, it follows that a”H, = u” ”n,, = x,,.Con
( , ~ ( a f i + l z L ) ) n l ,  ,afn c.0
aG,F;’H,
= aG,z”’~’n,, = u G , ~ ~ ,= ,,
=
k=O
and thus ./, has f as result. ‘The function G,: A[.] 0, coincides with the function f: A[,] B [ [ z ] ]and since Q, = ImageJ it follows that G, is surjective. T h u s .,Hf is accessible. Assume q E 0,is such that qn, = 0. T h u s qFf”11, = 0 for all n 2 0. Since F/”€lf= z”Hf = 7c,, it follows that q7cn = 0 for all n 2 0 and thus q = 0. Consequently d, is reduced I f
f
COROLLARY 5.9. If K is noetherian and f : A [ [ z ] + ] B [ [ z ] ]is sequential, then d, is jinite. I
Indeed, let .dbe a finite machine with result f. Then, by Proposition 5.1, ,&:*is accessible and finite. Thus, by Proposition 5.2, kar is finite. Since A,, Kf is finite I EXERCISE 5.1. I n the machine A? assume that a state q,, E Q rather than the state 0 is chosen as initial state. Show that the output sequence corresponding to a single input a E A is given by
Use this observation to show that the reduced machine coincides with that considered in Chapter LYII. EXERCISE 5.2. Let
as defined here,
dbe a Klinear machine with result
Show that if FP = 0 , then f I l = 0 for all n > p . Show that the converse also holds if ~ 6 is ? minimal.
422
XVI. Linear Sequential Machines
EXERCISE 5.3. Show that the Kmorphisms characterized by the following conditions aG = aG
G, R
a n d f are completely
for all a E A
z_G = G F
qRn, = qH Fly
for all q
Q
= Rzl
af = (a&’
zf
E
for all
aEA
=fz1
6. Parallel Composition
Ai =
Fi H,. ’ : A+B, Gi Ji
QL
A
Qi
Fi 0 Hi Fz H2
.A?= Qz 0
T h e Kmorphisms G: A
G = [Gi, Gz]: A
f
+
i=l,2
:
AB
Q and H : Q + B are given by QlxQ2,
H=
:I[
Q1xQ2+B
Clearly, if Al and d. are finite, then so is A. If f i and fzare the rethen f i f z is the result of A. This implies sults of dland d.,
+
6. Parallel Composition PROPOSITION 6.1.
423
If
f i : A[[z]]

i = 1, 2
B[[z]],
are Ksequential functions, the so is f i + f2
1
The state module Q of a sequential machine comes equipped with a Kendomorphism F : Q Q. It will be convenient to regard Q as a K[z]module by setting q z = qF. I n this sense the state module of the machine dl A, is 0, x Q 2 , a direct product of K[z]modules. Using this notion, the construction of dl d2 may be inverted. +
+
PROPOSITION 6.2.
+
Let I
Q
B
be a Ksequential machine and assume that
+
is a direct product of K[z]modules. Then d = Al A, where d, and .d2 have state modules Q1 and Q 2 . Further, ;f d is accessible or reduced, then the same holds for dl and dz. Proof, Since Q = Q l x Q Z as a K[z]module, the morphisms F , G, H , of the machine ~ z have f the form
A with Fi:Q i Q i , Gi: suffices to define +
+
Q i ,Hi: Qi
B Fi Hi

B for i = 1, 2. Thus it Qz
Qi
B

If A i s accessible, then G: A[z] + Q is surjective. Since G = [G1, G2], it follows that Gi: A[z] + Qi are surjective and thus dland A. are accessible. If .Iis reduced, then f7:Q + B[[z]] is injective and the same holds for Ri: Qi B[[z]], i = 1,2. Thus dland A, are reduced 1

XVI. Linear Sequential Machines
424 COROLLARY 6.3.
Assume that K is noetherian. Let

f : "I1
mz11
be a Ksequential function and let Q f = QixQz
be a direct product decomposition of Qfas a K[z]module.Then f = f i where f i : mz11 B"zl1

+f z
are Ksequential functions, such that QJ,
for i = 1, 2
Qi
I
7. Series Composition
Let
be Ksequential machines. T h e sevies composition or simply composition = Al J 2is defined as follows
A?
Qz
QI
C
F, 0 Hz H,G, F, H,J,: A + C A?= Q1 Qz
7. Series Composition
425
Clearly if .A', and tY2 are finite, then so is T h e reader mill easily verify that this definition of composition agrees with the definition given in XIII,8 for sequential niachines. This iniplies that the result
.f: "I1
+
C",Il
is the composition
(7.1)
A"z]]
L R"s]] & C"Z]]
of the results of A, and .A2. This can also be checked by an explicit calculation. This implies PROPOSITION 7.1.
I f f l (2nd f 2 in (7.1) are Ksequential, then so is
f =f,fi I T h e state module of A?' = d l,,ff2 is
when viewed as a Kmodule. Its endomorphism I: is however given by the matrix
I:= [ F z
H,G,
"J F,
T h u s viewed as K[z]modules, Q2 is a submodule of Q while Ql is a quotient module. In other words we have an exact sequence
0 +Q2+ Q
+
0, t o
of K[,]modules. This exact sequence splits when regarded as a sequence of Kmodules. These remarks show how to invert the construction of
.&TI..y,. PROPOSITION 7.2.
Let
Q
be a Ksequential machine over and let
C
XVI. Linear Sequential Machines
426
be an exact sequence of K [ z ]  m o d ~ ~ l esplit s , over K. Then H . d'; /i'i where d',:A B, .//;: B + C have state modules 0, , Q2. Further, d is accessible or reduced, theii the same holds for //, and . /LL. :
~
f
~
Proof. Since the csact sequence splits over K , we may assume that
Q = Q2XQI as a Kmodule. T h e Kendomorphisin F of Q then takes the form
where F,, F , are Kendomorphisms of Q Z , Q, while I,: Ql Kmorphism. Explicitly, F is given by (42,
4,)F
=
(q2F2
4QIL, q , F d
I t follows that 11.1may be written as Q2
QI
C
We now consider the machines
Q, F , H ,
A;= Qi L
H , : Qlx A
+
C
+
0, is
a
8. T h e Case W h e n K Is a Field COROLLARY 7.3.
427
Assume that K is noethevian. Let f : A".]]

C".]]
be a Ksequential function and let
Be an exact sequence of K[,]modides split over K. Then f is the composition A".]]
5 B".]]
11,C[[z]]
wheve g and h are Ksequential and
EXERCISE 7.1.
Cavvy ouer the formalisms of XII,9 and 10 to thepres
ent situation. 8. The Case When K I s a Field
So far finiteness assumptions have played a rather secondary role in our discussion. We shall consider questions in which finiteness is quite basic. We shall assume in this section that K is a field. Let Q be a K [ z ] module such that [ Q : K ]..: 00. Consider a direct product decomposition
p5.0, M
(8.1)
' . . M Q,,
of Q as a K[r]module. Assume that none of the modules Q,, . . . , Q,, is trivial and that n is largest possiblc. It follows that each Q , , . . . , Q,, is an indecomposable K[,]modulc, i.e. admits no direct product decomposition 0, = Q,' x 0," in which 0,' and 0,"are nontrivial. Since [Q:K] 00, it is clear that such a optimal decomposition (8.1) exists. I t is also known (this is the RemakKrullSchmidt theorem) that, except for the order of factors, it is unique. T h e structure of an indecoinposable K[z]module Q is completely K[.] which is ruled out by the assumption known. Either Q [ Q : K ].00 or else < _

Q = K[zll(P")
XVI. Linear Sequential Machines
428
where p is an irreducible rnonic polynomial in K[z], u is a positive integer, and (p") is the principal ideal in K [ z ] generated by p7'. If u = 1, then the module K [ z ] / ( p )is simple, i.e. it has no K[z]submodules except itself and zero. If u > 1, then we have in K [ x ] / ( p " ) the chain of submodules
T h e consecutive quotients are for 0 5 k
Multiplication by pa yields an isomorphism
T h u s in the composition series (8.2) all consecutive quotients are simple and are K[z]/(p).More precisely we have exact sequences of K [ z ] modules. (Pk) 0 O +  W+l) ++
(P")
(P")
m1
f
(P)
for all 0 5 k < u. Since K is a field, these exact sequences split over K . Let .&: A + B be a finite Klinear machine with state module Q. We shall say that ,k' is primary of type p if Q K [ z ] / ( p " )where u 2 1. As before p is assumed to be a monic irreducible polynomial. If u = 1, then we say that <,/Y is prime of type p. If f : '4[[z]] R [ [ z ] ]is a sequential morphism then we shall say that f is primary (or is a prime) of type p if this is true for the minimal machine .d1. A rather special situation is when QJ = 0. I n this case f is a direct morphism defined by a Kmorphism A + B. Proposition 6.2 and 7.2 now yield the following

f
Let Ld: A B be a jinite Klinear sequential machine with state module Q f 0. Then .A? admits a parallel decomposition THEOREM 8.1.
f
8. The Case When K Is a Field

429
into primary machines. I f /i, , f o r 1 5 i 5 k , is primary of type p , with ndniits a series decomposition 0, K [ Z ] / ( ~ :then ~), I
where each M I ,, 1 5 j 5 i i , , is a prime machine of tjipe p , ,
I
7
I here is an analogous statement for sequential functions:
THEOREM 8.2.
Let f : A[[.]]
+
B[[z]] be a Ksequential function, with
Qff 0. Then f is a sun1 f
 f 1
+ . . ' tfL
where each f l : .4[[z]] F B[[z]] ( f o r 1 5 i 5 k) is Ksequential and primary. I f f , is primary of tvpe p , with QJ, w K[=]/(py+) then f , is a composition
f where ench f , , , 1 5 j 5
ii,,
= j l U L. . .
f l ,
is sequential and p r i m of type p ,
I
T h e decompositions described in 'T'heorerns 8.1 and 8.2 will be called parallelseries decompositions of .8' and f into primes. l'hc particular decomposition supplied by Theorcm 8.2 is algorithmic in the sense that it corresponds directly to the standard and unique decomposition of the K[z]module Q,. One could engage in elaborate algebraic arguments in trying to state and prove that the dccomposition given in Theorem 8.2 is the best possible. We shall be satisfied with a more modest result which we will now statc. Let f : A[[:]] + B[[z]] be a sequential K[z]morphism, and let p E K[z] be a prime (i.e. an irreducible monic polynomial). We shall say p occurs in f if 0,has a primary component of type p . PROPOSITION 8.3. I f f = f , 4f 2 where f i and J2 are sequential, and ; f p occurs in f , then p must also occur in either f l or f 2 .
Let f = gh zuhere g and h are sequential. I f curs in f , theti p mist also occur in either g or h. PROPOSITION 8.4.
p oc
Both propositions will be proved below. An immediate consequence is
XVI. Linear Sequential Machines
430 COROLLARY 8.5. Let b
f=
c
fhtIL
. . .fil
1=I
where f,,for 1 5 i 5 k , 1 5 j 5 u , are prime of type p L , . Then all the primes occurring in f must be among the prinies pi, 1 T o prove Propositions 8.3 and 8.4, we consider inequalities between K[x]modules. I,et Q and R be K[z]modules. We shall write R Q if Q contains K[x]submodules Q" c Q' c Q such that R w Q'/Q''. T h e relation is easily seen to be transitive. Further, as long as we deal with modules that are finite over K , it is also easy to see that R Q and Q R implies R Q.
<
<
<
f:A [ [ z ] ]+ R[[z]] be a sequential K[z]movB a machine with result f,and state module Q. Then
PROPOSITION 8.6. Let
phisnz and df; A
Qs<
+
Q*
Proof, Let .&?ti be the accessible part of M . Then QIL is a K[zJsubmodule of Q and, by Theorem 5.3, Q, is a quotient K[z]module of QtL.
Thus Q,
PROPOSITION 8.7. Let
be an exact sequence of K[z]modules and let P is a prime. Then either P Q2 or P Q, .
<
<
< Q where P M
K[z]/(p)
P be a surProof, Let R be a K[x]submodule of Q and let 91: R jective K[x]morphism. Let R , = RB and R, = Ru'. There results an exact sequence f
0
OL'
R2
R
p'
Rl
0
with u', p' defined by (x and p. Assume (x'p f 0. Since P contains no submodules except 0 and P, it follows that a'q is surjective and thus P Q2. If dcp = 0 , then p' is a welldefined surjective inorphism R, + P so that P < Q, I
<
COROLLARY 8.8.
p occurs in f if and only $+K[z]/(p) < (& I
43 1
9. Rationality and Recurrence
+
Proof of Propositions 8.3 and 8.4, Since f is the result of .d',,.At,2 it follows from Proposition 8.6 that Q, QJ,\ Since p occurs in f , it follows from Corollary 8.8 that P Qf where P = K [ =] / (p ). Thus P Of, L Qf2 and Proposition 8.7 implies that P Q,, or P Q f 2 . T h u s P occurs in f i or in f.L. T h e proof of Proposition 8.4 is similar except that instead of Q,, x Qf,we hove the exact sequence
<
of2.
< <
<
&
0 + 0,L 0 such that Q,f<
+
Qg
+
<
Q
Q I
The discussion of this section has an analog for the sequential machines treated in Chapters XI and XII. This is known as the KrohnRhodes theory, and will be developed in detail in Volume B. I n the case considered here, the algebraic background needed is easily available since the ring K[a] where K is a field is rather well known. For the KrohnRhodes theory, the necessary algebraic preparation concerning decompositions of semigroups will have to be developed essentially a6 initio. 9. Rationality and Recurrence
I n this section we assemble a number of algebraic facts that will be needed later. Let A be a Kmodule and let
a
=
f
a,Lucll
ll=o
be a formal power series with coefficients in 4, i.e. an element of A [ [ z ] ] . Generalizing the definition made in VII,3, we shall say that a is rational if there exist polynomials
qE
k"z],
p
E
A[z]
such that
aq
=
p,
q(0) = 1
We shall call q a denominator for a. If q has the stnallest possible degree then we shall say that q is a lowest denominator for a. Let r(.) = a01 t clz"'' . . . c,,,
+
+
be a monic polynomial of degree m in K[a]. We shall say that r is a re
XVI. Linear Sequential Machines
432
for all but a finite number of indices t 2 0. If (9.1) holds for all t 2 0, then Y is called a complete recurrence polynomial for a. Observe that if r is a recurrence polynomial for a and (9.1) holds for t 2 s then z'r(z) is a complete recurrence polynomial for a. PROPOSITION 9.1.
is a denominator f o r a
The polynomial
E
A [ [ z ] ]if and only ;f
is a recurrence polynomial f o r a. Further, the polynomial ,"'Q(z)
is a complete recurrence polynoniirrl f o r a proaided s
20
and
s
1 nz 2 deg(aq)
Indeed, relation (9.1) espresses the fact that the coefficient of zm+! in aq is zero. T h u s (9.1) holds whenever t 4m 2 deg(aq) In general a rational power series a denominators. However we have
E
i l [ [ z ] ]may have several lowcst
PROPOSITION 9.2. If k ' is a jield, then each rational power series A [ [ z ] ]has a unique lowest denominator q. Further :'q(z) is thP lowest complete recurrence polynomial for a where a
E
{
+ deg(aq)  deg q
if deg(aq) < deg q otherwise
Proof. Let q be a lowest denominator for a. T h e n q and aq are relatively prime. If q' is another denominator for a, then q'(aq) = q(aq') and therefore q divides q'. Since q(0) = q'(0) = 1 it follows that either q = q' or deg q < deg q' I
10. Sequential Functions and Rationality
433
10. Sequential Functions and Rationality
Let 0 be a Kniodule such that [ Q : K ]= m and Kmouphisni. Then F s a t k f j e s a nionic polynomial
PROPOSITION 10.1.
let F : Q equation
f
0 he
N
F"8 + C I J i " l
1
4 . . .
+
Cllk
=
0
with coeficients c , , . . . , cIlf in K . Proof. Let sl, . . . , x,,~E Q be generators of 0 as a Kmodule. There exist then elements a i j E K for i, j = 1, . . . , m such that
for all j
=
1, . . . , 712. Since x8 = C:"l xlA,, \vc have
for all j = 1, . . . , m , where d,, are the coordinates of the unit matrix I . Let E be the ring of all Kmorphisms Q + Q. Clearly E is a Kalgebra in which the identity morphism I : ,Q + Q is the unit element. We denote by L the Ksubalgebra of E generated by the element F. Then L is commutative and its elements are polynomials in F with coefficients in A.' Note that F,, = I. 'The formula above may now be rewritten as
T h u s setting c . . Ia . .I

6 1J. .I;
we obtain in nz :< nzmatrix C in L and
From this system of homogencous equations we obtain by Cramer's rule (i.e. by building linear combinations whose coefficients are suitable minors of the matrix C)
xiICI=O
for
i1,
...,m
XVI. Linear Sequential Machines
434
Since the elements x,, . . . , x,,, generate Q as a Kmodule, they a fortiori generate Q as an Lmodule. Consequently I C I = 0. Returning to the definition of C, we find
I a i j l  hL,F 1
(10.1)
=
0
where the determinant is calculated in the commutative ring L. Expanding this determinant yields the required monk polynomial I This is of course nothing else but the familiar CayleyHamilton theorem, proved here under minimal assumptions on K and Q. Equation (10.1) is the characteristic equation (also called the secular equation) of F . T H E O R E M 10.2.
Let
be a K[x]nzorphism and let
(10.3) be the corresponding formal power series with coefficients in V = ( A , B ) , . If (10.2) is sequential, then (10.3) is rational. The converse also holds provided that [ A :K ] < 00. Proof.
Let
Q
B
be a machine with result f. Let [ Q : K ]= nz. Applying Proposition 10.1 we obtain elements c , , . . . , c,,, E K such that
for all t 2 0. Since f , , = GFi7'Nfor n > 0, it follows that
+
for all 2 > 0. Thus p L for f.
+ . . . + c,,, is a recurrence
polynomial
10. Sequential Functions and Rationality
43 5
'I'o prove the converse assume that [ A: K ] .'
03
and t h a t f is rational.
I let
be a complete recurrence polynomial for f . Consider t h e free Kmodule KIJtwith base elements d,,, . . . , d,,, , and define the Kmorphism
111
d,,_lL
=
C

c,d,,, 1  i
1=I
Clearly
d,,(L"' $ clL'n
+
and since d i= d,,Li for 0 5 i 5 m
L"k
(10.5)
*

.'
+ CJikL")= 0
1, it follows that
+ clL'"l + . . . + C,,,L, = 0
Next define
0 = '4 6R3 KJJ1
and observe that [ A X ] <: machine
00
implies [(2:K]< 00. Consider t h e finite
Q B Q F H : A+B  &= A G fo I
with
( a @ d,)F = n @ diL aG ( a 6)d k ) H For 0
5i < m
~
CCfLI1
=
a @ d,, for
O(i<ml
1, we have
aGFiH
=
( a 0d,,)FiH = ( a @ d i ) H = afi,,
XVI. Linear Sequential Machines
436
and therefore
GFkH= f i t l
O
for
By assumption the sequence { f i , satisfies the recurrence formula given by r . From (l0.S) it follows that the G F I H also satisfy the same recurrence formula. Consequently, GH“H = f , l + l for all n 0. T h u s f is the result of A‘ I
>
Observe that in the machine . /Z constructed above we h a w
AG
+ AGF +
* ’ *
+ AGF‘”’
0
1&
and thus the machine ,d! is accessible. T h u s Corollary 5.5 implies that the minimal machine .&”is finite, i.e. that [Q,:K] < 00. COROLLARY 10.3. Iff: A [ [ z ] ]B [ [ z ] ] is seqziential and [ A X ]< 00, then [Qf:K] < 00 and the minimal machine . H, is j n i t e I
As an application we prove T H E O R E M 10.4. Let L be a commiitatizre ring, and K a subring of L sitch that [ L X ] < 00. If the power series a = C:=p=, ajrz”E K[[z]] is ra
tional over L, theii it also is rational over K. Proof.
Let
Q
L L+L
be a finite Llinear machine with result
(1.
Thus
a,, = l(GF”’H)
for n > 0. Since [Q:L] i 00 and [Z,:K] .00,it follows that [ Q : K ]i 00 and thus we may view . / i as a finite Klinear machine. T h u s by Theorem 10.2, the coefficients { a , ! } satisfy a recurrence polynomial in K [ z ] .Consequently, a E K[[z]] is rational over k’ I EXERCISE 10.1. Show that Kmodule KIrLwith its endomorphism L, constructed in the proof of Theorem 10.2, wlieti reguircied as a K[z]module is isomorpnic with K [ z ] l ( r )where r is the complete recitrrence polynomial (10.2).
11. Integral Closure and Entire Rings
43 7
Let
EXERCISE 10.2.
O
H
be a finite Klinerrr machine. z4ssiimirig [ A: K ] 00 show that the accessible port , of / i is finite. [Hint: Ilse Proposition 10.1 to show that Q<'= AG + AGF f . . . + ACF"' for some integer n1.1 ~
11. Integral Closure and Entire Rings
Let K be a commutativc ring and L a commutative ring containing K as a subring. For each elcincn 1 of L the following three properties are known to be equivalent :
(11.1)
I is the root
of a monic polynoinial in K [ z ]
(11.2) [ K [ l ] : K ] K and 1.
03
,<
where K[1] is the least subring of L containing
(1 1.3) l'here exists a subring L' of I, such that
K c I,',
1 E L',
[ L ' : K ] ,00
T h e implications (1 1.1) => (1 I .2) * (1 1.3) are clear. T h e implication (1 I .3) 3 (11.1) follows easily from Proposition 10.1. If conditions (11.1)( 11.3) hold, then 1 is said to be integral over K. The elements of L that arc integral over K form a subring K L of L and
T h e ring K L is called the integral closiire of K in L. I n the rest of this section we shall assume that the ring K is entire (i.e. is a commutative ring in which u / ! = 0 implies a = 0 or 0 = 0). We donote by 0,the field of quotients of K . T h e integral closirve of K in 0,; is dcnoted by 1.We say that K is intepally closed if K = R . PROPOSITION 11.I. Let K be integrally closed and let p , q E Qli[z] be irioriic polytionzials. I f p y E K [ 2 ] ,then p , q E K [ z ] . Proof.
Let n
d e g p and let I, be an extension field of Q!; in which
7 .
p splits. Since p is monic, we h a w p(.)
= (z

I , ) . . . ( z  1,J
XVI. Linear Sequential Machines
438
with I , , . . . , l,, E Z,. Since 11, . . . , I,, are also roots of the polynomial pq E K [ z ] ,it follows that I , , . . . , 1,, are integral over K. T h u s the elementary symmetric functions of I , , . . . , I,, are integral over K and consequently the Coefficients of p are integral over K. However they are in QKand since K is integrally closed, they must be in K. T h u s p E K [ z ] COROLLARY 11.2. Let K be integrally closed and let p , q E $Il;[.] be polynomials such that p ( 0 ) = q(0) = 1. Zf pq E K [ z ] , then p , q E K [ z ] .
Apply Proposition 11.1 to the nionic polynomials
fi
and @ noting that
P@=E € Let
PROPOSITION 11.3.
II E
(11.4)
Q,. The condition CI
E
R
implies (11.5)
There exists d
E
K

0 such that du"
E
K for all n 2 0.
If K is noetherian, then (1 1.5) inzplies (1 1.4). Proof. Assume iL E R. Then for some integer m > 0, urnis a linear combination with coefficients in K of 1, ( x , . . . , ixlnl . It follows that d Lfor any n 2 0 is a linear combination with coefficients in K of 1, (1, . . . , (x7tL 1. Let u = a/b with a, b E K and let d = bnh l . T h e n (11.5) holds. Now assume that K is noetherian and that (1 1.5) holds. Let V = d'K be the least Ksubmodule of Q, containing &I. Since (x" E V for all n 2 0, it follows that K[ix] c V . Since K is noetherian, it follows that [ K [ u ] : K< ] 00, and thus rx E R
T h e entire ring K is called completely integrally closed if conditions d E K 0, da"
E
K
U E Q ~ ;
for all n 2 0
imply a E K. Proposition 11.3 implies PROPOSITION 11.4. Each comnpletelv integrally closed ring K is integrally closed. The converse also holds ;f K is noetherian €
12. The Main Rationality Theorems
439
12. The Main Rationality Theorems
With the preparation of Section 11 the main results concerning rationality may now be stated. THEOREM 12.1 (KalmanRouchaleauWyman) Let K be an entire noetlzerian ring, let a E K[[z]] be a formal power series rational over QK and let q E Q,[z]be its lowest denominator. Then a is rational over K and
q E R[z]. THEOREM 2.2 (Chabert) Let K be a completely integrally closed ring, let a E K[[z]] be a formal power series rational ooer QK and let q E Q,i(z) be its lowest denominator. Then a is rational over K and q E K [ z ] . T h e proofs of both theorems are deferred until the next section. If K is noetherian and integrally closed, then both theorems yield the same conclusion. In particular, if K = 2, they yield the Lemma of Fatou mentioned in VIII,4. Note the subtle difference in the conclusions of the two theorems. I n the second theorem q E K [ z ] and thus q is necessarily the lowest denominator of a . In the first case q E I[ and , thus if K is] not integrally closed q need not be in K [ z ] .T h u s the lowest denominator of a over K may have a degree higher than that of q. We shall show that this indeed takes place whenever K is not integrally closed. We now show that both theorems are, each in its own way, the best possible ones. For this assume
dEK duil E

K
0,
11
E PI;
for all
n
20
Consider the formal power series
Since
(1

ux)a
=
d
it follows that a is rational over Q,< and that q = 1  uz is its lowest denominator. Assume that the conclusion of Theorem 12.2 holds. Then q E K[z] i.e. rx E K . T h u s K is completely integrally closed.
XVI. Linear Sequential Machines
440
Now assume that K is noetherian but not integrally closed. Choose R  K. Then by Proposition 11.3, d as above exists. Theorem 12.1 ensures that IX is rational over K . However q = 1  uz is not in K [ z ] and thus the lowest denominator of a over K will have to have degree > 1 and will be a multiple of q.
cx
E
A D D E N D U M TO THEOREMS 12.1 AND 12.2. Both theorems remain
valid for a
E
K"[[z]].
For v = 1, the statement reduces to Theorems 12.1 and 12.2. We now assume v > 1 and proceed by induction. T h e power series a defines two power series a' E K [ [ c ] ]and a" E K"'[[Z]], both of which are rational over &. Let q, q', q" be the lowest denominators of a, a', a". Since q'q" is a denominator of a, it follows that q divides q'q". T h u s qt = q'q" for some t E Qli[z]. Since q(0) = q'(0) = q"(0) = 1 it follows that t(0) = 1. By the inductive hypothesis q', q" E R[z]and thus qt E R[z].Corollary 11.2 now implies q E R[z] I Proof.
13. Proof of Theorems 12.1 and 12.2
We consider the formal power series M
a =
C
aizi E K [ [ z ] ]
1=U
d=
a, a ,.
a, a,
aml a , is nonzero.
aW1 . * . am s..
azm2
13. Proof of Theorems 12.1 and 12.2
441
0 . Then for some 0 5 zi i m the row a , ) , . . . , ,O,i of earlier rows. We thus obtain a polynomial Indeed assunie d
=
a,,, ,,11 is a linear combination with coefficients in
(13.3)
+ PI."' + . . . t
y
PI>
such that
holds for all 0 5 t < m. However formula (13.2) implies that if (13.4) holds for any m consecutive integers then it also holds for the nest higher one. T h u s (13.4) holds for all t 2 0. Consequently (13.3) is a complete recurrence polynomial of degree zi , m , contradicting the minimality of m. For each i >_ 0, we consider the column vector
so that
We shall consider vectors
made u p of integers
For each such vector we consider the square matrix
obtained from the m x ( m
+ r)matrix
by removing the columns with subscripts
vi=m+riji
XVI. Linear Sequential Machines
442
Note that O
... t ~ ~ l r n f r  1
We denote by D ( j ) or by
D ( j , , . . j,) +
the determinant of the square matrix (13.5). We also allow the case Y = 0. I n this case the only vector j is ( ) = @ and clearly
D ( 0 )= d
(13.6) We also have for 0 < Y
D(0, j 2 , . . . , j,)
(13.7)
=
D ( h , . . . , j,)
and thus also
D(0, 0, . . . , 0)
(13.5) In the case 0 (13.9)
=
d
< r and 0 < j , we have the fundamental formula
mil, . .
' >
jr)
tI
=
C
(  l)kji+ip1D(j1  1, j ,
?
~
.
I , . . . , j i ,l i t . * . .,. , j,)
i=l
where
j^, indidates that j , is to be omitted. If j , + i  1 > nz then
should be interpreted as zero. T o prove (13.9), we observe that the condition 0  ' j , implies w1 m 4 Y 1 and thus the column s,,,, is present in (13.5). T h e recurrence formula (13.2) gives
u , +~ '  c
~
,
Thus the determinant of (13.5) breaks up into the sum of m determinants. These will have a repeated column except when wz Y  1  u = zli for some 1 5 i 5 m, i.e, when
+
We thus obtain the sum of the determinants
13. Proof of Theorems 12.1 and 12.2
443
If we move the last column into its proper place we obtain
T h c determinant above is exactly
and this proves (13.9). From (13.6)(13.9) it follows by an easy induction that
W’, . . . , j r ) = dP(j1, . , j r ) s
where P ( j , , . . . , j,) is a polynomial in Z [ a x , ,. . . , u,,,]. Formulas (13.6)(13.9) imply
( 13.6’)
(13.7’)
P(a)= 1 P(0, j , , . . . , j,)
=
P(0, . . . , 0)
(13.8‘)
=
Y
>0
1
replaced by P.
(13.9’) Formula (13.9) with Each mononiial of degree ten in the form
if
P ( j 2 , . . . , j,.)
Y
> 0 in a I , . . . , u,,, can uniquely be writ
UJ
= (L,,
..’
clJ,
where
j = (jl? .. . jr) jl 5 j , 5 . . . 5 j , 5 nz 3
0
’
T h e monomials of degree r will now be ordered using the lexicographic ordering of the vectors j . I n this way each polynomial P i n Z[rx,, . . . , u,,] has a leading term which is a nonzero multiple of a monomial of highest degree and highest in the lexicographic order. We assert
(13.10) T h e polynomial
P ( j ) = P ( j l , . . . , j,), has degree r and its leading term is
(  l)”’(Lj where I j
I = j , $ . . .
+ j,.
0 < r, 0 r‘ j ,
XVI. Linear Sequential Machines
444
T h e proof follows from formulas (13.6’)( 13.9’) by an easy induction upon observing that the leading term of P ( j , , . . . , j,) also is the leading term of (  l)kjlP(j2, . . . , j,) since all the remaining terms in (13.9’) either have degree < r (if j , = 1) or have degree r (if j , > l), but their leading monomial is lower in the lexicographic order since it involves ajl.,which olj does not. As a consequence of (13.10) we obtain that the polynomials P ( j ) together with the polynomial P ( @ )= 1 generate the additive group of Z[u,, . . . , u,,~]. Since d P ( j ) = D ( j ) E K it further follows that
dZ[U,, . . . , U J c K
(13.11)
T h e proof of Theorem 12.2 is now immediate. Since E K for all t 2 0 and all i = 1, . . . , rn and since K is completely integrally closed it follows that u i E K and thus r ( z ) E K [ z ] . Since the minimal denominator q of a over QIi has the same coefficients as Y it follows also that q E K[z]. To prove Theorem 12.1 let
L
=
K[rw,, . . . , ( L s r ] , I‘ = d’K
Then by (13.11), L c V . Since [T/:K]< 00 and K is noetherian, it follows that [ L : K ]< oc). Since rc is rational over L, it follows from Theorem 10.4 that a is rational over K . Since, by (11.3), L c R it follows that (xi E I? for i = 1, . . . , m T h e proof deserves two comments. T h e first one is that to prove (13.1 1) the signs in the formula (13.9) are completely irrelevant and could be replaced by T h e second comment is to the effect that if we call 1 j 1 = j , + . . . j , the weight of the monomial uj then the polynomials P(j) are isobaric, i.e. all the monomials in P ( j ) have weight I j I.
*. +
References
T h e theory of linear sequential machines was presented here as a chapter in algebra well integrated with the theory of automata. However its origins lie in the theory of continuoustime linear dynamical systems which in turn grew out of mathematical physics and electrical engineering. T h e transition from the continuoustime differential approach to the discretetime algebraic approach took place roughly between 1940 and 1965.
References
445
W. Hurewicz, Filters and servo systems with pulsed data, Chapter 5, in “Theory of Servomechanisms,” M.I.1’. Itad. Lab. Series, pp. 231261, McGrawHill, New York, 1947.
This article, imbedded in a technical work on a topic in electrical engineering, dramatizes the introduction of the discrete approach. R. I:. I
R. E. Kalnian, Lectures on controllability and ohservability, Proc. C.I.M.E. Summer School (I’ontecchio hlarconi, 1968) Edizioni Cremonese, Ronia, 1969.
Contains an extensive bibliography. This publication and the two preceding references are the basis for the approach used in this chapter. Y. Rouchaleau, 13. F. Wyman and R. E. Kalman, ,%lgebraicstructure of linearmathematical systems. 111, Realization theory over a commutative ring, Proc. Nut. Acad. Sci. U.S.A. 69 (1972), 34043406.
This is the source of Theorem 12.1 J. I,. Chabert, Anneaur de Fatou, Emszgmmeut Moth. 18 (1972), 141144.
This is the source of Theorem 12.2. T h e proof given in the paper depends on an exercise in Bourbaki which uses Galois theory rather heavily. We have preferred a inore linear proof, differing from that of Theorem 12.1 only at its ending. T h e counsel and help given by R. E. Kalman during the preparation of this chapter are gratefully acknowledged.
This P a ge Intentionally Left Blank
Index
A Accessible linear sequential machine, 417 part of an automaton, 22 sequential machine, 3 3 3 state, 22 subset construction, 34 Action monoid of an automaton, 61 of a xmodule, 3 I Algebra over K , 159 unitary, 162 Alphabet, 5 Analytic Ksubset, 196 Automaton, 12 accessible, 14 accessible part of, 22 action monoid of, 61 behavior of, 14 coaccessible, 23 coaccessible part of, 23 complete, 30 completion of, 3 1 deterministic, 30 generalized, 19 1 graph of, 26 minimal, 43 normalized, 138 pushdown, 286 reduced. 46
stack, 287 trim, 23 twoway, 283 of type ( P , r ) , 72 unambiguous, 147
B Base, 5, 88 maximal, 88 Behavior of an automaton, 14 of a machine, 267 Berstel’s theorem, 215 Bernoulli distribution, 223 Bijective interpretation, 115 Bimachine, 320 complete, 320 generalized, 320 result of, 321 C
Canonical projection, 241 Category, 6 composition in, 7 large, 8 morphisms in, 7 object of, 6 small, 8 ZCategory, 352
447
448
Index
CayleyHamilton theorem, 434 Chabert’s theorem, 439 Characteristic equation, 434 Closure, 379 Coaccessible state, part of an automaton, 23 Cobham’s theorem, 109 Coding, 117 Complete automaton, 30 minimal automaton, 47 recurrence polynomial, 432 semiring, 125 sequential machine, 298 subset, 47 Completely integrally closed ring, 438 Completion of a deterministic automaton, 3 1 Composition of linear sequential machines, 424 of relations, 2 of sequential machines, 350 Congruence in a monoid, 9 right, 60 Crosssection, 256
D Denominator, 204, 43 1 lowest, 43 1 Dense subset, 94 Deterministic automaton, 30 machine, 288 Differential, 314 Distance function, 359 Division theorem, I50 Domain of a relation, 3 Dual, 415
E Edge, 12 label of, 12 Equality theorem, 143 Equivalence relation, 8 Equivalent types, 268 Expansion of real numbers, 363
F Feller’s Tauberian theorem, 2 14 Fine morphism, 6 Free monoid, base of, 5 Function, 3 bijective, 3 generalized sequential, 299 injective, 3 linear sequential, 4 1 1 sequential, 298, 360 surjective, 3
G Generalized automaton, 191 Generating function, 196 Generic sequence, 395 GinsburgRose theorem, 3 17 Graph of an automaton, 26 of a relation. 2
H Hadamard product, 197 Height, 162, 169 Hilbert curve, 376 Hurwitz product, 197
I Initial state, 12 Input alphabet, 267 code, 267 Integral closure, 437 Integrally closed ring, 43 1 Internal shuffle product, 20 Interpretation bijective, 115 Polish, 116 reversed, 115 reversed bijective, 116 Russian, 116 standard, 104 Inverse relation, 2
Index
449 K
krecognizable sequence, 394 set, 107 Ksubset, 126 K2automaton, 135 KalmanRouchaleauWyman 439 Kleene’s theorem, 175
Multiplication left, 34 right, 35 Multiplicative dependence, 109 Multiplicative relation, 164 Multiplicity, 120, 126 theorem.
L Left multiplication, 34 Left shift, 417 Lengthpreserving relation, 254 Limit theorem, 220 Linear sequential machine, 409 accessible, 4 17 direct product of, 41 1 finite, 41 1 minimal, 417 reduced, 417 result of. 409 Local set, 27 Locally finite family, 127 monoid, 170 semigroup, 170
M Machine deterministic, 288 of type a, 266 Turing, 288 Maximal base, 88 prefix, 92 Mealy machine, 299 Minimal automaton, 43 linear sequential machine, 417 sequential machine, 338 Modules, 3 1 Monoid, 3 morphism of, 4 syntactic, 62 Moore machine, 299, 3 12
N Natural factorization mapping, 9 Nextstate function, 297 Nonsingular subset, 188 Normalization procedure, 139 Normalized automaton, 138 Null path, 13 0
output alphabet, 267 code, 267 extended, 297 function, 297 module, 298 module, generalized, 299
P Palindrome, 56 Parallel composition, 422 Parallel product, 354 Path in an automaton, 13 label of, 13 length of, 13 successful, 14 Peano curve, 37 1 Period, 100 of an analytic function, 209 Partial function, 3 Polish interpretation, 116 Positive semiring, 125 Positive rational function, 282 Post correspondence problem, 159 Prefix, 78 maximal, 92 Primary module, 428 Proper state mapping, 39 Purely singular subset, 189 Pushdown automaton, 286
450
Index
Q Quotient criterion, 55
R Rational closure, 163 expression, 167 formal power series, 204 Ksubset, 163 operation, 161 relation, 236 Rationally closed subset, 161 Recognizable Ksubset, 139 subset, 14 power series, 199 Recurrence formula, 205 polynomial, 432 Recurrent state, 97 Reduced automaton, 46 linear sequential machine, 417 output module, 338 Relation, 2 composition of, 2 computed by a machine, 267 domain of, 2 equivalence, 8 graph of, 2 inverse of, 2 lengthpreserving, 254 multiplicative, 164 positive rational, 282 rational, 236 RemakKrullSchmidt theorem, 427 Replacement procedure, 273 Restriction mapping, 40 Result of a bimachine, 321 linear sequential machine, 409 sequential machine, 298 Reversal of an automaton, 18 function, 18 Reversed interpretation, 115 Right congruence, 60 Right multiplication, 34 Right shift, 406 Russian interpretation, 116
S 2module, 31 action of, 3 1 complete, 31 Schutzenberger’s theorem, 230 Semigroup, 6 Semiring. 122 complete, 125 positive, 125 Sequential machine, 296 accessible, 333 complete, 298 generalized, 299 minimal, 417 result of, 298 statedependent, 3 12 Series composition, 425 Shuffle product, 19 internal, 20 Singleton, 127 SkolemMahlerLech theorem, 206 Stack automaton, 287 Standard interpretation, 104 Standard pair representation, 105 State, 12 accessible, 22 coaccessible, 23 initial, 12 recurent, 97 terminal, 12 Statemapping of automata, 38 complete, 412 of linear sequential machines, 412 proper, 38 of sequential machines, 330 State relation, 41 1 Stem, 100 Strong minimization problem, 343 Subalgebra, 160 Subcategory, 7 full, 7 Subdivision property, 71 Submonoid, 4 Subset construction, 33 accessible, 34 Substitution, 173 Subtraction theorem, 153 Successful path, 14 Support, 127
Index
451
Syntactic monoid, 62 morphism, 62 Synthesis problem, 348
T Terminal state, 12 subset of a machine, 268 Thue sequence, 399 Trim automaton, 23 Trivial path, 13 Transducer, 273 accelerated, 276 Transition matrix, 14 Turing machine, 288 Twoway automaton, 283 Type of a machine, 266
U Ultimately periodic sequence, 362 Ultimately periodic set, 101 Unambiguous automaton, 147 rational operations, 186
relation, 1 3 1 subset, 126 Uniform distribution, 224 Unitary, 77 algebra, 162 component, 77 monoid, 80 subset, 76 Unitaryprefix decomposition, 85 Unitaryprefix monomial, 85
V Very fine morphism, 6
W Word, 5 initial segment of, 6 segment of, 5 terminal segment of, 6
z Zero in a monoid, 64
This P a ge Intentionally Left Blank