Model Reduction of Finite State Machines by Contraction

Similar documents
Minimal DFA. minimal DFA for L starting from any other

1 Nondeterministic Finite Automata

Formal Languages and Automata

Designing finite automata II

Convert the NFA into DFA

State Minimization for DFAs

AUTOMATA AND LANGUAGES. Definition 1.5: Finite Automaton

Lecture 09: Myhill-Nerode Theorem

Formal languages, automata, and theory of computation

12.1 Nondeterminism Nondeterministic Finite Automata. a a b ε. CS125 Lecture 12 Fall 2016

Compiler Design. Fall Lexical Analysis. Sample Exercises and Solutions. Prof. Pedro C. Diniz

12.1 Nondeterminism Nondeterministic Finite Automata. a a b ε. CS125 Lecture 12 Fall 2014

CMPSCI 250: Introduction to Computation. Lecture #31: What DFA s Can and Can t Do David Mix Barrington 9 April 2014

Nondeterminism and Nodeterministic Automata

Assignment 1 Automata, Languages, and Computability. 1 Finite State Automata and Regular Languages

Coalgebra, Lecture 15: Equations for Deterministic Automata

CS 373, Spring Solutions to Mock midterm 1 (Based on first midterm in CS 273, Fall 2008.)

1. For each of the following theorems, give a two or three sentence sketch of how the proof goes or why it is not true.

Speech Recognition Lecture 2: Finite Automata and Finite-State Transducers

Chapter 2 Finite Automata

CS103B Handout 18 Winter 2007 February 28, 2007 Finite Automata

The University of Nottingham SCHOOL OF COMPUTER SCIENCE A LEVEL 2 MODULE, SPRING SEMESTER LANGUAGES AND COMPUTATION ANSWERS

Regular Expressions (RE) Regular Expressions (RE) Regular Expressions (RE) Regular Expressions (RE) Kleene-*

80 CHAPTER 2. DFA S, NFA S, REGULAR LANGUAGES. 2.6 Finite State Automata With Output: Transducers

Java II Finite Automata I

Chapter Five: Nondeterministic Finite Automata. Formal Language, chapter 5, slide 1

More on automata. Michael George. March 24 April 7, 2014

Non Deterministic Automata. Linz: Nondeterministic Finite Accepters, page 51

CS415 Compilers. Lexical Analysis and. These slides are based on slides copyrighted by Keith Cooper, Ken Kennedy & Linda Torczon at Rice University

Regular expressions, Finite Automata, transition graphs are all the same!!

Non-Deterministic Finite Automata. Fall 2018 Costas Busch - RPI 1

Lecture 08: Feb. 08, 2019

Lexical Analysis Finite Automate

DFA minimisation using the Myhill-Nerode theorem

CSE : Exam 3-ANSWERS, Spring 2011 Time: 50 minutes

The size of subsequence automaton

Grammar. Languages. Content 5/10/16. Automata and Languages. Regular Languages. Regular Languages

On Decentralized Observability of Discrete Event Systems

1. For each of the following theorems, give a two or three sentence sketch of how the proof goes or why it is not true.

CMSC 330: Organization of Programming Languages

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. Comparing DFAs and NFAs (cont.) Finite Automata 2

CS 310 (sec 20) - Winter Final Exam (solutions) SOLUTIONS

Finite Automata-cont d

Tutorial Automata and formal Languages

CHAPTER 1 Regular Languages. Contents

Theory of Computation Regular Languages. (NTU EE) Regular Languages Fall / 38

CSCI 340: Computational Models. Kleene s Theorem. Department of Computer Science

Homework 3 Solutions

Thoery of Automata CS402

Finite Automata. Informatics 2A: Lecture 3. Mary Cryan. 21 September School of Informatics University of Edinburgh

I1 = I2 I1 = I2 + I3 I1 + I2 = I3 + I4 I 3

Finite Automata. Informatics 2A: Lecture 3. John Longley. 22 September School of Informatics University of Edinburgh

Centrum voor Wiskunde en Informatica REPORTRAPPORT. Supervisory control for nondeterministic systems

FABER Formal Languages, Automata and Models of Computation

Intermediate Math Circles Wednesday, November 14, 2018 Finite Automata II. Nickolas Rollick a b b. a b 4

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. NFA for (a b)*abb.

Bases for Vector Spaces

Finite Automata Theory and Formal Languages TMV027/DIT321 LP4 2018

First Midterm Examination

Section: Other Models of Turing Machines. Definition: Two automata are equivalent if they accept the same language.

CISC 4090 Theory of Computation

Harvard University Computer Science 121 Midterm October 23, 2012

Theory of Computation Regular Languages

Table of contents: Lecture N Summary... 3 What does automata mean?... 3 Introduction to languages... 3 Alphabets... 3 Strings...

Myhill-Nerode Theorem

5. (±±) Λ = fw j w is string of even lengthg [ 00 = f11,00g 7. (11 [ 00)± Λ = fw j w egins with either 11 or 00g 8. (0 [ ffl)1 Λ = 01 Λ [ 1 Λ 9.

Scanner. Specifying patterns. Specifying patterns. Operations on languages. A scanner must recognize the units of syntax Some parts are easy:

Speech Recognition Lecture 2: Finite Automata and Finite-State Transducers. Mehryar Mohri Courant Institute and Google Research

Parse trees, ambiguity, and Chomsky normal form

1 From NFA to regular expression

Supervisory Control of Petri Nets with Language Specifications

Normal Forms for Context-free Grammars

Talen en Automaten Test 1, Mon 7 th Dec, h45 17h30

Worked out examples Finite Automata

Finite-State Automata: Recap

Anatomy of a Deterministic Finite Automaton. Deterministic Finite Automata. A machine so simple that you can understand it in less than one minute

Converting Regular Expressions to Discrete Finite Automata: A Tutorial

Let's start with an example:

CS 311 Homework 3 due 16:30, Thursday, 14 th October 2010

Deterministic Finite Automata

Revision Sheet. (a) Give a regular expression for each of the following languages:

First Midterm Examination

Formal Language and Automata Theory (CS21004)

NFA DFA Example 3 CMSC 330: Organization of Programming Languages. Equivalence of DFAs and NFAs. Equivalence of DFAs and NFAs (cont.

CS 267: Automated Verification. Lecture 8: Automata Theoretic Model Checking. Instructor: Tevfik Bultan

Non-deterministic Finite Automata

Homework Solution - Set 5 Due: Friday 10/03/08

CHAPTER 1 Regular Languages. Contents. definitions, examples, designing, regular operations. Non-deterministic Finite Automata (NFA)

1.4 Nonregular Languages

GNFA GNFA GNFA GNFA GNFA

CS:4330 Theory of Computation Spring Regular Languages. Equivalences between Finite automata and REs. Haniel Barbosa

Homework 4. 0 ε 0. (00) ε 0 ε 0 (00) (11) CS 341: Foundations of Computer Science II Prof. Marvin Nakayama

Closure Properties of Regular Languages

1.3 Regular Expressions

a,b a 1 a 2 a 3 a,b 1 a,b a,b 2 3 a,b a,b a 2 a,b CS Determinisitic Finite Automata 1

PART 2. REGULAR LANGUAGES, GRAMMARS AND AUTOMATA

Non-Deterministic Finite Automata

p-adic Egyptian Fractions

CSCI 340: Computational Models. Transition Graphs. Department of Computer Science

Review of Gaussian Quadrature method

Transcription:

Model Reduction of Finite Stte Mchines y Contrction Alessndro Giu Dip. di Ingegneri Elettric ed Elettronic, Università di Cgliri, Pizz d Armi, 09123 Cgliri, Itly Phone: +39-070-675-5892 Fx: +39-070-675-5900 Emil: giu@diee.unic.it Astrct The pper discusses n pproch to the model reduction of discrete event systems represented y finite stte mchines. A set of good reduced order pproximtions of deterministic finite stte mchine M cn e efficiently computed y looking t its contrctions, i.e., finite stte mchines constructed from M y merging two sttes. In some prticulr cse, it is lso possile to prove tht the pproximtions thus constructed re infiml, in the sense tht there do not exist etter pproximtions with the sme numer of sttes. The pper lso defines merit function to choose, mong set of pproximtions, the est one with respect to given oserved ehvior. Pulished s: A. Giu, Model Reduction of Finite Stte Mchines y Contrctions, IEEE Trns. on Automtic Control, Vol. 46, No. 5, pp. 797 801, My 2001. 1

1 Introduction Model reduction techniques hve een used in control theory to pproximte high order systems with simpler ones tht still cpture the ehvior of the originl complex systems. In this pper we consider the sme prolem in the frmework of discrete event systems [7]. In prticulr, discrete event system will e modeled y finite stte mchine (FSM) nd its ehvior will e given y the lnguge generted. A reduced order pproximtion of miniml deterministic FSM M with n sttes is deterministic FSM M with n < n sttes such tht L(M ) L(M). Let M e n pproximtion of order n of M; we sy tht M is infiml if there does not exist nother pproximtion M of order n n such tht L(M ) L(M ) L(M). Computing infiml pproximtions is complex tsk. The pper shows how set of good ut possily not infiml pproximtions of given miniml deterministic FSM M cn e computed efficiently y looking t contrctions of M, i.e., FSMs constructed from M y merging 2 sttes. In some prticulr cse, it cn lso e proven tht ll pproximtions in the set thus constructed re infiml. The pper lso discusses how, given set of pproximtions of FMS M, it is possile to define merit function to choose the est pproximtion with respect to given oserved ehvior L o L(M). The two requirements of hving smll order model nd tight lnguge pproximtion re conflicting. The procedure presented in this pper cn e recursively pplied, strting with given FSM nd computing contrctions until stisfctory trde-off etween order of the model nd degree of lnguge pproximtion is reched. The proposed pproch is prticulrly useful in the cse of systems composed of interconnected susystems. It is well know tht composing the FMS modules tht descrie the different susystems e.g., using the concurrent composition opertor [7] the numer of sttes of the resulting overll model grows exponentilly. The reduction of even few sttes in ech FMS module my led to significnt simplifiction of the resulting overll model. The pper is structured s follows. In Section II the nottion used is presented. In Section III contrctions re defined nd their properties re studied. In Section IV n efficient lgorithm for computing set of good reduced order pproximtions y contrction is presented. In Section V quntittive mesure to choose the est mong set of reduced order pproximtions is given. 2 Bckground A finite stte mchine [3, 4] is 5-tuple M = (Q, Σ, δ, q 0, F ), where: Q is finite stte set, Σ is finite lphet of symols, δ : Q Σ 2 Q is the trnsition reltion, q 0 Q is the initil stte, F Q is set of finl sttes. The trnsition reltion δ is usully extended to pply to 2

stte nd string, rther thn stte nd symol. Let w = 1 2 r Σ nd q δ(q, w). Then the following is legl move of M: m(q, w) = q[ 1 q 1 [ 2 q r 1 [ r q = q[w q nd we define m Q (q, w) = {q 1,, q r 1 }. A finite stte mchine is sid to e deterministic (DFSM) if the trnsition reltion is such tht δ(q, ) is singleton set or is not defined. The lnguge generted y FSM M is the set of ll strings w generted with move tht strts from the initil stte nd reches finl stte, i.e., L(M) = {w Σ δ(q 0, w) F }. Note tht the ove definitions re slightly different from clssic definitions of utomt ut re consistent with the modern discrete event systems terminology. As n exmple, in the clssic definition of deterministic utomt it is required tht δ(q, ) e defined for ll q Q nd for ll Σ. Note lso tht in the discrete event system pproch [7] there re usully two different notions of lnguges. The mrked ehvior is identicl to the lnguge L(M) defined ove. The closed ehvior is defined s the set of strings generted with move tht strts from the initil stte nd reches ny stte of M. Without ny loss of generlity, the pper will only consider mrked lnguges, since ny closed lnguge cn e considered s mrked lnguge if one lets the set of finl sttes F e identicl to the set of ll sttes Q. A DFSM M = (Q, Σ, δ, q 0, F ) with n sttes is sid to e miniml [5, 6] if there does not exist DFSM M = (Q, Σ, δ, q 0, F ) with n < n sttes such tht L(M ) = L(M). Note tht in the clssic definition of miniml FSM there is lwys dump stte tht cn e reched y ll strings tht cnnot e continued into string in L(M). Since we do not require tht δ(q, ) e defined for ll q Q nd for ll Σ, miniml DFSM ccording to our definition will e rechle (i.e., there is pth from q 0 to ny other stte) nd corechle (i.e., there is pth from ny stte q to stte in F ). Let M e miniml DFSM with n sttes. It is not possile to find DFSM M with n < n sttes tht genertes L(M). However, we cn look for n M with n < n sttes tht genertes L(M ) L(M) s wy to pproximte M. Definition 1. Let M = (Q, Σ, δ, q 0, F ) e miniml DFSM with n sttes. A lnguge L Σ is n pproximtion of L(M) if L L(M). An pproximtion L is order n implementle if there exists miniml DFSM M with n < n sttes such tht L = L(M ). We lso sy tht M implements L nd tht it is n pproximtion of order n of M. An order n implementle pproximtion L of L(M) is infiml if there does not exist nother DFSM M with n n sttes such tht L L(M ) L(M). If M implements L, we sy tht M is n infiml pproximtion of order n of M. 3

Infiml pproximtions of miniml DFSM M re the est pproximtions, in the sense tht, comptily with the stte spce size limittion, their ehvior contins the ehvior of M nd is s close s possile to it. 3 Contrctions Given miniml DFSM M with n sttes how cn one find n infiml pproximtion of order n < n? One possiility is tht of computing ll DFSMs with n sttes over the sme lphet Σ of M nd of looking for those tht stisfy the definition of infiml pproximtions. However, this pproch is clerly infesile in light of the following proposition. Proposition 1. There re (n + 1) m n 2 n different DFSMs with n sttes nd lphet Σ of crdinlity m. Proof: According to the definition of DFSM given in the previous section, for ll q Q nd ll Σ there re n + 1 possile choices of δ(q, ), keeping in mind tht it my e undefined. Thus there re (n + 1) m n different possile choices of δ. Finlly since F is suset of Q, there re 2 n different possile choices of F. We will explore the possiility of using contrctions, whose structure cn e esily computed, s mens of finding pproximtions of given miniml DFSM M. Definition 2. Let M = (Q, Σ, δ, q 0, F ) e DFSM nd let q i, q j Q, with q i q j. The (i, j)- contrction of M is the FSM M i,j otined from M y merging sttes q i nd q j. Formlly, M i,j = (Q, Σ, δ, q 0, F ), where: the stte set is Q = Q {q new } \ {q i, q j }. the trnsition reltion is δ(q, ), if q Q Q δ(q, ) Q Q ; δ q new, if q Q Q δ(q, ) {q i, q j }; (q, ) = δ(q i, ) δ(q j, ), if q = q new δ(q i, ) δ(q j, ) Q Q ; δ(q i, ) δ(q j, ) {q new } \ {q i, q j }, otherwise. { the initil stte is q 0 = q 0, if q 0 Q Q ; q new, otherwise. { the set of finl sttes is F F, if F Q ; = F {q new } \ {q i, q j }, otherwise. Note tht M i,j my well e non-deterministic even if M is DFSM. In Figure 1 it is shown DFSM M nd its three possile contrctions. M 0,1 is non-deterministic nd non-miniml; M 0,2 nd M 1,2 re deterministic nd miniml. Let us consider some properties of contrctions. 4

, q 0 q 1 q 2 q new q 2 M M 0,1 q new, q 1 q 0 q new M 0,2 M 1,2 Figure 1: A FSM M nd its contrctions. Lemm 1. Let M = (Q, Σ, δ, q 0, F ) e DFSM nd let M i,j = (Q, Σ, δ, q 0, F ) e its (i, j)- contrction. Then [( ) ] L(M i,j ) = L(M) L i 0 L j 0 L i,j (L i L j ) where: L k h = {w Σ δ(q h, w) = q k ; q i, q j m Q (q h, w)}, L h = ( {w Σ δ(q h, w) ) F ; q i, q j m Q (q h, w)}, L i,j = L i i Lj i Li j Lj j. Proof: We will just give sketch of the proof. First note tht from the definition of contrction, it follows tht for ll w such tht q new m Q (q 0, w): ( ) δ (q 0, w) = q new w L i 0 Lj 0, nd for ll w such tht q new m Q (q new, w): δ (q new, w) = q new w L i,j, δ (q new, w) F w (L i L j ). Since word w L(M i,j ) is generted either with move m(q 0, w) = q 0 [w q f F, where q new m Q (q 0, w), or with move m(q 0, w) = q 0 [w 0 q new [w r 1 q new [w r q f F, where q new m Q (q 0, w 0) nd for ll k > 0, q new m Q (q new, w k ), it is possile to prove the result of the lemm. Proposition 2. Let M = (Q, Σ, δ, q 0, F ) e DFSM nd let M i,j = (Q, Σ, δ, q 0, F ) e its (i, j)-contrction. Then L(M i,j ) L(M). Also if M is miniml DFSM then L(M i,j ) L(M). Proof: The fct tht L(M i,j ) L(M) trivilly follows from Lemm 1. 5

q 0 q 1 q new M M 0,1 Figure 2: A non-miniml FSM M nd its contrction. If M is miniml, then sttes q i nd q j re distinguishle, i.e., there must exist string w i such tht, sy, δ(q i, w i ) is in F while δ(q j, w i ) is not defined or is not in F. Now, let w 0,j e string such tht δ(q 0, w 0,j ) = q j. Then w 0,j w i L(M) while y Lemm 1 w 0,j w i L 0,j L i L(M i,j ). According to the ove proposition, the lnguges generted y contrctions of DFSM M re pproximtions of L(M). Exmple 1. The requirement tht M e miniml in Proposition 2 cn e explined y the following exmple. Figure 2 shows DFSM M tht is not miniml nd its contrction M 0,1. It cn e seen tht L(M) = L(M 0,1 ) =. Exmple 2. Not ll lnguges generted y contrctions re infiml pproximtions. Consider the miniml DFSM M in Figure 1 nd its three contrctions. The lnguge generted y M 0,1 is L(M 0,1 ) = Σ, i.e., it is superset of the lnguges generted y the contrctions M 0,2 nd M 1,2. In this cse, however, it is possile to prove tht M 0,2 nd M 1,2 re the only infiml pproximtions of M of order 2. To prove this one my construct ll pproximtions of M of order 2. Exmple 3. Not ll infiml pproximtions of order n 1 of miniml DFSM M with n sttes re contrctions. Consider the DFSM M with 4 sttes nd the DFSM M with 3 sttes in Figure 3. M is n pproximtion of M since L(M ) L(M) ut it cn e esily checked tht it is not contrction, ecuse its lnguge is not superset of ny contrction of M. Hence, there exists n infiml pproximtion of M of order 3 tht is not contrction. Note, however, tht in this cse it cn lso e shown tht for ll q i, q j, L(M i,j ) is not superset of L(M ). Hence one cnnot conclude tht the contrctions of M re not infiml pproximtions. Contrctions re good cndidtes for infiml pproximtions of miniml DFSM M. There re some cses in which it is possile to prove tht ny implementle pproximtion of L(M) is superset of lnguge generted y some contrction of L(M). Theorem 1. Let M = (Q, Σ, δ, q 0, F ) e miniml DFSM with n sttes nd let M = (Q, Σ, δ, q 0, F ) e miniml DFSM with n < n such tht L(M ) L(M). Let h : Q 2 Q e the mpping defined y q 0 h(q 0); q h(q), if q h( q) δ( q, ) = q δ ( q, ) = q. 6

q 0 M q 1 q 2 d c q 3 e q' 0 M' q' 1 q' 2 c,e d,e Figure 3: A miniml FSM M with 4 sttes nd n pproximtion of order 3. If h(q) is singleton set for ll q Q then there exists n (i, j)-contrction of M such tht L(M ) L(M i,j ) L(M). Proof: Since h(q) is singleton set nd n > n, there must exist two sttes q i, q j Q such tht h(q i ) = h(q j ) = q. Then it is possile to prove tht L(M ) L(M i,j ). In fct, y the definition of h nd the fct tht L(M ) L(M) it follows tht if δ(q, w) = q then δ (h(q), w) = h( q) while h(f ) F. Hence with the nottion of Lemm 1 w L i 0 L j 0, δ (q 0, w) = q, w L i i L j i Li j L j j, δ (q, w) = q, w L i L j, δ (q, w) F, nd ny string in the set L(M i,j ), whose expression is given in Lemm 1, cn lso e generted y M. Note 1. There re DFSMs M such tht, regrdless of the structure of M, the imge of h(q), s defined in the ove theorem, is singleton set. As n exmple, let M e DFSM with tree-like grph. Since there is only one pth from the initil stte to ny other stte nd since M is deterministic, h(q) cn only ssume single vlue. Thus, for this clss of DFSMs it follows from Theorem 1 tht if ll lnguges generted y contrctions re implementle then ll infiml pproximtions of order n 1 of L(M) re contrctions. The uthor s feeling is tht the implementle lnguges generted y contrctions of miniml DFSM M re lmost lwys infiml pproximtions of L(M) ecuse no counterexmple hs een found to disprove the following conjecture. Conjecture 1. Let M e miniml DFSM. Let L = {L(M i,j ) M h,k L(M i,j ) L(M h,k )}. Then ll implementle lnguges in L re infiml pproximtions of L(M). 7

q 0 q 1 q 2 M Figure 4: A miniml DFSM M in Exmple 4. 4 Implementing n pproximtion In the ove section we hve seen how to construct pproximtions of the lnguge generted y given miniml DFSM M y looking t its contrctions. We hve lso noted tht contrction is not lwys deterministic. Thus, to implement contrction lnguge we my hve to convert contrction M i,j into deterministic FSM. The following exmples will show severl possile cses. Exmple 4. In this exmple we consider contrctions tht re non-miniml. Consider the miniml DFSM with 3 sttes in Figure 4. It is esy to see tht ll its contrctions generte the lnguge L =, tht cn e generted y single stte DFSM. Since ll contrctions of M hve 2 sttes they re not miniml. Note tht M 0,1 is non-deterministic, while M 0,2 nd M 1,2 re deterministic. Exmple 5. In this exmple we show tht not ll lnguges generted y contrction re implementle. Consider the miniml DFSM M with 5 sttes in Figure 5. The contrction M 0,2 is not deterministic. When we compute the miniml DFSM tht genertes L(M 0,2 ) we otin the DFSM M0,2 D tht hs 6 sttes. The following lgorithm cn e used to compute set M of good pproximtions of miniml DFMS. Algorithm 1. Let M e miniml DFSM with n sttes. 1. Construct the set M c of ll contrctions of M. 2. Let M m e the set constructed s follows. For ll contrctions M i,j M c : () If M i,j is deterministic let M D i,j = M i,j, else let M D i,j e DFSM equivlent to M i,j. () If Mi,j D is miniml let M i,j m = M i,j D, else let M i,j m e miniml DFSM equivlent to Mi,j D. (c) If the numer of sttes of M m i,j is n m < n, let M m i,j Mm. 3. Let M = {M M m M M m L(M ) L(M )}. M is set of pproximtions of M of order less thn n. Some comments on the complexity of the lgorithm. ( ) n n (n 1) In step 1, there re = contrctions. 2 2 8

q 0 q 1 q 3 q 2 c d q 1 q new c q 4 d q 3 e M M 0,2 q 4 e q new {q 1,q 3 } c q 1 c d M D 0,2 {q new,q 4 } e q 4 e q 3 d Figure 5: A DFSM M nd its contrction M 0,2 whose lnguge cnnot e implemented. 9

Step 2.() is the computtionlly hrdest step. In fct, DFSM M D equivlent to nondeterministic one M with n sttes my hve up to 2 n sttes [3]. This mens tht in generl the determiniztion cnnot e done in polynomil time or spce. In step 2.(), the minimiztion of DFSM with n sttes cn e done with n n log n lgorithm given y Hopcroft [2]. In step 3, one cn use the lgorithm given in [1] pge 144 to check if L(M 1 ) L(M 2 ). If M 1 hs n 1 sttes nd M 2 hs n 2 sttes the complexity of the lgorithm is n G(n), where n = n 1 + n 2 nd G(n) 5 for n 2 65536. 5 Choosing the est pproximtion In this section we consider the following prolem. Given set M of pproximtions of given miniml DFSM M nd finite set of oserved strings L o L(M), choose mong ll FSMs in M the est pproximtion reltive to the oserved ehvior, i.e., the pproximtion M tht mximizes suitle function f(l 0, M ). First of ll, given M = (Q, Σ, δ, q 0, F ) we define two functions ν, µ : Q IN. The first one is such tht ν(q ) = 1 if q F (i.e., if it is finl stte), else ν(q ) = 0. The second one is such tht µ(q ) = { Σ δ (q, ) is defined }, i.e., it counts the numer of events enled t q. If we hve no dditionl knowledge, we my ssume tht t ech step while generting string w nd eing in stte q, M my choose with equl proility to ccept the string generted so fr (if q is finl stte) or to continue, executing one of the events enled t q. The totl numer of choices t ech stte is thus ν(q ) + µ(q ). Thus, let w = 1 2 r e generted y M with the move We define merit function m(q 0, w) = q 0[ 1 q 1[ 2 q r 1[ r q r. f(w, M ) = r i=0 1 ν(q i ) + µ(q i ), whose vlue is mesure of the likelihood tht w is generted y M. Exmple 6. Consider the DFSM M in Figure 1 nd its two pproximtions M 0,2, nd M 1,2. The string w 1 = () k is more likely to e generted y M 1,2 since f(w 1, M 0,2 ) = ( 1 2 1 ) k 1 3 2 = 1 2 6 k, while f(w 1, M 1,2 ) = ( 1 1 ) k 1 = 1 3 3 k. 10

On the contrry, the string w 2 = 2k for k > 1 is more likely to e generted y M 0,2 since f(w 2, M 0,2 ) = 1 ( 1 2 3 1 ) k = 1 2 2 6 k, while ( 1 f(w 2, M 1,2 ) = 1 3 1 ) k = 1 3 9 k. Next proposition shows tht f is good mesure for choosing mong pproximtions in the sense tht it tends to give higher rting to infiml pproximtions. Proposition 3. Let M = (Q, Σ, δ, q 0, F ) nd M = (Q, Σ, δ, q 0, F ) e DFSMs such tht L(M) L(M ). Then for ll w L(M), f(w, M) f(w, M ). Proof: Let w = 1 2 r e generted y M with the move q 0 [ 1 q 1 [ r q r, nd y M with the move q 0 [ 1 q 1 [ r q r. Since L(M) L(M ), it follows tht q i F if q i F, i.e., ν(q i ) ν(q i); δ(q i, ) is defined if δ(q i, ) is defined, i.e., µ(q i ) µ(q i). Hence f(w, M) f(w, M ). The merit function f cn e extended to set of strings. If L L(M ), we define f(l, M ) = w L f(w, M ). Thus, given set M of pproximtions of given miniml DFSM M nd finite set of oserved strings L o, we sy tht the est pproximtion of M with respect to f nd L o is the DFSM M M such tht f(l o, M ) = mx M M [f(l o, M )]. Different merit functions could e used if we ssume tht some knowledge on the proility of occurrence of different events in Σ is known. 6 Conclusions The pper hs presented introductory work on the model reduction of discrete event systems represented y finite stte mchines. It ws shown how set of good ut possily not infiml pproximtions of given miniml DFSM M cn e computed efficiently y looking t contrctions of M. In some prticulr cse, it is lso possile to prove tht the pproximtions thus constructed re infiml. 11

The pper hs lso discussed how, given set of pproximtions of FMS M, it is possile to define merit function to choose the est pproximtion with respect to given oserved ehvior L o L(M). The pproch presented in the pper leves open some interesting prolems. Firstly, we do not know if the conjecture presented in Section 3 is true; it should e possile to prove it or to find counterexmple to disprove it. Secondly, it my e interesting to try to pply the contrction technique to other grphicl models of discrete event systems such s Petri nets. References [1] A.V. Aho, J.E. Hopcroft, J.D. Ullmn, The Design nd Anlysis of Computer Algorithms, Addison-Wesley, 1974. [2] J.E. Hopcroft, An n log n Algorithm for Minimizing the Sttes in Finite Automton, The Theory of Mchines nd Computtions, Z. Kohvi (Ed.), pp. 189 196, Acdemic Press, 1971. [3] J.E. Hopcroft, J.D. Ullmn, Introduction to Automt Theory, Lnguges, nd Computtion, Addison-Wesley, 1979. [4] H.R. Lewis, C.H. Ppdimitriou, Elements of the Theory of Computtion, Prentice-Hll, 1981. [5] J. Myhill, Finite Automt nd the Representtion of Events, WADD TR-57-624, pp. 112 137, Wright Ptterson AFB, Ohio. [6] A. Nerode, Liner Automton Trnsformtions, Proceedings AMS, Vol. 9, pp. 541 544, 1958. [7] P.J. Rmdge, W.M. Wonhm, The Control of Discrete Event Systems, Proceedings IEEE, Vol. 77, No. 1, pp. 81 98, Jnury, 1989. 12