Full text
June 23, 2020 21:17 output International Journal of Neural Systems, Vol. XX, No. X (2020) 1–16 c World Scientific Publishing Company A Complete Arithmetic Calculator Constructed from Spiking Neural P Systems and its Application to Information Fusion Gexiang Zhang∗ Research Center for Artificial Intelligence, Chengdu University of Technology, Chengdu, 610059, China E-mail: [email protected] Haina Rong, Prithwineel Paul, Yangyang He School of Electrical Engineering, Southwest Jiaotong University, Chengdu, 610031, China Email: r[email protected], [email protected], [email protected] Ferrante Neri∗ COL Laboratory, School of Computer Science, University of Nottingham, Nottingham, UK E-mail:[email protected] Mario J. P´ erez-Jim´ enez Department of Computer Science and Artificial Intelligence University of Sevilla, Avda. Reina Mercedes s/n, 41012, Spain Email: [email protected] Several variants of spiking neural P systems (SNPS) have been presented in the literature to perform arith- 1 metic operations. However, each of these variants was designed only for one specific arithmetic operation. 2 In this paper, a complete arithmetic calculator implemented by spiking neural P systems is proposed. An 3 application of the proposed calculator to information fusion is also proposed. The information fusion is 4 implemented by integrating the following three elements: 1) an addition and subtraction SNPS already 5 reported in the literature; 2) a modified multiplication and division SNPS; 3) a novel storage SNPS, i.e., 6 a method based on spiking neural P systems is introduced to calculate basic probability assignment of 7 an event. This is the first attempt to apply arithmetic operation SNPS to fuse multiple information. The 8 effectiveness of the presented general arithmetic SNPS calculator is verified by means several examples. 9 Keywords: Membrane computing; spiking neural P system; arithmetic calculator; information fusion. 10 1. Introduction 11 Membrane computing44 is a research field in com- 12 puter science that aims at abstracting computing 13 models from the structure and functioning of liv- 14 ing cells41. These computing models are usually re- 15 ferred to as membrane systems or P systems 64; 45.16 They can be categorised into three classes: 17 •cell-like P systems 44; 67; 40; 38; 58;18 •tissue-like P systems 17; 66; 70;19 •neural-like P systems 27; 39; 42; 52; 65; 50; 57; 29.20 Spiking neural networks (SNNs) can efficiently 21 mimic biological neural networks. These networks 22 are also called as third generation neural networks 23 9; 18; 26; 55; 68; 20; 7; 6; 22; 21; 4 and massively parallel 24 algorithms can be developed using these models 25 2; 1; 5; 3. The neural-like P systems are well-known 26 as spiking neural P systems which are inspired from 27 the structure and functioning of biological neurons. 28 1
June 23, 2020 21:17 output 2Gexiang Zhang et al. Moreover the concepts of SNNs are incorporated29 into these models. Many variants of spiking neural30 P systems have been introduced and computational31 power 11; 60; 13; 35; 42; 53, applications 50; 57; 64; 65; 37 32 of these models have been investigated.33 Arithmetic is a branch of mathematics dealing34 with natural numbers and relations among them.35 A popular field of application of P systems is the36 modelling of arithmetic operations with natural37 numbers, i.e. addition, subtraction, multiplication38 and division33; 56; 19; 35; 15. Moreover, a new type of39 ALU(arithmetic logic unit) can be constructed using40 spiking neural P systems which further can be used41 for designing of CPU (central processing unit). Fur-42 thermore, constructing a complexity-effective ALU43 unit is an interesting area of research. This work is44 an attempt towards that direction. Another motiva-45 tion of this paper is to provide a framework combin-46 ing a relatively new variant of spiking neural net-47 work, i.e., spiking neural P systems and Dempster-48 Shafer (D-S) evidence theory which can be further49 used to solve real-world problems. Spiking neural50 P systems have been very efficient to solve many51 real-world problems such as fault diagnosis, im-52 age processing, computational biology etc. Many53 authors in 30; 8; 16; 61 have investigated new frame-54 works by combining different variants of neural net-55 works and D-S evidence theory to solve real-world56 problems. The information obtained from any sin-57 gle source can be doubtful. Hence information fu-58 sion can reduce inaccuracy and uncertainty in the59 information received from neural networks. In this60 work, a novel framework combining the SN P sys-61 tems and D-S evidence theory is proposed to ex-62 pand the scope of application of the bio-computing63 models, specifically membrane computing models.64 The arithmetic operation models can be di-65 vided into two categories:66 •arithmetic operation models based on cell-67 like P systems 62; 24; 25;68 •arithmetic operation models based on spik-69 ing neural P systems 63; 69; 32; 46; 31; 36; 12.70 The focus of this paper is on the arithmetic oper-71 ation models based on spiking neural P systems72 (SNPS). An SNPS is a class of neural-like P sys-73 tems which is inspired by the neurophysiological74 behavior of neurons sending short electrical im-75 pulses (spikes), identical in shape, along axons from76 presynaptic neurons to postsynaptic neurons in a77 distributed and parallel manner 27. SNPS can be78 viewed as computational model embedding ele-79 ments of a spiking neural network23; 28; 48; 54.80 The basic arithmetic operations models based81 on SNPS include two encoding methods. The first82 method represents the number as the interval of83 elapsed time between two spikes 63; 69; 32. The sec-84 ond method uses a spike sequence (spike train 49)85 to encode the number. Numbers are represented86 in binary and at each step, zero or one spike will87 be supplied to an input neuron, depending upon88 whether the corresponding bit of the binary number89 is 0 or 1 31; 36; 11. The arithmetic operation models90 used in this paper are based on the second encod-91 ing method.92 In Ref.36, the operation models based on SNPS93 were designed for the addition of Narbitrary natu-94 ral numbers, the subtraction of two arbitrary natu-95 ral numbers, and the multiplication of an arbitrary96 natural number by a fixed arbitrary natural num-97 ber, respectively. In Ref.36, an open problem was98 also suggested, that is, how to design an SNPS to99 solve the multiplication of any two arbitrary natu-100 ral numbers. In Ref.69, SNPS were designed to solve101 the multiplication operation of two natural num-102 bers with specified length. But in Ref.69, there is103 only one input neuron, while in Ref.36 there are104 multiple input neurons. In Ref.63 and 32, an adder,105 subtracter, multiplier and divider based on SNPS106 were designed, respectively. But the operation mod-107 els based on SNPS in Ref. 63 and 32 encode the in-108 terval of elapsed time between two spikes, but the109 models in Ref.36 use binary codes, that is, the bi-110 nary code “1” represents one spike and the binary111 code “0” represents no spike. In Ref.46, SNPS were112 used to solve the operations of addition and mul-113 tiplication, but the multiplication could not output114 correct results for some numbers. An SNPS for solv-115 ing the division operation of two signed integer was116 presented in Ref.12, but it could not output correct117 results for some numbers.118 Several variants of SNPS have been discussed119 in the literature to perform arithmetic operations.120 However, each of these variants was designed only121 for a specific arithmetic operation. In the previous122 studies, no integration of several arithmetic opera-123 tions based on SNPS have ever been used to per-124 form a complex computation. Also many SNP sim-125
June 23, 2020 21:17 output A Complete Arithmetic Calculator for Information Fusion Implemented by Spiking Neural P Systems 3 ulators have been introduced 10; 34. Unlike the pre- 126 vious studies, this paper makes the first attempt to 127 implement information fusion by integrating sev- 128 eral arithmetic operations based on SNPS, including 129 addition and subtraction SNPS reported in Ref.31,130 a modified version of the multiplication and divi- 131 sion SNPS proposed in Ref.46; 31; 11, and a novel 132 SNPS, referred to as storage SNPS. The five types 133 of operations designed by SNPS cooperate to fulfill 134 the computation of D-S evidence information fusion 135 14; 51. Also, the construction of SNPS simulator and 136 the information fusion implementation discussed in 137 this paper can be performed with less number of 138 neurons because we considered a new variant of 139 extended spiking neural P systems for performing 140 the arithmetic operations. Extended spiking neural 141 P systems are computationally universal and hence 142 the model considered in this paper is also compu- 143 tationally universal. One major advantage of con- 144 sidering this model is that it can perform the arith- 145 metic operations with less number of neurons, i.e., it 146 is a good model from the descriptional complexity 147 point of view. 148 The remainder of this paper is organized as fol- 149 lows. Section 2 briefly introduces spiking neural P 150 systems and the notation used throughout this ar- 151 ticle. Section 3 presents four arithmetic units (addi- 152 tion, subtraction, multiplication and division units), 153 storage unit and their simulator. In section 4, the in- 154 formation fusion SNPS is proposed to achieve two 155 instances of D-S evidence information fusion. Fi- 156 nally, conclusions are drawn in Section 5. 157 2. Spiking neural P systems 158 Definition 1. A spiking neural P system of degree 159 m≥1is a computational model identified by the 160 tuple27; 13:161 Π=(O, σ1, ..., σm, syn, in, out)162 where 163 (1) O={a}is a singleton alphabet where ais called 164 spike;165 (2) σ1,...σmare neurons, where σi= (ni, Ri),1≤166 i≤m, being 167 (a) niis the initial number of spikes contained in σi;168 (b) Riis the set of rules associated with σiof the 169 following two types: 170 (i) spiking rule:E/ac→a;d171 where Eis a regular expression over O, and 172 c≥1, d ≥0. The spiking rule is applicable if 173 a neuron σicontains kspikes, with k≥cand 174 ak∈L(E). This rule removes cspikes after a de- 175 lay of dsteps and after a spike is sent to the neu- 176 rons connected with the neuron where the rule 177 is applied. If d= 0, then one spike is sent to 178 the connected neurons immediately after appli- 179 cation of the rule. Furthermore, if L(E) = {ac}180 then the rule can be simply written as ac→a;d.181 It is important to note that if d≥1and the rule 182 is applied at any time t, then during the period 183 t, t + 1, t + 2, . . . , t +d−1the neuron becomes 184 closed, i.e., no spike can arrive and no spike can 185 leave the neuron during this period. However, 186 the neuron becomes open again at the step t+d.187 (ii) forgetting rule:as→λ188 with λthe empty string and san integer ≥1.189 The forgetting rule works with the following re- 190 striction, i.e., as/∈L(E)that for any spiking rule 191 E/ac→a;dof type (i) from Ri. Moreover this 192 rule is applicable in a neuron σiwhen it con- 193 tains sspikes and after application sspikes are 194 removed from the system. 195 A generalization of spiking neural P systems is 196 known as extended spiking neural P systems 197 where the rules are of the form E/ac→ap;d, 198 c≥1, p ≥1and p≤c. The above mentioned 199 spiking rules are special cases of extended spik- 200 ing neural P systems with p= 1.201 (3) syn ⊆ {σ1, σ2, . . . , σm} × {σ1, σ2, . . . , σm}with 202 (σi, σi)/∈syn,1≤i≤mrepresents the synap- 203 tic connection between the neurons. In fact, syn is 204 a directed graph of synapses between the linked 205 neurons; 206 (4) in, out ⊆ {σ1, σ2, . . . , σm}indicate the input neu- 207 ron set and the output neuron set of Π, respec- 208 tively. 209 Note: Forgetting rules used in this paper are of 210 the form am/an→λwhere m≥n, am/∈L(E)for 211 any spiking rule of the form E/ac→ap. Further- 212 more, after application of this rule nspikes are con- 213 sumed and (m−n)spikes will remain inside the 214 neuron. 215
June 23, 2020 21:17 output 4Gexiang Zhang et al. 3. Arithmetic operation units216 In this section, a natural number is coded in bi-217 nary and a series of spikes is used to represent the218 coded number. For the input and output neurons,219 one spike represents the binary bit “1” and no spike220 represents the binary bit “0”. The following subsec-221 tions outline the four arithmetic operation units (ad-222 dition, subtraction, multiplication and division) as223 well as the storage unit and their simulator.224 3.1. Add unit225 The Add unit initially introduced in Ref.31 and used226 in this paper, performs the addition operation of227 two arbitrary natural numbers (each natural num-228 ber is represented by a binary string). The Add unit229 is identified with the following SNPS:230 ΠAdd = (O, σ1, σ2, σ3, syn, in, out)231 where232 (1) O={a};233 (2) σi= (0, Ri),Ri={a→a},i= 1,2;234 (3) σ3= (0, R3),R3={a→a, a2/a →λ, a3/a →a};235 (4) syn ={(σ1, σ3),(σ2, σ3)};236 (5) in ={in1, in2}, being in1=σ1, in2=σ2;237 (6) out ={σ3}.238 aĺa aĺa aĺa a 2 /aĺ ° a 3 /a 2 ĺa I 1 I 2 Output ı 1 ı 2 ı 3 (a) 239 ADD I1 I2 Output (b) 240 Fig. 1. Add unit. The add functioning can be described in the fol-241 lowing way. When two binary strings with mand242 nbits are given as input to the input neurons from243 low to high bits at step t, respectively, the neuron244 σ3starts to output the sum of binary strings from245 low to high bits at step t+3. Fig. 1(a) and Fig. 1(b)246 show the detailed and simplified structures of the247 Add unit, respectively.248 In order to illustrate how the Add unit works,249 we take (1110)2+ (101)2= (10011)2as an example.250 Table 1 shows the changes of the numbers of spikes251 for neurons σ1, σ2, σ3, respectively, and the output.252 253 Table 1. Changes of the numbers of spikes in Add254 unit255 No. of steps σ1σ2σ3output 0 0 0 0 - 10 1 0 - 21 0 1 - 31 1 11 410 2 1 5 0 0 2 0 6 0 0 1 0 7 0 0 0 1 3.2. Sub unit256 The Sub unit used in this paper was introduced in257 Ref.31. The Sub unit can perform the subtraction258 operations of two arbitrary natural numbers repre-259 sented by binary strings under the condition that260 the minuend must be greater than subtrahend. The261 SNPS of the Sub unit262 ΠSub = (O, σ1, . . . , σ10, syn, in, out), where263 (1) O={a};264 (2) σi= (0, Ri),Ri={a→a},1≤i≤9, i 6= 3; σ3=265 (a, R3), R3={a→a};266 (3) σ10 = (0, R10),R10 ={a→λ, a2/a →a, a3/a2→267 λ, a4→a, a5→λ, a6/a5→a};268 (4) syn ={(σ1, σ4),(σ1, σ5),(σ1, σ6),(σ2, σ7),(σ3, σ8),269 (σ3, σ9),(σ8, σ9),(σ9, σ8),(σ4, σ10),(σ5, σ10),270 (σ6, σ10),(σ7, σ10),(σ8, σ10)};271 (5) in ={in1, in2}, being in1=σ1, in2=σ2;272 (6) out ={σ10}.273 When two binary strings with mand nbits are en-274 tered into the input neurons from lower to higher275 bits at step t, respectively, the neuron σ10 will start to276 output the subtraction of binary strings from lower277 to higher bits at step t+4. Fig. 2(a) and Fig. 2(b) show278 the detailed (10 neurons) and simplified Sub unit279 models, respectively.280
June 23, 2020 21:17 output A Complete Arithmetic Calculator for Information Fusion Implemented by Spiking Neural P Systems 5 aĺa aĺa aĺa aĺa aĺa aĺa a aĺa aĺa aĺa aĺ ° a 2 /aĺa a 3 /a 2 ĺ ° a 4 ĺa a 5 ĺ ° a 6 /a 5 ĺa I 1 I 2 ı 4 ı 3 ı 6 ı 5 ı 8 ı 9 ı 1 ı 2 ı 7 ı 10 Output (a) 281 SUB I 1 I 2 Output (b) 282 Fig. 2. Sub unit. In order to illustrate the functioning of the Sub 283 unit, the operation (1110)2−(101)2= (1001)2is 284 taken as an example. Table 2 shows the changes of 285 the numbers of spikes for Sub unit neurons and the 286 output of neuron σ10.287 288 Table 2. Changes of the numbers of spikes in Sub unit No. of steps σ1σ2σ3σ4σ5σ6σ7σ8σ9σ10 output 0 0 0 1 0 0 0 0 0 0 0 - 10 1 0 0 0 0 0 1 1 0 - 21 0 0 0 0 0 1 1 1 1 - 31 1 0 1 1 1 0 1 1 2 0 410 0 1 1 1 1 1 1 5 1 5 0 0 0 1 1 1 0 1 1 5 0 6 0 0 0 0 0 0 0 1 1 4 0 7 0 0 0 0 0 0 0 1 1 1 1 3.3. Mul unit 289 The Mul unit used in this paper is a modified 290 version of the unit presented in Ref.46. The mod- 291 ified Mul unit is as shown in Fig. 3 and Fig. 4, 292 in its detailed and simplified schemes, respectively. 293 The novel/modified rules are highlighted in Fig. 3 294 within a dashed frame. 295 This version extends to any pair of arbitrary 296 natural numbers the applicability of the Mul unit. 297 In order to understand the functioning of this unit, 298 let us consider two natural numbers Xand Yex- 299 pressed as binary strings 300 (x0, x1, . . . , xm−1) (y0, y1, . . . , yn−1)301 and they can be represented as sum of mand n302 terms in the following manner 303 X= m−1 X i=0 xi2i, Y = n−1 X j=0 yj2j.304 The multiplication number Zis 305 306 Z=X·Y= m−1 X i=0 y0xi2i+0 + m−1 X i=0 y1xi2i+1 +· · · +307 + m−1 X i=0 yn−2xi2i+n−2+ m−1 X i=0 yn−1xi2i+n−1308 309 Hence, the multiplication of Z=X·Ycan be ful- 310 filled by performing naddition operations. 311 The jth addition operation 312 m−1 X i=0 yjxi2i+j313 expresses the product of Xand yj2j. If yj= 1, the 314 computing result of the expression is X·2j, which 315 means jbits of Xare moved left. If yj= 0, the com- 316 puting result of the expression is 0. Hence we can 317 conclude that X.Y can be represented as sum of X318 copies of number of 1’s in the binary representation 319 of Y. As shown in Fig. 3, the neurons, σa10, σa11 and 320 σd1can obtain the first addition operation 321 m−1 X i=0 y0xi2i+0 322 Similarly, the kth addition operation 323 m−1 X i=0 ykxi2i+k324 can be achieved by neurons σak0, σak1, . . . , σakk, σdk.325 In Fig. 3, Part 1 with the dashed frame obtains the 326 input Xfor naddition operations and Part 2 with 327 the dashed frame achieves yjinput for naddition 328 operations. The neuron σ3gains the sum of naddi- 329 tions. 330
June 23, 2020 21:17 output 6Gexiang Zhang et al. aĺa I 1 aĺa aĺa aĺa aĺa aĺa aĺa aĺa a i /a i/2 ĺ ° , i=2k, Where, ʿNʿ>n2@ a j /a (j+1)/2 ĺa, j=2k-1, Where, ʿNʿ>n2@ a aĺa aĺa aĺa aĺa aĺa aĺ ° a 2 ĺa aĺa; d=m-1 aĺa a 2 ĺ ° aĺa a 2 ĺ ° aĺ ° a 2 ĺa aĺa; d=m-1 aĺa a 2 ĺ ° aĺa a 2 ĺ ° aĺ ° a 2 ĺa aĺa; d=m-1 aĺa a 2 ĺ ° aĺa a 2 ĺ ° aĺa aĺ ° a 2 ĺa aĺ ° a 2 ĺa aĺ ° a 2 ĺa I 2 ı 3 Part 1 Part 3 modified Part 2 ı a10 ı a11 ı a20 ı a21 ı a22 ı an0 ı an1 ı ann ı b0 ı b1 ı b2 ı bn ı c1 ı c2 ı cn ı e11 ı e12 ı e13 ı e21 ı e22 ı e23 ı en1 ı en2 ı en3 ı d1 ı d2 ı dn ı 1 ı 2 Output Fig. 3. Mul unit. MUL I1 I2 Output MUL I1 I2 Output 331 Fig. 4. Simplified version of Mul unit. The proposed Mul unit shown in Fig. 3 is gen-332 eral and needs to be adjusted according to the333 number of binary bits representing different natu-334 ral numbers. In our example, the Mul unit is used to335 calculate Z=X·Y, where Xis the binary string336 with mbits and Yis the binary sequence with n337 bits. Without a loss of generality, let us assume that338 n≤m. First of all, we should adjust the Mul unit339 according to the general unit which is shown in340 Fig. 3. To simplify the Mul unit, the Ywhich has341 the smaller number of binary bits should be used342 as the multiplier input through neuron σ2. Hence,343 the Mul unit includes n2+15n+8 2neurons because the344 neurons in Part 1 are associated with position of 1’s345 in X. Secondly, Xand Ywith binary strings from346 lower to higher bits are inputted into neurons σ1 347 and σ2at step t, respectively. Finally, σ3starts to out-348 put the product through binary sequence from low349 to high bits at step t+6.350 From the above explanation we know that in351 the Mul unit the string with bigger length is con-352 sidered as the multiplicand and the other string is353 considered as multiplier. In Part 2, if any input is354 1, i.e., yj= 1 for any 0≤j≤(n−1), then in355 the next step the neurons σc1, σc2, . . . , σcn receive356 two spikes. Subsequently, one spike is sent to the357 neurons σe11, σe21, . . . , σen1and σei2, σei3(1 ≤i≤358 n). In the next step σi2(1 ≤i≤n)spikes and359 one spike is sent to σdj(1 ≤j≤n). Neuron σd1 360 stores the value of the summation Pm−1 i=0 y0xi2i+0.361 Similarly, σd2stores the value of the summation362 Pm−1 i=0 y1xi2i+i.Finally the n-th neuron stores the363 value Pm−1 i=0 ynxi2i+n.364 In Part 3, the output of the multiplication of any365 two binary numbers Xand Yis computed, i.e., sum366
June 23, 2020 21:17 output A Complete Arithmetic Calculator for Information Fusion Implemented by Spiking Neural P Systems 7 of the binary numbers stored in σd1, σd2, . . . , σdn is 367 calculated. If i= 2kwhere 1≤k≤[n 2]then the 368 forgetting rule ai/a i 2→λis applied. After applica- 369 tion of this rule i 2number of spikes are consumed 370 and i 2number of spikes remains inside the neuron 371 σ3(This rule helps us to identify with sum of two 372 1’s). 373 Similarly, the rule aj/aj+1 2→awhere j= 2k−1374 is an odd number and 1≤k≤[n 2]helps us to relate 375 with the sum of 1and 0.376 To clearly illustrate the operation process of the 377 Mul unit, (1110101)2×(11101)2= (110101000001)2378 is taken as an example. Table 3 shows the changes 379 of the numbers of spikes for the key neurons in Mul 380 unit and the output of neuron σ3.381 The total number of neurons in the Mul unit 382 can be derived in the following manner. 383 Example 1. 384 Total number of neurons in Part 1is 1 + 385 2+3+. . . +n+ (n+ 1) = (n+1)(n+2) 2. To- 386 tal number of neurons in Part 2 is 1[σ2] + (n+387 1)[σb0, . . . , σbn]+n[σc1, . . . , σcn]+n[σe11, . . . , σen1]+ 388 2n[{σe12, σe13},...,{σen2, σen3}]=5n+ 2. Total 389 number of neurons outside Part 1and Part 2is 390 n[σd1, . . . , σdn] + 1[σ3]. So total number of neurons 391 in Mul unit is (n+1)(n+2) 2+5n+2+n+1 = n2+15n+8 2.392 393 Table 3. Changes of the numbers of spikes in Mul unit No. of stepsσ1σ2σa11 σa22 σa33 σa44 σa55 σd1σd2σd3σd4σd5σ3output 0 0 0 0 0 0 0 0 0 0 0 0 0 0 - 11 1 0 0 0 0 0 0 0 0 0 0 0 - 20 0 0 0 0 0 0 0 0 0 0 0 0 - 31 1 1 0 0 0 0 0 0 0 0 0 0 - 40 1 0 1 0 0 0 2 0 0 0 0 0 - 51 1 1 0 1 0 0 1 1 0 0 0 1 - 610 0 1 0 1 0 2 0 2 0 0 0 1 710 1 0 1 0 1 1 1 1 2 0 2 0 8 0 0 1 1 0 1 0 2 0 2 1 2 2 0 9 0 0 1 1 1 0 1 2 1 1 2 1 4 0 10 0 0 0 1 1 1 0 2 1 2 1 2 4 0 11 0 0 0 0 1 1 1 0 1 2 2 1 5 0 12 0 0 0 0 0 1 1 0 0 2 2 2 4 1 13 0 0 0 0 0 0 1 0 0 0 2 2 5 0 14 0 0 0 0 0 0 0 0 0 0 0 2 4 1 15 0 0 0 0 0 0 0 0 0 0 0 0 3 0 16 0 0 0 0 0 0 0 0 0 0 0 0 1 1 17 0 0 0 0 0 0 0 0 0 0 0 0 0 1 3.4. Div unit 394 The Div unit used in this paper is a modified ver- 395 sion of the unit proposed in Ref.12. The Div unit in 396 Ref.12 has two drawbacks. Firstly, the correct quo- 397 tient of any two signed non-zero integers cannot be 398 obtained. Secondly, the output is usually not clear 399 because the Div unit returns multiple outputs at dif- 400 ferent steps. Due to this second drawback, it is nec- 401 essary to identify the correct quotient from the mul- 402 tiple sets according to the marked spike of neuron 403 σs. With reference to the notation used for the Add 404 unit, the simplified scheme of the Div unit high- 405 lighting the multiple outputs is shown in Fig. 5. In 406 this case, the lengths of the two binary strings of 407 both dividend and quotient is the same (m=n). 408 DIV m=n control out n-1 y n-1 x n-2 y n-2 x 0 y 0 out n-2 out 0 x n-1 409 Fig. 5. Simplified version of Div unit. The modified Div unit is shown in Fig. 6. The 410 modified section is highlighted within the dotted 411 frame where the correct quotient ranks at the top of 412 the outputted sets. In other words, when the output 413 neurons have spiking rules to apply, the first output 414 is the quotient. Thus, the modified version avoids 415 the identification process of several outputs. 416 417 Table 4. Changes of the numbers of spikes in Div unit No. of stepsσa0σa1σa2σa3σs1σp0σp1σp2σp3σb4σ8out0out1out2out3 1 0 0 0 0 0 0 0 0 0 0 0 - - - - 2 0 0 0 0 0 0 0 0 0 0 0 - - - - 3 0 0 0 0 0 0 0 0 0 0 0 - - - - 4 2 0 2 1 0 0 0 0 0 1 0 - - - - 5 2 1 0 2 0 0 0 0 0 1 0 - - - - 6 0 1 0 0 0 0 0 0 0 1 0 - - - - 7 0 1 0 0 0 0 0 0 0 1 0 - - - - 8 2 1 1 1 0 0 0 0 0 1 0 - - - - 9 0 2 1 1 0 0 0 0 0 1 0 - - - - 10 0 0 2 1 0 1 0 0 0 1 0 - - - - 11 0 0 0 2 0 1 0 0 0 1 0 - - - - 12 2 0 1 1 0 1 0 0 0 1 0 - - - - 13 0 1 1 1 0 1 0 0 0 1 0 - - - - 14 0 1 1 1 0 2 0 0 0 1 0 - - - - 15 0 1 1 1 0 0 1 0 0 1 0 - - - - 16 2 1 2 2 0 0 1 0 0 1 0 - - - - 17 0 2 0 1 1 0 1 0 0 1 1 - - - - 18 0 0 1 1 0 3 4 3 3 1 0 - - - - 19 0 0 1 1 0 0 3 3 2 1 0 - - - - 20 2 0 2 2 0 0 0 2 2 1 0 - - - - 21 0 0 0 1 0 0 0 0 1 1 0 0100 The scheme in Fig. 6 refers to a general model 418 with 9n+ 25 neurons for calculating the quotient 419 of two numbers xand y, namely x/y, with nbits, 420 where x= (xn−1, . . . , x0)and y= (yn−1, . . . , y0)are 421 signed nonzero binary integers. The values xn−1,422 . . .,x0and yn−1,..., y0are the inputs of neurons 423
June 23, 2020 21:17 output 8Gexiang Zhang et al. aĺa aĺa; d=1 aĺa aĺa aĺa aĺa a2ĺ ¬ aĺa aĺa a2ĺ ¬ a3ĺa R R aĺa a2ĺ ¬ aĺa a2ĺ ¬ aĺa; d=1 aĺa; d=2 aĺa a2ĺ ¬ R R a2ĺa a3/a2ĺa aĺa; d=1 aĺa; d=2 aĺa a2ĺ ¬ R R a2ĺa a3/a2ĺa aĺa; d=1 aĺa; d=2 aĺa a2ĺ ¬ R R a2ĺa a3/a2ĺa aĺa R R aĺa aĺa aĺ ¬ a2ĺ ¬ a3 ĺa a4 ĺ ¬ aĺa aĺa aĺa; d=1 a2ĺa a3ĺa2 a4/a3ĺa3 aĺa a2ĺ ¬ R R aĺa a2ĺ ¬ aĺa; d=1 RR aĺa; d=1 aĺa aĺ ¬ a3ĺa a4ĺa2 a2ĺa a3ĺa2 a4/a3ĺa3 a2ĺa a3ĺa2 a4/a3ĺa3 a5 a6ĺa6 aĺ ¬ a3ĺa a4ĺa2 aĺ ¬ a3ĺa a4ĺa2 yn-1 xn-1 yn-2 xn-2 y1x1y0x0 ıpıyn-1 ıxn-1 ıyn-2 ıxn-2 ıy1 ıx1 ıy0 ıx0 ı0ı1 ı2 ıcn-1 ı'rn-1 ırn-1 ı'an-1 ıan-1 ıtıt2 ıt1 ıs ıst ı7ıs2 ıs1 ı6ıp0 ıp1 ıpn-1 ı8 ız0 ıout0 ızn-1 ıb2 ıb1 ı5 ıop ıcn-2 ırn-2 ı'rn-2 ıan-2 ıc1 ır1 ı'r1 ıa1 ıa0 ı'r0 ır0 ıc0 ı3 ıb3 ıb4 ı4 ıb5 ıb6 R={aĺa; n-1} aĺ ¬ a2ĺa aĺ ¬ a2ĺa aĺ ¬ a2ĺa out1 out0outn-1 ıout1 ıoutn-1 ız1 control Fig. 6. Div unit. σxn−1,. . .,σx0and σyn−1,. . .,σy0, respectively. The424 result of the computation is collected through neu-425 rons σout0,. . .,σoutn−1from lower to higher bits.426 Note that xn−1, yn−1and zn−1are sign bits. More-427 over, non-restoring division algorithm has been per-428 formed to calculate the quotient in the framework429 of SN P systems. This algorithm has advantages in430 hardware implementation.431 Non-restoring division algorithm contains432 three registers Q, M and Awhere initially Q=div-433 idend =x, M =divisor, A= 0. In the next step, the434 sign bit of the register Ais checked. If it is 1,AQ is435 shifted left and Ais updated as A+Mand simi-436 larly if it is 0,Ais updated as A−M. This task is437 performed by the neurons xi(0 ≤i≤n−1),yj(0 ≤438 j≤n−1),σci,(0 ≤i≤n−1),σ0 ri,0≤i≤n−1,439 σai,0≤i≤n−1, σ0 an−1,σ0, σ1, σ2, σ3, σp, σb3and440 σb4.441 The neurons σxi(0 ≤i≤n−1) and σyj(0 ≤442 j≤n−1) are the input neurons. The delays d= 2443 and d= 1 are associated with these neurons respec-444 tively. After receiving the inputs, these neurons can-445 not fire immediately. However, in the next step the446 control is activated and it further activates the neu-447 ron σpin the next step. Subsequently, σpsends one448 spike to the neurons σci(0 ≤i≤n−1) and σ3. At the449 same time the rules present in the neurons σyjsend450 one spike to the neurons σci,0≤i≤n−1. In the451 next step, the neurons σai,1≤i≤n−1receive the452 spikes from σci and σxifor 1≤i≤n−1. Further-453 more, σa0receives spikes from σc0, σx0and σ3. This454 process is further continued by sending spikes from455 the neuron σa0to σa1,σa1to σa2, and eventually the456 neuron σan−2sends one spike to σ0 an−1and σan−1 457 where these two neurons send spike to each other458 using the rule a→aand a2→λ. Note that the neu-459 rons σ0, σ1and σ2are introduced to adjust the delay460 d= 1 and d= 2 of the neurons yj(0 ≤j≤n−2)461 and xi(0 ≤i≤n−2) respectively.462 In the next step of non-restoring algorithm, the463 sign bit of the register Ais again checked. If the464 bit is 1, then Q[0] is 0, otherwise it is 1. Next, Nis465 decremented by 1, where |Q|=number of bits in466 Q=N. If N6= 0, then the previous steps are re-467
June 23, 2020 21:17 output A Complete Arithmetic Calculator for Information Fusion Implemented by Spiking Neural P Systems 9 peated. Otherwise, if the sign beat of Ais 1, it is up- 468 dated by A+M. This task is performed by the neu- 469 rons σt, σt1, σt2, σs, σs1, σs2, σst, σ6, σ7, σ8, σb5, σb6470 and σpi,0≤i≤n−1.471 After receiving the inputs in σxn−1and σyn−1,472 one spike is sent to σpand σxn−1sends one spike to 473 σt. In the next step, σpspikes according to the rules 474 present inside it. If it contains 1or 3spikes then it 475 sends one spike to σcj,0≤j≤(n−1) and the above 476 mentioned process is continued. 477 When the neuron σtreceives one spike from 478 σxn−1, the rule a→awith delay 1is applied. At 479 t= 3, it sends spikes to σt1and σt2. Next, the neuron 480 σt1sends one spike to σs. At the same time σ0 an−1481 sends one spike to σs. Also the supply of spikes to 482 the neuron σsis continued by the neurons σt1and 483 σt2and σ0 an−1and σan−1by sending one spike to 484 each other. 485 Note that the inputs received in the neurons are 486 initially processed in σaj,(0 ≤j≤n−1) and σ0 an−1.487 Again the processed input is sent to the neuron σs488 which further sends it to σp0, σp1, . . . , σpn−1and fur- 489 ther processed using the rules present in the system. 490 Finally, in the non-restoring algorithm the reg- 491 ister Qcontains the quotient. In the framework of 492 SN P systems, the neurons σout0, σout1, . . . , σoutn−1493 and σzi,0≤i≤n−1process the spikes re- 494 ceived from the neurons in the previous steps and 495 the output is collected depending on the spik- 496 ing/ non-spiking of the neurons in the neurons 497 σout0, σout1, . . . , σoutn−1. More specifically, the neu- 498 rons σ7and σpj,0≤j≤(n−1) spike at the 499 same time and send spikes to the neurons σzj,0≤500 j≤(n−1). The neurons in these neurons con- 501 tain three types of rules, i.e., a→λ, a3→aand 502 a4→a2and they are applied non-deterministically 503 and send one, two or zero spikes to the neurons 504 σoutj,0≤j≤(n−1). Moreover, these neurons 505 contain only the rules a→λand a2→aand non- 506 deterministic application of these rules can obtain 507 the output of the division of two binary numbers. 508 To clearly illustrate the operation functioning 509 of the Div unit, (0100)2/(0010)2= (0010)2is taken 510 as an example. At the beginning, y= (0010)2and 511 x= (0100)2are considered as the inputs of neurons, 512 i.e. y0= 0,y1= 1,y2= 0,y3= 0,x0= 0,x1= 0,513 x2= 1 and x3= 0. Table 4 shows the changes of 514 the numbers of spikes for the key neurons in Div 515 unit and the output of neurons σout0,σout1,σout2516 and σout3.517 3.5. Storage unit 518 Within the process of implementing the information 519 fusion, the calculation of polynomials often requires 520 complex arithmetic operations which involves mul- 521 tiple units. Thus, it is necessary to store the results of 522 intermediate calculations, which could be regarded 523 as the inputs to subsequent calculations. This paper 524 proposes a novel storage unit based on SNPS. The 525 storage unit can keep a certain number of binary 526 strings and can update the stored values accord- 527 ing to the input and control neurons. The simplified 528 scheme of the storage unit is depicted in Fig. 7. 529 Fig. 8 displays the detailed model of the stor- 530 age unit. In the storage unit, nbinary bits for a bi- 531 nary number are considered as the inputs of neu- 532 rons σ0,. . .,σn−1from low to high bits, respectively. 533 Then, three spikes are inputted into the neurons σc534 as the control signal. After two steps, nbinary bits 535 are saved into neurons σs0,. . .,σsn−1, and the num- 536 ber is outputted at each step. 537 SAVE Control outn-1 xn-1 x0 ... ... out0 SAVE Control outn-1 xn-1 x0 ... ... out0 Fig. 7. Simplified version of storage unit. 3.6. Simulator for SNPS 538 As described in the Subsections above, Mul, Div 539 and storage units contain dozens or even hundreds 540 of neurons which perform a large number of cal- 541 culations since each unit may contain many steps. 542 Hence, a manual calculation of the SNPS is ex- 543 tremely impractical and a proper simulating soft- 544 ware is required. 545 Fig. 9 describes the pseudocode of the novel 546 SNPS simulator developed in this study to auto- 547 matically accomplish the computation of arithmetic 548 units. The simulator is made by considering neu- 549 ron’s behaviors such as receiving spikes, applying 550 rules, spiking and sending spikes out of the neu- 551 ron, saving spikes inside the neuron and sending 552 spikes out of the neuron at every step. Furthermore, 553 the simulator builds the connection between neu- 554
June 23, 2020 21:17 output 16 Gexiang Zhang et al. nomics: Numerical p systems, Fundamenta Informati-998 cae 73 (2006) 213–227.999 44. G. P˘ aun, Computing with membranes, Journal of1000 Computer and System Sciences 61(1) (2000) 108–143.1001 45. G. P˘ aun, G. Rozenberg and A. Salomaa, The Oxford1002 Handbook of Membrane Computing (Oxford University1003 Press, Inc., New York, NY, USA, 2010).1004 46. X. Peng, X. Fan, J. Liu and H. Wen, Spiking neural1005 P systems for performing signed integer arithmetic1006 operations., Journal of Chinese Computer Systems 34(2)1007 (2013) 360–364.1008 47. I. P´ erez-Hurtado, M. ´ A. Mart´ ınez-del-1009 Amor, G. Zhang, F. Neri and M. J. P´ erez-Jim´ enez, A1010 membrane parallel rapidly-exploring random tree al-1011 gorithm for robotic motion planning, Integr. Comput.1012 Aided Eng. 27(2) (2020) 121–138.1013 48. F. Ponulak and A. Kasinski, Introduction to spik-1014 ing neural networks: information processing, learn-1015 ing and applications, Acta Neurobiologiae Experimen-1016 talis 71(4) (2011) 409–433.1017 49. G. P˘ aun, M. J. P´ erez-Jim´ enez and G. Rozenberg, Spike1018 trains in spiking neural P systems, International Jour-1019 nal of Foundations of Computer Science 17(4) (2006) 975–1020 1002.1021 50. H. Rong, K. Yi, G. Zhang, J. Dong, P. Paul and1022 Z. Huang, Automatic implementation of fuzzy rea-1023 soning spiking neural P systems for diagnosing faults1024 in complex power systems, Complexity 2019 (2013)1025 Article ID 2635714, 16 pages.1026 51. G. Shafer, A Mathematical Theory of Evidence (Prince-1027 ton University Press, 1976).1028 52. T. Song, L. Pan and Gh. P˘ aun, Asynchronous spiking1029 neural P systems with local synchronization, Informa-1030 tion Sciences 219 (2013) 197–207.1031 53. T. Song, L. Pan and G. P˘ aun, Asynchronous spiking1032 neural P systems with local synchronization, Informa-1033 tion Sciences 219 (2013) 197–207.1034 54. S. Stefan, K. Nikola and D.-P. Michael, On the prob-1035 abilistic optimization of spiking neural networks, In-1036 ternational Journal of Neural Systems 20(6) (2010) 481–1037 500.1038 55. Y. Todo, Z. Tang, H. Todo, J. Ji and K. Yamashita,1039 Neurons with multiplicative interactions of nonlinear1040 synapses, International Journal of Neural Systems 29(8)1041 (2019) p. Article No. 1950012.1042 56. H. Wang, K. Zhou and G. Zhang, Arithmetic opera-1043 tions with spiking neural P systems with rules and1044 weights on synapses., International Journal of Comput-1045 ers, Communications & Control 13(4) (2018,) 574–589.1046 57. T. Wang, G. Zhang, J. Zhao, Z. He, J. Wang and M. J.1047 P´ erez-Jim´ enez, Fault diagnosis of electric power sys-1048 tems based on fuzzy reasoning spiking neural P sys-1049 tems, IEEE Transactions on Power Systems 30 (ISSN1050 0885–8950, 2015) 1182–1194.1051 58. X. Wang, G. Zhang, F. Neri, T. Jiang, J. Zhao, M. Gheo-1052 rghe, F. Ipate and R. Lefticaru, Design and implemen-1053 tation of membrane controllers for trajectory tracking1054 of nonholonomic wheeled mobile robots, Integrated1055 Computer-Aided Engineering 23(1) (2016) 15–30.1056 59. X. Wang, G. Zhang, F. Neri, T. Jiang, J. Zhao, M. Gheo-1057 rghe, F. Ipate and R. Lefticaru, Design and implemen-1058 tation of membrane controllers for trajectory tracking1059 of nonholonomic wheeled mobile robots, Integr. Com-1060 put. Aided Eng. 23(1) (2016) 15–30.1061 60. T. Wu, F. Bilbie, A. Paun, L. Pan and F. Neri, Simpli-1062 fied and yet turing universal spiking neural P sys-1063 tems with communication on request, International1064 Journal of Neural Systems 28(8) (2018).1065 61. H. Xiang and D. Wang, The application of genetic1066 bp neural network and d-s evidence theory in the1067 complex system fault diagnosis, Recent Advances in1068 Computer Science and Information Engineering, Springer,1069 Berlin, Heidelberg, 2012, pp. 219–224.1070 62. R. Yang, P. Guo, J. Li and P. Gu, Arithmetic P systems1071 based on arithmetic formula tables, Chinese Journal of1072 Electronics 24(3) (2015) 542–549.1073 63. X. Zeng, T. Song, X. Zhang and L. Pan, Performing1074 four basic arithmetic operations with spiking neu-1075 ral P systems, IEEE Transactions on Nanobioscience 111076 (ISSN 1558–2639 2012) 366–374.1077 64. G. Zhang, M. J. P´ erez-Jim´ enez and M. Gheorghe,1078 Real-life Applications with Membrane Computing: Emer-1079 gence, Complexity and Computation (Springer Interna-1080 tional Publishing, 2017).1081 65. G. Zhang, H. Rong, F. Neri and M. P´ erez-Jim´ enez,1082 An optimization spiking neural P system for approxi-1083 mately solving combinatorial optimization problems,1084 International Journal of Neural Systems 24 (ISSN 1793–1085 6462 2014) 1–16.1086 66. G. Zhang, J. Cheng, M. Gheorghe and Q. Meng, A hy-1087 brid approach based on differential evolution and tis-1088 sue membrane systems for solving constrained man-1089 ufacturing parameter optimization problems, Applied1090 Soft Computing 13(3) (2013) 1528–1542.1091 67. G. Zhang, M. Gheorghe, L. Pan and M. J. P´ erez-1092 Jim´ enez, Evolutionary membrane computing: A1093 comprehensive survey and new results, Information1094 Sciences 279 (2014) 528–551.1095 68. X. Zhang, G. Foderaro, C. Henriquez and S. Ferrari,1096 A scalable weight-free learning algorithm for regula-1097 tory control of cell activity in spiking neuronal net-1098 works, International Journal of Neural Systems 28(2)1099 (2018) p. 1750015.1100 69. X. Zhang, X. Zeng, L. Pan and B. Luo, A spiking neu-1101 ral P system for performing multiplication of two ar-1102 bitrary natural numbers, Chinese Journal of Computers1103 32 (ISSN 0254–4164 2009) 2362–2372.1104 70. X. Zhang, Y. Liu, B. Luo and L. Pan, Computational1105 power of tissue P systems for generating control lan-1106 guages, Information Sciences 278 (2014) 285–297.1107