Information Technology Reference
In-Depth Information
k
4
N 1
N 2
N 3
s
k
s
s
t
M 1
M 2
M 3
h
0
t
1
1
1
A
R 1
R 2
R 3
R 4
Fig. 5. A 3-digit abacus with carry
yielded by the carry rules, each trying to consume 10 units from its right region
to produce 1 carry unit on its left region.
The computation, including the carry, may take up to k = 4 steps counted by
the countdown network as follows. When s becomes 1, the reaction r 10 : k
t
occurs leaving k =3and t =1.Ateachnextstep k is decreased, while the rules
consuming t are blocked because they want to globally consume t + s = t +1 units of
t .When k becomes 1 the rule r 13 : s
h unblocks producing the
Halt
substance
h and decreasing the value of s to 0. Now r 11 : t
k can refill k making the counter
network re-usable. The overall eciency, as in digital computers, has an important
limitation in the carry mechanism unless some additional optimizations are imple-
mented. Notice that the reaction arrows can transform matter either in the same
region or also communicate substances across membranes. The MP grammar in
standard boundary notation is given by:
R
Φ
ϕ 1 = u
r 1 :[ N 1 u
[ R 2 u
r 2 :[ M 1 u
[ R 2 u 2 = u
r 3 :[ N 2 u
[ R 3 u 3 = u
r 4 :[ M 2 u
[ R 3 u 5 = u
r 5 :[ N 3 u
[ R 4 u 4 = u
In = {N 1 ,N 2 ,N 3 ,M 1 ,M 2 ,M 2 }⊆L
Out = {R 1 ,R 2 ,R 3 ,r 4 }⊆L
Start
r 6 :[ M 3 u
[ R 4 u 6 = u
= s
S
r 7 :[ R 4 10 u
[ R 3 7 =1
Halt
= h
S
r 8 :[ R 3 10 u
[ R 2 8 =1
r 9 :[ R 2 10 u
[ R 1 9 =1
r 10 :[ A k
[ A t
10 = s
r 11 :[ A t → [ A k
11 = t
r 12 :[ A t → [ A k
12 = s
r 13 :[ A s → [ A h
13 = k
With the initial configuration
C
=[ A 4 K [7 u ] N 1 [2 u ] N 2 [8 u ] N 3 [3 u ] M 1 [2 u ] M 2 [2 u ] M 3 [] R 1 [] R 2 [] R 3 [] R 4 ].
 
Search WWH ::




Custom Search