## 6 Comparison with the SNN Dynamics  
The generation of the photorefractive soliton network was schematized following the experimental configuration used for a single X-junction [18]. We considered a lithium niobate crystal as large as 150 \(\upmu\)m along the \(x\) and \(y\) axes and 10 mm along the propagation axis (\(z\) axis). The experimental numerical parameters used in the simulations are reported in Table 5. Four equal intensity write beams were injected into the input to create the initial balanced network. These beams cross in pairs and then totally reflect at the substrate boundaries [23; 24; 25] to recreate the geometry of the network previously described in Figure 3. The result is a perfectly balanced network, which means that if any further signal propagating inside a waveguide reaches the crossing, it will be split 50\(-\)50 to the output channels. Thus, it represents a virgin network from the point of view of learning. Each elementary unit (neuron) is formed by a X-junction [14], whose small angle of about \(1^{\circ}\) allows for coupling between the crossing channels. The learning dynamics of the network derive from the imbalance of each single junction (SJR), following a logic of distributed intelligence. The complex 4-bit SNN network used here follows the functional scheme described above, using a cascade protocol for which the inputs of a deeper level of the network correspond to the outputs processed by the previous one. \begin{table}
\begin{tabular}{c c c c c c c c c c c c c c} \hline \hline \multicolumn{1}{c}{**(a)**} & \multicolumn{3}{c}{**Single junction Ratio: 0.7\(-\)0.3**} & \multicolumn{3}{c}{**(b)**} & \multicolumn{3}{c}{**Single Junction Ratio: 0.8\(-\)0.2**} & \multicolumn{3}{c}{**(c)**} & \multicolumn{3}{c}{**Single Junction Ratio: 0.9\(-\)0.1**} \\ \hline \hline
**channel** & **1** & **2** & **3** & **4** & **channel** & **1** & **2** & **3** & **4** & **channel** & **1** & **2** & **3** & **4** \\ \hline
**INPUT** & 1 & 1 & 1 & 0 & **INPUT** & 1 & 1 & 1 & 0 & **INPUT** & 1 & 1 & 1 & 0 \\ \hline
**OUTPUT** & 0.6581 & 0.8561 & 0.7274 & 0.7583 & **OUTPUT** & 0.4993 & 0.8724 & 0.807 & 0.8213 & **OUTPUT** & 0.2856 & 0.9174 & 0.8994 & 0.8975 \\ \hline
**INPUT** & 0 & 1 & 1 & 1 & **INPUT** & 0 & 1 & 1 & 1 & **INPUT** & 0 & 1 & 1 & 1 \\ \hline
**OUTPUT** & 0.7663 & 0.7273 & 0.8416 & 0.6658 & **OUTPUT** & 0.8315 & 0.8083 & 0.8508 & 0.5094 & **OUTPUT** & 0.9078 & 0.9012 & 0.8952 & 0.2958 \\ \hline
**INPUT** & 1 & 0 & 1 & 1 & **INPUT** & 1 & 0 & 1 & 1 & **INPUT** & 1 & 0 & 1 & 1 \\ \hline
**OUTPUT** & 0.7305 & 0.4804 & 0.9308 & 0.8583 & **OUTPUT** & 0.8067 & 0.3503 & 0.959 & 0.884 & **OUTPUT** & 0.8973 & 0.1888 & 0.983 & 0.9309 \\ \hline
**INPUT** & 1 & 1 & 0 & 1 & **INPUT** & 1 & 1 & 0 & 1 & **INPUT** & 1 & 1 & 0 & 1 \\ \hline
**OUTPUT** & 0.8445 & 0.9342 & 0.4924 & 0.7288 & **OUTPUT** & 0.891 & 0.9612 & 0.3675 & 0.8122 & **OUTPUT** & 0.8913 & 0.9827 & 0.2056 & 0.9205 \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Results of the simulation outputs of the mathematical model for 3-digit, 4-bit numbers and for different SJR values: (a) SJR = 0.7\(-\)0.3, (b) SJR = 0.8\(-\)0.2, and (c) SJR = 0.9\(-\)0.1. \begin{table}
\begin{tabular}{c c} \hline \hline
**Material** & **LiNbO3** \\ \hline linear ordinary refractive index & n\({}_{\text{oo}}\) = 2.3247 \\ \hline linear extraordinary refractive index & n\({}_{\text{oe}}\) = 2.2355 \\ \hline electro-optic coefficient & r\({}_{\text{33}}\) = 3.1 \(\times\) 10\({}^{-11}\) m/V \\ \hline electric bias & E\({}_{\text{bias}}\) = 36 kV/cm \\ \hline writing beam wavelength & 532 nm \\ \hline writing beam power & 10 \(\upmu\)W \\ \hline signal beam & 632 nm \\ \hline signal beam power & 0.5 \(\upmu\)W \\ \hline \hline \end{tabular}
\end{table} 
Table 5: Numerical parameters used in the soliton simulations. The behavior of the 4-bit soliton network was simulated using a well-tested FDTD numerical code [26], which solves the nonlinear wave equations in Slowly Varying Envelope Approximation. Figure 7 shows the flow chart of the solver.