## 2 Materials and Methods
### QoS-Guaranteed NOMA-VLC GRPA  
Due to the reasons outlined in the discussion of NOMA-VLC user outage probability, dynamic user priority and difficult threshold selection affect the outage distribution. According to reference [4], the threshold \(\varepsilon_{k}^{*}\) of (10) is given by \(\varepsilon_{k}^{*}\)= min \(\left\{\max\left\{\varepsilon_{1},\cdots,\varepsilon_{k},\cdots,\chi_{\min} \right\},x_{\max}\right\}\), where \(x_{\min}\) and \(x_{\max}\) are in (8). However, we notice that the determination of \(\varepsilon_{k}^{*}\), defined by [4], may not be easy to search. We propose using the beta distribution to estimate the original distribution for convenience in the observation of dynamic user priority. In approximate equivalence, the idea that we transform the determination of \(\varepsilon_{k}^{*}\) into the number of users is further deduced:  
\[\sum_{i=k}^{K}\frac{K!}{i!\left(K-i\right)!}F_{h_{k}^{2}}(x)^{i}\Big{[}1-F_{h _{k}^{2}}\left(x\right)\Big{]}^{K-i}=\frac{K!}{\left(i-1\right)!\left(K-i \right)!}\int_{0}^{F_{h_{k}^{2}}(x)}t^{i-1}(1-t)^{K-i}dt. \tag{15}\]  
It is clear that the left and right formulas in (15) are identical. If (10) is indicated by (15), the PDF of the outage can be expressed as (16):  
\[f_{P_{k}^{out}}\left(x\right) = \left[P_{k}^{out}\right]^{\prime}=\frac{\Gamma\left(K\!+\!1\right) }{\Gamma\left(i\right)\cdot\Gamma\left(K\!+\!1-i\right)}F_{h_{k}^{2}}(x)^{i-1 }\cdot\Big{[}1-F_{h_{k}^{2}}\left(x\right)\Big{]}^{K-i}\cdot f_{h_{k}^{2}} \left(x\right), \tag{16}\] \[= \frac{F_{h_{k}^{2}}(x)^{i-1}\cdot\Big{[}1-F_{h_{k}^{2}}\left(x \right)\Big{]}^{K-i}\cdot f_{h_{k}^{2}}\left(x\right)}{Be\left(i,K+1-i\right) }\propto f_{h_{k}^{2}}\left(x\right)\cdot Beta\left(F_{h_{k}^{2}}\left(x \right);i,K+1-i\right). \tag{17}\]  
If \(Be\left(\alpha,\beta\right)\overset{\Delta}{=}\frac{\Gamma\left(\alpha+\beta \right)}{\Gamma\left(\alpha\right)\cdot\Gamma\left(\beta\right)}\), \(\Gamma\left(n\right)\overset{\Delta}{=}\left(n-1\right)!\) and \(f_{h_{k}^{2}}\left(x\right)=F^{\prime}_{h_{k}^{2}}\left(x\right)\), (17) is obtained. When uthe ser positions are fixed, the distributions of \(F_{h_{k}^{2}}\left(x\right)\) and \(f_{h_{k}^{2}}\left(x\right)\) are determined, and we can perform an approximate numerical calculation in which the beta distribution can be used as the estimation of the outage probability distribution. For example, the probability, \(P_{k}^{out}\), of a discrete event can be generated by the normalization of \(Beta(i,K+1-i)\) in the numerical simulation. The accessible user data rate based on the dynamic user priority is formulated by (18):  
\[Rate_{k}\left(h_{k},a_{k},P_{k}^{out},\lambda_{k}\right)=\left(1-P_{k}^{out} \right)\cdot B\cdot\log_{2}\left(1+\frac{\left(h_{k}\lambda_{k}P_{t}\right)^{ 2}}{\lambda_{i}<\lambda_{k}}\sum\limits_{i\in\left[1,K\right]}\left(h_{k} \lambda_{i}P_{t}\right)+N_{0}B\right),k<K. \tag{18}\]  
\begin{table}
\begin{tabular}{c c c c c} \hline \hline
**No.** & **VLC Channel Gain** & **Desired Rate** & **Outage Probability** & **User Priority** \\ \hline
1 & - & High & Low & High \\
2 & Not Low & Med-High & Low & High \\
3 & - & High & Not Low & Med \\
4 & High & Med-High & Not Low & Med \\
5 & Low & Med-High & Low & Med \\
6 & - & Low-Med & Low & Med \\
7 & Not High & Med-High & High & Low \\
8 & - & Low-Med & High & Low \\
9 & - & Low & - & Low \\ \hline \hline \end{tabular}
\end{table}
Table 2: Fuzzy rule base.