23.08.2013 Views

Specification of Reactive Hardware/Software Systems - Electronic ...

Specification of Reactive Hardware/Software Systems - Electronic ...

Specification of Reactive Hardware/Software Systems - Electronic ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

8.5 A Computational Semantics 249<br />

we define<br />

pop( <br />

¥ ) ¥¡ ¥¡ ¡ ¡ ¥ 1 if ¡ n ¡ 1<br />

<br />

¡ en<br />

¥¡ ¡ ¥ en ) ¥¡ ¡ ¡ ¥ ¡ ¥ e<br />

e1<br />

e1<br />

e1 en<br />

e1 en if en ¥ e ¡ Stack<br />

¥ ¡ ¡ ¥¡ e1<br />

push(e¥<br />

top( ¡ ¡ ¥ en ¡ ¥¡ e1 ) en if n 1<br />

<br />

e1 ¥¡ ¡ ¡ ¥ en ¡ n<br />

¡<br />

s ¡ denotes the depth (the amount <strong>of</strong> elements) <strong>of</strong> stack s.<br />

¡<br />

<br />

¢¨¥ ¤ ¢ ¤<br />

We denote the first and second component <strong>of</strong> a stack element e by e(1) respectively e(2).<br />

So if e then e(1) and e(2) .<br />

To store for each non-primitive data object its class name, we define the set Type <strong>of</strong> types<br />

or type functions ranging over ¡ , ¡ ¡<br />

Type NDObj ¦£ CName<br />

Armed with these definitions we are able to define our set Conf <strong>of</strong> data configurations.<br />

Conf Stat e Stack Type <strong>Systems</strong><br />

A configuration conf consists <strong>of</strong> a statement part and an information part (see also<br />

Subsection 8.5.1). Here, the statement part <strong>of</strong> a configuration is an extended statement.<br />

The information part is composed <strong>of</strong> a variables state, a stack, a type and a system <strong>of</strong><br />

non-primitive data classes.<br />

Set Stat e , with typical elements S e ¥¡ ¡ ¡ , is an extended set <strong>of</strong> data statements, based on Stat.<br />

This extension is on its turn based on an extended set <strong>of</strong> data expressions Exp e , with typical<br />

elements E e ¥¡ ¡ ¡ . The extended sets are defined as follows:<br />

E e :: x<br />

u ¡<br />

new (C) ¡<br />

self ¡<br />

S e :: E e<br />

¡ x : Ee ¡ u : Ee ¡ Se 1; S2<br />

¡ Ee m(Ee 1 ¥¡ ¡ ¡ ¥ Ee ¡ ¤<br />

¡<br />

n)<br />

Se ¡ if<br />

; E<br />

¢¤£ ¥§¦ ¥©¨<br />

¡<br />

then else fi<br />

do ¢<br />

¥<br />

E ¡<br />

then od<br />

e<br />

¤ ¤<br />

<br />

Here, denotes the direct naming <strong>of</strong> object . This construct is incorporated to facilitate<br />

the semantic description. Ee indicates that a message is standing out and that the result<br />

<strong>of</strong> the message, which is the value <strong>of</strong> expression Ee , is to be inserted at the place <strong>of</strong> the .<br />

8.5.3 The Transition System<br />

We are now ready to define relation £ <strong>of</strong> transition system (Conf ¥ £ ). Transition relation<br />

£ ¥ Conf Conf

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

Saved successfully!

Ooh no, something went wrong!