Application of Neural Network to Game Algorithm

Intelligent was very important for command decision model, and it was also the key to improve the quality of simulation training and combat experiment. The decision-making content was more complex in the implementation of tasks and the nature of the problem was different, so the demand for intelligence was high. To solve better the problem, this paper presented a game method and established a game neural network model. The model had been successfully applied in the classification experiment of winning rate between chess game, which had good theoretical significance and application value.


Introduction
Today, simulation training and combat experiments are increasingly demanding on command decision models.Combat experiments need to solve the problem that the experimental credibility is not high and the space to think about is difficult to automatically explore.This poses a demand for the intelligence of the command decision model.In previous literatures [1] [2], a smart command decision model was solved all along.However, this paper will give an effective way to solve this problem by using the superiority of learning of neural network, and carry out the establishment of the game algorithm of neural network.The modern power system in the sending, configuration, use and other aspects of the participants was increasingly diverse, and they had their own independent demands of interests, moreover, it will inevitably lead to conflicts of interest.Therefore, it was necessary to establish a fair and reasonable coordination of interests and mechanisms of conflict resolved, balance and optimizing the interests of all parties [1].The game theory could solve these problems.The game theory is a mathematical theory and method to study the phenomenon of struggling or competitive nature.The game theory considers the predictive behavior and actual behavior of individuals in the game and studies their optimization strategies.
When the energy with volatility and randomness was accessed to the grid in the wind power generation, photovoltaic power generation and others, in order to effectively control the risk to achieve better control effect, the random interference of nature such as wind, light and other uncertain factors could be seen as non-cooperative game side, then the above problems could be solved based on non-cooperative game theory [2].The relationship between microgrid and large power grid had obvious game characteristics.It was of great practical significance to analyze the relationship between competition and cooperation by constructing the game model [3] [4].
Due to the need of confidentiality of communication, military and so on, and the environment for each signal was increasingly complex so that the characteristic information of the target had some ambiguity.However, fuzzy automata [2]- [8] are powerful tools to deal with fuzzy feature information.Based on this basis, this paper focuses on the establishment of target control system of fuzzy automata (FA).The system will be compared with the old method in the simulation.The simulation results show that its correct control rate is as high as 95.18%.This paper will propose a game method, establish the game neural network model, and apply the model to the classification experiment of winning rate between chess.

Game Algorithm
Game was an important application of heuristic search all along.There have been several game systems as early as 1960s.One of the parties in the game tries to maximize the odds of winning goal, while the other tries to make the opposite side deviate from the winning goal.Both sides of the game and the other side are always moving to the most beneficial to their own state, on the other hand, that is, both sides are always moving to the most disadvantageous to each other's state.
Each step in the game is to achieve a Nash equilibrium.That is, the game with n Objects is described as , where { } where i s * indicates the strategy chosen by the ith Object; i s * − represents the vector that consists of strategies of all Objects except for the ith Object; i U represents the benefit obtained by the ith Object; i S represents the strategy space of the ith Object.
In a more complex game, according to a certain time and space costs, the search is extended to a certain layer so far.Because of the leaf node of the explicit sub-graph by this expansion is not the final success or failure state of the game, it cannot give the sure value that is the success or failure in the end.In this case, the values to the leaf nodes are assigned according to some heuristic functions that can show the probability of success or failure.Then, the value of each node in the search graph is pushed forward from bottom to top according to the reverse rule of the ˅/˄ method, including the root node.However, the value of this retreat to the root node does not indicate who will win, but only consider the limited number of steps that are described the number of layers of and/or in the search graph.The heuristic function value that corresponds to the best state in these layers can be achieved.
Each Object wants to win in the game.Therefore, the advantage of one side relative to the other side is directly estimated by some heuristic knowledge.In the chess, the entropy advantage is very important, so a simple heuristic strategy is always to calculate the advantageous difference of entropy between one side ˅ and the other side ˄, and maximizes the difference as far as possible.The more sophisticated some heuristic strategies assign different heuristic function values based on the differences of the entropy.The vast majority of games will have many heuristics information that can be easily used.

Give the heuristic function ( )
h n , and assume the benefit function is , for example, ( ) Then, the depth and width search method is used to find the optimal step according to the Nash equilibrium principle.In order to facilitate the discussion, the nine-grid game here is used to describe the game algorithm of the heuristic function.Example 1.In the nine-grid game, assume one side ˅ is * side and the other side ˄ is the O side.Let ˅ start first.
The whole state in this issue is a total of 9! nodes.Even if the homogeneous chess game is removed, it is still a big number.Obviously, all blind searches here are not working.Therefore, the heuristic search method must be considered.In this case, the heuristic function ( ) The whole row, the whole column or the whole diagonal of the chessboard are called the winning line.Here, the winning line method is defined as follows: 1) If there is no any chessman on a winning line, it is called a 0-order winning line.0-order winning line can be regarded as belonging to the * side, can also be regarded as belonging to the O side, which they have no effect on the valuation.
2) If there is only one chessman of * (O) side on a winning line, it is called the first-order winning line of the * (O) side.
3) If there are two chessmen of * (O) side on a winning line, the winning line is called the second-order winning line of * (O) side.
4) If there are three chessmen of * (O) side on a winning line, the winning line is called the third-order winning line of * (O) side.

Thus, ( )
h n can be defined as: 1) If the node n is a non-final node of the * side, the evaluation function of the * side is as follows: ( ) 2) If the node n is the final node of the * side to win, then ( ) 3) If the node n is the failure final node of the * side, then ( ) 4) If the node n is a draw, then ( ) 0 h n = .The search graphs of the algorithm ˅/˄ on the first and second steps can be obtained by using ( ) h n , as shown in Figure 1 to Figure 2, respectively.The se- lected walking step is optimal and marked with a thick line.
Similarly, the search graph of heuristic algorithm ˅/˄ on the subsequent steps can be obtained.
From the search graphs with ˅/˄ of full two steps of the nine-grid game, both sides of the game are guided by ( ) h n to carry out the search.The outcome is a draw, and then the mistakes of either side will be "self-defeated".The heuristic function is important.If its definition is not appropriate, it may get undesirable results.In this case, the winning line is defined as: If there are only chessmen of * (O) side or empty on a winning line, but no chessmen of O (*) side, the winning line is called the winning line of the * (O) side.In this way, the heuristic function ( ) h n of the * side can be defined as the evaluation func- tion ( ) 1 h n as follows: 1) If the node n is a non-final node, then ( )  2) If the node n is a draw, then ( ) 3) If the node n is the final node of the * side to win, then ( )

of Computer and Communications
The heuristic search graph of ˅/˄ on the first step can be obtained by using ( ) h n , which is the same as that of by using ( ) h n , as shown in Figure 1.The extended depth of the search graph is 2, which is a seemingly reasonable part of the game tree.The optimal step of both sides is marked with bold lines in this However, the defect of ( ) h n has been exposed in the search graph of ˅/˄ on the second step, because it is not accurate to guide the search in the chess game, as shown in Figure 3.
From Figure 3, it can be determined that the optimal step of the * side by the estimate of ( ) h n , as shown in Figure 4(a) and   This heuristic method with search ˅/˄ is to separate completely the process of generating the game tree from the process of calculating, evaluating and determining the optimal step.Only when the game trees with the specified depth all are generated is carried out, then starts to calculate, evaluate and determine the optimal step, this separation leads to lower search efficiency.If the calculation of the evaluation function of the endpoint and the pushing down operation of the inverted value of the intermediate node are completed at the same time as the tree grows, i.e., while the game tree is generated and the evaluation is calculated at the same time, it is possible to reduce the workload of many generation and calculations.This technique is called ˅/˄ pruning technology.

Application of SOFM (Self-Organization Feature Mapping) Network in Classification of Chess Game
Learning the game algorithm by establishing a neural network is an important method in intelligent decision making.By analyzing the chess historical data of both sides of the game, the winning ratio of the two sides of the game is obtained in 100 games in a certain period of time, then the winning ratio can be defined: where ( ) r x denotes the winning ratio of two sides; x denotes any one of both sides; m indicates the times of winning event; n indicates the total number of matches.The results regarding winning ratio between two sides are different, as shown in Table 1.
The data in the table is taken as the input sample P of the network.P is a two-dimensional random vector, and its distribution is shown in Figure 5.
The weight is trained by SOFM network.The distribution of the initial weights of the network is shown in Figure 6.Each point in Figure 6 represents a neuron, since the initial weights of the network are set to 0.5, so these points are coincident in Figure 6 and look like a point, actually 12 points.W(i, 1) and W(i, 2) in Figure 6  It can be seen from Figure 7 to Figure 9, the neurons begin to self-organize after the training of 100 steps is carried out, and each neuron can distinguish

Conclusion
As a classical method to analyze the benefit relationship between the multi- decision main parts, the game theory is widely used in all aspects of macro-decision-making strategy and micro-decision-making system.In this paper, a smart command decision model was solved by using the superiority of learning of neural network, and the establishment of the game algorithm of neural network was also given.In general, the game theory plays an increasingly important role in the application of field of engineering decision-making research from macro to micro, from qualitative to quantitative.With the rise of the concept of Internet with various decision-making, the democracy and fairness of decision-making will be paid more and more attention, and the game method on neural network is a powerful tool to solve the above problems.
the number of first-order winning line of * side − the number of first-order winning line of O side) + 4 × (the number of second-order winning line of * side − the number of second-order winning line of O side) + a + 6 × (the number of third-order winning line of * side − the number of third-order winning line of O side) + b where, If the side takes the chessman, it can occupy the second-order winning line of the O side If the O side takes the chessman, it can occupy the second-order winning line of the If the side takes the chessman, it can occupy the third-order winning line of the O side If the O side takes the chessman, it can occupy the third-order winning line of the

1 hFigure 1 .
Figure 1.Search graph of the nine-grid game on the first-step.

Figure 2 .
Figure 2. Search graph of the nine-grid game on the second-step.

4 )
If the node n is the failure final node of the * side, then ( )1 h n = −∞ .Obviously, if the evaluation function ( ) 1 h n ′ is obtained by using the point of view of the O side to analyze the evaluation of the same chess, then there must be

Figure 4 (
b), because their evaluation is 1.The adverse step for the * side is shown in Figure 4(c) and Figure 4(d), because they are evaluated as 0.

Figure 3 .Figure 4 .
Figure 3. Search graph of the nine-grid game by using the second-step of h 1 (n).
are the coordinate of training weights of the ith neurons, respectively.Then the network is trained by using the training function.Assume the trained network can classify the input vector correctly.The number of training steps of network has great influence on network performance, so the number of steps is set to 100, 300, and 500, and the weight distribution is observed separately.When the number of steps is 100, the distribution of weights is shown in Figure 7 (distribution of weights (the number of training steps: 100)), and the distribution of weights when the number of steps is 300 is shown in Figure 8 (distribution of weights (the number of training steps: 300)), the distribution of weights when the number of steps is 500 is shown in Figure 9 (distribution of weights (the number of training steps: 500)).

Figure 5 .
Figure 5. Distribution of sample data.

Figure 6 .
Figure 6.Distribution of initial weights of network.

Figure 7 .
Figure 7. Distribution of weights when the number of steps is 100.
Figure10.Now, the winning ratio p = [0.5;0.5] for both parties in a certain period of time is input to verify which category it belongs to.The simulation result is Output = 12.This shows that the 12th neuron of the network is stimulated at this time, so p belongs to the fourth category.By comparing the data directly, p is indeed very close to the data in group 4, group 7 and group 10 of samples.

Table 1 .
The winning ratio of both sides of the game.