On Recognizable Timed Languages



Similar documents
Regular Sets and Expressions

Homework 3 Solutions

EQUATIONS OF LINES AND PLANES

One Minute To Learn Programming: Finite Automata

Reasoning to Solve Equations and Inequalities

Bayesian Updating with Continuous Priors Class 13, 18.05, Spring 2014 Jeremy Orloff and Jonathan Bloom

Section 5-4 Trigonometric Functions

Appendix D: Completing the Square and the Quadratic Formula. In Appendix A, two special cases of expanding brackets were considered:

Polynomial Functions. Polynomial functions in one variable can be written in expanded form as ( )

4.11 Inner Product Spaces

A.7.1 Trigonometric interpretation of dot product A.7.2 Geometric interpretation of dot product

CS99S Laboratory 2 Preparation Copyright W. J. Dally 2001 October 1, 2001

LINEAR TRANSFORMATIONS AND THEIR REPRESENTING MATRICES

Example A rectangular box without lid is to be made from a square cardboard of sides 18 cm by cutting equal squares from each corner and then folding

9 CONTINUOUS DISTRIBUTIONS

Solution to Problem Set 1

Example 27.1 Draw a Venn diagram to show the relationship between counting numbers, whole numbers, integers, and rational numbers.

and thus, they are similar. If k = 3 then the Jordan form of both matrices is

Or more simply put, when adding or subtracting quantities, their uncertainties add.

On the expressive power of temporal logic

0.1 Basic Set Theory and Interval Notation

FAULT TREES AND RELIABILITY BLOCK DIAGRAMS. Harry G. Kwatny. Department of Mechanical Engineering & Mechanics Drexel University

Second Term MAT2060B 1. Supplementary Notes 3 Interchange of Differentiation and Integration

P.3 Polynomials and Factoring. P.3 an 1. Polynomial STUDY TIP. Example 1 Writing Polynomials in Standard Form. What you should learn

1.2 The Integers and Rational Numbers

PROF. BOYAN KOSTADINOV NEW YORK CITY COLLEGE OF TECHNOLOGY, CUNY

Integration by Substitution

2 DIODE CLIPPING and CLAMPING CIRCUITS

Regular Languages and Finite Automata

Vectors Recap of vectors

Graphs on Logarithmic and Semilogarithmic Paper

FORMAL LANGUAGES, AUTOMATA AND THEORY OF COMPUTATION EXERCISES ON REGULAR LANGUAGES

MODULE 3. 0, y = 0 for all y

Pentominoes. Pentominoes. Bruce Baguley Cascade Math Systems, LLC. The pentominoes are a simple-looking set of objects through which some powerful

Unambiguous Recognizable Two-dimensional Languages

COMBINATORIAL HOPF ALGEBRAS FROM PROS

All pay auctions with certain and uncertain prizes a comment

5.2. LINE INTEGRALS 265. Let us quickly review the kind of integrals we have studied so far before we introduce a new one.

Use Geometry Expressions to create a more complex locus of points. Find evidence for equivalence using Geometry Expressions.

flex Regular Expressions and Lexical Scanning Regular Expressions and flex Examples on Alphabet A = {a,b} (Standard) Regular Expressions on Alphabet A

SPECIAL PRODUCTS AND FACTORIZATION

Math 314, Homework Assignment Prove that two nonvertical lines are perpendicular if and only if the product of their slopes is 1.

Babylonian Method of Computing the Square Root: Justifications Based on Fuzzy Techniques and on Computational Complexity

Solving the String Statistics Problem in Time O(n log n)

Math 135 Circles and Completing the Square Examples

Distributions. (corresponding to the cumulative distribution function for the discrete case).

MATH 150 HOMEWORK 4 SOLUTIONS

Automated Grading of DFA Constructions

Unit 6: Exponents and Radicals

Operations with Polynomials

1. Find the zeros Find roots. Set function = 0, factor or use quadratic equation if quadratic, graph to find zeros on calculator

Java CUP. Java CUP Specifications. User Code Additions You may define Java code to be included within the generated parser:

Section 7-4 Translation of Axes

Factoring Polynomials

. At first sight a! b seems an unwieldy formula but use of the following mnemonic will possibly help. a 1 a 2 a 3 a 1 a 2

Mathematics. Vectors. hsn.uk.net. Higher. Contents. Vectors 128 HSN23100

Integration. 148 Chapter 7 Integration

PHY 140A: Solid State Physics. Solution to Homework #2

Binary Representation of Numbers Autar Kaw

Algebra Review. How well do you remember your algebra?

A Visual and Interactive Input abb Automata. Theory Course with JFLAP 4.0

A formal model for databases in DNA

19. The Fermat-Euler Prime Number Theorem

On decidability of LTL model checking for process rewrite systems

Lecture 3 Gaussian Probability Distribution

Additional Protocol to the Convention on Human Rights and Biomedicine concerning Genetic Testing for Health Purposes

Concept Formation Using Graph Grammars

AntiSpyware Enterprise Module 8.5

Basic Research in Computer Science BRICS RS Brodal et al.: Solving the String Statistics Problem in Time O(n log n)

How fast can we sort? Sorting. Decision-tree model. Decision-tree for insertion sort Sort a 1, a 2, a 3. CS Spring 2009

How To Understand The Theory Of Inequlities

Basic Analysis of Autarky and Free Trade Models

Review guide for the final exam in Math 233

An Undergraduate Curriculum Evaluation with the Analytic Hierarchy Process

Protocol Analysis / Analysis of Software Artifacts Kevin Bierhoff

Section 5.2, Commands for Configuring ISDN Protocols. Section 5.3, Configuring ISDN Signaling. Section 5.4, Configuring ISDN LAPD and Call Control

** Dpt. Chemical Engineering, Kasetsart University, Bangkok 10900, Thailand

Orthogonally modeling video structuration and annotation: exploiting the concept of granularity

Treatment Spring Late Summer Fall Mean = 1.33 Mean = 4.88 Mean = 3.

6.2 Volumes of Revolution: The Disk Method

Lec 2: Gates and Logic

Firm Objectives. The Theory of the Firm II. Cost Minimization Mathematical Approach. First order conditions. Cost Minimization Graphical Approach

The Velocity Factor of an Insulated Two-Wire Transmission Line

Lectures 8 and 9 1 Rectangular waveguides

Lecture 5. Inner Product

RIGHT TRIANGLES AND THE PYTHAGOREAN TRIPLETS

Econ 4721 Money and Banking Problem Set 2 Answer Key

Pure C4. Revision Notes

Complexity Results in Epistemic Planning

FUNCTIONS AND EQUATIONS. xεs. The simplest way to represent a set is by listing its members. We use the notation

Transcription:

On Recognizle Timed Lnguges Oded Mler 1 nd Amir Pnueli 2,3 1 CNRS-VERIMAG, 2 Av. de Vignte, 38610 Gières, Frnce Oded.Mler@img.fr 2 Weizmnn Institute of Science, Rehovot 76100, Isrel 3 New York University, 251 Mercer St. New York, NY 10012, USA Amir.Pnueli@cs.nyu.edu Astrct. In this work we generlize the fundmentl notion of recognizility from untimed to timed lnguges. The essence of our definition is the existence of right-morphism from the monoid of timed words into ounded suset of itself. We show tht the recognizle lnguges re exctly those ccepted y deterministic timed utomt nd rgue tht this is, perhps, the right clss of timed lnguges, nd tht the closure of untimed regulr lnguges under projection is positive ccident tht cnnot e expected to hold eyond the finite-stte cse. 1 Introduction Let Σ e the free monoid generted y finite set Σ. A set (lnguge) L Σ is recognizle if there exists finite deterministic utomton A =(Q, δ, q 0,F) tht ccepts it. The utomton sends words into sttes vi the mpping ˆδ A : Σ Q defined s ˆδ A (ε) =q 0 nd ˆδ A (w ) =δ(ˆδ A (w),). A lnguge L is 1 ˆδ A recognizle if L = q F (q) for some utomton A. There re two common wys to express these notions more lgericlly. One is to spek of monoid morphism ϕ from Σ to finite monoid M stisfying ϕ(w w )=ϕ(w) ϕ(w ). The disdvntge of this pproch is tht the oject under study is not nymore the ction of word w on the initil stte, ut rther the whole trnsformtion it induces on Q. This oject is much less intuitive (nd typiclly exponentilly lrger) thn the utomton. An lterntive, mentioned riefly in [E74], is to spek of right modules nd of module morphism from the free module (Σ,Σ) to the finite module (Q, Σ). For the purpose of this pper we define n equivlent vrition on this notion tht will llow us to extend it esily to timed lnguges. Our definition is inspired y utomton lerning theory [G72,A87] where every stte of the utomton is identified with (one of) the first words 4 tht rech it from q 0. The This work ws prtilly supported y grnt from Intel, y the Europen Community Projects IST-2001-35304 AMETIST (Advnced Methods for Timed Systems), http://metist.cs.utwente.nl nd y the CNRS project AS 93, Automtes, modèles distriués et temporisés. 4 Tht is, word tht reches the stte vi cycle-free run.

stndrd prefix prtil-order on Σ is defined s u u v for every u, v Σ. A lnguge is prefix-closed if it includes the prefixes of ll its elements. The immedite exterior of prefix-closed lnguge P is defined s ext(p )=P Σ P, i.e. the first words tht go outside P. Definition 1 (Recognizle Lnguges). A lnguge L is recognizle if there exists finite prefix-closed suset P Σ, right -morphism ϕ : Σ P stisfying ϕ(w) =w if w P ϕ(w w )=ϕ(ϕ(w) w ) nd suset F P such tht L = ϕ 1 (w). w F As n exmple let us look t the deterministic utomton of Figure 1 nd one of its spnning trees. The prefix-closed set P = {ε,,,,,, } contins one representtive for ech of the sttes {q 0,...,q 7 }. The choice of P is not unique nd my depend on the spnning tree chosen. For exmple, we could replce nd y nd s representtives of q 2 nd q 4, respectively. The morphism from Σ to P is defined, for elements outside P, vi rewriting rules ( reltions in the lgeric jrgon) tht mimic the nonspnning trnsitions in the trnsition grph. Such rewriting rule is defined for every element in ext(p ). In our exmple the rules re = ε, =, = ε, =, = =, = nd =. These rewriting rules cn e pplied only t the left of word, tht is, the rule = corresponds to the fmily w = w for every w Σ. The recognition of word y this structure proceeds like reding the word y n utomton: word w is scnned until prefix u ext(p ) is detected, such tht w = uv. Thn the rewriting rule u = u is pplied, reducing w to w = u v with u = ϕ(u) P nd the process is continued with w until w is reduced to word in P which is tested for memership in F (in our exmple F = {}). For untimed lnguges this exercise seems nothing more thn fncy formultion of cceptnce y finite utomton, yet it emphsizes the fundmentl property of finite-stte systems nd lnguges: the ility to distinguish etween finite numer of clsses of input histories. Before dpting this notion for timed lnguges let us recll some known fcts out miniml utomt nd the notion of stte in dynmicl system. Every L Σ dmits unique cnonicl utomton A L (not necessrily finite-stte) tht ccepts it. Any other utomton ccepting L cn e reduced to A L y n utomton homomorphism (merging of sttes). This utomton is

q 0 q 1 q 0 q 1 q 0 q 1 q 0 q 1 q 2 q 3 q 2 q 3 q 2 q 3 q 2 q 3, q 4 q 5, q 4 q 5, q 4 q 5, q 4 q 5 q 6 q 6 () () (c) (d) Fig. 1. () A deterministic utomton; () A spnning tree of the utomton (the solid lines); (c) A miniml utomton for the lnguge ccepted y the utomton in (); (d) A spnning tree for the miniml utomton. defined using the syntctic right-congruence 5 reltion induced y L on Σ u v iff w uw L vw L The sttes of the miniml utomton for L re the equivlence clsses of. This is the Nerode prt of the Myhill-Nerode chrcteriztion of regulr lnguges s those for which hs finite index. A lnguge like n n cn e proved non-recognizle y showing tht n m for every n m nd hence hs n infinite index nd no finite set of representtives of its congruence clsses exists. By choosing proper representtives for ech clss we cn hve set P of miniml size. Figure 1-(c) shows miniml utomton for our exmple. The corresponding lgeric oject is otined from the non-miniml one y removing from P, removing the rules = nd = nd dding the rule =. 2 Timed Lnguges We consider timed lnguges s susets of the time-event monoid T = Σ R +, the free product (shuffle) of the free monoid (Σ,,ε) nd the commuttive monoid (R +, +, 0). This monoid hs een introduced in [ACM02] s n lterntive semntic domin for timed ehviors, where elements of Σ indicte events nd elements of R + denote pssge of time. Elements of T cn e written s 5 A right-congruence reltion of Σ is n equivlence reltion such tht u v implies uw vw for every w.

timed words of the form t 0 1 t 1 2 t 2 n t n (1) with t i 0 nd i Σ {ε} for every i. Such word indictes pssge of t 0 time, followed y the occurrence of 1, followed y pssge of t 1 time, etc. The reder my find in [ACM02] more precise detils, exmples nd definition of cnonicl form to which two equivlent timed words cn e reduced. For exmple, 0 cn e reduced to nd t ε t reduces to t + t. The prefix prtil-order reltion on T is defined s u u v for ny u, v T. Note tht, in prticulr, w t w t whenever t t. A timed word w of the form (1) cn e projected onto Σ nd R +, respectively, vi the following two morphisms: The untime function, μ(w) = 1 2 n nd the durtion function λ(w) = t 0 + t 1 + + t n. For n untimed word u, u indictes its logicl length (numer of letters). These functions re lifted nturlly from individul words to sets of words. It is cler tht the notion of finite recognizility is useless for timed lnguges. It suffices to look t the singleton lnguge {5 }, consisting of the word where occurs t time 5, nd see tht it hs n uncountle numer of Nerode clsses s t t for every t t where t, t < 5. We elieve tht the suitle notion for timed lnguges is tht of oundedness (which implies finiteness for discrete systems). Intuitively this mens tht one cn distinguish etween finite numer of clsses of (qulittive) histories nd in ech of these clsses it is possile to distinguish etween durtions tken from ounded set. Definition 2 (Bounded Timed Lnguges). A timed lnguge L T is ounded if μ(l) is finite nd λ(l) is ounded in the usul sense of R +. We wnt to generlize Definition 1 to timed lnguges using ounded prefix-closed suset P of T nd morphism to it. Before giving forml definition let us illustrte the ide using the lnguge {t w : t [1, 5],w T} consisting of ll timed words tht hve no letters until 1 nd n occurrence of somewhere in [1, 5]. The set P should contin ll the time prefixes t with t [0, 5]. All the words of the form t with t<1 re Nerode equivlent (they ccept nothing) nd cn e represented y nd the sme holds for ll t with t>5. Likewise, the words of the form t with t [1, 5] re equivlent (they ccept everything) nd hence cn e represented y 1. So for this lnguge we hve P = {t : t [0, 5]} {} {1 }, F = {1 }

The immedite exterior of P contins ll the -continutions of P which re outside P, nmely the words t with t (0, 1) (1, 5] s well s nd 1. The immedite exterior vi time pssge is hrder to define due to the density of (R, ). In generl, given timed word w, one cnnot 6 chrcterize its first time continution. One solution would e to tke n ritrrily smll positive ɛ nd let the exterior of w e {w t : t (0,ɛ)}. We will use the nottion w t for tht, nd denote the corresponding elements of ext(p ) y t, 1 t, nd 5 t. The morphism is defined using the following rewriting rules: {t = : t [0, 1)} {t =1 : t [1, 5]} = t = 1 =1 t =1 5 t = A discrete-time interprettion of this oject ppers in Figure 2. As one cn see, we need formlism to express prmeterized fmilies of words elonging to P nd F s well s prmeterized fmilies of rewriting rules. The choice of this formlism depends on the type of dense-time utomt whose expressive power we wnt to mtch. In this work we concentrte on timed utomt nd efore doing so let us give n exmple of non-recognizle timed lnguge, L d = T { t 1 t 2 t n : n N n t i =1}. (2) i=1 This lnguge, which cn e ccepted y non-deterministic timed utomton, ws introduced y Alur [A90] to demonstrte the non-closure of timed utomt under complementtion. It is not hrd to see tht for every n t 1 t n t 1 t n t n+1 whenever 0 < n+1 i=1 t i < 1 nd hence for ny P, μ(p ) should contin the infinite lnguge { n : n N} nd P cnnot e ounded. 3 Timed Automt We consider Σ-leled timed utomt s cceptors of susets of T. Timed utomt re utomt operting in the dense time domin. Their stte-spce is product of finite set of discrete sttes (loctions) nd the clock-spce R m +, the set of possile vlutions of set of clock vriles. The ehvior of the utomton consists of n lterntion of time-pssge periods where the utomton 6 Perhps definition cn e given using non-stndrd nlysis with infinitesimls, or y tking limits on sequence of discretiztions with decresing time steps.

, t 1 0 t 1 t 2 t 3 t 4 t 5 t, t Fig. 2. An cceptor for discrete time interprettion of [1, 5] T. Trnsitions leled y t indicte pssge of one time unit. Dshed rrows indicte non-spnning trnsitions tht correspond to the rewriting rules. stys in the sme loction nd the clock vlues grow uniformly, nd of instntneous trnsitions tht cn e tken when clock vlues stisfy certin conditions nd which my reset some clocks to zero. The interction etween clock vlues nd discrete trnsitions is specified y conditions on the clock-spce which determine wht future evolution, either pssge of time or one or more trnsitions, is possile t given prt of the sttespce. The clocks llow the utomton to rememer, to certin extent, some of the quntittive timing informtion ssocited with the input word. This ility is ounded due to the finite numer of clocks nd due to the syntctic restrictions on the form of the clock conditions, nmely comprisons of clock vlues with finite numer of rtionl constnts. This, comined with the monotonicity of clock growth, mens tht clock ecomes inctive fter its vlue crosses the vlue of the mximl constnt κ nd it cnnot distinguish in tht stte etween time durtion of length κ nd of length κ + t for ny positive t. Let X = {x 1,...,x m } e set of clock vriles. A clock vlution is function x : X R +.Weuse1 to denote the unit vector (1,...,1) nd 0 for the zero vector (0,...,0). Definition 3 (Clock nd Zone Constrints). A clock constrint is either single clock constrint x d or clock difference constrint x i x j d, where {<,, =,,>} nd d is n integer. A zone constrint is conjunction of clock constrints. Definition 4 (Timed Automton). A timed utomton is A =(Σ,Q,X,q 0,I,Δ,F) where Q is finite set of sttes (loctions), X is finite set of clocks, I is the stying condition (invrint), ssigning to every q Q zone I q, nd Δ is trnsition reltion consisting of elements of the form (q,, φ, ρ, q ) where q nd q re sttes, Σ {ε}, ρ X nd φ (the trnsition gurd) is rectngulr zone constrint. The initil stte is q 0 nd the cceptnce condition F is finite set of pirs of the from (q, φ) where φ is zone constrint.

A configurtion of the utomton is pir (q, x) consisting of loction nd clock vlution. Every suset ρ X induces reset function Reset ρ on vlutions which resets to zero ll the clocks in ρ nd leves the other clocks unchnged. A step of the utomton is one of the following: δ A discrete step: (q, x) (q, x ), for some trnsition δ =(q,, φ, ρ, q ) Δ, such tht x stisfies φ nd x = Reset ρ (x). The lel of such step is. t A time step: (q, x) (q, x + t1), t R + such tht x + t 1 stisfies I q for every t <t. The lel of time step is t. A run of the utomton strting from the initil configurtion (q 0, 0) is finite sequence of steps ξ : (q 0, 0) s 1 (q 1, x 1 ) s 2 s n (qn, x n ). A run is ccepting if it ends in configurtion stisfying F. The timed word crried y the run is otined y conctenting the step lels. The timed lnguge ccepted y timed utomton A consists of ll words crried y ccepting runs nd is denoted y L A. A timed utomton is deterministic if from every rechle configurtion every event nd non-event leds to exctly one configurtion. This mens tht the utomton cnnot mke oth silent trnsition nd time pssge in the sme configurtion. Definition 5 (Deterministic Timed Automton). A deterministic timed utomton is n utomton whose gurds nd stying conditions stisfy: 1. For every two distinct trnsitions (q,, φ 1,ρ 1,q 1 ) nd (q,, φ 2,ρ 2,q 2 ), φ 1 nd φ 2 hve n empty intersection (event determinism). 2. For every trnsition (q, ε, φ, ρ, q ) Δ, the intersection of φ with I q is, t most, singleton (time determinism). In deterministic utomt ny word is crried y exctly one run. We denote the clss of timed lnguges ccepted y such utomt y DTA. Before defining the recognizle timed lnguges let us present prticulr tomic type of zones clled regions, introduced in [AD94], which ply specil role in the theory of timed utomt. Intuitively region consists of ll clock vlutions tht re not (nd will not e) distinguishle y ny clock constrint. A region constrint is zone constrint where for every x it contins constrint of one of the following forms: x = d, d<x<d+1or κ<xnd for every

pir of clocks either x i x j = d or d<x i x j <d+1. The set of ll regions over m clocks with lrgest constnt 7 κ is denoted y G m κ. Regions re the elementry zones from which ll other zones cn e uilt. Two clock vlutions tht elong to the sme region stisfy the sme gurds nd stying conditions. Moreover, y letting time pss from ny two such points, the next visited region is the sme. Finlly, ny reset of clocks sends ll the elements of one region into the sme region. This motivtes the definition [AD94] of the region utomton, finite-stte utomton whose stte spce is Q G m κ nd its trnsition reltion is constructed s follows. First we introduce specil symol τ which indictes the pssge of n under-specified mount of time, nd connect two regions R nd R τ y τ-trnsition, denoted y (q, R) (q, R ) if time cn progress in (q, R) nd R is the next region encountered while doing so. Secondly, for every trnsition (q,, φ, ρ, q ) nd every R which stisfies φ we define trnsition (q, R) (q, R ) if R is the result of pplying Reset ρ to R. As n exmple consider the deterministic utomton nd its corresponding region utomton ppering on Figure 3. The utomton ccepts ny word with 3 s such tht the second occurs 1 time fter the eginning nd the third 1 time fter the first. 8 4 Recognizle Timed Lnguges Let T n = {t 0,...,t n } e n ordered set of non-negtive rel vriles. A contiguous sum over T n is S j..k = k i=j t i nd the set of ll such sums over T n is denoted y S n.atimed inequlity on T n is condition of the form S i..j J where J is n intervl with nturl endpoints. A timed condition is conjunction of timed inequlities. A timed lnguge L is elementry if μ(l) ={u} with u = 1 n nd the set {(t 0,...t n ):t 0 1 n t n L} is definle y timed condition Λ. We will sometime denote elementry lnguges y pir (u, Λ). The immedite exterior ext(l) of n elementry lnguge L =(u, Λ) consists of the following sets: for every Σ, ext (L) is the set (u, Λ ) where Λ = Λ {t n+1 = 0}. The immedite exterior vi time pssge is ext t (L) =(u, Λ t ) where Λ t is otined from Λ s follows. If Λ contins one or more equlity constrints of 7 There re some simplifictions in the description in order to void full exposition of the theory of timed utomt. In prticulr, if some clock x>κin some region, we do not cre nymore out its comprisons with other clocks. This wy the region utomton hs just one terminl stte in which ll the clocks re lrger thn κ. Reders interested in ll the sutle detils my consult [B03]. 8 Note tht the existence of two trnsitions leving q 2, one leled with x =1nd one with x = 1,, is not considered violtion of determinism. A word 1 t for n ritrrily smll t will tke the former nd the word 1 will tke the ltter.

q 1 x 1 1 x 1 1,/x 2 := 0 q x 1 =1, 2 q 3 x 1 1 x 2 1 x 2 =1 x 1 =1 x 1 < 1, x 2 =1, x 1 =1 q 5 x 2 < 1, q 4 q 1 q2 q 3 3 6 15 23 22 2 5 9 21 26 8 1 4 7 10 25 11 28 14 20 27 29 19 13 18 24 17 12 16 30 q 5 q 4 Fig. 3. A timed utomton with 2 clocks nd its region utomton. Solid rrows indicte time pssge nd ε trnsitions while dshed rrows re trnsitions. The -leled self-loops from ll regions ssocited with q 4 nd q 5 re depicted in StteChrt style. The regions re detiled in Tle 1.

the form S j..n = d, these constrints re replced y constrints of the form d<s j..n. Otherwise, let j e the smllest numer such tht constrint of the form S j..n <dppers in Λ. This constrint is replced y S j..n = d. Definition 6 (Chronometric Suset). A suset P of T is chronometric if it cn e written s finite union of disjoint elementry lnguges. Definition 7 (Chronometric Reltionl Morphism). Let P e ounded nd prefix-closed suset of T. A chronometric (reltionl) morphism Φ from T to P is reltion definle y finite set of tuples (u, Λ, u,λ,e) such tht ech (u, Λ) is n elementry lnguge included in ext(p ), ech (u,λ ) is n elementry lnguge contined in P, nd E is set of equlities of the form n i=j t i = n i=k t i, where n = u nd n = u. It is required tht ll (u, Λ) re disjoint nd their union is equl to ext(p ). For every w = t 0 1 n t n nd w = t 0 1 n t n, (w, w ) Φ iff there exists tuple (u, Λ, u,λ,e) in the presenttion of Φ such tht w (u, Λ), w (u,λ ) nd the respective time vlues for w nd w stisfy ll the equlities in E. The definition of Φ for words outside ext(p ) is done vi the identity Φ(u v) =Φ(Φ(u) v). As n exmple of component (u, Λ, u,λ,e) of chronometric morphism let (u, Λ) =(t 0 t 1,{0 <t 0 < 1, 0 <t 1 < 1, 0 <t 0 + t 1 < 1}), (u,λ )=(r 0 r 1 r 2, {0 <r 0 < 1,r 1 =0, 0 <r 2 < 1, 0 <r 0 + r 1 + r 2 < 1}) nd E = t 0 + t 1 = r 0 + r 1 + r 2. This components corresponds to the non-spnning trnsition R 8 = R 17 in the region utomton of Figure 3. The reltion Φ is sid to e well formed if the following holds for ech tuple (u, Λ, u,λ,e) in Φ: For every w (u, Λ), there exists w (u,λ ) such tht (w, w ) Φ. For every w (u,λ ), there exists w (u, Λ) such tht (w, w ) Φ. A reltion Φ is sid to e comptile with chronometric suset F if for every (u, Λ, u,λ,e) in Φ, either (u,λ ) F or (u,λ ) F =. Remrk: From well formed reltionl chronometric morphism Φ one cn derive (functionl) chronometric morphism ϕ : T P y letting ϕ(w) e some w such tht (w, w ) Φ. From the reltion descried ove we cn derive functionl morphisms such s ϕ(t 0 t 1 ) = t 0 t 1,or ϕ(t 0 t 1 ) = (t 0 + t 1 ). While functionl morphisms follow more closely the spirit of clssicl theory, reltionl morphisms re more suitle for the proofs in this pper.

Definition 8 (Recognizle Timed Lnguges). A timed lnguge L is recognizle if there is chronometric prefix-closed set P, chronometric suset F of P nd chronometric reltionl morphism Φ : T P comptile with F such tht L = Φ 1 (w). w F 4.1 From Deterministic Automt to Recognizle Lnguges We re now redy to prove the first result, stting tht every lnguge ccepted y DTA is recognizle, y ssigning timed words to rechle configurtions. The correspondence etween vlues of clock vriles in the utomton nd vlues of time vriles in n input word of length n is done vi clock inding over (X, T n ), function β : X S n ssociting with every clock x contiguous sum of the form S j..n. Recll tht region is conjunction of single clocks constrints nd clock difference constrints. By sustituting β(x) for x, the former ecome timed inequlities nd the ltter ecome inequlities on S j..n S k..n = S j..k nd, hence, timed inequlities s well. Clim 1 (DTA REC) From every deterministic timed utomton A one cn construct chronometric prefix-closed suset P of T nd morphism Φ : T P such tht if (w, w ) Φ then w nd w led to the sme configurtion from the initil stte. Sketch of Proof: Build the region utomton for A nd pick spnning tree in which ech region is reched vi simple pth. Strting from the root we ssocite with every region n elementry timed lnguge in prefix-closed mnner. More precisely with every region R of the utomton we ssocite the triple (u, Λ, β) where (u, Λ) is n elementry timed lnguge with u = n nd β is clock inding on (X, T n ). We decompose Λ into two sets of timed inequlities Λ nd Λ + where Λ consists of the nchronistic inequlities not involving t n nd Λ + of live constrints involving t n. Note tht trnsitions my chnge the inding nd move some inequlities from Λ + to Λ. For the initil region R 0 =(q 0, 0), u = ε, Λ = Λ + is t 0 =0nd ll clocks re ound to t 0. Consider now the inductive step. Given region R with (u, Λ, β) we compute (u,λ,β ) for its successor (vi spnning trnsition) R. There re two cses: 1. R is simple time successor of R: in this cse u = u nd β = β. We let Λ = Λ nd otin Λ + from the region formul ψ y replcing every clock x y β(x). 9 9 Note tht Λ + nd Λ + re very similr consisting of lmost identicl sets of inequlities differing from ech other only y replcing one or more inequlities of the form S i..n = d y d<s i..n <d+1, etc.

2. R is trnsition successor of R vi n -leled 10 trnsition: in this cse u = u t n+1, we hve new time vrile t n+1 nd the (T n+1,x) inding β is derived from β nd from the corresponding trnsition s follows. If clock x is not reset y the trnsition then β (x) =S i..n+1 whenever β(x) = S i..n.ifx is reset then β (x) =t n+1 (note tht x =0in R ). To compute Λ we dd to Λ the sustitution of β(x) for x in ψ nd let Λ + e the sustitution of β (x) in ψ. From this construction it is esy to see tht the union of the otined lnguges is prefix-closed (we proceed y conctention nd y respecting pst timing constrints) nd chronometric nd tht ll rechle configurtions re covered y words. Next, we construct the reltion Φ sed on trnsitions which correspond to ck- or cross-edges in the spnning tree. Consider non-spnning trnsition leding from region R with chrcteristic (u, Λ, β) into region R with chrcteristic (u,λ,β ). Let (u,λ,β ) e the lnguge nd inding ssocited with the successor of R ccording to the previously descried procedure. This trnsition contriutes to Φ the tuple (u,λ,u,λ,e). For ech clock x which is not reset y the trnsition, E contins the equlity β (x) =β (x).ifx is reset y the trnsition, then E contins the equlity β (x) =0. Tle 1 shows the correspondence etween the regions of Figure 3 nd elementry lnguges. The numering of the regions is consistent with the chosen spnning tree. 4.2 From Recognizle Lnguges to Deterministic Automt We will now prove the other direction y uilding deterministic timed utomton for given recognizle lnguge. To fcilitte the construction we will use n extended form of timed utomt, proposed in [SV96], where trnsitions cn e e lelled y ssignments of the form x := 0 nd x := y (clock renming). As shown in [SV96] such utomt cn e trnsformed into stndrd timed utomt (see lso [BDFP00]). Clim 2 (REC DTA) From every chronometric suset P of T nd chronometric morphism Φ : T P one cn uild DTA A such tht if two timed words led to the sme configurtions in A then (w, w ) Φ. Sketch of Proof: The construction of the utomton strts with n untimed utomton (with tree structure) whose set of sttes is μ(p ) with ε s the initil 10 The specil cse where the trnsition is not leled is resolved y introducing new time vrile t n+1 such tht the word cn e written s t 0 n t n ε t n+1.

stte nd trnsition function such tht δ(u, ) =u whenever u is in μ(p ). We then decorte the utomton with stying conditions, trnsition gurds, nd resets s follows. With every trnsition we reset new clock so tht for every word t 0 1 n t n, the vlue of clock x i t ny stte 1 j, i j is ound to S i..j. For every stte u = 1 n μ(p ) let Λ(u) ={(t 0,...,t n ):t 0 1 n t n P }. By decomposing Λ(u) into nchronistic (Λ ) nd live (Λ + ) constrints nd sustituting x i insted of every S i..n in Λ +, we otin the stying condition for stte u. For every u nd such tht u is in μ(p ) let H u, = {(t 0,...,t n ):t 0 1 n t n P }. Without loss of generlity we ssume tht H u, is definle y timed condition. 11 Hence every expression S i..j in it cn e replced y x j x i nd the whole condition cn e trnsformed into zone constrint tht will serve s the gurd of the trnsition etween u nd u. This wy we hve n utomton in which every element of P reches distinct configurtion. Consider n element (u, Λ, u,λ,e) Φ, such tht (u, Λ) ext (P ), with u = n nd u = n. Such n element introduces into the constructed utomton n -leled trnsition from u to u. For every constrint of the form S j..k J included in Λ, we include in the trnsition gurd the constrint x j x k J. For every equlity S j..n = S k..n included in E, we dd to the reset function the ssignment x j := x k. Likewise every (u, Λ, u,λ,e) Φ such the (u, Λ) ext t (P ) induces timed trnsition from u to u with gurd nd reset function similr to the previous cse. Corollry 1 (REC=DTA). The recognizle timed lnguges re those ccepted y deterministic timed utomton. 5 Discussion Ever since the introduction of timed utomt nd the oservtion tht their lnguges re not closed under complementtion, reserchers were trying to find 11 In generl it could e definle y finite union of timed conditions nd we should mke severl trnsitions from u to u.

R q ψ u β Λ 1 q 1 0=x 2 = x 1 t 0 x 1 = t 0 t 0 =0 x 2 = t 0 2 q 1 0 <x 2 = x 1 < 1 t 0 x 1 = t 0 0 <t 0 < 1 x 2 = t 0 3 q 1 x 2 = x 1 =1 t 0 x 1 = t 0 t 0 =1 x 2 = t 0 4 q 2 0=x 2 = x 1 t 0 t 1 x 1 = t 0 + t1 t 0 = t 1 =0 x 2 = t 1 5 q 2 0 <x 2 = x 1 < 1 t 0 t 1 x 1 = t 0 + t1 t 0 =00<t 1 < 1 x 2 = t 1 6 q 2 x 2 = x 1 =1 t 0 t 1 x 1 = t 0 + t1 t 0 =0t 1 =1 x 2 = t 1 7 q 2 0=x 2 <x 1 < 1 t 0 t 1 x 1 = t 0 + t1 0 <t 0 < 1 t 1 =0 x 2 = t 1 8 q 2 0 <x 2 <x 1 < 1 t 0 t 1 x 1 = t 0 + t1 0 <t 0 < 10<t 1 < 10<t 0 + t 1 < 1 x 2 = t 1 9 q 2 0 <x 2 <x 1 =1 t 0 t 1 x 1 = t 0 + t1 0 <t 0 < 10<t 1 < 1 t 0 + t 1 =1 x 2 = t 1 10 q 2 x 2 =0x 1 =1 t 0 t 1 x 1 = t 0 + t1 t 0 =1t 1 =0 x 2 = t 1 11 q 5 x 1 > 1 x 2 > 1 t 0 εt 1 x 1 = t 0 + t 1 1 <t 0 + t 1 x 2 = t 0 + t 1 12 q 5 x 1 = x 2 =0 t 0 t 1 t 2 x 1 = t 0 + t 1 + t 2 t 0 = t 1 = t 2 =0 13 q 5 0 <x 1 = x 2 < 1 t 0 t 1 t 2 x 1 = t 0 + t 1 + t 2 t 0 = t 1 =00<t 2 < 1 14 q 5 x 1 = x 2 =1 t 0 t 1 t 2 x 1 = t 0 + t 1 + t 2 t 0 = t 1 =0t 2 =1 15 q 3 x 2 = x 1 =1 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 t 0 =0t 1 =1t 2 =0 16 q 5 0=x 2 <x 1 < 1 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 0 <t 0 < 1 t 1 =0t 2 =0 17 q 5 0 <x 2 <x 1 < 1 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 0 <t 0 < 1 t 1 =00<t 2 < 1 0 <t 0 + t 2 < 1 18 q 5 0 <x 2 <x 1 =1 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 0 <t 0 < 1 t 1 =00<t 2 < 1 0 <t 0 + t 2 =1 19 q 5 0 <x 2 < 1 <x 1 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 0 <t 0 < 1 t 1 =00<t 2 < 1 0 <t 0 + t 2 > 1 20 q 5 0 <x 2 =1<x 1 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 t 0 =1t 1 = t 2 =0t 3 =1 21 q 3 0 <x 2 <x 1 =1 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 0 <t 0 < 10<t 1 < 1 t 0 + t 1 =1t 2 =0 22 q 3 0 <x 2 < 1 <x 1 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 0 <t 0 < 10<t 1 < 1 t 0 + t 1 + t 2 > 10<t 2 < 1 t 1 + t 2 < 1 23 q 3 0 <x 2 =1<x 1 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 0 <t 0 < 10<t 1 < 1 t 0 + t 1 + t 2 > 10<t 2 < 1 t 1 + t 2 =1 24 q 5 0 <x 2 < 1 <x 1 =1 t 0 t 1 εt 2 x 1 = t 0 + t1 +t 2 t 0 =1t 1 = t 2 =00<t 3 < 1 25 q 3 x 1 =1x 2 =0 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 t 0 =1t 1 = t 2 =0 26 q 3 0 <x 2 < 1 <x 1 t 0 t 1 t 2 x 1 = t 0 + t1 +t 2 t 0 =1t 1 =00<t 2 < 1 27 q 4 x 2 = x 1 =1 t 0 t 1 t 2 t 3 x 1 = t 0 + t1 +t 2 + t 3 t 0 =0t 1 =1t 2 =0t 3 =0 + t 3 28 q 4 1 <x 1 1 <x 2 t 0 t 1 t 2 t 3 x 1 = t 0 + t1 +t 2 + t 3 t 0 =1t 1 =0t 2 =1t 3 > 0 + t 3 29 q 4 0 <x 2 =1<x 1 t 0 t 1 t 2 t 3 x 1 = t 0 + t1 +t 2 + t 3 t 0 =1t 1 =0t 2 =1t 3 =0 + t 3 30 q 5 x 1 =1x 2 =0 t 0 t 1 t 2 t 3 x 1 = t 0 + t 1 + t 2 + t 3 t 0 =1t 1 = t 2 = t 3 =0 + t 3 Tle 1. Correspondence etween regions in the utomton of Figure 3 nd timed words.

well-ehving su-clss of lnguges. 12 Among the proposls given, we mention the event-clock utomt of [AFH99] where for ech letter in the lphet, the utomton cn mesure only the time since its lst occurrence. It ws shown tht these lnguges dmit deterministic timed cceptor. Recognizle timed lnguges tke this ide further y llowing the utomton to rememer the occurrence times of finite numer of events, not necessrily of distinct types. The ides of [AFH99] were developed further in [RS97] nd [HRS98], resulting in rich clss of timed lnguges chrcterized y decidle logic. While eing stisfctory from logicl point of view, the utomton chrcteriztion of this clss is currently very complicted, involving cscdes of eventrecording nd event-predicting timed utomt. We feel tht our more restricted clss of recognizle lnguges cptures the nturl extension of recognizility towrd timed lnguges, nmely which clsses of input histories cn e distinguished y finite numer of sttes nd finite numer of ounded clocks. 13 Deterministic timed lnguges hve not een studied much in the literture due to severl resons. The first is slight confusion out wht deterministic mens in this context nd etween cceptors nd genertors in generl. A trnsition gurded y ft condition of the form x [l, u] is non-deterministic only if it is not leled y n input letter. If it is leled y n input the trnsition is deterministic, recting differently to t nd t for t t. Another reson for ignoring deterministic utomt is the centrlity of the equivlence etween DFA nd NDFA in the untimed theory which serves to show tht regulr lnguges re closed under projection. Recognizle timed lnguges re indeed not closed under projection. The non-recognizle lnguge L d (2) cn e otined from recognizle lnguge over {, } y projecting wy. Not seeing, the utomton hs to guess t certin points, whether hs occurred. When this guessing hs to e done finite numer of times, the Rin-Scott suset construction cn simulte it y DFA tht goes simultneously to ll possile successors. However when these hidden events cn occur unoundedly within finite intervl nd their occurrence times should e memorized, finite suset construction is impossile. In this context it is worth mentioning the result of [W94] out the determinizility of timed utomt under uniform ounded vriility ssumption nd lso to point out tht for the sme resons determiniztion is lwys possile under ny time discretiztion. The closest work to ours, in the sense of trying to estlish semntic inputoutput definition of stte in timed system, is [SV96], motivted y testing of 12 The question whether non-deterministic timed utomton cn e determinized is undecidle, see [T03]. 13 Note tht in the untimed theory recognizility implies decidility ut not vice vers, for exmple the emptiness prolem for push-down utomt is decidle.

timed utomt. In tht pper the uthors give n lgorithm for semntic minimiztion of timed utomt nd lso mke useful oservtions out clock permuttions nd ssignments nd out the relevnce of clocks in vrious sttes. Similr oservtions were mde in [DY96] where clock ctivity nlysis ws used to reduce the dimensionlity of the clock spce in order to sve memory during verifiction. Another relted work is tht of [BPT03] which is concerned with dt lnguges, lnguges over n lphet Σ D where D is some infinite domin. Bsed on ides developed in [KF94], they propose to recognize such lnguges using utomt ugmented with uxiliry registers tht cn store finite numer of dt elements ut not perform computtions on these vlues. The results in [BPT03] show tht cceptnce y such utomt coincides with their notion of recognizility y finite monoid. These very generl results cn e specilized to timed lnguges y interpreting D s solute time nd every pir (, d) Σ D s letter nd time stmp d. Although the specil nture of time cn e imposed vi monotonicity restrictions on the d s, we feel more comfortle with our more cusl tretment of time s n entity whose elpse is consumed y the utomton in the sme wy input events re. Other investigtions of the lgeric spects of timed lnguges re reported in [D01]. To summrize, we hve defined wht we elieve to e the pproprite notion of recognizility for timed systems nd hve shown tht it coincides with cceptnce y deterministic timed utomton. We elieve tht this is the right clss of timed lnguges nd we hve yet to see useful nd relistic timed lnguge which is outside this clss. Our result lso mkes timed theory closer to the untimed one nd opens the wy for further lgeric investigtions of timed lnguges. Let us conclude with some open prolems triggered y this work: 1. Wht hppens if contiguous sums re replced y ritrry sums or y liner expressions with positive coefficients? Clerly, the former cse corresponds to stopwtch utomt nd the ltter to some clss of hyrid utomt nd it is interesting to see whether such study cn shed more light on prolems relted to these utomt. 2. Is there nturl restriction of the timed regulr expressions of [ACM02] which gurntees recognizility? Unfortuntely, dropping the renming opertion will not suffice ecuse the lnguge L d (2) cn e expressed without it. 3. Cn our results e used to develop n lgorithm for lerning timed lnguges from exmples nd for solving other relted prolems such s minimiztion nd test genertion?

4. Cn recognizility e relted to the growth of the index of the Nerode congruence for discretiztion of the lnguge s time grnulrity decreses? Acknowledgment: This work enefited from discussions nd monologues with Eugene Asrin, Stvros Tripkis, Pscl Weil, Yssine Lkhnech, Pul Cspi nd Sergio Yovine, s well s from thoughtful comments from nonymous referees tht improved the correctness nd presenttion of the results. References [A90] R. Alur, Techniques for Automtic Verifiction of Rel-Time Systems, PhD Thesis, Stnford, 1990. [AD94] R. Alur nd D.L. Dill, A Theory of Timed Automt, Theoreticl Computer Science 126, 183 235, 1994. [AFH99] R. Alur, L. Fix, nd T.A. Henzinger, Event-Clock Automt: A Determinizle Clss of Timed Automt, Theoreticl Computer Science 211, 253-273, 1999. [A87] D. Angluin, Lerning Regulr Sets from Queries nd Counter-Exmples, Informtion nd Computtion 75, 87-106, 1987. [ACM02] E. Asrin, P. Cspi nd O. Mler, Timed Regulr Expressions The Journl of the ACM 49, 172-206, 2002. [B03] P. Bouyer, Untmele Timed Automt!, Proc. STACS 03, 620-631, LNCS 2607, Springer, 2003. [BDFP00] P. Bouyer, C. Dufourd, E. Fleury nd A. Petit, Expressiveness of Updtle Timed Automt, Proc. MFCS 2000, 232-242, LNCS 1893, Springer, 2000. [BPT03] P. Bouyer, A. Petit, nd D. Thérien, An lgeric Approch to Dt Lnguges nd Timed Lnguges, Informtion nd Computtion 182, 137-162, 2003. [D01] C. Dim, Rel-Time Automt, Journl of Automt, Lnguges nd Comintorics 6, 3-24, 2001. [DY96] C. Dws nd S. Yovine, Reducing the Numer of Clock Vriles of Timed Automt, Proc. RTSS 96, 73-81, IEEE, 1996. [E74] S. Eilenerg, Automt, Lnguges nd Mchines, Vol. A, Acdemic Press, New- York, 1974. [G72] E.M. Gold, System Identifiction vi Stte Chrcteriztion, Automtic 8, 621-636, 1972. [HRS98] T.A. Henzinger, J.-F. Rskin, nd P.-Y. Schoens, The Regulr Rel-time Lnguges, Proc. ICALP 98, 580-591, LNCS 1343, Springer, 1998. [KF94] M. Kminski nd N. Frncez, Finite-memory Automt, Theoreticl Computer Science 134, 329-363, 1994. [RS97] J.-F. Rskin nd P.-Y. Schoens, Stte Clock Logic: A Decidle Rel-Time Logic, in Hyrid nd Rel-Time Systems (HART), 33-47, LNCS 1201, Springer, 1997. [T03] S. Tripkis, Folk Theorems on the Determiniztion nd Minimiztion of Timed Automt, Proc. FORMATS 03, 2003. [SV96] J.G. Springintveld nd F.W. Vndrger, Minimizle Timed Automt, Proc. FTRTFT 96, 130-147, LNCS 1135, Springer, 1996. [W94] Th. Wilke, Specifying Stte Sequences in Powerful Decidle Logics nd Timed Automt, Proc. FTRTFT 94, LNCS 863, 694-715, Springer, 1994.