## 3 Proposed Hybrid Algorithm
### Algorithmic Details  
Given a scalar multiplier \(k\) and a starting point \(P\), the PM operation computes the point \(Q\), which is equal to \(k\) times \(P\). This can be expressed as \(Q=K(P+P+\ldots+P)\), where there are \(K\) terms in the sum.  
To convert a point \(P\) from affine coordinates to \(\omega\) coordinates as shown in Algorithm 1, we calculate the values of \(W_{2}\) and \(Z_{2}\) using the formula \(W_{2}=x(P)\cdot Z_{2}^{-1}\) and \(Z_{2}=1\). We set \(W_{1}\) and \(Z_{1}\) to \(0\). For point multiplication, we iterate over the binary digits of scalar \(k\) from the most significant bit to the least significant bit. For each bit \(i\), we perform the following steps:  
* If the \(i\)-th bit of \(k\) is \(0\), we perform a point addition operation \(P=P+Q\) and update the \(\omega\) coordinates of the points using the dADD function. We set \((W_{1}:Z_{1}),(W_{2}:Z_{2})=dADD((W_{0}:Z_{0}),(W_{1}:Z_{1}),(W_{2}:Z_{2}))\), where \((W_{0}:Z_{0})\) is the \(\omega\) coordinates of \(P\).
* If the \(i\)-th bit of \(k\) is \(1\) and the \((i-1)\)-th bit is \(0\) or \(i=m-1\), we perform a double-and-add operation. We double the current value of the result using the double function, and update the \(\omega\) coordinates of the points as \((W_{1}:Z_{1}),(W_{2}:Z_{2})=double((W_{1}:Z_{1}),(W_{2}:Z_{2}))\).
* If the \(i\)-th bit of \(k\) is \(1\) and the \((i-1)\)-th bit is also \(1\), we perform a point addition operation \(Q=P+Q\) using the current value of \(P\), and update the \(\omega\) coordinates of the points as \((W_{2}:Z_{2}),(W_{1}:Z_{1})=dADD((W_{0}:Z_{0}),(W_{2}:Z_{2}),(W_{1}:Z_{1}))\).  
After iterating over all the bits of \(k\), we return the \(\omega\) coordinates of the resulting point \(Q\) as \((W_{1}:Z_{1}),(W_{2}:Z_{2})\).  
\begin{table}
\begin{tabular}{c c} \hline
**Instructions** & **Original Formulas** \\ \hline \(Instr_{1}\) & \(A\gets W_{1}\times Z_{1}\) \\ \hline \(Instr_{2}\) & \(B\gets W_{1}\times W_{2}\) \\ \hline \(Instr_{3}\) & \(C\gets Z_{1}\times Z_{2}\) \\ \hline \(Instr_{4}\) & \(W_{d}\gets A\times A\) \\ \hline \(Instr_{5}\) & \(Z_{d}\leftarrow((e_{1}\times W_{1}+Z_{1})^{4})\) \\ \hline \(Instr_{6}\) & \(Z_{a}\leftarrow(e_{2}\times B+C)^{2})\) \\ \hline \(Instr_{7}\) & \(W_{a}\leftarrow(B\times C+w\times Z_{a})^{2}\) \\ \hline \end{tabular}
\end{table}
Table 1: PA and PD instructions.  
```
Input:\(E_{B,d_{1},d_{2}}/GF(2^{m}):d_{1}(x+y)+d_{2}(x+y)^{2}=xy(x+1)(y+1)\), \(P\in E_{B,d_{1},d_{2}}\) and \(k=(k_{m-1},\ldots,k_{1},k_{0})\) Output:\(Q=w(k.P)\) \(W_{1}=0\), \(Z_{1}=1\), \(W_{2}=w(P)\), \(Z_{2}=w(P)\)\(\triangleright\)Step-1:--Conversions from Affine to \(\omega\) Coordinates. for(i from \(m-1\) down to \(0\))do\(\triangleright\)Step-2:--Point Multiplication. if\(k_{i}=0\)thenPoint\(Addition\to P=P+Q\) \(((W_{1}:Z_{1}),(W_{2}:Z_{2})):=dADD((W_{0}:Z_{0}),(W_{1}:Z_{1}),(W_{2}:Z_{2}))\) else if\(k_{i}\
eq k_{i-1}\)then \(Q=P+Q\) \(((W_{2}:Z_{2}),(W_{1}:Z_{1})):=dADD((W_{0}:Z_{0}),(W_{2}:Z_{2}),(W_{1}:Z_{1}))\) else \(((W_{1}:Z_{1}),(W_{2}:Z_{2})):=double((W_{1}:Z_{1}),(W_{2}:Z_{2}))\) End If End For Return:(W_{1}:Z_{1}),(W_{2}:Z_{2})
```  
**Algorithm 1**Hybrid Montgomery and double-and-add algorithm