Presentation is loading. Please wait.

Presentation is loading. Please wait.

Definition of cell-shaped spaces. CCA = n C cell’s state variables; n S finite alphabet to represent each cell’s state; n n dimensional space; n N neighboring.

Similar presentations


Presentation on theme: "Definition of cell-shaped spaces. CCA = n C cell’s state variables; n S finite alphabet to represent each cell’s state; n n dimensional space; n N neighboring."— Presentation transcript:

1 Definition of cell-shaped spaces

2 CCA = n C cell’s state variables; n S finite alphabet to represent each cell’s state; n n dimensional space; n N neighboring cells; n T global transition function;  local computing function; Discrete/continuous time bases. Cell Spaces

3 CA = S  Z  #S <  ; {r, c}  N, r,c < , with r the number of rows and c the number of columns; C = { C ij /  i,j  N  i  [1,r], j  [1,c], C ij  S };   N; N = { (i p,j p ) / i p, j p  Z  i p, j p  [-1, 1]  p  N, p  [1,  ] }. B = {  } if the cell space is wrapped; or B = {C ij / C ij  C  (i = 1  i = f)  (j = 1  j = c) } otherwise. T: C x c.Z 0 +  C;  : N  S ; Executable Cellular Automata

4 n “Quiescent” states n CPU time wasted in synchronous CA n SOLUTION: consider a CA as a discrete-event model n Formal modelling: verification tasks improved n Model specifications (errors: specification is changed) n Timing delays for the cell behavior description n Individual cells: atomic models n Automatic coupling between cells in a space n Hierarchical coupling with other DEVS models n Abstract simulation mechanism Asynchronous CA

5  Basic models: atomic cells. Automatic coupling mechanism.  Discrete-Events cell spaces: transport, inertial delays  Abstract simulation mechanism: hierarchical/flat. Cell-DEVS

6 Cell-DEVS Atomic Models Transport Delay Inertial Delay N inputs to a given cell Computing a local function Inertial or Transport delays Outputs only if the cell state changes

7 Cell Behavior Specification of behavior States change and delay definition Translation of the specification to internal representation of the models. External transition: cell's affection (depending on the inputs - neighborhood state). If the state has changed, delay the output. Internal transition: it is repeated for each waiting output message.

8 CD = X  R is the set of input external events; Y  R is the set of output external events; I = is the model’s modular interface, with   N,  the neighborhood size,   N,   the number of other ports, and  j  [1,  ], i  {X, Y}, P j i = { (N j i, T j i ) /  j  [1,  ], N j i  [i 1, i  ] (port name), and T j i  i (port type)},  i = { x / x  X if i = X } or  i = { x / x  Y si i = Y } ; S  R is the set of possible states for a given cell; Atomic Cell-DEVS

9  is the definition of the cell’s state variables, defined by  = { (s, phase,  queue,  ) / s  S is the state value for a cell, phase  {active, passive},  queue = { ((v 1,  1 ),...,(v m,  m )) / m  N  m   (i  N, i  [1,m]), v i  S  i  R 0 +   }; and   R 0 +   } ; for cells with transport delays, and  = { (s, phase, f,  ) / s  S, phase  {active, passive}, f  T, and   R 0 +   } for cells with inertial delays; N  S , is the set of the input events; Atomic Cell-DEVS (cont.)

10 d  R 0 +, d <  is the delay of the cells;  int :  is the internal transition function;  ext : QxX   is the external transition function, with Q = { (s, e) / s   x N x d; e  [0, D(s)]};  : N  S is the local computing function; : S  Y is the output function, and D:  x N x d  R 0 +  , is the duration function. Atomic Cell-DEVS (cont.)

11 Transport delays Inertial Delays Cell delay functions

12 GCC b = Neighborhood list: { (0, -1), (0,0), (0,1), (-1,0)} P ij Y 1  P i,j-1 X 1 (1) P ij Y 2  P ij X 2 (2) P ij Y 3  P i,j+1 X 3 (3) P ij Y 4  P i-1,j X 4 (4) Inverse neighborhood list: { (0, 1), (0,0), (0, -1), (1, 0)} P ij X 1  P i,j+1 Y 1 (1) P ij X 2  P ij Y 2 (2) P ij X 3  P i,j-1 Y 3 (3) P ij X 4  P i+1,j Y 4 (4) Coupled Cell-DEVS

13 GCC b = Ylist = { (k,l) / k  [0,r], l  [0,c]}; Xlist = { (k,l) / k  [0,r], l  [0,c]}; I =, where  i  {X, Y},  ( (k,l)  ilist, (k, l)  [1, f] x [1,c]), P kl i = { (N(k,l) i, T(k,l) i ) / N(k,l) i = i(k,l) (port name), and T(k,l) i = {0, 1} (port type)}; n X = {0, 1}; n Y = {0, 1}; {r, c}  N;   N,   r.c; N = { (i p,j p ) / (i p, j p )  Z  i p, j p  [-1, 1])  p  N, p  [1,  ]}. C = {C ij / i  [1,r]  j  [1,c]}, where C ij = is an atomic component; Coupled Cell-DEVS

14 B = {  } if the cell space is “wrapped”, or B = {C ij / (i = 1  i = f)  (j = 1  j = c)  C ij  C  C ij = is an atomic cell}, if the border has different behavior than the rest of the cell space. Z: I ij  kl  defined by Z(P ij Y q ) = P kl X q, with (q  N, q  [1,  ])   s,t)  N, k = (i+s) mod r; l = (j+t) mod c; and Z(P ij X q ) = P kl Y q, with (q  N, q  [1,  ])   s,t)  N, k = (i-s) mod r; l = (j-t) mod c. select = { (k,l) / (k,l)  N } is the tie-breaking function. Coupled Cell-DEVS (cont.)

15 CM = n X is the set of external input events; n Y is the set of external output events; D  N is an index of the components of the coupled model, and  d  D M d is a DEVS basic model, where M d = GCC bd = if the coupled model is a Cell-DEVS model; otherwise, M d = n I d is the set of influencees of the model d, and Coupled DEVS

16  j  I d, Z dj is the d to j translation function, where Z dj : Y d  X j if none of the models are Cell-DEVS, Z dj : Y(c 1 ) d  X(c 2 ) j, with (c 1 )  Ylist d, and (c 2 )  Xlist j if any of the models d or j is a GCC, or Z dj : Y(f,g) d  X(k,l) j, with (f,g)  Ylist d, and (k,l)  Xlist j if any of the models d or j is a GCC b. n Finally, select is the tie-breaking selector. Xlist 1 = { (3,1) } Ylist 1 = { (1,2), (2,2), (3,2) } Xlist 2 = { (1,1), (2,1), (3,1) } Ylist 2 = {  } Xlist 3 = {(1,1)} Ylist 3 = {(2,2)} Y(1,2) 1  X(1,1) 2 Y(2,2) 1  X(3,1) 2 Y(3,2) 1  X(1,1) 3 Y(3,1) 1  X 4 Y 4  X(3,1) 1 Y(2,2) 3  X(2,1) 2 Coupled DEVS

17 Coupled model definition Neighborhood: coupling of model components. Cell-space size. Borders (wrapped cell-spaces or self-state generating borders). Initial state for the cell space. Priorities to treat simultaneous events (to classify the imminent cells in the cell space). Array of atomic models and coupling automatically created.

18 N: { (0,0), (-1,0), (1,0), (0,-1), (0,1) }; d=in_delay(wind). Result Input values 1((0,0) = 1 AND NOT (ALL = 0) ) OR ( (0,0)= 0 AND (ANY = 1) ) 0(ALL = 0 AND (0,0) = 1) An application example

19 M A = Xlist A = { (1,10); (2,10) }; Ylist A = {  }.  A = 5; I A =, with P x = {, }; P y = {  }; N A = { (0,0), (-1,0), (1, 0), (0,1), (0,-1) }; X A = Y A = {0, 1}; m A = 9; n A = 10; B A = {  }; C A = {C Aij / i  [1,9], j  [1,10]} Z A : P ij Y 1  P i,j-1 X 1 P i,j+1 Y 1  P ij X 1 P ij Y 2  P i+1,j X 2 P i-1,j Y 2  P ij X 2 P ij Y 3  P i,j+1 X 3 P i,j-1 Y 3  P ij X 3 P ij Y 4  P i-1,j X 4 P i+1,j Y 4  P ij X 4 P ij Y 5  P ij X 5 select A = { (-1,0), (0,1), (0,0), (0,-1), (1, 0) }; Cell-DEVS coupled model

20 M = X = Y = {  }; D = { A, B, C, D, E }, I A = {  }; I B = { C, E }; I C = { A, B, D, E }; I D = { A, C }; y I E = { B, C }. In this case, Z ij is defined by: Z BC : Y(1,3) B  X(4,5) C Z BE : Y(1,9) B  IN E1 Z CA : Y(1,10) C  X(2,10) A Z CB : Y(4,4)C  X(1,2) B Z CD : Y(4,15) C  IN D Z CE : Y(4,1) C  IN E2 Z DA : OUT D1  X(1,10) A Z DC : OUT D2  X(4,14) C Z EB : OUT E2  X(1,7) B Z EC : OUT E1  X(3,4) C Finally, select = { C, A, B, D, E}. E D External coupling definition


Download ppt "Definition of cell-shaped spaces. CCA = n C cell’s state variables; n S finite alphabet to represent each cell’s state; n n dimensional space; n N neighboring."

Similar presentations


Ads by Google