# Game-Based Resource Allocation Mechanism in B5G HetNets with Incomplete Information
## 3 Distributed Resource Allocation Algorithm
### Follower Game
With a continuous type space, we can obtain a pure Bayesian Nash equilibrium (BNE) \(\mathbf{s}=(\mathbf{s}_{1},\mathbf{s}_{2},\ldots,\mathbf{s}_{n})\), if and only if:  
\[\mathbf{s}_{i}(h_{i})\in\arg_{\mathbf{q}_{i}}\overline{u_{i}^{F}}(\mathbf{q}_ {i},\mathbf{s}_{-i};\mathbf{h}_{i},\mathbf{h}_{-i}) \tag{11}\]  
**Proposition 1**. : _Given the price strategies of bandwidth \(\mathbf{b}=(b_{1},b_{2},\ldots,b_{m})\) made by networks, in the proposed follower game among mobile users, whose expected utility is \(\overline{u_{i}^{F}}(\mathbf{q}_{i},\mathbf{s}_{-i};\mathbf{h}_{i},\mathbf{h}_ {-i})\), there exists at least one pure Bayesian Nash equilibrium (BNE)._  
Proof. : The strategy space \(\mathbf{s}_{i}\) is a bounded closed set in Euclidean space, and is convex, compact for each \(i\). The partial derivation of the expected utility \(\overline{u_{i}^{F}}(\mathbf{q}_{i},\mathbf{s}_{-i};\mathbf{h}_{i},\mathbf{h}_ {-i})\), with respect to action \(q_{ij}\) and type \(h_{ij}\), is given as:  
\[ \begin{array}{l}\frac{\partial^{2}\overline{u_{i}^{F}}(\mathbf{q}_{i}, \mathbf{s}_{-i};\mathbf{h}_{i},\mathbf{h}_{-i})}{\partial q_{ij}\partial h_{ ij}}\\ =Z\cdot\left\{1-\frac{q_{ij}}{1+\sum\limits_{j=1}^{n}C_{ij}}\cdot\log_{2} \left(1+\frac{p_{i}h_{ij}}{\sum_{k\
eq i}p_{k}h_{kj}+q_{0}^{2}}\right)\right\} \\ =Z\cdot\left\{1-\frac{C_{ij}}{1+\sum\limits_{j=1}^{n}C_{ij}}\right\} \end{array}  \tag{12}\]  
where \(z\) is represented as:  
\[Z=\frac{\alpha_{i}}{\left(\ln 2\right)^{2}}\cdot\frac{1}{1+\sum\limits_{j=1}^{n}C_{ ij}}\cdot\frac{p_{i}}{p_{i}\cdot h_{ij}+\sum_{k\
eq i}p_{k}\cdot h_{kj}+{ \sigma_{0}}^{2}} \tag{13}\]  
It is easy to know that \(\alpha_{i}>0\), \(q_{ij}>0\), \(p_{i}>0\) and \(h_{ij}>0\) for all \(i\) and \(j\), so that \(Z>0\) and  
\[\frac{\partial^{2}\overline{u_{i}^{F}}(\mathbf{q}_{i},\mathbf{s}_{-i};\mathbf{ h}_{i},\mathbf{h}_{-i})}{\partial q_{ij}\partial h_{ij}}>0 \tag{14}\]  
As a result, \(\partial^{2}\overline{u_{i}^{F}}(\mathbf{q}_{i},\mathbf{s}_{-i};\mathbf{h}_{i},\mathbf{h}_{-i})\) satisfies the single crossing condition (SCC) for random \(q_{ij}\) and \(h_{ij}\), which ensures the existence of Bayesian Nash equilibrium. User's utility curve in simulation part also indicates the concave properties and consequently proves the existence of the equilibrium point. Moreover, the uniqueness of BNE can also be proved with the method of Karush-Kuhn-Tucker conditions to Equation (11), which offers the necessary and sufficient conditions for the uniqueness [21]. Given the price strategies of the allocated bandwidth made by operators, it is necessary for mobile users to obtain the optimal strategy \(\mathbf{q}_{i}^{*}\) by changing requesting strategies for limited bandwidth. We apply a distributed algorithm to study the dynamic process, in which the rate of strategy change is directly proportional to the gradient of the expected utility function:  
\[\dot{q}_{ij}=\frac{\partial^{2}\overline{u_{i}^{F}}(\mathbf{q}_{i},\mathbf{s}_ {-i};\mathbf{h}_{i},\mathbf{h}_{-i})}{\partial q_{ij}\partial l_{ij}} \tag{15}\]  
\[q_{ij}(\tau+1)=q_{ij}(\tau)+\lambda_{i}\dot{q}_{ij}(\tau) \tag{16}\]  
where \(q_{ij}\) represents the gradient, \(\tau\) is time variance, \(\lambda_{i}\) is the learning rate of user \(i\) (e.g., the rate of strategy adaptation), and \(\lambda_{i}>0\). Specifically, during the time slot between \(\tau\) and \(\tau+1\), the dynamic iteration of the follower's strategy can be expressed as Equation (16). The concave utility function ensures the dynamic algorithm converges to the Bayesian Nash equilibrium.