Modeling and Performance Analysis of Channel Assembling Based on Ps-rc Strategy with Priority Queues in CRNs

Based on two types of priority queues, this paper proposes a polling scheduling strategy with reserved channel (Ps-rc strategy) for predefined priority services in cognitive radio networks (CRNs). Channel assembling (CA) technology and spectrum adaptation (SA) technology are adopted to dynamically adjust the assembled channels of secondary users (SUs) to improve the performance of the secondary network. Specifically, the SUs in CRNs are divided into two queues with different priorities; based on polling scheduling, a part of the idle channel is reserved for high-priority queue during the polling stage of the low-priority queue. The purpose is to increase the service quality (QoS) of high priority on the basis of providing fair scheduling. Furthermore, the CA-based channel access process of the proposed strategy is presented and modeled by continuous time Markov chain (CTMC). Then, the process of resource flow between users is mapped on CTMC, and the transition conditions and parameter sets of channel assembling covering all user activities of the system are derived. Finally, the system performance of the proposed CA-based Ps-rc scheduling strategy is simulated and evaluated, including network capacity, spectrum utilization, blocking probability, and forced termination probability. Numerical results show that the proposed strategy can improve the QoS of the predefined high-priority service without causing excessive starvation problem of low-priority service.


Introduction
At present, the number of the communication users is growing exponentially [1], but the operation of the traditional wireless communication system has the problem of low utilization due to the static allocation of the radio spectrum. With the cognitive radio (CR) technology, secondary users (SUs) are able to transmit information over the unused spectrum of primary users (PUs) to enhance spectrum utilization [2]. Relying on the ability of spectrum sensing, CRNs can realize dynamic spectrum allocation (DSA) and resource sharing [3], which provide flexible resource allocation for SUs.
Among the existing DSA technologies, the application of channel assembling (CA) and spectrum adaptation (SA) can effectively improve the QoS of the secondary system. By adopting the CA technology, the service rate of SUs can be increased through assembling one channel to multiple channels. Meanwhile, because the absolute priority of PUs, the service of SUs may be interrupted. Through combining the technology of SA, the interrupted SUs can flexibly adjust the assembled channels according to the activities of PUs and other SUs. Therefore, the resource scheduling strategy adapted to application requirements is the key to improve the service quality (QoS) of the secondary system. This paper considers the scheduling requirements of the predefined priority services in special scenarios, such as battlefield and medical rescue, and proposes a polling scheduling strategy with reserved channel (Ps-rc) for multitype of data services in CRNs. Based on the technologies of CA and SA, a CTMC is developed to model the resource flow process, then the system performance of the CA-based Ps-rc strategy is evaluated. The main contributions are as follows: (1) A novelty scheduling strategy: combining polling scheduling and channel reservation, part of idle channel in the system is reserved for high-priority SUs in the polling process of low-priority SUs. Thus, a Ps-rc strategy with two types of priority queues is proposed to increase the possibility of high-priority SUs accessing the channel. This strategy provides a new scheduling idea for the predefined priority services in CRNs (2) Dynamic channel access process with channel assembling: by adopting the technologies of channel assembling and spectrum adaptation, we present the dynamic channel access process by analyzing the activities of PU arrivals, PU departures, SU arrivals, and SU departures in the system (3) A continuous time Markov chain: based on the dynamic channel access process, a CTMC model is developed and all possible destination states, user activities, transition rates, and transition conditions starting from a general state are obtained. Therefore, the resource flow of the secondary network is mapped on the Markov chain; the performance analysis of SUs is transformed into a mathematical problem (4) The conditions and implementation methods of channel assembling are given: the change dynamics of the users in the secondary system are divided and presented by the graphical method visually. Then, the dimension reduction is achieved by the marking method, and the analytic expressions of system performance metrics are given. MATLAB is used to evaluate and analyze the performance of the system

Related Work
CR can make full use of the idle spectrum and satisfy the requirements of data services especially in scenarios such as natural disasters and emergency treatment [4][5][6][7]. Previous studies [8][9][10] have proven that adopting a resource scheduling strategy that is suitable for application scenarios can help improve spectrum utilization. Jiao et al. pointed out that using the channel assembling (CA) technology and spectrum adaptive (SA) technology in secondary system can help for enhancing the QoS [10]. For CRNs containing multiple types of data services, a scheduling strategy based on service classification can achieve more efficient data transmission. References [11][12][13][14][15] investigated the resource scheduling schemes based on service classification. A channel assembling strategy based on priority queues was proposed by using channel aggregation and spectrum adaptive technologies [11]. However, strict priority scheduling maintains the queues with decreasing priorities. Low-priority queue can only start their services when the services of high-priority queue are all completed, which may cause the starvation problem of low-priority services due to long-term lack of service. Thus, [12] used the channel bonding technology with starvation mitigation and adopted a priority-based nonpreemptive M/G/1 queuing model to set up the spectrum handoff of SUs. Reference [15] divided the SUs into five priorities and arranged into two queues, then a round robin priority (RRP) scheduling was proposed to minimize the starvation problem of lowpriority users by executing short suspension of the highpriority queue. But the RRP scheduling uses a combination of dynamic and static spectrum allocation, which has the disadvantages of high system overhead and inconvenient hardware implementation.
Since the arrival of the users is not constrained by time slot in CRNs, continuous time Markov chain (CTMC) is used to model the resource flow process to avoid the problem of time synchronization. CTMC modeling provides a theoretical basis for resource allocation-based performance analysis of secondary networks. References [10,11] adopted CA and SA and established the CTMC model to analyze the performance of heterogeneous SUs in CRNs. Reference [11] proved that the establishment of priority queues could effectively reduce the blocking probability and the forced termination probability of the high-priority queue. Reference [16] indicated that when less than one channel was allowed to transmit for some SU traffics, combining with channel fragmentation technology, the noninteger channel can be used to satisfy the QoS of SUs, so as to enhance system utilization. Reference [17] proposed a flow-adaptive leased channel adjustment algorithm, and the CTMC was developed to conduct theoretical analyses.
Polling scheduling is widely used in communication networks by serving each queue in turn [18,19]. However, when a certain queue has high traffic, the system performance will be reduced because other queues are not served for a long time. Reference [20] proposed a special priority reservation method, in which a part of the transmission rate was allowed to reserve for high-priority services to improve the QoS. The above studies have inspired our research. This paper proposes a polling scheduling strategy with reserved channel (Ps-rc) with two types of priority queues. Based on the technologies of CA and SA, a CTMC model is developed to depict the resource flow process. We present the differences between our studies and other studies as shown in Table 1. Besides, the results of the above-mentioned research develop the study ideas of this paper. Thus, we summarize the research results of the related references in Table 2.

Channel Assembling Based on Ps-rc Strategy
Priority-based scheduling is necessary to improve the reliability of important information during transmission. This paper proposes a polling scheduling strategy with reserved channel (Ps-rc) for the predefined priority services in special scenarios, which combines channel assembling technology and spectrum adaptive technology. Also, this section presents the dynamic channel access process based on the proposed Ps-rc strategy.
3.1. System Model and Assumptions. Centralized cognitive radio network consists of two types of radios, primary users (PUs) and secondary users (SUs), which are controlled by the base station. Suppose there are M ðM ∈ Z * Þ PUs in the system sharing the spectrum bandwidth; each PU can access only one channel. PUs have absolute channel access priority 2 Wireless Communications and Mobile Computing over SUs. SUs can obtain the behavior of PUs through spectrum sensing and access the channels that are not occupied by PUs. Suppose that SUs have perfect sensing ability and the sensing time is short enough that PUs will not arrive at the channel within this period. Once a PU arrival is detected, the ongoing SU will release the channel and perform spectrum adaptation. The adaptive time is also short, so that the transmission of SU is not affected. This paper considers the scheduling of the SU base station in the uplink direction of data transmission. The buffer is set for SUs at each terminal. The departure of the SUs in the buffer is treated as the beginning of the channel service. Through the packet classifier, users in the secondary system are divided into high priority ðSU h Þ and low priority ðSU w Þ and enter into the high-priority queue ðL h Þ and low-priority queue ðL w Þ, respectively. Suppose the two queues are isomorphic. The scheduling of SUs in the queues obeys the first come first service (FCFS).
3.2. Ps-rc Strategy. As shown in Figure 1, the Ps-rc strategy consists of three units: priority assignment unit, information scheduling unit, and data transmission unit.
Priority assignment unit: through the packet classifier, SU h ðSU w Þ enters into L h ðL w Þ and waits for scheduling.
Information scheduling unit: to ensure fairness between the two queues (L h and L w ), polling scheduling is adopted. Meanwhile, to improve the QoS of SU h , a part of the idle channels is reserved for the high-priority queue during the polling period of SU w . The reserved channel is allocated to SU h who enters the system in the polling period of SU w . Therefore, the secondary system state is divided into the polling stage when both SU h and SU w are scheduled and the priority support stage when only SU h is scheduled. Assuming that each stage has a fixed length of time, time length sets for the priority support stage will not cause excessive delay in the transmission of SU w .
Data transmission unit: once a PU arrives at a channel occupied by a SU, the transmission of the SU will be interrupted. The interrupted SU will exit the channel at once and adjust the number of the aggregated channels based on spectrum adaptive. The feedback loop is adopted, then the interrupted SUs will go back to the end of the original queue to improve the possibility of being served. If the corresponding queue is full, the service of the SU will be forced to terminate. Besides, if there is no space left when a SU first arrives at the queue, the service of the SU will be blocked.
Channel assembling is adopted for SUs to enhance service efficiency. The service rate of SUs can be increased

[10]
The performance of secondary network is superior when dynamic resource allocation is adopted. 2014 [11] Introducing queue for secondary users can significantly improve secondary system performance. 2016 [14] Differential scheduling can meet the demand of emergency data transmission. 2016 [16] The performance of the network varies according to different access schemes.
2017 [12,13]; 2018 [15] The starvation problem of low-priority queue should be taken into account when differential scheduling is adopted.
3 Wireless Communications and Mobile Computing through assembling one channel to multiple channels. Accordingly, SU h can start the service by aggregating h channels and enhance the service rate by increasing the number of the aggregated channels to the upper bound, vðh, v ∈ Z * , and h ≤ vÞ. SU w can start the service by aggregating w channels, and the service rate can be improved by increasing the aggregated channels to the upper bound, uðw, u ∈ Z * , and w ≤ uÞ. Set h < w to ensure that the highpriority services are started first. The implementation of the proposed Ps-rc strategy is shown in Algorithm 1.
As shown above, the total number of the currently available idle channels, N free , will be determined at the beginning of each phase. In the priority support stage, the SU h in L h will be served first. If L h is empty, the idle channels will be assembled for SUs according to the following Rule 1.
Rule 1: the ongoing SU h with minimum aggregated channels (denoted as SU h -min) will assemble the idle channels until all of the ongoing SU h were assembled to the upper bound, v. If there are still idle channels, the remaining chan-nels will be assembled to the ongoing SU w with minimum aggregated channels (denoted as SU w -min) until all of the ongoing SU w reached the upper bound, u:.
In the polling stage, the data packets in L w are marked, and a service request list (SRL) for SU w is generated. Suppose that this process is short enough and none is reached within this period. If SRL is empty, this polling stage will be terminated. If SRL is not empty, a part of the channel will be reserved for SU h in L h according to the allocation factor, ηð0 < η < 1Þ, then the remaining channels will serve the SU w in SRL. Here, η is determined by the service classification requirements of different scenarios. We assume that the setting of η will not cause the SU w in L w to be out of service for a long time. This process is done on lines 10~15 of Algorithm 1, where j SRL is the number of SU w on SRL.
Please note that the channel allocation of SU w in L w within the polling stage is only for the SU w marked on SRL at the beginning of this stage. Therefore, the newly arrived SU w in this polling stage needs to wait for at least

13:
Then w•j SRL channels give service to SU w in SRL 14: Else j SRL − bηN free /wcSU w s waiting in the queue & bηN free c channels give service to bηN free /wcSU w s 15: End if 16: Else N free channels go back to (A). 17: End if (polling stage is over. The marked SU w s release the channel after completing the service.) Algorithm 1: Polling scheduling strategy with reserved channels. 4 Wireless Communications and Mobile Computing one service cycle. After this polling, the marked SU w on SRL will be cleared and remarked in the next polling stage. But the service will not be interrupted immediately when the polling time ends. If PU does not occupy the aggregated channels, the channels will be released when the ongoing service is complete. Therefore, there are still SU w running in the priority support stage. The Ps-rc strategy can be applied by the predefined highpriority and low-priority services in special environments to achieve traffic classification scheduling of different transmission requirements. For example, in emergency rescue scenarios, high-priority services can be defined as elastic or real-time services related to medical information according to message correlation, so as to improve the security and reliability of vital signal transmission.
3.3. Dynamic Channel Access Process. Dynamic channel access process is based on the Ps-rc strategy. In this section, the arrival and departure process of uses in CRNs is introduced, which contains four events including PU arrivals, PU departures, SU arrivals, and SU departures.

Event A: PU Arrivals.
When PU arrives at the system, if N free > 0, it will access to the idle channel. If N free = 0, the PU will interrupt the service of a SU h or a SU w , and the interrupted SU will exit the channel and perform spectrum adaptation.
If the interrupted SU performs spectrum adaptation successfully, then the SU will continue its service, which includes two cases: (1) The remaining number of the interrupted SU can continue its service. (2) An ongoing SU with maximum number of channel aggregation donates a channel to the interrupted SU, and the remaining channels of the donor can also support the service. Furthermore, if SU h and SU w have the same number of channels, SU w will donate the channel first.
If the adaptation is not successful, it means that all of the ongoing SU cannot donate the channel for the interrupted SU. The interrupted SU will release the remaining channels and return to the queue according to the feedback loop. In the worst case, if the queue is full, the service of the interrupted SU will be forced to terminate. All assembled channels of the terminated SU will be released. Then, if there are enough released channels, the services of SU in the queue will be started. The channel assembly follows Algorithm 1. Since h < w, this can usually occur when SU w is forced to terminate and SU h is waiting in L h . If there is no SU using the idle channels in the queue, these channels will be allocated to the ongoing SUs obeying Rule 1.

Event B: PU Departures.
The departure of the PU releases a channel. If the departure occurs in the priority support stage, according to FCFS rules, only when L h is not empty and there are h − 1 idle channels in the system, the SU h in L h can use the idle channel. If there is no SU h in L h , use the idle channel; it will be assembled to the ongoing SU obeying Rule 1.
It needs to determine whether SRL of this polling stage is empty if the departure occurs in the polling stage. There are two cases: (1) SRL is empty. In this case, there is no waiting packet in L w or bηN free c ≥ w ⋅ j SRL (in Algorithm 1); the assembling of the idle channel is the same as that in the priority support stage. (2) SRL is not empty, then bηN free c < w ⋅ j SRL . The idle channel is preferentially assembled to SU w on SRL who can start the service when there are w − 1 idle channels in the system. If the current number of the channels is not enough to start the service of SU w but can start SU h , the SU h in L h will be started. If there are no SUs in the queue, we use the idle channel; the channel will be allocated to the ongoing SU obeying Rule 1.

Event C: SU Arrivals.
Whether in the polling stage or not, the service of SU h can be started when there exists h idle channels upon it arrivals. If there are less than h idle channels, the ongoing SU with maximum number of aggregated channels will donate to the newly arrived SU h . After donation, the ongoing SU should be able to satisfy its own service. If the service of the new SU h still cannot be started, the ongoing SU with the second maximum number will donate the channel, etc. In particular, for the ongoing SUs with the same number of aggregated channels, the low-priority SUs (SU w ) will donate the channel first. If the total number of the channels provided by all of the ongoing SUs cannot start the service, the new SU h will go back to L h . However, if L h is full, the newly arrived SU h will be blocked.
If a new SU w arrives during the priority support stage, it will wait in L w . When the system starts a new polling stage, the newly arrived SU w will appear on the new SRL. But it will be blocked if L w is full. If it arrives during the polling stage, the new SU w needs to wait at least one polling cycle (i.e., the SU w that reaches the system during the polling stage cannot appear on the latest SRL). Accordingly, the new SU w will be blocked if L w is full.

Event D: SU Departures.
With SU departures, all aggregated channels are released. Consequently, we suppose the SU with m aggregated channels ðSU h ðmÞÞ releases m channels due to the departure, and the SU with n channels ðSU w ðnÞÞ releases n channels.
If the SU leaves in the priority support stage, the released channels will first schedule to the SU h in L h according to Algorithm 1. Otherwise, these channels will be scheduled to the ongoing SU obeying Rule 1.
When the departure occurs in the polling stage, if SRL is empty, channel access is the same as that of the priority support stage. If SRL is not empty, idle channels will assign to the marked SU w on SRL until this polling stage ends or the services on this SRL are completed. Due to the setting that h < w, it is easier to start the service ofSU h thanSU w . If the number of the idle channels is not enough to start SU w but can start SU h , the SU h in L h will be started. If no SU in the queue uses the idle channels, the channels will schedule to the ongoing SUs obeying Rule 1.

CTMC Analysis and QoS Measures
In this section, the continuous time Markov chain (CTMC) is used to avoid the problem of time synchronization 5 Wireless Communications and Mobile Computing between primary and secondary users. Based on the dynamic channel access process, a CTMC is developed to model the resource flows in secondary networks. Let a general state in the system be where l i , ðh ≤ i ≤ vÞ is the number of SU h with i aggregated channels, j k , ðw ≤ k ≤ uÞ is the number of SU w with k channels, l pu is the number of PU in the system, and l hq and l wq are the current queue lengths of L h and L w , respectively. s is an indicator function, in which s = 1 means the secondary system is in the polling stage; s = 0 means it is in the priority support stage. The set of feasible states for the system can be noted as follows: Here, n h and n w are the total capacity of L h and L w . ∑ u−w k=1 kj w+k < w, if l wq > 0 means that if L w is not empty, the summation of maximum number of channels that all ongoing SU w can donate will always be less than the lower bound of SU w . Similarly, if l hq > 0 shows that if L h is not empty, the summation of the maximum number of channels that all ongoing SU h can donate will always be less than the lower bound of SU h . bðxÞ is the total number of the utilized channels at state x, which can be described by Furthermore, M − bðxÞ is the number of the idle channels, which equals to N free that is defined in Algorithm 1.
To analyze the transition rate from a general state x to other states, we assume that the arrivals of PU and SU services in the system obey Poisson distribution with arrival rates λ p for PU, λ h for SU h , and λ w for SU w , while the departures of PU and SU services are exponential distribution with departure rates μ p for PU, μ h for SU h , and μ w for S U w . However, the scheduling with feedback will cause the external arrivals of SUs services no longer obey the Poisson distribution. To simplify the study, it is assumed that the setting of feedback mechanism has little effect on SUs services, i.e., exogenous arrivals of SUs services are all obey Poisson distribution. Accordingly, the CTMC model can be established based on four events including PU arrivals, PU departures, SU arrivals, and SU departures. State transition from a general state x can be developed.

Event A: PU Arrivals.
State transition from a general state x upon a PU arrival is derived. Indexes such as destination state, user activity, transition rate are obtained in Figure 2 while transition conditions are listed in Figure 3.
In Figure 3, the arrival behavior of PU is not constrained by the stage of the secondary system, so the transition condition is s = 0 or s = 1. The interrupted SU (SU h , for example) will return to the queue if the queue is not full, such as the condition l hq < n h in state t 4~s tate t 10 . Otherwise, the SU service is forced to terminate, such as l hq = n h in state t 19~s tate t 25 .
The arrival of PU may interrupt the service of any SU, such as that in state t 4~s tate t 10 and state t 19~s tate t 25 (Figure 2), there may exist ongoing SU w ðwÞ in the system when SU h ðhÞ is interrupted. In Figure 3, the condition that the idle channels are released by the interrupted SU h ðhÞ or the forcibly terminated SU h ðhÞ can be assembled by the ongoing SU w ðwÞ is ∀k ðw < k ≤ uÞ, j k = 0, which means there is no SU w with more than w aggregated channels in the system. The condition ∀ i ðh < i ≤ vÞ, l i = 0, in state t 4 and state t 19 means that there is no SU in the system that can perform adaptation, while ∀ i ðh = i = vÞ, l i > 0, means the SUs in the system cannot perform spectrum adaptation. The conditions in state t 11 and state t 26 have similar meanings. Due to the assumption that h < w in state t 18 and state t 33 , if SU h exists in L h , i.e., l hq ≥ 1, the idle channels released by the interrupted SU w or the forcibly terminated SU w can be used by SU h in L h .

Event B: PU Departures.
State transition from a general state x upon a PU departure is derived. The destination state, user activity, and transition rate are shown in Figure 4, and the conditions are listed in Figure 5.
When the departure of PU occurs during priority support stage, the ongoing SU h can use the idle channel released by PU in state t 3 which is based on that the idle channel is not occupied by SU h in L h . There are two possible cases: (1) No packet exists in L h , i.e., if h = 1, then l hq = 0:2. (2) There are packets in L h , but the total number of the remaining channels is not enough to start the service of SU h in L h , i.e., if 1 < h ≤ v, then l hq ≥ 0 and M − bðxÞ < h − 1. Furthermore, in state t 5 , the ongoing SU w can use the idle channel released by PU which is based on the SU h in L h , and the ongoingSU h do not use the idle channel, which also has two cases: (1) Ongoing SU h cannot assemble more channels, i.e., if l m > 0, When the departure occurs during the polling stage, if SRL is empty, the transition conditions are the same as those in the priority support stage. Otherwise, if SRL is not empty, SU h in L h can use the idle channel in state t 2 , which is based on that the sum of the idle channel released by PU and the remaining idle channels in the system is not enough to start the service of SU w on SRL but can start the service of SU h , i.e., h ≤ M − bðxÞ + 1 < w. The ongoing SU h can use the idle channel in state t 4 only if no SU in the queue uses the channel. The ongoing SU w can use the idle channel in state t 6 only if no SU in the queue uses the idle channel and the ongoingSU h do not use the channel.  The condition that the service of SU h can be started upon its arrival in state t 1~s tate t 6 is that the sum of the idle channels in the system and the channels that can be donated   Figures 8 and 9.
The total number of the idle channels used by the ongoing SUs should not be greater than the number of the channels released by the leaving SUs, such as the condition m ≥ ∑ v−1 i=h ðv − iÞ l i − ðv − mÞ in state t 4 . Besides, in state t 10 , state t 11 , state t 21 , and state t 22 , the departure of SU occurs in the polling stage, and the condition that SU w in L w can use the idle channel is SRL ∉ ∅. In state t 12~s tate t 20 , since n ≥ w, if SU w ðnÞ leaves during the polling stage, there must be SRL = ∅.
Above all, by integrating all the possible destination states, activities, transition rates, and transition conditions from Event A to Event D, the steady-state probability of the system, πðxÞ, can be calculated from global balance equations and normalization condition: where π is a steady-state probability vector and Q is the transition rate matrix generated by q ij and q ii : Here, q ij ði, j ∈ S, and i ≠ jÞ is the transition rate from any reachable state t i to another reachable state t j , which is the sum of the possible transition probabilities considering all events A~D. S is the system feasible state set (Equation (2)). The diagonal elements q ii in transition rate matrix Q can be found as q ii = −∑ i,jði≠jÞ∈S q ij : Then, the performance evaluation of the secondary system can be measured as follows: (1) Network capacity (packet/unit time) is the service completion rate, which means the average number of services completed per time unit. The capacity of SU h service is denoted as C h and that of SU w service is denoted as C w , which are given as (2) Spectrum utilization is determined by the ratio of the average number of available channels to the total number of channels: where bðxÞ is the number of available channels in state x and M is the total number of channels.
(3) Blocking probability is the probability that the newly arrived SU cannot be served due to all of the available channels in the system are busy (i) Blocking probability of SU h : a newly arrived SU h will be blocked if the following conditions are met: (1) The sum of the total number of idle channels available in the system and the number of channels that can be donated by other ongoing SUs does not satisfy the lower bound of channel assembly of SU h ; (2) L h has no space left to hold SU h . Thus, the blocking probability of S U h , P h b , can be obtained: { lh+1, .
. ,ju,l (ii) Blocking probability of SU w : a new SU w will directly put into L w no matter if it arrives during the polling stage or the priority support stage. The service of SU w is blocked if there is no space left in L w : The blocking probability of SU w , P w b , can be obtained: where the set A w is the trigger condition for SU w to be blocked: A w = fx ∈ S, l wq = n w g.
(4) Forced termination probability refers to the probability that the SU service is forced to terminate because of the absolute channel access priority of PU. Forced termination of SU only occurs upon PU arrivals in Event A, which needs to meet the following conditions: (1) what the PU preempts is a SU h with h channels or a SU w with w channels, (2) there are no remaining channels in the system, and (3) other ongoing SUs cannot perform spectrum adaptation to share the channel with the interrupted SU. Forced termination probability can be determined by the ratio of the average forced termination probability to the arrival rate of SUs who are not blocked (iii) Forced termination probability of SU h : the forced termination of SU h occurs in state t 19~s tate t 25 of Event A, the probability, P h f , can be expressed as where Λ h is the arrival rate of the unblocked SU h : Λ h = λ h ð1 − P h b Þ:B h is the set of states of S U h who are forced to terminate: 10 Wireless Communications and Mobile Computing (iv) Forced termination probability of SU w : the forced termination of SU w occurs in state t 26 state t 33 of Event A, the probability, P w f , can be expressed as where Λ w is the arrival rate of the unblocked SU w : Λ w = λ w ð1 − P w b Þ:B w is the set of states of SU w who are forced to terminate:

Numerical Simulation and Analysis
In this section, four study cases are conducted to evaluate the secondary system performance based on the proposed Ps-rc strategy and the channel access process. Performance analysis is carried out in a CRN with 6 channels ðM = 6Þ sharing the spectrum bandwidth, i.e., there are 6 PUs in the secondary network. The arrival rate and departure rate of PUs are set as λ p = 1, μ p = 0:5, respectively. Only one secondary user is allowed to arrive at once in the secondary system; the arrival rate and departure rate of SU h and SU w are set as λ h = 1, λ w =2, μ h = 1, μ w = 1, respectively. Dynamic parameters ðh, v, w, u, n h , n w Þ in the spectrum access process are set as h = 1, w = 2, v = u = 4, n h = 1, n w = 2: The allocation factor η = 0:5: Based on the above setting, the general state x of Equation (1) can be specified: where l i ði = 1, 2, 3, 4Þ is SU h with i aggregated channels; j k ðk = 2, 3, 4Þ is SU w with k channels; the superscript of each position indicates the upper limit of the number of users at the corresponding position, such as l 2 3 means that there are at most 3 SU h s in the system simultaneously who assemble 2 channels; and l wq 2 represents that there are at most 2 SU w s waiting in L w . Therefore, the transfer events can be specific. Due to high dimension, the transition rate matrix Q generated by x needs to be downgraded. A random general state ð3 0 0 0 0 0 0 2 0 2 0Þ is taken as an example to show the degradation process. Obviously, the current secondary system is in priority support stage in state ð3 0 0 0 0 0 0 2 0 2 0Þ: And there are 7 flows, among which 3 are ongoing SU h with one aggregated channel, 2 PUs are in the system, and each PU occupies one channel. Also, there are 2 SU w waiting in L w .
Marking method to achieve the dimension reduction: the possible transition of state ð3 0 0 0 0 0 0 2 0 2 0Þ is triggered by all user activities related to this state in Event A~Event D. Denote the state ð3 0 0 0 0 0 0 2 0 2 0Þ as 7 − * , where the first position, 7, is the total number of flows in this state and the second position, * , is the counting in order (the maximum value is the total number of states with 7 flows in the system). When there arrives a new flow in this state, it may be the arrival of PU or any SU (Event A or Event C may be triggered), then there will be 8 flows in the next state. When there is a flow leaving from this state, it may be the departure of PU or any SU h (Event B or Event D may be triggered), then there will be 6 flows in the next state. According to one-step transition, state 7 − * can only . ,lv,jw+1, .
. ,lv,jw, .  The transition rate matrix Q is a block matrix, whose number of layers is theoretically generated by the product of the superscript (Equation (14)); the size is 5184 × 5184: However, due to the system settings, it is not always reachable between any two states. In our numerical simulation process, the size of matrix Q was simplified to 443 × 443: But the specific form of Q is still hard to show here. Therefore, we take a random state i, i = ð3 0 0 0 0 0 0 2 0 2 sÞ to show the way of obtaining the elements in matrix Q (s is the secondary system stage). Figure 10 shows the transition from state i ð3 0 0 0 0 0 0 2 0 2 sÞ to all of the reachable states j.
According to Figure 10, the transition rate of the i-th row (i.e., starting from the state ð3 0 0 0 0 0 0 2 0 2 sÞ) in matrix Q to all reachable states j (i.e., j-th column) can be obtained. The other specific states can be done in the same manner. Then, the transition rate matrix Q can be developed.   Figure 9: The transition conditions of the system from the general state x to all reachable states with SU departures.
13 Wireless Communications and Mobile Computing the network capacity of SUs increases with the arrival rate, but the trend is slowing down. This is because as the arrival rate of SUs increase, the channels in the system are fully utilized for saturation. For SU h , the network capacity increased by 8.48% at the maximum difference position as the buffer capacity of L h increased from n h = 0 to n h = 2: For SU w , the network capacity increased by 9.3% at the maximum difference position as the buffer capacity of L w increased from n w = 0 to n w = 4: It shows that expanding the buffer capacity can increase network capacity. By allowing more flows to wait in the queue, the number of the flows stored in the system also increases, which makes it possible for more SUs to access the channel. Therefore, increasing the buffer capacity of SUs can effectively increase the network capacity.
Comparing Figures 11 and 12, we can see that the network capacity of SU h is always higher than that of SU w , which is due to the proposed Ps-rc strategy paying more attention to high-priority services. In order to alleviate the starvation problem of low-priority SUs, we set a larger buffer capacity for SU w : Therefore, it can be seen that as the arrival  14 Wireless Communications and Mobile Computing rate increases, the increase of network capacity of SU w becomes greater. It is reflected in the slope change of SU w which is greater than that of SU h .

Case 2:
Spectrum Utilization. Figure 13 shows the change of the arrival rate of SUs with spectrum utilization.
Let the x-axis be the arrival rate of SU w (it is the same for SU h ). Similar to network capacity, the change of spectrum utilization increases first and then becomes stable. As the arrival rate increases, more channels are utilized. The available channels in the system gradually reach saturation. The increase of buffer capacity increases the possibility of SUs being served, thus effectively increasing the spectrum utilization. Figures 14 and 15 show the relationship between the blocking probability of SU and the arrival rate of PUs. Figure 14 shows the change of blocking probability of SU h and SU w under different buffer capacities. When the arrival rate of PUs increases gradually, more channels are occupied by PUs because of the absolute channel access priority, resulting in a linear increase in the blocking probability of SUs. Since we set the polling loop for the low-priority queue, the newly arrived SU w cannot be served directly. Therefore, the blocking probability of SU w is higher than that of SU h : By comparing the blocking probability of SUs with different buffer capacities, it can be seen that the larger the buffer capacity, the more services of flows that can be stored, then the lower the blocking probability. Figure 15 shows the comparison of the blocking probability of SU h with the proposed Ps-rc strategy and without using the proposed strategy when the buffer capacity is n h = 1 and n w = 2: After using the proposed Ps-rc strategy, the blocking probability of SU h is reduced by 33.3% at the maximum difference position, λ p = 0:6: The reason is that the polling mechanism is adopted in L w , and then, a part of the channels are reserved for SU h in the polling stage. In fact, the service of SU w is delayed in exchange for the service of SU h : It is obvious that the adoption of the

Wireless Communications and Mobile Computing
Ps-rc strategy can significantly reduce the blocking probability. Therefore, the Ps-rc strategy proposed in this paper can meet the demands of improving the priority of important information in CRNs. However, when the arrival rate of PUs increases, the blocking probability of SU h still increases significantly, because SUs have a lower priority than PUs in CRNs. Figures 16 and  17 show the relationship between the forced termination probability of SUs and the arrival rate of PUs. Figure 16 shows the changes of the forced termination probability of SU h and SU w under different buffer capacities. Figure 17 shows the comparison of the forced termination probability of SU h with the Ps-rc strategy and without using the strategy when the buffer capacity is fixed ðn h = 1, n w = 2Þ.

Case 4: Forced Termination Probability.
From Figure 16, we can see that the forced termination probability of SU h under the Ps-rc strategy is always lower than that of SU w . As the arrival rate of PUs increases, the number of channels available to SUs decrease, then the number of SUs being served is decreased. When the queue of SUs in the buffer is full, the services of the interrupted SUs are forced to terminate. Therefore, the forced termination probability of SUs increases significantly. It can be seen from Figure 16 that setting a larger buffer capacity for SU w can effectively reduce the forced termination probability of SU w .
It can be seen from Figure 17 that the proposed Ps-rc strategy can reduce the forced termination probability of S U h . After using the proposed Ps-rc strategy, the forced termination probability of SU h is reduced by 40% at the maximum difference position, λ p = 0:8: In particular, when the arrival rate of PUs is low, the proposed strategy has more channel access opportunities for SU h . Therefore, the proposed Ps-rc strategy can guarantee the QoS of the predefined high-priority SUs in CRNs.

Conclusions
A Ps-rc strategy with two types of priority queues was proposed in this paper to satisfy the classification demands of the predefined priority services in CRNs. The realization process was presented by algorithm. Combining with the technologies of channel assembling and spectrum adaptation, the dynamic channel access process based on the proposed strategy was depicted. The process was triggered by four events including PU arrivals, PU departures, SU arrivals, and SU departures. Furthermore, a continuous time Markov chain (CTMC) was developed, and the resource flow processes triggered by user activities were mapped on the state of CTMC. Then, all possible destination states starting from a general system state were obtained; the corresponding user activities, transition rates, and conditions were also derived. By dimension reduction, the steady state of the secondary system was further obtained, thereby obtaining the performance metrics including network capacity, spectrum utilization, blocking probability, and forced termination probability. Finally, four study cases were carried out to evaluate the performance of secondary system. Numerical experiments show that the proposed Ps-rc strategy can effectively reduce the blocking probability and forced termination probability of high-priority SUs. Results prove that the proposed Ps-rc strategy can improve the service quality of high-priority services without causing the problem of excessive starvation of low-priority services.   16 Wireless Communications and Mobile Computing

Data Availability
The data used to support the findings of this study are included within the article.

Conflicts of Interest
The authors declare that there are no conflicts of interest regarding the publication of this paper.