Energy-Efﬁcient Cluster Head Selection via Quantum Approximate Optimization

: This paper proposes an energy-efﬁcient cluster head selection method in the wireless ad hoc network by using a hybrid quantum-classical approach. The wireless ad hoc network is divided into several clusters via cluster head selection, and the performance of the network topology depends on the distribution of these clusters. For an energy-efﬁcient network topology, none of the selected cluster heads should be neighbors. In addition, all the selected cluster heads should have high energy-consumption efﬁciency. Accordingly, an energy-efﬁcient cluster head selection policy can be deﬁned as a maximum weight independent set (MWIS) formulation. The cluster head selection policy formulated with MWIS is solved by using the quantum approximate optimization algorithm (QAOA), which is a hybrid quantum-classical algorithm. The accuracy of the proposed energy-efﬁcient cluster head selection via QAOA is veriﬁed via simulations.


Introduction
The present era is a turbulent period of technological advancement towards the noisy intermediate-scale quantum (NISQ) era and the 6G era [1,2]. With the development of NISQ devices, various fields, such as quantum communication, quantum machine learning, and quantum optimization, are evolving as components of 6G. In the field of quantum optimization, in particular, various studies have been conducted, based on technologies such as quantum adiabatic algorithm (QAA), variational quantum eigensolver (VQE), and quantum approximate optimization algorithm (QAOA) [3][4][5]. Among them, the QAOA, a special case of bounded-error quantum polynomial time (BQP) algorithm, can be applied to various fields because of its simple structure [6,7]. The structure of QAOA is divided into a parameterized quantum circuit part and a classical optimization part that determines the optimal parameters. Heuristic methods are mainly used in the classical optimization part, and control of hyperparameters is necessary to find the optimal parameter. Therefore, QAOA does not always guarantee quantum supremacy; however, it has the flexibility to adapt to variations of the target problem [8,9]. The main target problem of QAOA research is the maximum cut problem, and various studies have been conducted to empirically optimize this problem [10][11][12][13][14][15]. In addition, QAOA application studies have also been actively conducted [16,17]. Along with these various research attempts, QAOA is expected to be useful as a quantum heuristic optimizer in the near future.
The wireless ad hoc network is an important research topic, even in the 6G era, because of its relevance to the internet of things (IoT) and autonomous driving [18][19][20][21][22]. In a wireless ad hoc network using limited resources, it is advantageous to construct a hierarchical network topology through

Background
For many decades, quantum computing researchers have aimed to find quantum algorithms that can surpass classical algorithms. Various attempts have been made, and a few quantum algorithms with quantum supremacy over classical algorithms in certain cases have been identified [5,27,28]. In the NISQ era, the discovery of potential quantum algorithms has been accelerated because of the evolved quantum processors and interactions with machine learning techniques [1]. In particular, QAOA is one of the lightest and most flexible hybrid quantum-classical optimization algorithms in the NISQ era and is suitable for application to various graph-based systems [5,29]. QAOA can control the resource (quantum operations and times) usage-performance trade-off by adjusting the circuit depth, so it can be used in various environments. If the proper quantum hardware is supported, QAOA is also suitable in sensor networks or embedded systems with limited resources and capabilities. Therefore, before discussing a hybrid quantum-classical approach to energy-efficient cluster head selection in limited systems, this section describes the QAOA and a graph-based MWIS formulation.

Quantum Approximate Optimization Algorithm (QAOA)
QAOA is a hybrid quantum-classical optimization algorithm that uses a parameterized quantum circuit composed of unitary operators [5,30,31]. In addition, the QAOA is a type of quantum heuristic algorithm which is known to perform well in some combinatorial optimization problems.
The first step in QAOA is to map the objective function f (x) of the problem consisting of binary bit strings to the Hamiltonian H P , as follows: where H P is a problem Hamiltonian. The problem Hamiltonian H P can be divided into the objective Hamiltonian H O and constraint Hamiltonian H C , as follows: where ρ ∈ R + is a constant coefficient. The Hamiltonians H O and H C represent the objective and constraint, respectively, of the problem. The mixing Hamiltonian H M , a transverse-field Hamiltonian, is defined as follows: where σ x j is a Pauli-X operator applied on the jth qubit. The Pauli-X operator acts similar to the classical NOT operator, that is, it acts as a bit-flip.
To construct a quantum circuit, H P and H M are converted into unitary operators, as follows: where γ and β are parameters and where U P (γ) and U M (β) are usually called the problem operator and mixing operator, respectively. In the QAOA circuit, the initial state |s can be a uniform superposition state, as follows: where n ∈ Z + . If the depth of a quantum circuit is defined as p ∈ Z + , the 2p parameters are represented as follows: Therefore, the parameterized state |γ, β , which is generated in a quantum circuit, is as follows: The expectation value of f (x) for the solution samples obtained via repeated measurements on |γ, β is as follows: The optimal parameters γ op and β op can be obtained from the classical optimization loop; therefore, the optimal solution can be computed from (9) via γ op and β op .
A schematic of the QAOA is shown in Figure 1. The green part represents the classical optimization loop, for example, the stochastic gradient descent (SGD). Indeed, the optimization of parameters in the classical optimization loop part has a significant impact on the performance of the QAOA. The p value also has a significant impact on the performance of QAOA, and the proper p value is different depending on the problem. When the p value increases, the number of unitary operators increases and, thus, the number of quantum gates in the circuit increases. In other words, the accuracy of the computation can be increased but the gate noise increases as well. Therefore, in QAOA, proper design of the problem Hamiltonian, proper optimization of parameters, and proper setting of the p value are all important.

Maximum Weight Independent Set (MWIS)
Let us consider a weighted graph G = (V, E) with |V| = n nodes and |E| = m edges. Assume that the weight w j is at node v j ∈ V, where 1 ≤ j ≤ n. The independent set can be constructed by selecting only nonadjacent nodes. Among the possible independent sets, the MWIS has the largest sum of weights.
In Figure 2b,c, 2 cases represent the following independent sets V 1 ⊂ V and V 2 ⊂ V, respectively: The sums of the weights of each set are as follows:    There is no independent set having a sum of weights greater than 58; thus, V 1 is MWIS. Expanding from the example, the generalized formulation of the MWIS is as follows: max : where The MWIS formulation has been applied to various research fields, such as communication, machine learning, and computer vision [32][33][34][35][36]. Although the MWIS is non-deterministic polynomial-time (NP) hard, which requires an approximate solution, it is useful for modeling complex and large-scale structures.

Energy-Efficient Cluster Head Selection
Clustering is an essential technique for organizing networks more efficiently. In particular, the communication between clusters in a wireless ad hoc network which has a distributed control structure is performed by the cluster heads [26]. Therefore, it is very important to set the cluster head selection policy according to the purpose of the wireless ad hoc network. This section describes the clustering method via cluster head selection for an energy-efficient wireless ad hoc network.

Clustering Wireless Ad Hoc Network
The wireless ad hoc network is a multi-hop system of self-organizing wireless nodes that can communicate with each other without additional infrastructure [37,38].
Let us consider a wireless ad hoc network, as shown in Figure 3. Figure 3a,b represents the flat ad hoc network topology before clustering and the hierarchical ad hoc network topology after clustering, respectively. The numbers on the nodes indicate the weight of each node. In real-world applications, the weight can be a numerical representation of the feature; for example, the efficiency of energy-consumption, level of security, or robustness [26]. In the graphs covered in this paper, the weight of each node represents the efficiency of energy-consumption. When transmitting the same data, less energy is used and more stable transmission is possible on a node that has high efficiency of energy-consumption. Therefore, it is good to use nodes that have high efficiency of energy-consumption in wireless ad hoc network communication.   In the wireless ad hoc network, a hierarchical structure such as that shown in Figure 3b has more advantages than a nonhierarchical structure such as that in Figure 3a for limited resource utilization [23,37]. In the hierarchical structure, all nodes are classified into cluster head, gateway, and normal nodes. The general clustering process in which the roles of the nodes are determined as follows: (i) The cluster head nodes are determined sequentially according to the policy. (ii) The clusters are created by grouping the cluster head nodes and adjacent nodes. (iii) Except for the cluster head node in each cluster, the nodes required for communication with other clusters are determined as gateway nodes. (iv) The remaining nodes that are not required for communication with other clusters are determined as normal nodes.
Through this process, 10 clusters are identified in Figure 3b, marked with dotted lines. The completely separated clusters are marked with green dotted lines, and the others are marked with red dotted lines. The network topology can be completely changed according to the cluster head selection policy. In other words, the numbers and distributions of clusters depend on the cluster head selection policy. Therefore, the stability and performance of the network also depend on the cluster head selection.

Cluster Head Selection Policy using MWIS
As mentioned in Section 3.1, it is recommended to select nodes with high energy-consumption efficiency as cluster heads, for stable data transmission. In order to construct an energy-efficient network topology, the cluster heads should not be neighbors. Therefore, for an energy-efficient and stable network, the cluster head selection policy can be formulated with MWIS. The proposed cluster head selection policy is as follows: where v k = 1, if the kth node is selected as cluster head, 0, otherwise, E k,l = 1, if there is an edge between the kth node and the lth node, 0, otherwise.
Note that v j ∈ {1, 0} is a binary decision variable of the jth node, V is the set of binary decision variables of all nodes in the network topology, w j ∈ R + is the energy-consumption efficiency of the jth node, and E is the adjacency matrix.
The cluster head selection policy formulated with MWIS can be implemented using heuristic approaches, such as the greedy algorithm [39]. For example, the clusters in Figure 3b are the implementation results of the cluster head selection policy using MWIS. Clustering via the MWIS-based cluster head selection policy has several advantages over minimum ID clustering and maximum degree clustering [26]. One of the advantages of clustering via MWIS-based cluster head selection policy is that it produces fewer completely separated clusters. This can reduce the communication time and energy consumption when transmitting data between cluster heads.

Energy-Efficient Cluster Head Selection via QAOA
The cluster head selection policy proposed in Section 3.2 can be implemented via QAOA, a hybrid quantum-classical optimization algorithm, by proper Hamiltonian design [5,12]. In other words, the problem Hamiltonian, which represents the proposed policy, can be designed, and based on this, a QAOA circuit can be implemented. This approach with the QAOA circuit can have an advantage in speed over the classical MWIS-based clustering algorithm by rapid quantum computation by the principles of superposition and entanglement. In addition, the performance benefits can be also expected if advanced quantum hardware is supported in the future. Theoretically, QAOA increases the approximation quality corresponding to performance by increasing the circuit depth [5]. In the advanced quantum hardware that is free from the effects of gate noise, the circuit depth can be increased to a greater extent; thus, it can be possible to obtain a more accurate solution for the MWIS-formulated cluster head selection policy.

Hamiltonian Design
By (2), the problem Hamiltonian is designed by dividing into the objective Hamiltonian and constraint Hamiltonian. To match the optimization directions of the objective Hamiltonian and constraint Hamiltonian, both Hamiltonians are designed to be minimized rather than maximized. The mixing Hamiltonian is redefined with the symbols of (18).

The objective Hamiltonian.
Suppose that there is a Boolean function, f 1 (x), as follows: To obtain a Boolean Hamiltonian H 1 mapped from f 1 (x), the following equation can be constructed for a single qubit: where I is the identity operator, σ z is the Pauli-Z operator, and A and B are constant coefficients. For the same input, the expectation value of H 1 should be adjusted to the same value as the output of f 1 (x). Therefore, the system of equations for obtaining the values of A and B, according to Table 1, is as follows: The values of the constant coefficients A and B are obtained from (23) as 1 2 and − 1 2 , respectively. Therefore, H 1 mapped from f 1 (x) can be defined as follows, from (22): According to (24), the objective function (18) of the energy-efficient cluster head selection policy is mapped to the following Hamiltonian H O * : where σ z j is the Pauli-Z operator applied on the jth node. Because H O * should be maximized, the objective Hamiltonian H O that should be minimized is as follows: The constraint Hamiltonian. According to the constraint (19), all cases between two nodes are shown in Figure 4. The black nodes represent the cluster heads, and in the energy-efficient cluster head selection policy, it is a prohibition condition that two cluster heads are directly connected via an edge.
The constraint function C(k, l) that extends this prohibition condition to the entire network topology can be defined as follows: Note that ∧ represents a Boolean AND operator and that k > l is a condition to avoid duplication of E k,l and E l,k , indicating the same edge.  The definition of a Boolean AND function f 2 (x 1 , x 2 ) is as follows: To obtain a Boolean Hamiltonian H 2 mapped from f 2 (x 1 , x 2 ), the following equation can be constructed: where C, D, E, and F are constant coefficients and σ z 1 and σ z 2 are Pauli-Z operators applied on the first and second nodes, respectively.
According to Table 2, configured to obtain the Hamiltonian H 2 that has the same expectation value as the output of f 2 (x 1 , x 2 ), the following system of equations can be constructed: The values of the constant coefficients C, D, E, and F are obtained from (30) as 1 4 , − 1 4 , − 1 4 , and 1 4 , respectively. Therefore, H 2 mapped from f 2 (x 1 , x 2 ) can be defined as follows, from (29): According to (31), the constraint function (27) of the energy-efficient cluster head selection policy is mapped to the following Hamiltonian H C * that should be minimized: In (32), σ z k and σ z l are the Pauli-Z operators applied on the kth and lth nodes, respectively. By removing the constant term of (32), the simplified version of the constraint Hamiltonian H C that should be minimized is obtained as follows: The problem Hamiltonian. From the definition of H O in (26) and H C in (33), the problem Hamiltonian H P that should be minimized is defined as follows: Note that ρ ∈ R + is a constant coefficient called the penalty rate. ρ determines the proportion of H C compared to H O , which determines the optimal value of H P .

Circuit Implementation
From the problem Hamiltonian H P in (34), which defines the energy-efficient cluster head selection policy, and the mixing Hamiltonian H M in (35), which provides various states via bit-flip, the unitary operators for constructing the quantum circuit are defined as follows: Note that U P (γ), U O (γ), U C (γ), and U M (β) are called the problem operator, objective operator, constraint operator, and mixing operator, respectively. In addition, γ and β are the 2p parameters of the QAOA circuit defined in (7). Note that the forms of Equations (37)- (39) are in consideration of the rotation-z (RZ) and rotation-x (RX) gates.
The RZ gate RZ(θ), representing a single-qubit rotation about the z-axis, and the RX gate RX(θ), representing a single-qubit rotation about the x-axis, are defined as follows: According to Equation (37), U O (γ) can be implemented using the RZ gates. Moreover, U C (γ) can be implemented as a combination of the RZ gates and controlled-not (CNOT) gates, according to Equation (38). Therefore, U P (γ) can be implemented with U O (γ) and U C (γ), according to Equation (36). Subsequently, U M (β) can be implemented using the RX gates by (39).
The proposed QAOA circuit for energy-efficient cluster head selection is shown in Figure 5. This circuit is an example applied to a simple network topology with 5 nodes and the following adjacency matrix E .
Each node corresponds to each qubit, and the initial state is set to a uniform superposition state by the Hadamard gates. After passing the quantum gates that represent the unitary operators from the initial state, the measurement is performed on the created parameterized state. This sample circuit represents QAOA with depth p = 1; the parameters of unitary operators are expressed as γ 1 and β 1 . As p increases, the number of parameters increases, as in (7).
As shown in Figure 5, U O (γ 1 ) requires as many RZ gates as the number of nodes. U C (γ 1 ) requires as many RZ gates and CNOT gates as 3 times and 2 times the number of edges, respectively. U M (β 1 ) requires as many RX gates as the number of nodes. The total number of RZ gates, CNOT gates, and RX gates required for the QAOA p circuit, which has a circuit depth of p, is p times greater than that of the QAOA 1 circuit.  Figure 5. Proposed QAOA 1 circuit for MWIS with 5 qubits: The qubit q j corresponds to jth node. γ 1 and β 1 are circuit parameters, and w j is the weight of jth node. Each qubit is initialized to the uniform superposition state via the Hadamard gate. The objective operator U O (γ 1 ) is implemented using the RZ(γ 1 w j ) gates. The constraint operator U C (γ 1 ) is implemented as a combination of the RZ(−E k,l γ 1 ρ(w k + w l )/2) gates, CNOT gates, and RZ(E k,l γ 1 ρ(w k + w l )/2) gates, where k > l. In (42), only E 2,1 (= E 1,2 ) and E 5,3 (= E 3,5 ) are 1, so U C (γ 1 ) is implemented only between q 1 and q 2 and between q 3 and q 5 . The mixing operator U M (β 1 ) is implemented using the RX(2β 1 ) gates. At the end of the QAOA 1 circuit, measurements are performed.

Simulation Results
This section discusses the QAOA simulation results for the energy-efficient cluster head selection policy formulated using MWIS. The simulation is performed on the regular graphs that are suitable for wireless ad hoc networks. QAOA is one of the simple quantum algorithms that intuitively express the state with qubit rotation via the quantum gate [16,40]. This intuitive and simple process has something in common with the classical greedy algorithm. Therefore, the greedy algorithm, which is also useful for MWIS-based cluster head selection, is used as a comparison algorithm [26].

Simulation Method
A set of 10-node 3-regular weighted graphs and a set of 10-node 5-regular weighted graphs were randomly generated with 1000 instances each. The range of the node weight representing the energy-consumption efficiency was from 1 to 10. The optimal solution of each graph was found by the brute-force search so that the following approximation ratio δ could be computed for each graph [41].
where f app is the solution obtained via the approximation algorithm, f op is the optimal solution obtained via brute-force search, H P is the problem Hamiltonian in (34), and γ and β are the parameters of the QAOA circuit. For each instance, the greedy algorithm and QAOA with depth p = 1, 2, · · · , 10 were evaluated in terms of the δ obtained from 1000 measurements. The simulation was performed using TensorFlow Quantum, and the Adam optimizer was used to optimize the parameters of the QAOA circuit [42,43].

Simulation Analysis
The simulation aimed to find a valid circuit depth p for which the QAOA could outperform the greedy algorithm in MWIS-based clustering.

Simulation on 3-Regular Weighted Graphs
As shown in Figure 6a and Table A1, when focusing on the mean of δ on the 3-regular weighted graphs, it is observed that QAOA p defeats the greedy algorithm when p ≥ 4. Moreover, QAOA p has a larger minimum of δ than the greedy algorithm, except for QAOA 1 , QAOA 4 , and QAOA 5 . Based on the mean and minimum of δ, it is confirmed that QAOA p outperforms the greedy algorithm at p ≥ 6.
In Figure 7a, most of QAOA p shows a better distribution than that of the greedy algorithm expressed in dark gray. In particular, QAOA p shows an overwhelming performance over the greedy algorithm at p = 9, 10 expressed in blue and dark blue, respectively. In Table A1, it can be numerically confirmed that the optimal solution ratio of QAOA p is 85% at p = 9, 10, which outperforms 68% of the greedy algorithm.

Simulation on 5-Regular Weighted Graphs
As shown in Figure 6b and Table A2, when focusing on the mean of δ on the 5-regular weighted graphs, it is observed that QAOA p defeats the greedy algorithm when p ≥ 3. Moreover, QAOA p has a larger minimum δ than the greedy algorithm, except for QAOA 1 , QAOA 2 , and QAOA 3 . Based on the mean and minimum of δ, it is confirmed that QAOA p outperforms the greedy algorithm at p ≥ 4.
In Figure 7b, most of QAOA p shows a better distribution than the greedy algorithm expressed in dark gray. Similar to the 3-regular graphs case, QAOA p shows an overwhelming performance over the greedy algorithm at p = 9, 10 expressed in blue and dark blue, respectively. In Table A2, QAOA 9 and QAOA 10 show the optimal solution ratios of 69% and 69.9%, respectively. These are overwhelming accuracies when compared to that of the greedy algorithm with an optimal solution ratio of 41%.

Summary and Further Discussion
On the 3-regular weighted graphs and 5-regular weighted graphs, performance analysis was performed for QAOA p (1 ≤ p ≤ 10) and the greedy algorithm.
As p increases, the mean of δ tends to increase, the standard deviation of δ tends to decrease, and the optimal solution ratio tends to increase. In other words, it is experimentally proven that the MWIS-based clustering accuracy via QAOA p increases as p increases. In particular, QAOA 9 and QAOA 10 show overwhelming accuracies over the greedy algorithm. However, it is not a good choice to increase p recklessly. Because each time p increases by 1, the number of parameters in the circuit increases by 2, increasing the time spent on parameter optimization and increasing the risk of falling into a local optimum. Therefore, finding the appropriate p, which depends on the graph type of the network, is the key to clustering via QAOA p .
As a topic of further discussion, there is an interesting point about the measurement of QAOA p . The best solution for each instance can be defined as the value closest to or the same as the optimal solution, from among the outputs of the measurements. Therefore, the minimum number of measurements required to obtain the best solution for each instance can be computed by dividing the number of total measurements by the number of best solutions. N(p), which is the mean of the minimum number of measurements required to obtain the best solution for all instances at the circuit depth p, is as shown in Figure 8. On both 3-regular weighted and 5-regular weighted graphs, N(p) shows a tendency to decrease as p increases. Considering that the optimal solution ratio tends to increase as the circuit depth p increases, at large p, the possibility that the best solution and optimal solution are the same is high. Therefore, at large p, the optimal solution can be obtained even with a small number of measurements. This shows the potential for an efficient design of QAOA p by reducing the number of measurements at large p.

Conclusions and Future Work
This paper proposed an energy-efficient clustering method with a hybrid quantum-classical approach. First, the cluster head selection policy was modeled via an MWIS formulation. Subsequently, the objective and constraint of the modeled policy were mapped to a designed objective Hamiltonian and constraint Hamiltonian, respectively. Based on the designed Hamiltonians, the QAOA p circuit that implemented an energy-efficient cluster head selection policy was proposed. According to the simulation results, the proposed QAOA p outperformed the greedy algorithm at p ≥ 6 on the 3-regular weighted graphs and p ≥ 4 on the 5-regular weighted graphs. In particular, QAOA 9 and QAOA 10 showed the highest performance. Finally, it was experimentally proven that the accuracy of the cluster head selection via QAOA p tended to increase as p increased.
One of the future research directions will focus on improving the performance and efficiency by optimizing the gate configuration of the constraint operator part. A larger number of nodes with a large degree would lengthen the circuit of the constraint operator part. As a solution, a parallel gate configuration of the circuit was considered. By separating the set of nodes into subsets via graph preprocessing, the circuit of the constraint operator part could be divided into sub-circuits. Subsequently, a parallel gate configuration could be created in which the CNOT gates on the sub-circuits ran at the maximum simultaneously. This optimization of the gate configuration could certainly shorten the circuit. Therefore, one of our next works would be a concrete implementation of the parallel gate configuration.
Another future research direction will focus on data-intensive performance evaluation with various types of real quantum computers or better testbeds. Using a superconducting quantum computer, a photonic quantum computer, a trapped ion quantum computer, or a better testbed, various clustering algorithms will be compared with our MWIS-based clustering via QAOA. Considering the scalability, the experiment will be performed with more nodes. An analysis of the energy-consumption according to the number of gates and qubits for each type of quantum computer will also be performed to quantify the required energy. In other words, another of our next works would be to conduct more realistic performance evaluations for real-world implementation.
Author Contributions: J.C. was the main researcher who initiated and organized the research reported in the paper, and all authors including S.O. and J.K. were responsible for analyzing the simulation results and writing the paper. All authors have read and agreed to the published version of the manuscript.

Funding: This research was supported by NRF-Korea (2019M3E4A1080391 and 2019M3E3A1084054).
Acknowledgments: J. Kim is the corresponding author of this paper.

Conflicts of Interest:
The authors declare no conflict of interest.

Appendix A. Details on Simulation Results
Here, there are supplementary data tables of the simulation results in Section 4.