07.01.2013 Views

Lecture Notes in Computer Science 3472

Lecture Notes in Computer Science 3472

Lecture Notes in Computer Science 3472

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

3.4.2 Naik’s Algorithm<br />

3 State Verification 79<br />

Naik’s algorithm for comput<strong>in</strong>g UIO sequences was presented <strong>in</strong> 1997 [Nai97],<br />

when the problem was already known to be PSPACE-complete [LY94]. The<br />

algorithm is complete, <strong>in</strong> the sense that it computes a UIO sequence for every<br />

vertex that has one, and always term<strong>in</strong>ates. The basic idea is still to exam<strong>in</strong>e<br />

all possible <strong>in</strong>put sequences, but it is augmented by a number of other ideas,<br />

<strong>in</strong>clud<strong>in</strong>g:<br />

(1) Techniques for ensur<strong>in</strong>g term<strong>in</strong>ation.<br />

(2) Inference rules to extend a sequence for one state to sequences for other<br />

states.<br />

(3) Heuristics that under some circumstances provide UIO sequences for some<br />

states <strong>in</strong> polynomial time.<br />

(4) A modified depth-first search to f<strong>in</strong>d UIO sequences for some states.<br />

(5) Techniques for shorten<strong>in</strong>g found sequences.<br />

We will exam<strong>in</strong>e the first four items <strong>in</strong> this list.<br />

Naik uses UIO trees, which are trees with edges labeled by <strong>in</strong>put-output<br />

pairs, and nodes labeled by vectors that represent paths <strong>in</strong> the mach<strong>in</strong>e that<br />

exhibit the <strong>in</strong>put-output behavior <strong>in</strong>dicated by the edges from the root to the<br />

node.<br />

Def<strong>in</strong>ition 3.8 (Path Vectors). Given a Mealy mach<strong>in</strong>e M, apath vector is a<br />

> satisfy<strong>in</strong>g the follow<strong>in</strong>g. There<br />

vector of state pairs PV =< s1/s ′ 1,...,sk /s ′ k<br />

is an <strong>in</strong>put sequence x and an output sequence y such that λ(si, x )=y and<br />

δ(si, x )=s ′ i for every pair si/s ′ i <strong>in</strong> PV. The vector IV (PV)=< s1,...,sk ><br />

consist<strong>in</strong>g of the first components of the pairs <strong>in</strong> PV is called the <strong>in</strong>itial vector of<br />

PV. The vector CV (PV)=< s ′ 1 ,...,s′ k > consist<strong>in</strong>g of the second components<br />

is called the current vector.<br />

Given a Mealy mach<strong>in</strong>e M =(I , O, S,δ,λ), its IO tree is an <strong>in</strong>f<strong>in</strong>ite tree <strong>in</strong><br />

which every node has |I |·|O| children, one for each possible <strong>in</strong>put-output pair <strong>in</strong><br />

M. The edges to the children are labeled by dist<strong>in</strong>ct <strong>in</strong>put-output pairs. Thus<br />

the nodes of the tree correspond to every possible <strong>in</strong>put-output sequence.<br />

Def<strong>in</strong>ition 3.9 (Full UIO Tree). Let M =(I , O, S,δ,λ) be a Mealy mach<strong>in</strong>e.<br />

The full UIO tree of M is a label<strong>in</strong>g of the IO tree by path vectors. The root of<br />

the tree is labeled by < s1/s1,...,sn/sn >, wheren is the number of states of<br />

M. If a node <strong>in</strong> the tree is reachable from the root by a path labeled by <strong>in</strong>put<br />

sequence x and output sequence y, and has label PV =< s1/s ′ 1 ,...,sk /s ′ k >,<br />

then for every si/s ′ i <strong>in</strong> PV,itmustholdthatλ(si, x )=y and δ(si, x )=s ′ i .<br />

Furthermore, PV conta<strong>in</strong>s all pairs si/s ′ i such that λ(si, x )=y and δ(si, x )=s ′ i .<br />

Notice that some nodes may be labeled by empty path vectors.<br />

It immediately follows that if a node, labeled by a s<strong>in</strong>gleton < s/s ′ >,is<br />

reachable from the root by a path labeled with <strong>in</strong>put sequence x and output<br />

sequence y, thenx is a UIO sequence for s. Thisisbecauses must be the only

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!