The firework algorithm begins to iterate, and sequentially uses explosion operators, mutation operators, mapping rules and selection strategies until it reaches the termination condition, that is, meets the accuracy requirements of the problem or reaches the maximum function evaluation times.
Fireworks algorithm includes the following steps:
1) Some random fireworks are generated in a particular solution space, each fireworks represents a solution to the solution space.
2) Calculate the fitness value of each fireworks according to the fitness function, and generate the sparks according to the fitness values. The number of sparks is calculated based on the idea of immunological concentrations in immunology, ie the greater the fitness value, the greater the number of sparks produced by the fireworks.
3) According to the reality of the fireworks properties combined with the actual situation of the search problem, sparks in the radiation space of fireworks. (The magnitude of a fireworks explosion is determined by the fireworks fitness function, the greater the fitness value, the greater the explosion, and vice versa). Each spark represents a solution in the solution space. In order to ensure the diversity of the population, fireworks need to be properly mutated, such as Gaussian mutation.
4) Calculate the optimal solution to the population, determine whether the requirements are met, stop the search if it is satisfied, and continue the iteration if not satisfied. The initial value of the iteration is the best solution obtained for this cycle and the other solutions chosen.