A multi-objective algorithm based on genetic algorithm (GA) and particle swarm optimization (PSO)
By combining GA and PSO, a dual-objective collaborative optimization for the detection of key nodes in complex networks is achieved, which solves the shortcomings of traditional algorithms in balancing attack costs and network failure scale, and improves detection efficiency and accuracy.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- GUILIN UNIV OF ELECTRONIC TECH
- Filing Date
- 2026-03-31
- Publication Date
- 2026-07-03
Smart Images

Figure CN122334411A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of critical node detection problems, specifically to a multi-objective algorithm based on the genetic algorithm (GA) and the particle swarm optimization algorithm (PSO). Background Technology
[0002] In modern society, complex networks have penetrated many areas of natural and human society, becoming a core tool for describing the structure and dynamic characteristics of various complex systems. Complex network models abstract the interaction relationships of various complex systems in reality into a "node-edge" model, and are widely applicable to various scenarios such as power, communication, transportation, and social interaction, providing a unified analytical framework for revealing the operational laws of complex systems. Whether it is infrastructure networks, such as power and transportation networks; biological networks, such as gene regulation networks; or financial systems, such as economic cooperation networks, their safe and stable operation is directly related to social order and economic development, and is of vital importance to the development and security of various fields.
[0003] The Critical Node Detection Problem (CNDP) is a hot topic in complex network research, significant for network optimization, resource allocation, and reducing protection costs. Critical nodes typically refer to nodes that have a significant impact on network structure and function. As the core carriers of network topology and functionality, the stability of critical nodes directly determines whether the overall network function can operate normally. Taking social networks as an example, accurately identifying and locating individuals or groups with critical influence can provide a precise tool for targeted marketing campaigns, thereby effectively improving user engagement and marketing conversion efficiency. However, when these nodes suffer from multiple threats such as random failures, natural disasters, deliberate attacks, and network virus intrusions, it can lead to network function degradation or even paralysis, severely impacting network performance. Therefore, research on critical node detection in complex networks has significant theoretical and practical value for improving network resilience, reducing disaster losses, and saving operational costs.
[0004] For a long time, researchers have conducted extensive studies on non-cascading and cascading scenarios in complex networks. In non-cascading scenarios, the nodes or edges in a complex network are independent of each other, and the failure of some nodes or edges will not affect other nodes or edges. Conversely, in cascading scenarios, when some nodes or edges in a complex network are attacked or damaged, connected nodes or edges will also be affected, triggering cascading failures. These failures will cause other nodes or edges to fail as well, continuously propagating this effect throughout the network until no new nodes or edges fail. Examples include high-voltage transmission lines breaking due to snowfall and falling onto another line, causing large-scale power outages; damage to a node causing overload of other components, leading to large-scale power outages; and internet crashes due to congestion. Therefore, in cascading scenarios, research on the detection of critical nodes in complex networks is crucial for improving network robustness.
[0005] In the practical application of CNDP, there is a significant conflict between minimizing attack costs and maximizing the scale of network failure after an attack, making it difficult for single-objective optimization to achieve a balance between the two. The core advantage of Multi-Objective Optimization (MOO) lies precisely in its ability to find a Pareto optimal solution set that balances multiple conflicting objectives, ensuring each objective reaches a relatively optimal state. This balances the relationships between multiple conflicting objectives, generating a series of non-dominated solutions, thus providing a comprehensive and balanced solution for complex network optimization. Based on this, many researchers have combined multi-objective optimization algorithms with the critical node detection problem. Research innovation in this field focuses on two main dimensions: firstly, innovative problem modeling, breaking through the limitations of single-objective optimization by constructing multi-dimensional, multi-objective trade-off models. This includes innovative definitions of BCVND and BOCNDP, and the proposal of dimensionality reduction models such as KGDP and precise iterative algorithms to break the fixed k-value constraint; secondly, overcoming scenario fragmentation by integrating cascaded and non-cascaded failure scenarios into a unified model, and constructing practical multi-objective models for specific scenarios such as dependent networks and information propagation. Second, the algorithm architecture is innovative. It focuses on efficiently solving complex multi-objective models, integrates heterogeneous frameworks such as membrane computing, evolutionary multi-task, and co-evolution, optimizes the core mechanism of classic algorithms, and realizes knowledge transfer and information reuse by relying on node coupling relationships and network topology features, effectively solving the problem of search space expansion in large-scale or multi-layer networks.
[0006] Therefore, this paper proposes a multi-objective algorithm based on the genetic algorithm (GA) and the particle swarm optimization algorithm (PSO), which breaks through the limitations of traditional single-objective optimization and solves the problem of multi-objective optimization objectives being detached from reality, thereby realizing dual-objective collaborative optimization for the detection of key nodes in complex networks. Summary of the Invention
[0007] This invention proposes a multi-objective algorithm based on the genetic algorithm (GA) and the particle swarm optimization (PSO) algorithm. By integrating GA and PSO, the GA module performs a global search to ensure population diversity, while the PSO module performs local optimization to accelerate convergence. This approach combines the advantages of both algorithms while overcoming the shortcomings of GA's slow convergence speed and PSO's tendency to get trapped in local optima.
[0008] To solve the above problems, the present invention is achieved through the following technical solution:
[0009] A multi-objective algorithm based on genetic algorithm (GA) and particle swarm optimization (PSO) includes the following steps:
[0010] Step 1: Define parameters, network, and construct the objective function. Determine key parameters such as population size `pop_size`, maximum number of iterations `max_gen`, elite ratio `elite_ratio`, crossover probability `cross_rate`, mutation probability `mutate_rate`, PSO iteration count `iter`, and the number of individuals optimized in PSO `k`. For the CNDP problem, this method constructs attack cost and attack effect that closely resemble real values, i.e., the failure scale after the attack. In subsequent optimization processes, a dual-objective collaborative optimization is achieved to minimize the attack cost and maximize the attack effect. To reduce the conflict between objectives, the attack effect is negatively evaluated, transforming the objective effect into minimizing both objectives, which facilitates improved optimization performance.
[0011] Step 2: Initialization. Binary encoding is used to precisely map individuals in the population. A binary string of length equal to the total number of network nodes is used as the population individual, where a 1 indicates the corresponding node has been attacked, and a 0 indicates it has not been attacked. Each individual represents a set of candidate key nodes in a complex network. This method utilizes prior knowledge based on node cascading potential, degree centrality, and betweenness centrality, and employs neighborhood heuristics and random generation as core ideas to generate a diverse and high-quality initial population. The algorithm uses cascading potential, betweenness centrality, and degree centrality as prior knowledge of the population, calculates and normalizes them, and then assigns weights to obtain a node importance score (node_score).
[0012] Step 3: Global Search Using the GA Algorithm. In this step, based on the GA algorithm framework, a comprehensive exploration of candidate key node sets is performed in the search space. First, a mating pool with a size of twice `pop_size` is generated based on the individuals in the population. Next, an adaptive hybrid crossover operator based on uniform crossover and multi-point crossover is used to explore a wider space while finding high-quality candidate sets, balancing population diversity and convergence. Second, an adaptive mutation operator is designed based on evolutionary progress and clustering degree to ensure solution quality. Then, adaptive grid technology is integrated into the selection operator to increase the distribution range of the population and make the Pareto front diverse and convergent. Finally, based on directional neighborhood search, a local search strategy is designed to fully explore the neighborhood of each node, improving the quality and diversity of solutions.
[0013] Step 4: Local optimization using the PSO algorithm. In this stage, an adaptive update strategy for the velocity and position of PSO particles in the binary discrete space of the critical node detection problem is proposed. This strategy aims to achieve directed local optimization by achieving individual optima and local-global optima, thereby improving the quality of the solution.
[0014] Step 5: Output Results. If the algorithm reaches the maximum number of iterations or the termination condition, the evolution stops, and the algorithm outputs the optimal set of Pareto nodes—the set of key nodes with the lowest attack cost and the best attack effect. Simultaneously, it outputs the HV metric and the Pareto front graph. Based on the front graph, it finds the corresponding optimal solution according to different selection conditions and effect requirements, adapting to various scenarios.
[0015] Compared with the prior art, the present invention has the following characteristics:
[0016] 1. Traditional CNDP often uses the number of attack nodes to simulate attack costs when constructing a target. However, in reality, attack costs are often related to the functionality of nodes and the difficulty of the attack. Therefore, using the number of attack nodes for simulation cannot accurately reflect reality and cannot be widely applied in real-world scenarios. This paper, on the other hand, sets the attack cost using node degree as the core quantitative parameter, realizing a positive correlation between node importance and attack difficulty, which is more in line with real-world attack costs. Furthermore, this paper uses a load-allocation-based cascading failure model to calculate the attack effect, which also closely resembles real-world complex network models, such as power grids.
[0017] 2. Traditional CNDP often uses random attacks to generate the initial population during initialization, resulting in low-quality individuals in the population, which severely affects the evolutionary convergence speed and the accuracy of space exploration. This paper, however, uses prior knowledge combined with heuristics and random generation to create a diverse and high-quality population, accelerating the convergence speed and increasing the probability of finding the optimal solution.
[0018] 3. This invention deeply integrates the GA and PSO algorithms, constructing a multi-objective optimization framework that combines global exploration with local optimization via GA. The PSO algorithm improves convergence speed, while the GA algorithm ensures population diversity. Simultaneously, modifications are made to both the GA and PSO algorithms to adapt to the current binary discrete space, enabling rapid identification of the optimal candidate solution set for both objectives.
[0019] 4. In the process of selecting the Pareto front, the Knee Point technique is used to retain the critical point on the Pareto front that contributes the most to the solution set. That is, selecting this point allows for the exchange of the minimum loss of one objective for the maximum gain of the other objective, representing the most significant balance between the objectives. Using this technique can solve the problem of insufficient selection pressure caused by an excessive number of non-dominated solutions during the selection process, and prevent the algorithm from being overly biased towards one objective while neglecting the optimization of the other. Attached Figure Description
[0020] Figure 1 This is a flowchart of a multi-objective algorithm based on the genetic algorithm (GA) and the particle swarm optimization algorithm (PSO).
[0021] Figure 2 This represents the topology of an unweighted, undirected network abstracted from a complex network, along with its corresponding adjacency matrix. Detailed Implementation
[0022] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to specific examples and the accompanying drawings.
[0023] See Figure 1 A multi-objective algorithm based on genetic algorithm (GA) and particle swarm optimization (PSO) specifically includes the following:
[0024] Step 1: Define parameters and network. First, abstract the complex network into a graph theory problem and model it using G=(V,E). Here, the symbols V=(1,2,…,n) and E=(e... ij |i,j∈V,i≠j) represent the n nodes and m edges of network G, respectively. Furthermore, the adjacency matrix A=(a ij ) n×n It can also be used to represent networks. In an unweighted, undirected graph, A is a symmetric matrix. When there is an edge between nodes i and j, i.e., e ij =1, a in the adjacency matrix ij =1, otherwise a ij =0. In a weighted graph, a ij Let A be the weight of the corresponding edge. For a directed graph, A is an asymmetric matrix. ijThis represents both the connectivity between nodes and the direction of those connections. It shows the topology of an unweighted, undirected network and its corresponding adjacency matrix. (Example:) Figure 2 As shown, it defines all the parameters used by the algorithm, such as population size pop_size, maximum number of iterations max_gen, elite ratio elite_ratio, crossover probability cross_rate, mutation probability mutate_rate, PSO iteration count iter, and number of individuals optimized by PSO k.
[0025] Step 2: Construct the objective function. The goal of the Critical Node Detection Problem (CNDP) is to search for a set of nodes S⊂V in a complex network such that attacking these nodes significantly reduces the network connectivity of the residual network G[V\S]. Typically, CNDP is defined as a bi-objective optimization problem, aiming to simultaneously minimize the attack cost F. C And maximize attack effect F E The formula is , of which F E It takes different forms in different scenarios, and F C The commonly defined formula is: Where S represents the set of attack nodes, and cost(i) records the cost of attack node i. In existing multi-objective optimization algorithms, F C and F E These are two commonly used, conflicting objectives.
[0026] Typically, the cost of attacking node i is defined as 1, and the total attack cost F is... C This is often defined as the total number of attack nodes. However, this paper uses non-uniform cost, with node degree as the core quantification parameter. A quantification model is constructed through a combination of "non-linear exponential terms + linear terms," making the importance of a node positively correlated with the attack difficulty. Ultimately, this achieves the effect that "the more important the node, the higher the attack cost," which better reflects the cost in real-world attack scenarios. The cost calculation formula for attack node i is as follows: Where cost(i) is the attack cost of node i, d(i) is the degree of node i, and r, m and s are specified parameters, which are 2.0, 1.0 and 1.0 respectively in this paper. r is used to divide the cost level, and m and s are used to measure the cost difference between the same ranking and different rankings.
[0027] In the CNDP (Network-Consecutive-Device) domain, there are two scenarios: non-cascaded and cascaded. A non-cascaded scenario occurs when the initial failure of one or more nodes in the network only causes the failure of the links connected to them, without damaging other components; conversely, a cascaded scenario occurs when the failure of other nodes causes the failure of the links connected to them. In a non-cascaded scenario, F... EThere are various evaluation metrics, the most common being pairwise connectivity (PWC), which is the number of node pairs connected by paths in a graph. In cascading failure scenarios, the total number of failed nodes is usually obtained using a cascading failure model (CFM) to measure the destructive effect of a network attack. Several methods for cascading failure models (CFM) have been proposed. This paper constructs a cascading failure simulation framework based on node load and capacity constraints, employing a load transfer mechanism that primarily distributes loads according to the load share of neighboring nodes, with uniform distribution as a fallback, to simulate the failure propagation process. The total number of failed nodes is ultimately used as the network failure scale. Specifically, each node v... i They all have a capacity C i and initial load L i When the network is attacked, the failed node will redistribute its load to neighboring nodes. When a neighboring node v j initial load L j and additional load △L ij When the total amount exceeds its capacity, i.e., L j +△L ij >C j Node v j When a failure occurs, its load will be further locally distributed to other nodes until the cascading terminates. Finally, the total number of failed nodes in the initial network is counted as the attack effect, using the formula: Where |CF(S,G)| represents the total number of cascaded faulty nodes after attacking a group of nodes S.
[0028] Step 3: Population Initialization. In the initialization phase, the algorithm first uses a binary search method to calculate the minimum number of attacking nodes, kmin, required to cause the entire network to fail during the cascading failure simulation. During initialization, the number of individual attacking nodes in the population is strictly limited to kmin, thereby narrowing the target search space, guiding the search direction, and improving search efficiency. Then, knowledge-guided prior techniques are used to prevent the generated population from being too random, accelerating later evolutionary convergence. This algorithm uses commonly used network metrics: betweenness centrality, degree centrality, and node cascading potential. Weights are assigned to these metrics to obtain node scores, facilitating the selection of key attacking nodes and accelerating convergence. Finally, based on the target space, individuals in the population are generated heuristically to ensure population diversity and prevent excessive concentration, which could lead to premature convergence. In this paper, binary encoding is used to accurately map individuals in the population. A binary string of length equal to the total number of network nodes is used as the population individual, where a 1 indicates that the corresponding node has been attacked, and a 0 indicates that it has not been attacked. Each individual represents a set of candidate key nodes in a complex network. The cascade potential (CP) is composed of the proportion of failed nodes and the ratio of additional load to remaining capacity, as shown in the following formula: ,|F(vi Attack node v i The number of nodes that fail in the subsequent cascade, ΔL ij For node v j Additional load received, C j and L j They are nodes v j Initial capacity and initial load; betweenness centrality measures the number of shortest paths through a node, as shown in the formula. , Indicates passing through node v i , with node v s v t The number of shortest paths between the two ends; Indicates the connection node v s v t The number of shortest paths. Degree centrality measures the number of connections a node has in a network, and the formula is as follows: , Represents node v i The degree of efficiency can be significantly improved by calculating the three parameters, avoiding blind searches, increasing convergence speed, and enhancing the quality of solutions.
[0029] Step 4: GA Evolutionary Stage. This paper proposes an evolutionary process based on the GA algorithm framework, mainly consisting of five parts: mating pool generation, crossover, mutation, local search, and selection, as detailed below:
[0030] 1) Mating pool generation: This paper uses a two-round tournament selection method to generate a mating pool with twice the population size, which is fully compatible with the subsequent crossover method.
[0031] 2) Crossover: Since a single crossover operator cannot effectively balance population diversity and convergence, this paper designs an adaptive hybrid crossover operator based on uniform crossover and multi-point crossover. Uniform crossover ensures population diversity but fails to converge quickly, while multi-point crossover converges rapidly but is prone to getting trapped in local optima. Therefore, the algorithm uses a higher probability of uniform crossover in the early stages of evolution to improve population diversity, enhance the algorithm's search capability in the target space, and avoid getting trapped in local optima; in the later stages of evolution, a higher probability of multi-point crossover is used to accelerate the algorithm's convergence speed. The adaptive hybrid crossover operator combines the advantages of both crossover methods, achieving a better balance between population diversity and convergence.
[0032] 3) Mutation: This paper designs an adaptive mutation operator that mutates individuals based on the progress of evolution and the degree of clustering in the population. If the population is clustered and in the early stages of evolution, the mutation rate is increased to improve population diversity; otherwise, the mutation rate is decreased. Simultaneously, if all individuals fail, the attack cost is reduced to minimize the impact of failure; if not all individuals fail, a higher mutation rate is used, prioritizing mutation of nodes with high cascading potential. This mutation operator increases population diversity while ensuring high-quality solutions, balancing the algorithm's global exploration capability and local optimization capability.
[0033] 4) Selection: This paper incorporates adaptive grid technology into the selection operator to increase the distribution range of the population, ensuring that solutions are distributed throughout the entire target space. This achieves a uniform distribution of the Pareto front while balancing convergence and diversity. The algorithm first performs a non-dominated sort on the merged population, adaptively setting the grid size based on the sorted result. This enables broad exploration through coarse-grained partitioning in the early stages and local optimization through fine-grained partitioning in the later stages. Then, all objective functions are normalized to prevent excessive bias towards one objective due to large differences in the ranges between the two objectives, thus completing the mapping of the target space. Next, a hierarchical selection criterion is adopted within the grid: the first priority retains super-elite solutions, selecting the optimal solution for complete failure, the knee solution, and the bipolar solution of the first front; the second priority is to selectively supplement complete failure solutions and select the best solution in ascending order of attack cost; the third priority selects non-complete failure solutions based on the low-density grid priority principle, ensuring the breadth of the Pareto front distribution. When the population size is insufficient, supplementation is achieved through global non-dominated hierarchy and crowding. This strategy preserves high-quality solutions while ensuring population diversity, balancing the algorithm's convergence and global exploration capabilities.
[0034] 5) Local Search: This paper proposes a local search strategy based on directed neighborhood exploration. Specifically, the algorithm pre-calculates all evaluation metrics, including the dual-objective values used for key node detection and cascading potential, so that they do not need to be repeatedly calculated in loops, thus accelerating the search speed. The algorithm also initializes local search parameters, including the search count `step` and the number of neighborhood solutions `max_neighbors`, to prevent excessive local searches from causing the algorithm to get stuck in local optima, while simultaneously accelerating the local search process and balancing speed and optimization performance.
[0035] A greedy algorithm is used for local search. First, an empty neighborhood solution set is initialized to facilitate the subsequent storage of generated neighborhood solutions. Then, the algorithm selectively filters the neighborhood flipping pool based on whether the current solution is completely invalid. If completely invalid, the top 50% of nodes with the highest cascading potential are selected as the neighborhood flipping pool to reduce attack costs while ensuring invalidity; otherwise, the top 50% of nodes with the highest cascading potential are selected as the neighborhood flipping pool to collaboratively optimize attack costs and the scale of invalidity. Next, the algorithm generates neighborhood solutions by flipping the binary codes of individuals in the population. In the neighborhood flipping pool, k nodes are randomly selected for bit flipping to generate new neighborhood solutions, which are then added to the neighborhood solution set to deeply explore the neighborhood of the current solution. Next, the algorithm preprocesses the neighborhood solutions, first removing duplicate solutions from the neighborhood solution set, then compressing the range of attack nodes and filtering invalid solutions. Finally, the dual objective values are normalized to eliminate the influence of units. Subsequently, the algorithm uses hierarchical non-dominated sorting to filter high-quality neighborhood solutions. The algorithm first selects the lower-cost solution when both the current solution and its neighboring solutions are invalid. Then, for solutions where all neighboring solutions are invalid but the current solution is not, it selects the neighboring solution. Finally, for the remaining solutions, it uses a non-dominated sorting algorithm to select the neighboring solution whose bi-objective value is no worse than the current solution and whose at least one objective is better. Finally, the algorithm executes a greedy update strategy, updating and iterating only when a better solution is found; otherwise, it terminates the search early, improving search speed and efficiency.
[0036] The algorithm fine-tunes nodes in the later stages of iteration. When the search progress exceeds 70%, it randomly selects one node in the population to perform a single flip fine-tuning and evaluates the target value of the fine-tuned solution. If the fine-tuning operation does not bring optimization benefits, it immediately rolls back the flip operation to restore the original solution, effectively enhancing diversity.
[0037] The local search strategy proposed in this paper fully explores the neighborhood of each node by targeted neighborhood selection, flipping to generate neighborhood solutions, hierarchical selection, greedy search, and post-fine-tuning, thereby improving the quality and diversity of solutions, accelerating the search speed, and achieving dual-objective collaborative optimization of key node detection.
[0038] Step 5: PSO Local Optimization Stage. In the GA evolutionary stage, although the algorithm traverses the entire target space, explores the distribution regions of all solutions, and escapes local optima, its reliance on crossover and mutation for random exploration leads to poor convergence and low search efficiency. The PSO algorithm, however, guides the search direction based on individual and global optima, accelerating convergence and improving solution quality. Therefore, introducing the PSO local optimization stage can form a global and local search framework with the GA evolutionary stage. This retains the advantages of GA in exploring the entire solution space and escaping local optima while incorporating the advantages of PSO in fast convergence and directional optimization, thereby improving the quality of the Pareto front and balancing its convergence and diversity.
[0039] In the local optimization stage of PSO, this paper proposes an adaptive update strategy for the velocity and position of PSO particles in discrete space. This algorithm strategy is fully adaptable to binary discrete space, achieving directional guided local optimization.
[0040] 1) Initialization. Initialize the number of optimizations k and the number of iterations iter, and obtain the non-dominated solutions, resulting in the optimal solution set after GA evolution, which is the object of PSO optimization. Traverse the non-dominated solution set, adding nodes to the candidate solutions sequentially until the number of optimizations k is reached, constructing the candidate solution set candidatess for local optimization. Then initialize the core parameters.
[0041] 2) The core strategy for the local optimization phase of PSO. The algorithm first initializes the particle positions and velocities for each iteration. The particle positions are assigned the solutions from the candidate set; in the binary discrete space of this paper, the particle positions represent the attack node set. The algorithm first performs non-dominated sorting on the solutions in the candidate set to obtain a local non-dominated front, and then selects the inflection point solution from the front as the local optimum (local_gbest) within the candidate set. This strategy guides the dual-objective optimization direction, avoiding local optima achieved by focusing on a single objective.
[0042] 3) Traverse the candidate set and update the velocity and position of each particle to achieve local optimization of the population. First, adaptively adjust the three core parameters of PSO. Then, update the velocity according to the classic PSO velocity update formula. Since traditional PSO is applicable to continuous solution spaces, this paper uses the Sigmoid activation function to map continuous velocity values to flip probabilities in the [0,1] interval to adapt to discrete spaces. The larger the velocity value, the higher the flip probability of the corresponding node; the smaller the velocity value, the lower the flip probability of the corresponding node. Next, the algorithm generates a random array with the same dimension as the particle position, where each value is a random number in the [0,1] interval. The random number is compared with the mapped flip probability to construct a flip mask. Then, the algorithm performs a flip operation based on the flip mask to generate a brand new solution and complete the particle position update. Finally, the algorithm evaluates the new particle and the individual optimal objective. If the objective value of the new solution is better than the historical optimal objective value of the particle, the individual optimal objective value of the particle is updated. Then, according to the standard non-dominance rule, the new solution is compared with the particle's individual optimal solution pbest: if the new solution is dominated by pbest, the particle's position is immediately reverted; otherwise, the new solution is retained. Finally, the particle's individual optimal solution pbest is globally updated.
[0043] 4) The algorithm will fill the candidate set of solutions that have completed all local optimizations back into the corresponding positions in the original population, replacing the original solutions.
[0044] It should be noted that although the embodiments described above are illustrative, they are not intended to limit the invention. Therefore, the invention is not limited to the specific embodiments described above. Any other embodiments obtained by those skilled in the art under the guidance of this invention without departing from its principles are considered to be within the protection scope of this invention.
Claims
1. A multi-objective optimization method based on genetic algorithm (GA) and particle swarm optimization (PSO), comprising the following steps: Step 1: Define parameters, network, and construct the objective function. Determine key parameters such as population size `pop_size`, maximum number of iterations `max_gen`, elite ratio `elite_ratio`, crossover probability `cross_rate`, mutation probability `mutate_rate`, PSO iteration count `iter`, and the number of individuals optimized in PSO `k`. For the CNDP problem, this method constructs attack cost and attack effect that closely resemble real values, i.e., the failure scale after the attack. In subsequent optimization processes, a dual-objective collaborative optimization is achieved to minimize the attack cost and maximize the attack effect. To reduce the conflict between objectives, the attack effect is negatively evaluated, transforming the objective effect into minimizing both objectives, which facilitates improved optimization performance. Step 2: Initialization. Binary encoding is used to precisely map individuals in the population. A binary string of length equal to the total number of network nodes is used as the population individual, where a 1 indicates the corresponding node has been attacked, and a 0 indicates it has not been attacked. Each individual represents a set of candidate key nodes in a complex network. This method utilizes prior knowledge based on node cascading potential, degree centrality, and betweenness centrality, and employs neighborhood heuristics and random generation as core ideas to generate a diverse and high-quality initial population. The algorithm uses cascading potential, betweenness centrality, and degree centrality as prior knowledge of the population, calculates and normalizes them, and then assigns weights to obtain a node importance score (node_score). Step 3: Global Search Using the GA Algorithm. In this step, based on the GA algorithm framework, a comprehensive exploration of candidate key node sets is performed in the search space. First, a mating pool with a size of twice `pop_size` is generated based on the individuals in the population. Next, an adaptive hybrid crossover operator based on uniform crossover and multi-point crossover is used to explore a wider space while finding high-quality candidate sets, balancing population diversity and convergence. Second, an adaptive mutation operator is designed based on evolutionary progress and clustering degree to ensure solution quality. Then, adaptive grid technology is integrated into the selection operator to increase the distribution range of the population and make the Pareto front diverse and convergent. Finally, based on directional neighborhood search, a local search strategy is designed to fully explore the neighborhood of each node, improving the quality and diversity of solutions. Step 4: Local optimization using the PSO algorithm. In this stage, an adaptive update strategy for the velocity and position of PSO particles in the binary discrete space of the critical node detection problem is proposed. This strategy aims to achieve directed local optimization by achieving individual optima and local-global optima, thereby improving the quality of the solution. Step 5: Output Results. If the algorithm reaches the maximum number of iterations or the termination condition, the evolution stops, and the algorithm outputs the optimal set of Pareto nodes—the set of key nodes with the lowest attack cost and the best attack effect. Simultaneously, it outputs the HV metric and the Pareto front graph. Based on the front graph, it finds the corresponding optimal solution according to different selection conditions and effect requirements, adapting to various scenarios.
2. According to claim 1, a multi-objective optimization method based on Genetic Algorithm (GA) and Particle Swarm Optimization (PSO) is used in step 2 to construct the objective function using non-uniform cost. Node degree is used as the core quantization parameter, and a quantization model is constructed through a combination of "non-linear exponential terms + linear terms." This ensures that the importance of a node is positively correlated with the attack difficulty, ultimately achieving the effect that "the more important the node, the higher the attack cost," which better reflects the cost in real-world attack scenarios. The cost calculation formula for attacking node i is cost(i) = m^(d(i) / r) + (d(i) / r) × s, where... cost(i) is the attack cost of node i, d(i) is the degree of node i, and r, m and s are specified parameters, which are 2.0, 1.0 and 1.0 respectively in this paper. r is used to divide the cost level, and m and s are used to measure the cost difference between the same ranking and different rankings.
3. According to claim 1, the multi-objective optimization method based on genetic algorithm (GA) and particle swarm optimization (PSO) is used in step 2 to design the objective function for the attack effect, which is divided into cascaded and non-cascaded scenarios. In the non-cascaded scenario, there are various evaluation indicators for the attack effect, the most common of which is pairwise connectivity (PWC), i.e., the number of node pairs connected by paths in the graph. In the cascaded failure scenario, the total number of faulty nodes is usually obtained through the cascaded failure model (CFM) to measure the destructive effect of the network after being attacked. Several methods for the cascaded failure model (CFM) have been proposed. This paper constructs a cascaded failure simulation framework based on node load and capacity constraints, and adopts a load transfer mechanism that mainly distributes loads according to the load ratio of neighboring nodes and uniformly distributes loads as a fallback to simulate the failure propagation process. Finally, the total number of faulty nodes is used as the network failure scale. The total number of faulty nodes in the network is used as the attack effect, as follows: F_E=|CF(S,G)| / n where, |CF(S,G)| represents the total number of cascaded faulty nodes after attacking a group of nodes S.
4. In the multi-objective optimization method based on Genetic Algorithm (GA) and Particle Swarm Optimization (PSO) as described in claim 1, step 3 uses node cascade potential, degree centrality, and betweenness centrality as prior knowledge to calculate node importance scores, thereby guiding the heuristic generation strategy for initialization and generating a high-quality initial population. Cascade potential (CP) is composed of the proportion of failed nodes and the ratio of additional load to remaining capacity, as shown in the following formula: ,|F(v i Attack node v i The number of nodes that fail in the subsequent cascade, ΔL ij For node v j Additional load received, C j and L j They are nodes v j Initial capacity and initial load; betweenness centrality measures the number of shortest paths through a node, as shown in the formula. , Indicates passing through node v i , with node v s v t The number of shortest paths between the two ends; Indicates the connection node v s v t The number of shortest paths. Degree centrality measures the number of connections a node has in a network, and the formula is as follows: , Represents node v i The degree of efficiency can be significantly improved by calculating the three parameters, avoiding blind searches, increasing convergence speed, and enhancing the quality of solutions.