## 4 Simulation  
Based on the above CR spectrum allocation model of HAN, a corresponding simulation is implemented in this section. Furthermore, the commonly used spectrum allocation method in [10] is used as a comparison to provide a more intuitive explanation of the stable convergence. As shown in Figure 4, assuming HAN has covered a rectangular region measuring 100 m \(\times\) 100 m, the central red star represents the gateway of HAN, and 15 secondary users (CR terminal) are randomly distributed in the rectangular area. Each user employs self-adaption modulation to communicate, and one user can only use one channel for transmission at any given time. Four, six and eight free CR channels, respectively, that are licensed by 750 MHz TV band are available for gateway allocation, assuming that the ability for receiving signal is equal for all CR users. Figure 3: Algorithm flow chart. The following Table 1 shows the simulative parameters of the simulation:  
After initialization, the initial transmission efficiency of each user is calculated by:  
\[k\ =\log_{2}(1+K\tau_{i}) \tag{14}\]  
Where \(\tau_{i}\) is the SNR value of \(i\)th user and \(K\) is a constant given by  
\[K=\frac{1.5}{\ln(0.2\ /\ BER_{tar})} \tag{15}\]  
In Equation (15), \(BER_{tar}\) is the objective bit error rate, which can be expressed as  
\[BER_{tar}=0.2\exp\biggl{(}\frac{-1.5\tau_{i}}{2^{k}-1}\biggr{)} \tag{16}\]  
In the proposed model, the threshold value of the target bit error rate was set at \(10^{-3}\). Thus, the initial transmission efficiency of the 15 CR users is shown in Figure 5.  
In Figure 5, the horizontal coordinates signifies the index of 15 CR users, whereas the vertical coordinates signifies the transmission efficiency. After obtaining the results of initial transmission efficiency, the CR users that were demonstrated to have higher transmission efficiency are chosen to allocate the free spectrum channel. Equation (3) is used to proceed with the first iteration. From the second iteration, the utility function is given by Equation (8) instead of (3). After several iterations, the NASH equilibrium points are determined. Finally, a unique NASH equilibrium point is obtained by judging the gradient of the utility function and time complexity. This spectrum allocation method \begin{table}
\begin{tabular}{l l} \hline Primary channel source & 750 MHz TV band \\ Number of free channels & 4, 6, 8 \\ Number of CR users & 15 \\ Coverage & 100 m \(\times\) 100 m \\ Number of iterations & 50 \\ \hline \end{tabular}
\end{table} 
Table 1: Simulative parameters. Figure 4: Simulative HAN with random distributed users. successfully prevents the appearance of multi-NASH equilibrium and enormously improves system performance. The results of the simulation are shown below. Figure 6 shows the convergent results of the general spectrum allocation algorithm used in HAN without a critical function judging the convergence of utility function, the horizontal coordinates signifies the number of iterations, and the vertical coordinates signifies the index of the four free TV band channels. As the cognitive users accomplish the spectrum allocation by maximization of the private utility, there is probability of multi-Nash equilibrium. As a result, the spectrum allocation strategies are constantly switched. In the above figure, user 4 is unstable and divergent, continuously switching between channels 2 and 4 in the entire iteration process, which is a result of the existence of multi-NASH equilibrium. Figure 5: The initial transmission efficiency of the 15 CR users. Figure 6: The simulation result of general CR spectrum allocation algorithm with four channels. Figure 10 shows the variation of the total utility along with the iteration proceeding. Evidently, the proposed algorithm has a higher utilization rate and a better convergence property compared with the fair spectrum allocation algorithm.