# Multiple-Valued Logic Modelling for Agents Controlled via Optical Networks
## 3 Results
### Representation of Quantum Protocol by AGA Function  
The model of the logic ledger \(h^{(m,s)}=F_{ldg}(m,t,e_{m,s},\,\mathbf{h}_{m,h-s})\) proposed above describes a system whose states are linked by a logic expression for entries taken for different time moments. This model principally can be used for description of an arbitrary procedure, including various classical and quantum protocols, as the truth table and its equivalent product terms are simple and visual tools for preparation and debugging of a logic function. This is illustrated further for the case of the route verification scheme cited in Section 1.2. Verification procedures discussed in [32] and in Section 1.2 suppose that the prover and the verifier in each of the checkpoints interact as two different agents and execute the quantum protocol PU [33], which includes the transfer and measurements of classical and quantum signals. Given above in the Figure 3, the actions of verifiers in every checkpoint were represented by the logic function \(F_{TN}(P,\,t,\,V_{1},V_{2},S_{1},S_{2},S_{3},S_{4},J)\)[32], describing the work of crossed measurement modules. Input variable \(P\) here describes the initiating signal, \(t\) is time, and \(V_{1}\) and \(\,V_{2}\) depict the transfer of two equal values \(q\) by entangled photons emitted by the EPR module. Indexed parameters \(S_{1},S_{2},S_{3},S_{4}\) describe the transfer of classical test signals coming from the RO module via four crossed modules of the verifier, and \(J\) is the counter of the involved devices and procedures. In its turn, actions of the prover \(P\) were represented in [32] by logic function \(F_{P}\)\(\big{(}\,t,\,\mathbf{Y}\,,S_{p1},S_{p2},S_{p3},S_{p4},J\big{)}\), where \(t\) is time, \(\mathbf{Y}\) is the measurement of the photon polarization state \(|\mathbf{\Psi}>\) in the basis \(B=H(x_{1}\oplus x_{2}\oplus x_{3}\oplus x_{4})\) responding to the 2D scheme of verification, \(S_{p1},S_{p2},S_{p3},S_{p4}\) refer to measurements of classical signals sent to four verifier modules in the crossed scheme, and \(J\) is the counter of the devices and procedures. \(H\) is the random hash function of the RO [32; 77] used by all verifiers and provers. In order to model the interaction of the two agents commented above in the joint logic model, one should define the united AGA function \(F_{VP}\) given by Equation (10) and disclosed in Table 5:  
\[y\ =\ F_{VP}\big{(}t,P,\,\,V_{1},V_{2},S_{1},S_{2},S_{3},S_{4},\,\mathbf{\Psi} \,,S_{p1},S_{p2},S_{p3},S_{p4},J_{v},J_{p}\big{)} \tag{10}\]  
\begin{table}
\begin{tabular}{c c c c c c c c c c c c c c c c c c} \hline \hline  & \multicolumn{14}{c}{**Input Variables**} & \multicolumn{14}{c}{**Output**} & **Activated Procedure** \\ \hline \(t\) & \(P\) & \(V_{1}\) & \(V_{2}\) & \(S_{1}\) & \(S_{2}\) & \(S_{3}\) & \(S_{4}\) & \(J_{V}\) & \(\mathbf{\Psi}\) & \(S_{p1}\) & \(S_{p2}\) & \(S_{p3}\) & \(S_{p4}\) & \(J_{P}\) & \(F_{VP}\) & \\ \(t_{0}\) & p & - & - & - & - & - & - & - & - & - & - & - & - & - & \(C_{1}\) & Prover initiates protocol \\ \(t_{1}\) & - & - & - & \(s_{1}\) & - & - & - & \(j_{2}\) & - & - & - & - & - & - & \(C_{2}\) & Step 1: load \(s_{1}\) from RO \\ \(t_{1}\) & - & - & - & - & \(s_{2}\) & - & - & \(j_{3}\) & - & - & - & - & - & \(C_{3}\) & Load \(This function is defined for the set of all 14 input variables used earlier in \(F_{P}\) and \(F_{TN}\), and the output variable is given by the set of constants \(C_{1},\ldots,C_{21}\), for simplicity tagged as they are in paper [32]. According to [32,33,79], the used version of route verification protocol PU [33] was slightly adapted for the 2D case, and one checkpoint was considered as one verifier agent, which interacts with the prover agent. Their interaction corresponds to the protocol PU [33] and is subdivided into six steps tagged by time countdowns \(t_{0},\ldots,t_{6}\).