# A Charging and Discharging Data Privacy Protection Scheme for V2G Networks Based on Cloud-Fog-End
## 5 Performance Evaluation
### Computation Cost  
In our experiments, we conducted the operations on our personal computer configured with an Intel Core I5-4210H 1.80 GHz processor, 8 GB RAM, and Windows 10. We utilized the Pairing-Based Cryptography (PBC) library to perform these operations, and the running times for different operations are shown in Table 3. The table only includes the computationally expensive operations, among which the bilinear pairing operation is significantly more costly than the multiplication operation. \(T_{p}\) is calculated by using bilinear pairs \(e:G_{1}\times G_{1}\to G_{2}\). \(G_{1}\) of order \(q\) is generated by elliptic curves \(\mathbb{E}(F_{p^{\prime}})\): \(y^{2}=x^{3}+x\) defined over finite field \(F_{p^{\prime}}\). \(T_{\text{pm}}\) is calculated from elliptic curves \(E(F_{p}):y^{2}=x^{3}+ax+b\) defined over finite fields \(F_{p}\).Table 4 shows the computation cost comparison among CLASC schemes. In this scheme, each CP requires \(3T_{pm}+T_{sm}\) for signcryption of \(m_{i}\) to generate the charging and discharging data report \(P_{i}\). Therefore, the computation cost for each CP is \(3T_{pm}+T_{sm}\). Each FN requires \((n+2)T_{pm}\) for aggregating and verifying \(n\) received data reports \(P_{i}(n=1,2,\ldots,n)\), and \(T_{sm}\) is used for generating the corresponding signature. Hence, the total computation cost for each FN is \((n+2)T_{pm}+T_{sm}\). The CSO requires \((m+2)T_{pm}\) for aggregating and verifying \(m\) received area data reports \(T_{w}(w=1,2,\ldots,m)\) and \(mnT_{pm}\) for decrypting \(mn\) encrypted messages. The total computation cost of the CSO is \((mn+m+2)T_{pm}\). \begin{table}
\begin{tabular}{c c c c} \hline \hline \multirow{2}{*}{**Scheme**} & **Signcryption** & **Verification** & **Verification and Unsigncryption** \\  & **(CP)** & **(FN)** & **(CSO)** \\ \hline
[27] & \(2T_{h}+7T_{pm}\) & \(2 nT_{h}+4 nT_{p}+nT_{pn}\) & \(2 mnT_{h}+(mn+3)T_{p}+3 mmT_{pm}\) \\
[28] & \(2T_{h}+6T_{pm}\) & \((n+1)T_{h}+3 nT_{p}+2 nT_{pm}\) & \((mn+1)T_{h}+(mn+2)T_{p}+4 mnT_{pm}\) \\
[24] & \(3T_{pm}+4T_{sm}\) & — & \((3 mn+1)T_{pm}\) \\
[25] & \(5T_{pm}+2T_{sm}\) & \((3n+1)T_{pm}\) & \(2 mnT_{pm}\) \\ Ours & \(3T_{pm}+T_{sm}\) & \((n+2)T_{pm}+T_{sm}\) & \((mn+m+2)T_{pm}\) \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Computation cost comparison among CLASC schemes. \begin{table}
\begin{tabular}{c c c} \hline \hline \multirow{2}{*}{**Symbol**} & \multicolumn{2}{c}{**The Run Time of**} & \multirow{2}{*}{**Meaning**} \\  & **Operation (ms)** & \\ \hline \(T_{\text{P}}\) & 4.2846 & Time for a bilinear pairing operation \\ \(T_{\text{pm}}\) & 0.4720 & Time for point multiplication operation in elliptic curve \\ \(T_{\text{sm}}\) & 0.2530 & Time for scalar multiplication operation \\ \(T_{h}\) & 3.8643 & Time for map to point hash \\ \hline \hline \end{tabular}
\end{table} 
Table 3: Execution times of related operations. Figure 3 shows the computation costs of CP signcryption among the relevant CLASC schemes. The computation cost of FN verification compared with other schemes is shown in Figure 4. We can see that neither [24; 25] nor our scheme involves bilinear mapping operations, resulting in higher execution efficiency compared to [27; 28]. With the increase in the number of charging and discharging EVs, the computation overhead of the FN becomes lower and lower compared with other schemes. When \(n=120\), charging and discharging data reports are uploaded in the local area, and the total aggregation verification time of the FN is 57.837 ms, which is a very effective and reasonable time assumption for FNs with certain computing abilities. Figure 5 shows the computation cost of the CSO in this scheme with the increase in the number of FNs \(m\) and the number of EVs in the local region \(n\). Assuming that the number of FNs \(m=1\), the comparison of computation costs of the CSO is shown in Figure 6. It can be seen that the advantages of our scheme are gradually reflected in the increase in the number of FNs and the number of EVs in the local region.