## 4 Mathematical Model of Symbol Error Rate  
In many applications in the mm wave and terahertz range, QAM is the leading modulation format or is part of a more complicated modulation such as OFDM or MIMO, therefore, our synthesis considers a general model of the symbol error rate (SER) of M-QAM. There have been various works on the dependence of SER on rain attenuation; examples include [37; 38; 39]. We chose to use a textbook expression for symbol error rate independent of rain [40] in our model, and then to weight it with the probability for rain rate, which is widely considered to be lognormal, as noted above; though, as noted above, in some regions, another model may be a better fit. Our model can thus be adapted in a straightforward manner if another model for rain rate or SER were to be desired. The independent probability for symbol error is  
\[P_{M}(s(r_{r}),M)=2\bigg{(}1-\frac{1}{\sqrt{M}}\bigg{)}erfc(F(s(r_{r}),M)) \times\bigg{[}1-\frac{1}{2}\bigg{(}1-\frac{1}{\sqrt{M}}\bigg{)}erfc(F(s(r_{r}),M))\bigg{]} \tag{5}\] \begin{table}
\begin{tabular}{c c c} \hline \hline  & **mm Band** & \\ \hline
**Freq (GHz)** & \(k\) & \(\alpha\) \\ \hline
30 & 0.2347 & 0.931125 \\
80 & 1.1686 & 0.706807 \\
100 & 1.36755 & 0.678999 \\ \hline \hline  & **Terahertz Band** & \\ \hline
**Freq (THz)** & \(k\) & \(\alpha\) \\ \hline
0.2 & 1.64105 & 0.636246 \\
0.3 & 1.6286 & 0.6279 \\
0.4 & 1.584 & 0.6259 \\
0.7 & 1.4638 & 0.629948 \\
0.8 & 1.4328 & 0.63245 \\
1 & 1.38085 & 0.637598 \\ \hline \hline \end{tabular}
\end{table} 
Table 2: ITU parameters for attenuation constants. where _erfc_ is the complementary error function, defined as 1 minus the error function, or as _erfc_(\(z\)) = \(2/\sqrt{\pi}\int_{z}^{\infty}exp[-t]dt\), and \(F\) and \(s\) are defined as follows:  
\[F(s(r_{r}),M)=\sqrt{\frac{3}{2(M-1)}ns(r_{r})} \tag{6}\]  
\[s(r_{r})=s_{0}10^{\frac{-\gamma(\gamma_{p})z_{0}}{10}} \tag{7}\]  
Here, \(M=2^{n}\), \(s_{0}\) is the average SNR per bit without rain, \(\gamma\) is the specific attenuation of rain from (4), and \(z_{0}\) the distance by which the signal passes through the rain (km). This can be approximated by [30]  
\[P_{M}(s(r_{r}),M)\leq 2 erfc(F(s(r_{r}),M)) \tag{8}\]  
thus providing an upper bound for the error. However, we wish to take into account the probability for rain. Using the expression for lognormal distribution as found in (1) and the term for symbol error probability as in (5)-(8), the average symbol error probability of M-ary QAM in this case is given by multiplying the symbol error probability \(f\) as a function of rain rate by the probability distribution function for rain rate, and integrating overall rain rates:  
\[\overline{P_{M}}=\int_{0}^{\infty}P_{M}(s(r_{r}),M)f_{r}(r_{r})dr_{r}. \tag{9}\]  
We are looking for a closed form expression for the probability of symbol error. The ITU-R attenuation is in dB/km, and we convert it in the following calculation. The minus sign is used to indicate that this is a loss. Collecting constants and plugging in (2) and (5)-(8), this is written explicitly as  
\[\overline{P_{M}}=\int_{0}^{\infty}\frac{A}{r_{r}}erfc\left(B\sqrt{s_{0}10^{ \frac{-\mu_{r}^{2}}{10}}}\right)\exp\left[-\frac{1}{2}\left(\frac{\ln r_{r}- m_{r}}{\sigma_{r}}\right)^{2}\right]dr_{r}\]  
The term with the square root can temporarily be collected into a constant \(C\) that is not a function of \(y\), enabling a simpler integration over \(y\).