Network game solving method based on greedy algorithm

By applying the node increment method based on greedy algorithms in large-scale networks, the problem that traditional algorithms are difficult to efficiently solve the offensive and defense strategy selection is solved, and more efficient calculation and optimization effects are achieved.

CN119544523AInactive Publication Date: 2025-02-28NAT UNIV OF DEFENSE TECH

Patent Information

Application Number
CN202411563182.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-05
Publication Date
2025-02-28
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

In large-scale networks, traditional game solution algorithms are difficult to efficiently solve the problem of offensive and defensive strategy selection.

Method used

A network game solution method based on greedy algorithm is proposed. Through the node incremental greedy algorithm, the global optimal solution is gradually approached and the offensive and defense strategy selection is optimized.

Benefits of technology

It effectively improves the computing efficiency of offensive and defensive strategy selection in large-scale networks, and can optimize strategies under Nash equilibrium conditions and improve network performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119544523A_ABST
    Figure CN119544523A_ABST
Patent Text Reader

Abstract

The invention discloses a network game solving method based on a greedy algorithm, and the method comprises the steps: obtaining a topological structure of a network, determining a strategy set of an attack party and a defense party, and constructing a basic model of a network game; representing the network performance by using a maximum connected slice scale index, calculating the earnings of an attacker and a defense party under each strategy profile, and obtaining an earnings matrix of the network game model; starting from an initial attack and defense strategy, solving a game problem through a random selection strategy; continuously updating strategies of an attacker and a defender based on a greedy algorithm by traversing nodes successively; through an iterative strategy improvement process, strategies of an attacker and a defender cannot be independently improved, and Nash equilibrium is achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of complex network games in system engineering, and in particular to a network game solving method based on a greedy algorithm. Background Art

[0002] In the field of building network game models, the combination of game theory and complex network theory has led to the development of a mathematical model for attacker-defender confrontations within infrastructure networks (such as railway infrastructure networks). This approach quantifies various forms of attack and defense and their results into formulas that can be quantitatively analyzed. Subsequently, the competition problems arising from these confrontations are solved by mathematical optimization methods. In the predictive analysis of adversarial behavior, game theory can help analyze and predict the behavior patterns of participants in the process of network games. In turn, complex network theory enables the strategies used by participants to be macro-examined. Under the guidance of game system theory, the defender can understand how to choose an effective defense strategy, and the game trends of both parties in Nash equilibrium are accurately portrayed. The application of game theory in analyzing attacker-defender behavior has proven to be effective.

[0003] Greedy algorithms are widely used and effective optimization strategies in the field of artificial intelligence. They solve problems by making the best or most beneficial choice at each step. The principle of these algorithms is that a series of local optimal decisions can lead to a global optimal solution. Greedy algorithms are often used for problems with optimal substructure properties, that is, local optimal decisions can be aggregated into an optimal solution for the entire problem. The classic application of greedy algorithms is to find minimum spanning trees in graph theory, and Prim's algorithm and Kruskal's algorithm are two famous examples. In addition, greedy algorithms are also widely used in many scenarios such as resource allocation, scheduling, coding problems, and network flow optimization. Although greedy algorithms are simple and efficient, they do not always produce global optimal solutions. This is because once a local optimal choice is made, the algorithm does not backtrack but continues to move forward, which may lead to missing a better global solution. As shown by the "no free lunch" theorem, different problems may require different algorithms to achieve the best solution. To overcome the limitations of greedy algorithms, researchers have proposed several improvement strategies, such as introducing randomness or using heuristic information to avoid falling into local optimality. In addition, greedy algorithms can be combined with other optimization techniques (such as dynamic programming or local search) to improve their performance and applicability. In the context of intelligent computing, the greedy algorithm can be regarded as a heuristic search method that exhibits powerful optimization capabilities when solving specific problems. However, the application of the greedy algorithm requires a deep understanding of the structure of the problem to ensure that the local optimal decisions can be effectively combined to form a global optimal solution. Summary of the invention

[0004] The present invention aims to solve at least one of the technical problems existing in the prior art. To this end, the present invention discloses a network game solving method based on a greedy algorithm. A node incremental greedy algorithm is proposed to optimize the attack and defense strategy selection problem in the infrastructure network, and gradually approach the global optimal solution through local optimal selection.

[0005] The object of the present invention is to achieve a network game solving method based on a greedy algorithm through the following technical solution, the method comprising:

[0006] Step 1: Obtain the topological structure of the network, determine the strategy set of the attacker and the defender, and build a basic model of network game;

[0007] Step 2: Using the maximum connected piece size indicator to represent network performance, calculate the benefits of the attacker and defender under each strategy profile, and obtain the benefit matrix of the network game model;

[0008] Step 3, starting from the initial attack and defense strategy, solve the game problem by randomly selecting a strategy;

[0009] Step 4: By traversing the nodes one by one, the strategies of the attacker and defender are continuously updated based on the greedy algorithm;

[0010] Step 5: Through the iterative strategy improvement process, the strategies of the attacker and the defender cannot be improved independently, and the Nash equilibrium is reached;

[0011] The network is represented as a simple undirected graph G(V,E), where V represents the set of all nodes in the network, N=|V| represents the number of nodes in the network; and E represents the connection set.

[0012] The attack strategy set of the attacker is S A ={X 1 ,X 2 ,...,X m}, the defense strategy set of the defender is S D = {Y 1 ,Y 2 ,...,Y n}, for node V i , if attacked but not defended, then node V i The edges connected to it will be removed.

[0013] Specifically, the profit matrix is ​​divided into the profit matrix of the attacker and the profit matrix of the defender.

[0014] U A (X,Y) represents the attacker’s profit, U D (X,Y) represents the defender's payoff:

[0015]

[0016] Among them, Γ(G) represents the maximum connected piece size of the initial network G, It represents the maximum size of the connected piece of the network after a round of game. The profit matrix of the attacker and the profit matrix of the defender are respectively expressed as:

[0017]

[0018] Among them, U A represents the attacker’s payoff matrix, U D represents the payoff matrix of the defender, Indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The attacker's profit is Indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The defender's profit.

[0019] Specifically, the initial attack and defense strategy of step 3 is divided into an initial attacker strategy and an initial defender strategy, which are obtained by randomly selecting a certain proportion r of the attacker and defender strategy sets; the solution to the game problem adopts a linear programming model:

[0020] max z

[0021]

[0022] maxω

[0023]

[0024] Among them, max means maximization, z is the profit of the attacker, ω is the profit of the defender, X i represents the i-th attack strategy, Y j represents the jth defense strategy, U A (X i ,Y j ) indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The attacker's profit is U D (X i ,Y j ) indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The defender's profit is p i Indicates that the attacker chooses the i-th attack strategy X in the mixed strategy i The probability of jIndicates that the defender chooses the jth defense strategy Y in the mixed strategy j The probability of S A represents the attack strategy set of the attacker, S D represents the defense strategy set of the defender,

[0025] ∑ represents the summation symbol, represents any symbol, ∈ represents the symbol, solving the model, we get p = (p 1 ,p 2 ,...,p m ) T , q=(q 1 ,q 2 ,...,q n ) T This is the Nash equilibrium solution of the game.

[0026] Furthermore, the greedy algorithm is to find a pure strategy D that maximizes the defender's benefits through a greedy strategy. The first step is to set the defender's strategy. The second step is to traverse the nodes and find the best node v that can increase the profit under the premise of satisfying the resource constraints. If the defender uses a pure strategy And the attacker uses a mixed strategy P A , then the expected benefit of the defender in this case is It can be expressed as:

[0027]

[0028] Among them, z D,A Used to mark the attacking strategy S A Whether the defended party's strategy S has been successfully deleted D The selected target point set, if V D ∩V A =V D , indicating that the attacker fails, then z D,A =0; otherwise z D,A =1; represents the jth pure strategy of the defender, P A represents the attacker’s mixed strategy, It represents the profit of the defender in the game when the attacker chooses the i-th strategy and the defender chooses the j-th strategy;

[0029] If the node v can satisfy U D2 (D∪{v},y)>U D2 (D,y), then add node v to strategy D; otherwise, if U D2 (D∪{v},y)>U D3(x, y), then v is added to strategy D. Finally, when the number of nodes in strategy D reaches the upper limit of the number of resources of the defender, it stops, that is, |D| = R D .

[0030] Furthermore, the iterative strategy improvement process refers to iterating by traversing the nodes, starting from node 1, and the second iteration starts from node 2, increasing successively until the number of iterations reaches NR D +1, all strategy combinations are traversed and the final strategy optimization result is obtained.

[0031] Compared with the existing methods, the advantages of the method of the present invention are: network game is a research hotspot in recent years, but the traditional game solving algorithm is extremely difficult to solve in a large-scale network. The present invention provides a network game solving method based on a greedy algorithm. The method gradually approaches the global optimal solution through the local optimal selection, effectively solving the computational efficiency problem of attack and defense strategy selection in a large-scale network. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] Figure 1 A schematic diagram of a process flow of an embodiment of the present invention is shown;

[0033] Figure 2 A schematic diagram showing a network topology structure in an embodiment of the present invention is shown;

[0034] Figure 3 A schematic diagram of probability allocation according to an embodiment of the present invention is shown;

[0035] Figure 4 A schematic diagram of probability allocation of the defense side according to an embodiment of the present invention is shown. DETAILED DESCRIPTION

[0036] In order to make the purpose, technical solution and advantages of the present invention clearer, the present invention will be further described in detail below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0037] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.

[0038] In this embodiment, the attacker is the attacker, the defender is the defender, and the network model takes the railway network as an example, which can be abstracted into a simple undirected graph G(V,E), where V = {V 1 ,V 2 ,...,V N} represents the set of all nodes in the network, N = |V| represents the number of nodes in the network, and a node represents a station in the railway network;

[0039] represents a set of connections, where connections represent railway connections between stations, and A(G) = (a ij ) N×N Represents the adjacency matrix of graph G. If node V i and V j If there is a railway line between ij =a ji =1, if node V i and V j If there is no railway line between ij =a ji =0.

[0040] Only one attacker and one defender are considered, and both parties have complete knowledge of the topological structure of the existing network. All targets of attack and defense are nodes in the network. The criterion for determining whether a node is successfully attacked is: the node is attacked by the attacker and not protected by the defender. This game is played for only one round.

[0041] like Figure 1 As shown, a network game solving method based on a greedy algorithm comprises:

[0042] Step 1: Obtain the topological structure of the network, determine the strategy set of the attacker and the defender, and build a basic model of network game;

[0043] Step 2: Using the maximum connected piece size indicator to represent network performance, calculate the benefits of the attacker and defender under each strategy profile, and obtain the benefit matrix of the network game model;

[0044] Step 3, starting from the initial attack and defense strategy, solve the game problem by randomly selecting a strategy;

[0045] Step 4: By traversing the nodes one by one, the strategies of the attacker and defender are continuously updated based on the greedy algorithm;

[0046] Step 5: Through the iterative strategy improvement process, the strategies of the attacker and the defender cannot be improved independently, and the Nash equilibrium is reached;

[0047] The network is represented as a simple undirected graph G(V,E), where V represents the set of all nodes in the network, N=|V| represents the number of nodes in the network; and E represents the connection set.

[0048] The attack strategy set of the attacker is S A ={X 1 ,X 2 ,...,Xm}, the defense strategy set of the defender is S D = {Y 1 ,Y 2 ,...,Y n}, for node V i , if attacked but not defended, then node V i The edges connected to it will be removed.

[0049] Specifically, the profit matrix is ​​divided into the profit matrix of the attacker and the profit matrix of the defender.

[0050] U A (X,Y) represents the attacker’s profit, U D (X,Y) represents the defender's payoff:

[0051]

[0052] Among them, Γ(G) represents the maximum connected piece size of the initial network G, It represents the maximum size of the connected piece of the network after a round of game. The profit matrix of the attacker and the profit matrix of the defender are respectively expressed as:

[0053]

[0054] Among them, U A represents the attacker’s payoff matrix, U D represents the payoff matrix of the defender, Indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The attacker's profit is Indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The defender's profit.

[0055] Specifically, the initial attack and defense strategy of step 3 is divided into an initial attacker strategy and an initial defender strategy, which are obtained by randomly selecting a certain proportion r of the attacker and defender strategy sets; the solution to the game problem adopts a linear programming model:

[0056] max z

[0057]

[0058] maxω

[0059]

[0060] Among them, max means maximization, z is the profit of the attacker, ω is the profit of the defender, Xi represents the i-th attack strategy, Y j represents the jth defense strategy, U A (X i ,Y j ) indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The attacker's profit is U D (X i ,Y j ) indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The defender's profit is p i Indicates that the attacker chooses the i-th attack strategy X in the mixed strategy i The probability of j Indicates that the defender chooses the jth defense strategy Y in the mixed strategy j The probability of S A represents the attack strategy set of the attacker, S D represents the defense strategy set of the defender,

[0061] ∑ represents the summation symbol, represents any symbol, ∈ represents the symbol, solving the model, we get p = (p 1 ,p 2 ,...,p m ) T , q=(q 1 ,q 2 ,...,q n ) T This is the Nash equilibrium solution of the game.

[0062] Furthermore, the greedy algorithm is to find a pure strategy D that maximizes the defender's benefits through a greedy strategy. The first step is to set the defender's strategy. The second step is to traverse the nodes and find the best node v that can increase the profit under the premise of satisfying the resource constraints. If the defender uses a pure strategy And the attacker uses a mixed strategy P A , then the expected benefit of the defender in this case is It can be expressed as:

[0063]

[0064] Among them, z D,A Used to mark the attacking strategy S A Whether the defended party's strategy S has been successfully deleted D The selected target point set, if V D ∩V A =VD , indicating that the attacker fails, then z D,A =0; otherwise z D,A =1; represents the jth pure strategy of the defender, P A represents the attacker’s mixed strategy, It represents the profit of the defender in the game when the attacker chooses the i-th strategy and the defender chooses the j-th strategy;

[0065] If the node v can satisfy U D2 (D∪{v},y)>U D2 (D,y), then add node v to strategy D; otherwise, if U D2 (D∪{v},y)>U D3 (x, y), then v is added to strategy D. Finally, when the number of nodes in strategy D reaches the upper limit of the number of resources of the defender, it stops, that is, |D| = R D .

[0066] Furthermore, the iterative strategy improvement process refers to iterating by traversing the nodes, starting from node 1, and the second iteration starts from node 2, increasing successively until the number of iterations reaches NR D +1, all strategy combinations are traversed and the final strategy optimization result is obtained.

[0067] According to the above content, this embodiment is based on Figure 2 The network topology diagram shown in the figure is used for experiments, and the performance of the present invention is compared with the algorithms in the traditional attacker-defender game model. Traditional algorithms include random update strategy method (RS), degree update strategy method (DS), betweenness update strategy method (BS), proximity update strategy method (CS) and eigenvalue update strategy method (ES). RS refers to the defender randomly updating the strategy in each iteration; DS refers to the defender updating the strategy according to the degree of the node, giving priority to the strategy with the largest degree; BS refers to the defender giving priority to the node with the largest betweenness; CS refers to the defender giving priority to the node with the largest proximity; ES refers to the defender giving priority to the node with the largest eigenvalue. The results are shown in Figure 2. Figure 3 shown.

[0068] Then we can draw a profit graph of the defender under different attack and defense resources, such as Figure 4 As shown in Figure 2, when the attack resource is set to 2 and the defense resource is set to 8, the defender suffers the least loss. The experimental results show that when the attack-defense resources are the same and small, the attacker can try to avoid the defender's defense to attack the element to reduce the defender's benefit. When there are a large number of attack-defense resources, the defender can defend the node as comprehensively as possible, and the attack cannot succeed even if the attacker has a large number of resources.

[0069] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.

Claims

1. A network game solving method based on a greedy algorithm, characterized in that: The method comprises: Step 1: Obtain the topological structure of the network, determine the strategy set of the attacker and the defender, and build a basic model of network game; Step 2: Using the maximum connected piece size indicator to represent network performance, calculate the benefits of the attacker and defender under each strategy profile, and obtain the benefit matrix of the network game model; Step 3, starting from the initial attack and defense strategy, solve the game problem by randomly selecting a strategy; Step 4: By traversing the nodes one by one, the strategies of the attacker and defender are continuously updated based on the greedy algorithm; Step 5: Through the iterative strategy improvement process, the strategies of the attacker and the defender cannot be improved independently, and the Nash equilibrium is reached; The network is represented as a simple undirected graph G(V,E), where V represents the set of all nodes in the network, a node represents a station in the railway network, N=|V| represents the number of nodes in the network; and E represents a connection set.

2. The network game solving method based on the greedy algorithm according to claim 1 is characterized in that: The attack strategy set of the attacker is S A ={X1,X2,...,X m }, X i represents the i-th attack strategy, and the defense strategy set of the defender is S D ={Y1,Y2,...,Y n },Y j Represents the jth defense strategy, for node V i , if attacked but not defended, then node V i The edges connected to it will be removed.

3. The network game solving method based on the greedy algorithm according to claim 1 is characterized in that: The profit matrix is ​​divided into the profit matrix of the attacker and the profit matrix of the defender. A (X,Y) represents the attacker’s profit, U D (X,Y) represents the defender’s gain: Among them, Γ(G) represents the maximum connected piece size of the initial network G, It represents the maximum size of the connected piece of the network after a round of game. The profit matrix of the attacker and the profit matrix of the defender are respectively expressed as: Y1 Y2…Y n Y1 Y2…Y n Among them, U A represents the attacker’s payoff matrix, U D represents the payoff matrix of the defender, Indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The attacker's profit is Indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The defender's profit.

4. The network game solving method based on the greedy algorithm according to claim 3 is characterized in that: The initial attack and defense strategy of step 3 is divided into an initial attacker strategy and an initial defender strategy, which are obtained by randomly selecting a certain proportion r of the attacker and defender strategy sets; the solution of the game problem adopts a linear programming model: max z maxω Among them, max means maximization, z is the profit of the attacker, ω is the profit of the defender, X i represents the i-th attack strategy, Y j represents the jth defense strategy, U A (X i ,Y j ) indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The attacker's profit is U D (X i ,Y j ) indicates that the attacker chooses attack strategy X i , the defender chooses defense strategy Y j The defender's profit is p i Indicates that the attacker chooses the i-th attack strategy X in the mixed strategy i The probability of j Indicates that the defender chooses the jth defense strategy Y in the mixed strategy j The probability of S A represents the attack strategy set of the attacker, S D represents the defense strategy set of the defender, ∑ represents the summation symbol, and solving the linear programming model, we get p=(p1,p2,...,p m ) T , q=(q1,q2,...,q n ) T This is the Nash equilibrium solution of the game.

5. The network game solving method based on the greedy algorithm according to claim 4 is characterized in that: The greedy algorithm is to find a pure strategy D that maximizes the defender's benefits through a greedy strategy. The first step is to set the defender's strategy. The second step is to traverse the nodes and find the best node v to increase the profit under the premise of satisfying the resource constraints. If the defender uses a pure strategy And the attacker uses a mixed strategy P A , then the expected benefit of the defender in this case is Expressed as: Among them, z D,A Used to mark the attacking strategy S A Whether the defended party's strategy S has been successfully deleted D The selected target point set, if V D ∩V A =V D , indicating that the attacker fails, then z D,A =0; otherwise z D,A =1, V D Represents the set of nodes for defense, V A A set of nodes representing attacks; represents the jth pure strategy of the defender, P A represents the attacker’s mixed strategy, It represents the profit of the defender in the game when the attacker chooses the i-th strategy and the defender chooses the j-th strategy; If the node v can satisfy U D2 (D∪{v},y)>U D2 (D,y), then node v is added to strategy D, D∪{v} represents the defense strategy after adding network node v, y represents the mixed strategy of the attacker, U D2 (D,y) represents the defender's gain; otherwise, if U D2 (D∪{v},y)>U D3 (x, y), then v is added to strategy D. Finally, when the number of nodes in strategy D reaches the upper limit of the number of resources of the defender, it stops, that is, |D| = R D , R D Indicates the maximum number of nodes that the defender can defend.

6. The network game solving method based on the greedy algorithm according to claim 5 is characterized in that: The iterative strategy improvement process is to iterate by traversing the nodes, starting from node 1, and the second iteration starts from node 2, increasing gradually until the number of iterations reaches NR D +1, all strategy combinations are traversed and the final strategy optimization result is obtained.

Citation Information

Patent Citations

  • Attack and defense behavior quantitative evaluation method and system based on game theory

    CN110035066A

  • Network game strategy generation method based on node average path constraint

    CN118246545A

Cited By

  • Defense method based on edge computing DDoS attack

    CN120378218A

  • Communication resource allocation method based on master-slave game

    CN120378224A