Charging station dynamic pricing method based on game grey wolf algorithm
By introducing a gray wolf algorithm based on hierarchical game in the dynamic pricing of charging stations, combining neuroplasticity mutation and adaptive local search, the problems of low computing efficiency and easy to fall into local optimality in the existing technology are solved, and a more efficient pricing strategy is achieved.
Patent Information
- Application Number
- CN202411905518.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-23
- Publication Date
- 2025-04-15
AI Technical Summary
The prior art has low computational efficiency in dynamic pricing of charging stations, is prone to falling into local optimal solutions, is difficult to adapt to dynamically changing market environment, and is less efficient in high-dimensional optimization problems.
A gray wolf algorithm (HGGWO) based on hierarchical game is proposed. By introducing variant operations based on neuroplasticity, adaptive local search strategies and hierarchical game mechanisms, the diversity of populations and search efficiency are enhanced and premature maturity convergence is avoided.
The HGGWO algorithm significantly improves the quality of solution speed and resolving in the dynamic pricing problem of charging stations, can find better solutions in a shorter time, and provides efficient pricing strategy support.
Smart Images

Figure BDA0005204287210000041 
Figure BDA0005204287210000042 
Figure BDA0005204287210000043
Abstract
Description
Technical Field
[0001] The patent of this invention involves a dynamic pricing method for charging stations, which has important application prospects in the field of new energy transportation. Background Art
[0002] As global warming and environmental pollution become increasingly serious, governments and the public are calling for the development of clean energy and the reduction of greenhouse gas emissions. In this context, electric vehicles (EVs) are becoming more and more popular as an environmentally friendly and efficient means of transportation. However, the large-scale promotion of electric vehicles still faces many challenges, among which the lack of charging infrastructure is one of the main bottlenecks restricting the development of electric vehicles.
[0003] As a key node connecting electric vehicles and power grids, electric vehicle charging stations (EVCS) play a vital role in promoting the promotion and application of electric vehicles. However, there are currently many problems with electric vehicle charging stations, such as insufficient number and uneven distribution. The insufficient number of charging stations makes it difficult for electric vehicle users to find suitable charging points, affecting travel convenience; and the uneven distribution of charging stations also brings challenges to power grid dispatching, which may cause local power grids to face greater load pressure during peak hours, threatening the stable operation of the power grid.
[0004] In order to alleviate these problems, it is particularly important to rationally plan and build electric vehicle charging infrastructure. By building new charging stations, electric vehicles can be provided with more convenient and reliable charging services, improving the user experience of electric vehicles. However, on the other hand, the construction and operation of electric vehicle charging stations also face challenges such as high construction costs, long investment payback period, and difficult operation and maintenance. How to maximize the economic benefits of charging stations while ensuring the quality of charging services has become an urgent problem to be solved.
[0005] Dynamic pricing strategy is an important means to optimize the operation and management of charging stations and improve economic benefits. By adjusting the charging price in real time according to factors such as market supply and demand and grid load conditions, users can be guided to charge during off-peak hours and reduce the load pressure of the grid during peak hours. At the same time, reasonable dynamic pricing can also improve the utilization rate of charging stations and increase operating income. However, designing an efficient dynamic pricing strategy is not easy and requires comprehensive consideration of many complex factors, such as user charging needs, electricity price changes, and operating costs.
[0006] Traditional optimization algorithms, such as heuristic algorithms, have some limitations when solving the problem of dynamic pricing of charging stations. These algorithms often have slow solution speed, low computational efficiency, and are prone to fall into local optimal solutions, making it difficult to adapt to the dynamically changing market environment. In order to overcome these challenges, researchers began to explore the application of intelligent optimization algorithms in this problem. Among them, the Grey Wolf Optimizer (GWO) algorithm has received widespread attention for its simplicity, high efficiency, and fast convergence speed. However, the standard GWO algorithm still has shortcomings such as premature convergence and easy to fall into local optimal solutions when dealing with complex optimization problems.
[0007] In view of the above problems, the present invention proposes a hierarchical game-based Grey Wolf Optimizer (HGGWO). The algorithm enhances the diversity of the population by introducing a mutation operation based on neural plasticity, effectively avoiding the algorithm from converging to the local optimal solution too early. In addition, HGGWO also integrates an adaptive local search strategy to conduct detailed exploration of potential areas during the search process, thereby improving the search efficiency and the quality of the solution. At the same time, the algorithm also simulates the competition and cooperation between wolves of different levels through a hierarchical game mechanism, promotes the sharing and dissemination of information, and further enhances the global search capability. Finally, HGGWO improves the algorithm's solution speed as much as possible by eliminating individuals with poor performance according to the number of iterations.
[0008] The HGGWO algorithm proposed in this paper shows excellent performance in solving the dynamic pricing problem of charging stations. Compared with traditional heuristic algorithms, HGGWO can find a better solution in a shorter time, providing strong decision-making support for charging station operators to formulate efficient pricing strategies. The research results of this algorithm have important theoretical significance and practical value for promoting the optimized operation of electric vehicle charging infrastructure and promoting the sustainable development of the electric vehicle industry. Summary of the invention
[0009] The existing dynamic pricing methods for charging stations based on traditional heuristic algorithms have the problem of low computational efficiency. Specifically, when the scale or complexity of the problem to be solved increases, the computational efficiency of the traditional heuristic algorithm decreases significantly, making it difficult to meet the needs of real-time or near real-time pricing; and when the solution space is complex or the objective function has multiple local optimal points, the traditional heuristic algorithm is prone to fall into the local optimal solution and cannot quickly obtain the approximate optimal solution, which affects the effectiveness and economic benefits of the charging station pricing strategy. In addition, the real-time pricing problem of charging stations has high-dimensional characteristics and requires the simultaneous optimization of prices in multiple time periods. Since the search space grows exponentially with the dimension, the traditional heuristic algorithm is less efficient in dealing with such high-dimensional optimization problems, and it is easy to have the problem of dimensional search imbalance during the search process, that is, there is an over-concentration or insufficient search in the dimension of certain time periods, which leads to a large deviation between the obtained pricing scheme and the optimal value in a specific time period.
[0010] In order to solve the above problems, the present invention designs a charging station dynamic pricing method based on the game gray wolf algorithm. The present invention mainly includes seven parts: (1) Modeling the problem of dynamic pricing of charging stations. (2) Modeling the Markov decision process. (3) Introducing a double-layer population reduction strategy. (4) Introducing an adaptive local search strategy. (5) Integrating a neural plasticity mutation strategy. (6) Integrating a competition and cooperation mechanism based on hierarchical game. (7) Experimental verification of the effectiveness of the algorithm.
[0011] The following are the contents of the above seven parts:
[0012] 1. Model the problem of dynamic pricing of charging stations. Define the problem according to the actual situation, and define the decision variables and objective function of dynamic pricing of charging stations.
[0013] 2. Markov decision process modeling. In the dynamic pricing problem of charging stations, the arrival of vehicles at the charging station in each time period and the charging station's execution of pricing actions can be regarded as a decision sequence. In the present invention, such a pricing process is modeled as a Markov decision process.
[0014] 3. In order to improve the convergence speed and resource utilization efficiency of the gray wolf optimization algorithm, we have integrated a double-layer population reduction strategy into the algorithm. This strategy comprehensively considers the global progress and local accuracy requirements of the optimization process, and gradually reduces the population size through two-level nonlinear reduction methods to achieve a dynamic balance between exploration and utilization.
[0015] 4. In order to balance the exploration and development capabilities of the algorithm and improve the convergence speed and optimization accuracy of the algorithm, we introduced an improved adaptive local search strategy into the algorithm. This strategy comprehensively considers the relationship between the current iteration stage, the individual fitness value and the optimal fitness value of the population, adaptively adjusts the scope and intensity of the local search, and dynamically balances the exploration and development of the algorithm at different stages and in different areas.
[0016] 5. The present invention also introduces a mutation strategy based on the neural plasticity mechanism. This strategy comprehensively considers the individual fitness information, population diversity and the dynamic characteristics of the optimization process, adaptively guides individuals to directional mutation, and maintains the diversity of the population while improving the convergence speed.
[0017] 6. The present invention also incorporates a competitive cooperation mechanism based on hierarchical game to further improve the optimization performance of the gray wolf optimization algorithm. This mechanism divides the population into different levels according to individual fitness, and designs corresponding interaction rules within and between levels to achieve a dynamic balance between exploration and utilization.
[0018] 7. Experimental verification of the effectiveness of the model. Experiments have shown that the present invention has higher quality solutions in similar computing time compared to existing heuristic algorithms, and has higher solution quality and shorter computing time compared to most traditional heuristic methods.
[0019] The detailed implementation steps taken by the present invention to achieve the above-mentioned purpose are as follows:
[0020] Step 1: In order to solve the problem of dynamic pricing of charging stations, the present invention establishes a complete mathematical model, which is mainly used to simulate the charging behavior of electric vehicles (EVs) and the use of charging stations within a day. The model comprehensively considers multiple factors, including the remaining battery power, the time required for charging, the user's sensitivity to prices, and individual behavior differences. In the present invention, it is assumed that the charging station cannot know in advance the arrival of electric vehicles and charging needs in the future time period, including information such as the specific arrival time and charging time. Therefore, the charging demand faced by the charging station is random and uncertain.
[0021] The core goal of this problem is to determine a reasonable electricity price that users are willing to accept and maximize the overall revenue of the charging station operator. On this basis, the present invention takes the total revenue of the charging station as the optimization goal, and the objective function is specifically expressed as:
[0022]
[0023] Where R represents the total revenue of the charging station, p T-1 represents the charging station price at time T-1, ct i represents the charging time of the i-th vehicle.
[0024] To more accurately describe the operation of the charging station, a day is divided into 24 consecutive time periods, and the charging demand of electric vehicles is randomly simulated in each time period. The number of electric vehicles arriving is assumed to follow a Poisson distribution, and the set of all vehicles arriving in this time period is defined as V T In addition, the present invention adopts bs i ,ct i and em i They respectively indicate the vehicle's battery status, charging duration, and charging urgency.
[0025] The battery status is calculated by the ratio of the vehicle's remaining power to the battery capacity bc i To measure, the charging time ct i It is calculated by the following formula:
[0026]
[0027] Where P represents the charging power of the charging station.
[0028] The urgency of the vehicle i Determined by the current battery status, the calculation formula is:
[0029]
[0030] Assume that when users make charging decisions, they are more sensitive to the current charging price, so the decision result is significantly affected by the current electricity price. In the user's decision model, there are three key parameters: w q , w p and α i , w q Among them, w q represents the weight of the waiting queue length of the charging station on the user's decision when making a decision, w p represents the impact weight of the current charging price. In addition, parameter α i It is used to describe the price sensitivity of different users and follows a normal distribution with a mean of 1 and a standard deviation of 0.3.
[0031] Parameter w q and w p The calculation formula is as follows:
[0032] w q =0.5+β×em i
[0033] w q +w p =1
[0034] Where β is a parameter for adjusting the urgency weight.
[0035] Ultimately, the user's decision is based on the comprehensive score of the above parameters. When the comprehensive score reaches the decision threshold ν, the user will choose to charge. If the charging pile is idle, the vehicle will start charging directly; otherwise, the user will wait in line in the waiting area. The user's decision rule can be expressed as:
[0036]
[0037] where r q represents the current occupancy rate of the waiting area of the charging station, p max Indicates the highest charging price that the user can accept.
[0038] Charging stations are available on a first-come, first-served basis for waiting areas and assembly areas. T The vehicles in the station are charged, and the charging fee is collected after charging is completed and included in the total revenue of the charging station.
[0039] Step 2: Construct a Markov decision process model. In the dynamic pricing problem of charging stations, the number of vehicles arriving at the charging station in each time period and the pricing actions performed by the charging station can be regarded as a decision sequence. Therefore, the present invention adopts the Markov decision process (MDP) for modeling. MDP consists of four tuples:<S,A,R,η> where S represents the state space, A is the action of the agent, R is the reward function, and η is the noise used for exploration.
[0040] The state space S represents the set of states of the system. At each time step T, the state information s T ∈S includes the current charging price, the occupancy rate of the charging pile, the occupancy rate of the waiting area, and the current time and other environmental information. At time T, the state set can be recorded as in represents the occupancy rate of the waiting area at time step T, represents the usage rate of the charging pile at time step T. In this environment, the agent (Agent) T , select an action a T , for example, adjusting the charging price p T This decision will affect the future state of the system and trigger the evolution of the state. The state transition function of the system can be expressed as s T+1 =F(s T ,a T ), s T+1 is the system state of the next time step, and F is the state transition function. The specific state transition is defined as follows:
[0041]
[0042] in is the number of charging piles in use, is the number of EVs in the waiting area.
[0043] s T+1 The information in is updated as follows:
[0044]
[0045] Where N c is the total number of charging piles, N q The total number of parking spaces in the waiting area.
[0046] The action set A represents the agent in state s T In the present invention, the action a of the agent T ∈[-0.5, 0.5] represents the adjustment strategy of the electricity price at the current time step. A positive value indicates an increase in price, and a negative value indicates a decrease in price. When the agent interacts with the environment, it first initializes the system environment and converts it into available state features. The agent will receive the state feedback s at each time step. T As input, it is passed into the policy network for decision making, thereby generating the corresponding electricity price adjustment action a T The specific input can be expressed as The core goal of the agent is to use a behavior strategy μ θ , so that it can be in different states s T Choose the best action a T , in order to maximize the cumulative discounted return. Finally, the optimal strategy μ θ * The goal can be expressed as:
[0047]
[0048] Where γ is the attenuation factor used to measure the importance of future returns, and 0≤γ<1, R T is the reward at T time steps.
[0049] The reward function R represents the immediate return obtained by the agent in the process of interacting with the environment. In the present invention, the revenue of the vehicle that completes charging in each time step will be used as the reward for that step. When designing the reward, taking into account the particularity of the charging station, there is a certain time delay from the start to the completion of the charging service, so the "delayed reward" mechanism is introduced. This means that the environment will regard the revenue generated by the electric vehicle that arrives at the charging station in the T-1 time step and completes charging in the T time step as the reward R of the T time step. T .
[0050] This reward mechanism is more in line with the operating characteristics of actual charging stations, and helps the agent better learn strategies to maximize long-term benefits, rather than just immediate economic benefits. In addition, this design also improves the applicability of the model to actual scenarios, making it more in line with the phenomenon of delayed benefits in real environments. T The calculation formula is as follows:
[0051]
[0052] Step 3: In order to improve the convergence speed and resource utilization efficiency of the gray wolf optimization algorithm, a double-layer population reduction strategy is integrated into the algorithm. This strategy comprehensively considers the global process and local accuracy requirements of the optimization process, and gradually reduces the population size through two-level nonlinear reduction methods to achieve a dynamic balance between exploration and utilization.
[0053] The first level of reduction is based on the global optimization process, according to the current number of iterations t relative to the maximum number of iterations T max The proportion of the population size N is nonlinearly reduced:
[0054]
[0055] Where N min is the minimum population size, N max is the initial population size. As can be seen from the above formula, with the increase of the number of iterations t, the population size N1 shows a nonlinear reduction trend. In the early stage of optimization, the population size decreases slowly to maintain population diversity and promote global exploration; in the later stage of optimization, the population size decreases rapidly to accelerate algorithm convergence and promote local utilization. Compared with the linear reduction method, this strategy can better adapt to the dynamic characteristics of the optimization process.
[0056] The second layer is reduced based on the local convergence accuracy, according to the average fitness of the current population Relative to the global optimal fitness f * The proportion of the first layer after the reduction of the population size N1 is further adjusted:
[0057]
[0058] Where ∈ is a small positive number to avoid the denominator being zero. When the average fitness of the current population Close to the global optimal fitness f * When , the population size N2 is further reduced to reduce computational redundancy; on the contrary, when the average fitness of the current population Far lower than the global optimal fitness f *When , the population size N2 remains unchanged to maintain population diversity. By introducing the second layer of reduction, the algorithm can adaptively adjust the population size according to the actual convergence situation, thereby improving the utilization efficiency of computing resources.
[0059] The two-layer reduction strategy combines the considerations of global optimization process and local convergence accuracy, and realizes adaptive adjustment of population size through nonlinear reduction at two levels. At different stages of optimization, this strategy can dynamically balance the needs of exploration and utilization according to actual conditions, effectively improving the convergence speed and resource utilization efficiency of the algorithm. However, despite the continuous reduction of population size, due to N min The existence of , the algorithm always maintains a certain population size, preventing the algorithm from losing its exploration ability in the later stage. In addition, by combining with the adaptive local search strategy, neural plasticity mutation strategy and hierarchical game mechanism proposed later in this invention, the double-layer reduction strategy can better play its advantages and further improve the overall performance of the gray wolf optimization algorithm.
[0060] Step 4: In order to further balance the algorithm's exploration and development capabilities and improve the algorithm's convergence speed and optimization accuracy, we introduced an improved adaptive local search strategy into the algorithm. This strategy comprehensively considers the relationship between the current iteration stage, individual fitness value and the optimal fitness value of the population, adaptively adjusts the scope and intensity of local search, and dynamically balances the algorithm's exploration and development at different stages and in different areas.
[0061] For each individual x in the population i (i=1,2,…,N), its local search process is:
[0062]
[0063] in represents the new position obtained after local search, η is the search step, and u is the search direction vector, whose components are randomly generated between [-1,1]. In order to ensure the rationality of the search direction, u is standardized, that is, divided by its binorm:
[0064]
[0065] In order to adaptively adjust the scope of local search at different stages of optimization, the calculation formula of the search step length η is designed as follows:
[0066]
[0067] where t and T max Respectively represent the current number of iterations and the maximum number of iterations, f(x i ) and f(x α ) represent the individual x iThe fitness value and the optimal individual x of the population α The fitness value of .
[0068] The search step length η is related to the current number of iterations t and the individual fitness value f(x i ). Specifically, as the number of iterations t increases, the term will gradually decrease, resulting in a gradual decrease in the search step η. This means that in the later stages of optimization, the algorithm will pay more attention to local development and perform fine searches in the allowed areas. In addition, for individuals with higher fitness values, the step size of their local searches is relatively small. This helps to conduct in-depth searches near high-quality solutions and improve the convergence accuracy of the algorithm; for individuals with lower fitness values, the step size of their local searches is relatively large. This helps individuals to jump out of the local optimum and explore other areas of the solution space.
[0069] By adaptively adjusting the search step size, the algorithm can achieve a dynamic balance between exploration and development at different stages and in different areas of optimization, thereby improving the optimization capability and convergence speed. In addition, the calculation of the search step size only depends on the number of iterations and the fitness value, without the need to introduce additional control parameters, making the strategy easy to implement and apply.
[0070] The new position obtained after the local search The boundary of the search space may be exceeded. In order to ensure the feasibility of the solution, the new position needs to be bounded:
[0071]
[0072] Where lb and ub represent the lower and upper bounds of the search space, respectively. Through this boundary constraint processing, the components beyond the boundary can be truncated to the boundary, ensuring that the individual always searches within the feasible solution space.
[0073] In order to avoid premature convergence of the algorithm, the present invention adopts a probabilistic trigger mechanism to decide whether to perform local search on individuals. Specifically, in each iteration, half of the individuals are randomly selected for local search:
[0074]
[0075] rand() represents a random number between [0,1]. If the number is less than υ, then i Perform local search, otherwise remain unchanged. By introducing a probabilistic trigger mechanism, the original position information can be retained to a certain extent, increasing the diversity of the population while reducing computational overhead. The introduction of this randomness helps the algorithm to balance between exploration and development, improving the algorithm's robustness and global optimization capabilities.
[0076] Step 5: The mutation strategy based on the neural plasticity mechanism integrated by the present invention comprehensively considers the individual fitness information, population diversity and the dynamic characteristics of the optimization process, and adaptively guides the individual to perform directional mutation, thereby maintaining the diversity of the population while improving the convergence speed.
[0077] (1) Mutation operation
[0078] For each individual x in the population i , and its variation process is:
[0079]
[0080] in represents the new position after mutation, ω is the neural plasticity weight vector, m i is a mutation vector consisting of exploration terms and utilization terms:
[0081] m i =α·r1+(1-α)·(x α -x i )
[0082] Where α∈[0,1] is the weight coefficient for balancing exploration and utilization, is a standard normal distribution random vector, representing the exploration term; x α -x i It represents the utilization term, that is, the deviation of the individual towards the current optimal solution. By adjusting the size of α, the exploration and utilization tendency of the algorithm can be flexibly controlled.
[0083] (2) Adaptive weight adjustment
[0084] In order to enable the mutation operation to adaptively respond to the individual fitness state and the dynamic characteristics of the optimization process, the present invention introduces an adaptive weight adjustment strategy based on the neural plasticity mechanism. The calculation formula of the neural plasticity weight ω is:
[0085]
[0086] That is the plasticity modulation factor of the jth dimension, s j ∈[0,1] is the success rate of the jth dimension.
[0087] Plasticity modulators It reflects the relative relationship between individual fitness and the optimal fitness of the population. The calculation formula is:
[0088]
[0089] For individuals with lower fitness values, their plasticity modulation factor is larger, which means its neuroplasticity weight ωj This helps to enhance the exploration ability of individuals and escape from the local optimum. On the contrary, for individuals with higher fitness values, their plasticity modulation factor Smaller, representing its neuroplasticity weight ω j This helps to reduce the variation of individuals and conduct a fine search within the allowed area.
[0090] Success rate j It reflects the individual's historical variation experience in the jth dimension, and its calculation formula is:
[0091]
[0092] Where η∈(0,1) is the learning rate, is the indicative function, when Relative to x i,j If there is improvement, it takes 1, otherwise it takes 0. Success rate s j An adaptive update mechanism is used. If historical mutations often lead to improvements in the jth dimension, then s j This feedback mechanism helps individuals dynamically adjust mutation strategies based on their own experience and speed up the convergence of the algorithm.
[0093] The neuroplasticity weight ω is adaptive and dynamic. On the one hand, it can adaptively adjust the variation amplitude according to the individual's fitness state and balance between exploration and utilization. On the other hand, it can dynamically adjust the variation strategy according to the individual's historical experience and accelerate the convergence of the algorithm.
[0094] The new position after mutation It may exceed the boundary of the search space, so it needs to be bounded in the same way as in step 4.
[0095] Step 6: This paper proposes a competitive cooperation mechanism based on hierarchical game to further improve the optimization performance of the gray wolf optimization algorithm. This mechanism divides the population into different levels according to individual fitness, and designs corresponding interaction rules within and between levels to achieve a dynamic balance between exploration and utilization.
[0096] (1) Layered mechanism
[0097] First, the algorithm is based on the individual fitness f(x i ) divides the population into three levels: elite layer P e , middle layer P m and exploration layer P lAmong them, the elite layer contains individuals with the highest fitness, which are mainly responsible for leading the population to converge to the global optimal solution; the middle layer contains individuals with medium fitness, which are mainly responsible for searching in the allowed area of the solution space; the exploration layer contains individuals with the lowest fitness, which are mainly responsible for exploring in the unknown area of the solution space.
[0098] The setting of stratification thresholds λ1 and λ2 needs to comprehensively consider the diversity and convergence speed of the population. This study adopts the following adaptive stratification thresholds:
[0099]
[0100] λ2=arg(f)
[0101] Where μ and avg(f) represent the average values of the population fitness, std(f) represents the standard deviation of the population fitness, σ is the diversity control parameter, and ∈ is a very small positive number used to avoid the denominator being zero. The stratification thresholds λ1 and λ2 can be adaptively adjusted according to the diversity of the population. When the population diversity is large, the threshold λ1 increases accordingly, which expands the size of the elite layer and speeds up the convergence of the population. Conversely, when the population diversity is small, the threshold λ1 decreases accordingly, which reduces the size of the elite layer and maintains the diversity of the population.
[0102] (2) Intra-tier competition
[0103] In each layer, individuals adopt competitive strategies and improve their search capabilities through mutual learning. e For individuals in the , an elite learning strategy with adaptive weights is adopted:
[0104] x i =(1-ω i )·x i +ω i ·x α
[0105] where ω i is the learning rate. Individuals with higher fitness have a larger learning rate and are more likely to move towards the optimal solution x α Learning; individuals with lower fitness have a smaller learning rate and retain more of their own position information. In addition, the learning process in the above formula can be regarded as a gradual position update, which helps to perform fine search in the local area.
[0106] For the middle layer P m Individuals in the group adopt a learning strategy that balances exploration and utilization:
[0107] x i =(1-r)·G(x i )+r·B(x i )
[0108] Where r∈[0,1] is the weight coefficient for balancing exploration and utilization, G(·) represents the Gaussian mutation operation, which is used to expand the search range, and B(·) represents learning from randomly selected elite individuals, which is used to improve search accuracy. By adjusting the size of r, the exploration and utilization tendencies of middle-level individuals can be flexibly controlled.
[0109] For the exploration layer P l Individuals in the range use the Lévy flight mutation strategy:
[0110] x i =x i +α·LF(λ)
[0111] Among them, α is the step size control parameter, and λ is the parameter of Lévy distribution. Lévy flight is a random walk with long tail characteristics, which can generate a wide range of search steps and help individuals jump out of local optimality. At the same time, in order to further maintain the diversity of the population, the exploration layer individuals also introduce a reinitialization strategy:
[0112] x i =lb+r·(ub-lb)
[0113] Among them, r~U(0,1) are uniformly distributed random numbers. By reinitializing, the exploration layer individuals can be randomly generated in the solution space, injecting new diversity into the population.
[0114] (3) Inter-layer cooperation
[0115] Between different levels, individuals adopt cooperative strategies and guide the population to converge to the global optimal solution through information sharing.
[0116] The upper-level individuals influence the lower-level individuals through demonstration, and the lower-level individuals learn from the upper-level individuals with a certain probability:
[0117] x i =(1-r)·x i +r·x j
[0118] where x j is a randomly selected upper-layer individual, and r~U(0,1) is a uniformly distributed random number. Through inter-layer learning, the lower-layer individuals can learn from the excellent experience of the upper-layer individuals and accelerate the convergence of the population.
[0119] In addition, the lower-level individuals influence the upper-level individuals through a feedback mechanism. When the fitness of the lower-level individuals is better than that of the corresponding upper-level individuals, the position information of the two is exchanged:
[0120]
[0121] By exchanging positions, upper-level individuals can obtain valuable information explored by lower-level individuals in a timely manner, thus avoiding premature convergence of the population.
[0122] The competitive cooperation mechanism based on hierarchical game achieves a dynamic balance between exploration and utilization through intra-layer competition and inter-layer cooperation. On the one hand, the intra-layer competition strategy adopts different interaction rules according to the individual's level, which improves the individual's search ability. On the other hand, the inter-layer cooperation strategy effectively shares information within the population through upper-layer demonstration and lower-layer feedback, which accelerates the convergence of the population. Compared with the traditional GWO algorithm, this mechanism can better adapt to the needs of different optimization stages, thereby significantly improving the algorithm's optimization performance.
[0123] The present invention proposes a charging station dynamic pricing method based on the game grey wolf algorithm. The method establishes a charging station dynamic pricing model and a Markov decision process model, introduces a double-layer decreasing population reduction strategy, an adaptive local search strategy, and a neural plasticity mutation strategy, and integrates a competition and cooperation mechanism based on hierarchical game, thereby effectively solving the problems existing in the existing methods. The present invention has been experimentally verified to prove the superior performance of the proposed method. Compared with traditional methods, the present invention can significantly improve the pricing efficiency and profitability of charging stations, which is of great significance to the intelligent operation of electric vehicle charging stations. BRIEF DESCRIPTION OF THE DRAWINGS
[0124] Figure 1 This is a schematic diagram of the dynamic pricing problem of charging stations in the present invention.
[0125] Figure 2 This is a schematic diagram of the HGGWO framework in the present invention.
[0126] Figure 3 It is the characteristic distribution diagram of different scale data sets constructed in the present invention
[0127] Figure 4 This is the population size hyperparameter verification experiment result diagram in the present invention
[0128] Figure 5 This is the result of the experiment to verify the number of iterations hyperparameters in the present invention.
[0129] Figure 6 This is the verification diagram of the ablation experiment results in the present invention DETAILED DESCRIPTION
[0130] The present invention is further described below in conjunction with the accompanying drawings and embodiments.
[0131] Aiming at the problem of dynamic pricing of charging stations, the present invention establishes a deep reinforcement learning simulation environment with Markov, and designs a dynamic pricing method for charging stations that integrates sample augmentation and a dual-value deep deterministic policy gradient algorithm.
[0132] Step 1: In order to solve the problem of dynamic pricing of charging stations, the present invention establishes a complete mathematical model, which is mainly used to simulate the charging behavior of electric vehicles (EVs) and the use of charging stations within a day. The model comprehensively considers multiple factors, including the remaining battery power, the time required for charging, the user's sensitivity to prices, and individual behavior differences. In the present invention, it is assumed that the charging station cannot know in advance the arrival of electric vehicles and charging needs in the future time period, including information such as the specific arrival time and charging time. Therefore, the charging demand faced by the charging station is random and uncertain.
[0133] The core goal of this problem is to determine a reasonable electricity price that users are willing to accept and maximize the overall revenue of the charging station operator. On this basis, the present invention takes the total revenue of the charging station as the optimization goal, and the objective function is specifically expressed as:
[0134]
[0135] Where R represents the total revenue of the charging station, p T-1 represents the charging station price at time T-1, ct i represents the charging time of the i-th vehicle.
[0136] To more accurately describe the operation of the charging station, a day is divided into 24 consecutive time periods, and the charging demand of electric vehicles is randomly simulated in each time period. The number of electric vehicles arriving is assumed to follow a Poisson distribution, and the set of all vehicles arriving in this time period is defined as V T In addition, the present invention adopts bs i ,ct i and em i They respectively indicate the vehicle's battery status, charging duration, and charging urgency.
[0137] The battery status is calculated by the ratio of the vehicle's remaining power to the battery capacity bc i To measure, the charging time ct i It is calculated by the following formula:
[0138]
[0139] Where P represents the charging power of the charging station.
[0140] The urgency of the vehicle i Determined by the current battery status, the calculation formula is:
[0141]
[0142] Assume that when users make charging decisions, they are more sensitive to the current charging price, so the decision result is significantly affected by the current electricity price. In the user's decision model, there are three key parameters: w q , w p and α i , w q Among them, w q represents the weight of the waiting queue length of the charging station on the user's decision when making a decision, w p represents the impact weight of the current charging price. In addition, parameter α i It is used to describe the price sensitivity of different users and follows a normal distribution with a mean of 1 and a standard deviation of 0.3.
[0143] Parameter w q and w p The calculation formula is as follows:
[0144] w q =0.5+β×em i
[0145] w q +w p =1
[0146] Where β is a parameter for adjusting the urgency weight.
[0147] Ultimately, the user's decision is based on the comprehensive score of the above parameters. When the comprehensive score reaches the decision threshold ν, the user will choose to charge. If the charging pile is idle, the vehicle will start charging directly; otherwise, the user will wait in line in the waiting area. The user's decision rule can be expressed as:
[0148]
[0149] where r q represents the current occupancy rate of the waiting area of the charging station, p max Indicates the highest charging price that the user can accept.
[0150] Charging stations are available on a first-come, first-served basis for waiting areas and assembly areas. T The vehicles in the station are charged, and the charging fee is collected after charging is completed and included in the total revenue of the charging station.
[0151] Step 2: Construct a Markov decision process model. In the dynamic pricing problem of charging stations, the number of vehicles arriving at the charging station in each time period and the pricing actions performed by the charging station can be regarded as a decision sequence. Therefore, the present invention adopts the Markov decision process (MDP) for modeling. MDP consists of four tuples:<S,A,R,η> where S represents the state space, A is the action of the agent, R is the reward function, and η is the noise used for exploration.
[0152] The state space S represents the set of states of the system. At each time step T, the state information s T ∈S includes the current charging price, the occupancy rate of the charging pile, the occupancy rate of the waiting area, and the current time and other environmental information. At time T, the state set can be recorded as in represents the occupancy rate of the waiting area at time step T, represents the usage rate of the charging pile at time step T. In this environment, the agent (Agent) T , select an action a T , for example, adjusting the charging price p T This decision will affect the future state of the system and trigger the evolution of the state. The state transition function of the system can be expressed as s T+1 =F(s T ,a T ), s T+1 is the system state of the next time step, and F is the state transition function. The specific state transition is defined as follows:
[0153]
[0154] in is the number of charging piles in use, is the number of EVs in the waiting area.
[0155] s T+1 The information in is updated as follows:
[0156]
[0157] Where N c is the total number of charging piles, N q The total number of parking spaces in the waiting area.
[0158] The action set A represents the agent in state s T In the present invention, the action a of the agent T ∈[-0.5, 0.5] represents the adjustment strategy of the electricity price at the current time step. A positive value indicates an increase in price, and a negative value indicates a decrease in price. When the agent interacts with the environment, it first initializes the system environment and converts it into available state features. The agent will receive the state feedback s at each time step. T As input, it is passed into the policy network for decision making, thereby generating the corresponding electricity price adjustment action a T The specific input can be expressed as The core goal of the agent is to use a behavior strategy μ θ , so that it can be in different states s TChoose the best action a T , in order to maximize the cumulative discounted return. Finally, the optimal strategy μ θ * The goal can be expressed as:
[0159]
[0160] Where γ is the attenuation factor used to measure the importance of future returns, and 0≤γ<1, R T is the reward at T time steps.
[0161] The reward function R represents the immediate return obtained by the agent in the process of interacting with the environment. In the present invention, the revenue of the vehicle that completes charging in each time step will be used as the reward for that step. When designing the reward, taking into account the particularity of the charging station, there is a certain time delay from the start to the completion of the charging service, so the "delayed reward" mechanism is introduced. This means that the environment will regard the revenue generated by the electric vehicle that arrives at the charging station in the T-1 time step and completes charging in the T time step as the reward R of the T time step. T .
[0162] This reward mechanism is more in line with the operating characteristics of actual charging stations, and helps the agent better learn strategies to maximize long-term benefits, rather than just immediate economic benefits. In addition, this design also improves the applicability of the model to actual scenarios, making it more in line with the phenomenon of delayed benefits in real environments. T The calculation formula is as follows:
[0163]
[0164] Step 3: The overall process of the algorithm proposed by the present invention is shown in the attached figure of the specification Figure 2 As shown in the figure, the algorithm will first initialize the population and update the positions of α wolf, β wolf and δ wolf, and then execute the population reduction strategy at the beginning of each iteration. This strategy comprehensively considers the global progress and local accuracy requirements of the optimization process, and gradually reduces the population size through nonlinear reduction methods at two levels, achieving a dynamic balance between exploration and utilization.
[0165] The first level of reduction is based on the global optimization process, according to the current number of iterations t relative to the maximum number of iterations T max The proportion of the population size N is nonlinearly reduced:
[0166]
[0167] Where N min is the minimum population size, N maxis the initial population size. As the number of iterations t increases, the population size N1 shows a nonlinear reduction trend. In the early stage of optimization, the population size decreases slowly to maintain population diversity and promote global exploration; in the later stage of optimization, the population size decreases rapidly to accelerate algorithm convergence and promote local utilization. Compared with the linear reduction method, this strategy can better adapt to the dynamic characteristics of the optimization process.
[0168] The second layer is reduced based on the local convergence accuracy, according to the average fitness of the current population Relative to the global optimal fitness f * The proportion of the first layer after the reduction of the population size N1 is further adjusted:
[0169]
[0170] When the average fitness of the current population Close to the global optimal fitness f * When , the population size N2 is further reduced to reduce computational redundancy; on the contrary, when the average fitness of the current population Far lower than the global optimal fitness f * When , the population size N2 remains unchanged to maintain population diversity. By introducing the second layer of reduction, the algorithm can adaptively adjust the population size according to the actual convergence situation, thereby improving the utilization efficiency of computing resources.
[0171] The two-layer reduction strategy combines the considerations of global optimization process and local convergence accuracy, and realizes adaptive adjustment of population size through nonlinear reduction at two levels. At different stages of optimization, this strategy can dynamically balance the needs of exploration and utilization according to actual conditions, effectively improving the convergence speed and resource utilization efficiency of the algorithm. However, despite the continuous reduction of population size, due to N min The existence of , the algorithm always maintains a certain population size, preventing the algorithm from losing its exploration ability in the later stage. In addition, by combining with the adaptive local search strategy, neural plasticity mutation strategy and hierarchical game mechanism proposed later, the double-layer reduction strategy can better play its advantages and further improve the overall performance of the gray wolf optimization algorithm.
[0172] Step 4: After executing population reduction, the algorithm performs adaptive local search to further balance the algorithm's exploration and development capabilities and improve the algorithm's convergence speed and optimization accuracy. This strategy comprehensively considers the relationship between the current iteration stage, individual fitness value and the optimal fitness value of the population, adaptively adjusts the scope and intensity of local search, and dynamically balances the algorithm's exploration and development at different stages and in different areas.
[0173] For each individual x in the population i(i=1,2,…,N), its local search process can be expressed as:
[0174]
[0175] where x i LS represents the new position obtained after local search, η is the search step, and u is the search direction vector, whose components are randomly generated between [-1,1]. In order to ensure the rationality of the search direction, u is standardized, that is, divided by its binorm:
[0176]
[0177] In order to adaptively adjust the scope of local search at different stages of optimization, the calculation formula of the search step length η is designed as follows:
[0178]
[0179] where t and T max Respectively represent the current number of iterations and the maximum number of iterations, f(x i ) and f(x α ) represent the individual x i The fitness value and the optimal individual x of the population α The fitness value of .
[0180] The search step length η is related to the current number of iterations t and the individual fitness value f(x i ). Specifically, as the number of iterations t increases, the term will gradually decrease, resulting in a gradual decrease in the search step η. This means that in the later stages of optimization, the algorithm will pay more attention to local development and perform fine searches in the allowed areas. In addition, for individuals with higher fitness values, the step size of their local searches is relatively small. This helps to conduct in-depth searches near high-quality solutions and improve the convergence accuracy of the algorithm; for individuals with lower fitness values, the step size of their local searches is relatively large. This helps individuals to jump out of the local optimum and explore other areas of the solution space.
[0181] By adaptively adjusting the search step size, the algorithm can achieve a dynamic balance between exploration and development at different stages and in different areas of optimization, thereby improving the optimization capability and convergence speed. In addition, the calculation of the search step size only depends on the number of iterations and the fitness value, without the need to introduce additional control parameters, making the strategy easy to implement and apply.
[0182] The new position obtained after the local search The boundary of the search space may be exceeded. In order to ensure the feasibility of the solution, the new position needs to be bounded:
[0183]
[0184] Where lb and ub represent the lower and upper bounds of the search space, respectively. Through this boundary constraint processing, the components beyond the boundary can be truncated to the boundary, ensuring that the individual always searches within the feasible solution space.
[0185] In order to further maintain the diversity of the population and avoid premature convergence of the algorithm, this paper adopts a probabilistic trigger mechanism to decide whether to perform local search on individuals. Specifically, in each iteration, we randomly select half of the individuals for local search:
[0186]
[0187] rand() represents a random number between [0,1]. If the number is less than υ, then i Perform local search, otherwise remain unchanged. By introducing a probabilistic trigger mechanism, the original position information can be retained to a certain extent, increasing the diversity of the population while reducing computational overhead. The introduction of this randomness helps the algorithm to balance between exploration and development, improving the algorithm's robustness and global optimization capabilities.
[0188] Step 5: After completing the adaptive local search, the algorithm executes the following mutation strategy. This strategy comprehensively considers the individual fitness information, population diversity, and the dynamic characteristics of the optimization process, and adaptively guides the individual to directional mutation, thereby maintaining the diversity of the population while improving the convergence speed. The specific process is as follows.
[0189] (1) Mutation operation
[0190] For each individual x in the population i , and its variation process can be expressed as:
[0191]
[0192] in represents the new position after mutation, ω is the neural plasticity weight vector, m i is a mutation vector consisting of exploration terms and utilization terms:
[0193] m i =α·r1+(1-α)·(x α -x i )
[0194] Where α∈[0,1] is the weight coefficient for balancing exploration and utilization, is a standard normal distribution random vector, representing the exploration term; x α -x i It represents the utilization term, that is, the deviation of the individual towards the current optimal solution. By adjusting the size of α, the exploration and utilization tendency of the algorithm can be flexibly controlled.
[0195] (2) Adaptive weight adjustment
[0196] In order to make the mutation operation adaptively respond to the individual fitness state and the dynamic characteristics of the optimization process, this paper introduces an adaptive weight adjustment strategy based on the neural plasticity mechanism. Specifically, the calculation formula of the neural plasticity weight ω is:
[0197]
[0198] in is the plasticity modulation factor of the jth dimension, s j ∈[0,1] is the success rate of the jth dimension.
[0199] Plasticity modulators It reflects the relative relationship between individual fitness and the optimal fitness of the population. The calculation formula is:
[0200]
[0201] For individuals with lower fitness values, their plasticity modulation factor is larger, which means its neuroplasticity weight ω j This helps to enhance the exploration ability of individuals and escape from the local optimum. On the contrary, for individuals with higher fitness values, their plasticity modulation factor Smaller, representing its neuroplasticity weight ω j This helps to reduce the variation of individuals and conduct a fine search within the allowed area.
[0202] Success rate j It reflects the individual's historical variation experience in the jth dimension, and its calculation formula is:
[0203]
[0204] Where η∈(0,1) is the learning rate, is the indicative function, when Relative to x i,j If there is improvement, it takes 1, otherwise it takes 0. Success rate s j An adaptive update mechanism is used. If historical mutations often lead to improvements in the jth dimension, then s j This feedback mechanism helps individuals dynamically adjust mutation strategies based on their own experience and speed up the convergence of the algorithm.
[0205] From the above formula, we can see that the neuroplasticity weight ω is adaptive and dynamic. On the one hand, it can adaptively adjust the variation range according to the individual's fitness state and balance between exploration and utilization. On the other hand, it can dynamically adjust the variation strategy according to the individual's historical experience and accelerate the convergence of the algorithm.
[0206] The new position after mutation It may exceed the boundary of the search space, so it needs to be bounded in the same way as in step 4.
[0207] Step 6: Finally, the algorithm will solve the problem according to the competition and cooperation mechanism of the hierarchical game to improve the optimization performance of the gray wolf optimization algorithm. This mechanism divides the population into different levels according to individual fitness, and designs corresponding interaction rules within and between levels to achieve a dynamic balance between exploration and utilization.
[0208] (1) Layered mechanism
[0209] First, the algorithm is based on the individual fitness f(x i ) divides the population into three levels: elite layer P e , middle layer P m and exploration layer P l Among them, the elite layer contains individuals with the highest fitness, which are mainly responsible for leading the population to converge to the global optimal solution; the middle layer contains individuals with medium fitness, which are mainly responsible for searching in the allowed area of the solution space; the exploration layer contains individuals with the lowest fitness, which are mainly responsible for exploring in the unknown area of the solution space.
[0210] The setting of stratification thresholds λ1 and λ2 needs to comprehensively consider the diversity and convergence speed of the population. This study adopts the following adaptive stratification thresholds:
[0211]
[0212] λ2=arg(f)
[0213] Among them, μ and avg(f) represent the average value of population fitness, std(f) represents the standard deviation of population fitness, σ is the diversity control parameter, and ∈ is a very small positive number used to avoid the denominator being zero. The stratification thresholds λ1 and λ2 can be adaptively adjusted according to the diversity of the population. When the population diversity is large, the threshold λ1 increases accordingly, expanding the size of the elite layer and accelerating the convergence of the population. Conversely, when the population diversity is small, the threshold λ1 decreases accordingly, reducing the size of the elite layer and maintaining the diversity of the population.
[0214] (2) Intra-tier competition
[0215] In each layer, individuals adopt competitive strategies and improve their search capabilities through mutual learning. e For individuals in the , an elite learning strategy with adaptive weights is adopted:
[0216] x i =(1-ω i )·x i +ω i ·x α
[0217] where ω i is the learning rate. Individuals with higher fitness have a larger learning rate and are more likely to move towards the optimal solution x α Learning; individuals with lower fitness have a smaller learning rate and retain more of their own position information. In addition, the learning process in the above formula can be regarded as a gradual position update, which helps to perform fine search in the local area.
[0218] For the middle layer P m Individuals in the group adopt a learning strategy that balances exploration and utilization:
[0219] x i =(1-r)·G(x i )+r·B(x i )
[0220] Among them, r∈[0,1] is the weight coefficient for balancing exploration and utilization, G(·) represents the Gaussian mutation operation, which is used to expand the search range, and B(·) represents learning from randomly selected elite individuals, which is used to improve the search accuracy. By adjusting the size of r, the exploration and utilization tendencies of middle-level individuals can be flexibly controlled.
[0221] For the exploration layer P l Individuals in the range use the Lévy flight mutation strategy:
[0222] x i =x i +α·LF(λ)
[0223] Among them, α is the step size control parameter, and λ is the parameter of Lévy distribution. Lévy flight is a random walk with long tail characteristics, which can generate a wide range of search steps and help individuals jump out of local optimality. At the same time, in order to further maintain the diversity of the population, the exploration layer individuals also introduce a reinitialization strategy:
[0224] x i =lb+r·(ub-lb)
[0225] Among them, r~U(0,1) are uniformly distributed random numbers. By reinitializing, the exploration layer individuals can be randomly generated in the solution space, injecting new diversity into the population.
[0226] (3) Inter-layer cooperation
[0227] Between different levels, individuals adopt cooperative strategies and guide the population to converge to the global optimal solution through information sharing.
[0228] The upper-level individuals (elite and middle-level) influence the lower-level individuals through demonstration. Specifically, the lower-level individuals learn from the upper-level individuals with a certain probability:
[0229] x i =(1-r)·x i +r·x j
[0230] where x j is a randomly selected upper-layer individual, and r~U(0,1) is a uniformly distributed random number. Through inter-layer learning, the lower-layer individuals can learn from the excellent experience of the upper-layer individuals and accelerate the convergence of the population.
[0231] In addition, the lower-level individuals (middle and exploration layers) influence the upper-level individuals through a feedback mechanism. Specifically, when the fitness of the lower-level individuals is better than that of the corresponding upper-level individuals, the position information of the two is exchanged:
[0232]
[0233] By exchanging positions, upper-level individuals can obtain valuable information explored by lower-level individuals in a timely manner, thus avoiding premature convergence of the population.
[0234] The competitive cooperation mechanism based on layered game achieves a dynamic balance between exploration and utilization through intra-layer competition and inter-layer cooperation. On the one hand, the intra-layer competition strategy adopts different interaction rules according to the individual's level, which improves the individual's search ability. On the other hand, the inter-layer cooperation strategy effectively shares information within the population through upper-layer demonstration and lower-layer feedback, which accelerates the convergence speed of the population. Compared with the traditional GWO algorithm, this mechanism can better adapt to the needs of different optimization stages, thereby significantly improving the algorithm's optimization performance.
[0235] Step 7: In the present invention, after completing all the above operations, the algorithm will update the positions of all populations, thus completing one iteration. In the verification, the SA, GA, GWO, and PSO algorithms are used as baseline algorithms to verify the performance of HGGWO on data sets of different sizes, and representative heuristic algorithm verification examples and analysis are given. Through hyperparameter experiments (as shown in the attached figure of the specification), Figure 4 , Figure 5) and ablation experiments (see Figure 1 Figure 6 ) verified the effectiveness of the proposed method. The final results show that the HGGWO model is superior to traditional heuristic algorithms in terms of solution time and solution quality.
Claims
1. A charging station dynamic pricing method based on the game grey wolf algorithm, characterized in that The steps include: Definition: The present invention provides a charging station dynamic pricing method based on the game gray wolf algorithm, which includes the following steps: establishing a charging station dynamic pricing model and a Markov decision process model; introducing a double-layer decreasing population reduction strategy to select the best individual and the worst individual from the current population, and removing the worst individual from the population according to a certain ratio; introducing an adaptive local search strategy to perturb the individuals trapped in the local optimum during the gray wolf algorithm search process to jump out of the local optimum; introducing a neural plasticity mutation strategy to simulate the synaptic plasticity mechanism of biological bodies and adaptively mutate the gray wolf individuals; integrating a competition and cooperation mechanism based on hierarchical game, constructing an interest game model between charging stations and electric vehicles, and guiding the gray wolf algorithm search process; using the proposed improved gray wolf algorithm to solve the charging station dynamic pricing problem and obtain an optimized charging station pricing strategy; Step 1: In order to solve the problem of dynamic pricing of charging stations, the present invention establishes a complete mathematical model, which is mainly used to simulate the charging behavior of electric vehicles (EVs) and the use of charging stations within a day; the model comprehensively considers multiple factors, including the remaining battery power, the charging time required, the user's sensitivity to prices, and individual behavior differences; in the present invention, it is assumed that the charging station cannot know in advance the arrival of electric vehicles in the future time period and the charging demand, including the specific arrival time and charging time; therefore, the charging demand faced by the charging station is random and uncertain; The core goal of this problem is to determine a reasonable electricity price that users are willing to accept and maximize the overall revenue of the charging station operator. On this basis, the present invention takes the total revenue of the charging station as the optimization goal, and the objective function is specifically expressed as: Where R represents the total revenue of the charging station, p T-1 represents the charging station price at time T-1, ct i represents the charging time of the i-th vehicle; In order to more accurately describe the operation of the charging station, a day is divided into 24 consecutive time periods, and the charging demand of electric vehicles is randomly simulated in each time period; the number of electric vehicles arriving is assumed to follow a Poisson distribution, and the set of all vehicles arriving in this time period is defined as V T In addition, the present invention adopts bs i ,ct i and em i Respectively indicate the vehicle's battery status, charging duration, and charging urgency; The battery status is calculated by the ratio of the vehicle's remaining power to the battery capacity bc i To measure, the charging time ct i It is calculated by the following formula: Where P represents the charging power of the charging station; The urgency of the vehicle i Determined by the current battery status, the calculation formula is: Assume that when making charging decisions, users are more sensitive to the current charging price, so the decision result is significantly affected by the current electricity price; in the user's decision model, there are three key parameters: w q , w p and α i , w q ; Among them, w q represents the weight of the waiting queue length of the charging station on the user's decision when making a decision, w p represents the impact weight of the current charging price; in addition, parameter α i It is used to describe the price sensitivity of different users and follows a normal distribution with a mean of 1 and a standard deviation of 0.
3. Parameter w q and w p The calculation formula is as follows: In q =0.5+β×em i In q +in p =1 Where β is the parameter for adjusting the urgency weight; Ultimately, the user's decision is based on the comprehensive score of the above parameters; when the comprehensive score reaches the decision threshold ν, the user will choose to charge; if the charging pile is idle, the vehicle will start charging directly; otherwise, the user will queue in the waiting area; the user's decision rule can be expressed as: where r q represents the current occupancy rate of the waiting area of the charging station, p max Indicates the highest charging price that the user can accept; Charging stations are available on a first-come, first-served basis for waiting areas and assembly areas. T The vehicles in the charging station are charged, and the charging fee is charged after the charging is completed and included in the total revenue of the charging station; Step 2: Construct a Markov decision process model; in the problem of dynamic charging station pricing, the vehicles arriving at the charging station in each time period and the pricing actions performed by the charging station can be regarded as a decision sequence; therefore, the present invention adopts a Markov decision process (MDP) for modeling; the MDP consists of a four-tuple<S,A,R,η> Composition, where: S represents the state space, A is the action of the agent, R is the reward function, and η is the noise used for exploration; The state space S represents the set of states of the system; at each time step T, the state information s T ∈S includes the current charging price, the occupancy rate of the charging pile, the occupancy rate of the waiting area, and the current time and other environmental information; at time T, the state set can be recorded as in represents the occupancy rate of the waiting area at time step T, represents the utilization rate of the charging pile at time step T; in this environment, the agent (Agent) T , select an action a T , for example, adjusting the charging price p T ; This decision will affect the future state of the system and trigger the evolution of the state; the state transition function of the system can be expressed as s T+1 =F(s T ,a T ), s T+1 is the system state of the next time step, and F is the state transfer function; the specific state transfer is defined as follows: in is the number of charging piles in use, is the number of EVs in the waiting area; s T+1 The information in is updated as follows: Where N c is the total number of charging piles, N q is the total number of parking spaces in the waiting area; The action set A represents the agent in state s T In the present invention, the action a of the agent T ∈[-0.5, 0.5] represents the adjustment strategy of the electricity price at the current time step. A positive value indicates a price increase, and a negative value indicates a price decrease. When the agent interacts with the environment, it first initializes the system environment and converts it into available state features. The agent will receive the state feedback s at each time step. T As input, it is passed into the policy network for decision making, thereby generating the corresponding electricity price adjustment action a T ; The specific input can be expressed as The core goal of the agent is to use a behavior strategy μ θ , so that it can be in different states s T Choose the best action a T , to maximize the cumulative discounted return; ultimately, the optimal strategy μ θ * The goal can be expressed as: Where γ is the attenuation factor used to measure the importance of future returns, and 0≤γ<1, R T is the reward for T time steps; The reward function R represents the immediate return obtained by the agent in the process of interacting with the environment. In the present invention, the revenue of the vehicle that completes charging in each time step will be used as the reward of that step. When designing the reward, considering the particularity of the charging station, there is a certain time delay from the start to the completion of the charging service, so the "delayed reward" mechanism is introduced; this means that the environment will regard the revenue generated by the electric vehicle that arrives at the charging station in the T-1 time step and completes charging in the T time step as the reward R of the T time step. T ; This reward mechanism is more in line with the operating characteristics of actual charging stations, and helps the agent to better learn the strategy of maximizing long-term benefits, rather than just being limited to immediate economic benefits. In addition, this design also improves the applicability of the model to actual scenarios, making it more in line with the phenomenon of delayed benefits in real environments. The reward R T The calculation formula is as follows: Step 3: In order to improve the convergence speed and resource utilization efficiency of the gray wolf optimization algorithm, a double-layer population reduction strategy is integrated into the algorithm; this strategy comprehensively considers the global process and local accuracy requirements of the optimization process, and gradually reduces the population size through two-level nonlinear reduction methods to achieve a dynamic balance between exploration and utilization; The first level of reduction is based on the global optimization process, according to the current number of iterations t relative to the maximum number of iterations T max The proportion of the population size N is nonlinearly reduced: Where N min is the minimum population size, N max is the initial population size; from the above formula, it can be seen that with the increase of the number of iterations t, the population size N1 shows a nonlinear reduction trend; in the early stage of optimization, the population size decreases slowly to maintain population diversity and promote global exploration; in the later stage of optimization, the population size decreases rapidly to accelerate the convergence of the algorithm and promote local utilization; compared with the linear reduction method, this strategy can better adapt to the dynamic characteristics of the optimization process; The second layer is reduced based on the local convergence accuracy, according to the average fitness of the current population Relative to the global optimal fitness f * The proportion of the first layer after the reduction of the population size N1 is further adjusted: Where ∈ is a small positive number to avoid the denominator being zero; when the average fitness of the current population Close to the global optimal fitness f * When , the population size N2 is further reduced to reduce computational redundancy; on the contrary, when the average fitness of the current population Far lower than the global optimal fitness f * When , the population size N2 remains unchanged to maintain population diversity; by introducing the second layer of reduction, the algorithm can adaptively adjust the population size according to the actual convergence situation, thereby improving the utilization efficiency of computing resources; The double-layer reduction strategy combines the considerations of global optimization process and local convergence accuracy. Through nonlinear reduction at two levels, the adaptive adjustment of population size is achieved. At different stages of optimization, the strategy can dynamically balance the needs of exploration and utilization according to the actual situation, effectively improving the convergence speed and resource utilization efficiency of the algorithm. However, despite the continuous reduction of population size, due to N min The existence of , the algorithm always maintains a certain population size, preventing the algorithm from losing its exploration ability in the later stage; in addition, by combining with the adaptive local search strategy, neural plasticity mutation strategy and hierarchical game mechanism proposed later in the present invention, the double-layer reduction strategy can better play its advantages and further improve the overall performance of the gray wolf optimization algorithm; Step 4: In order to further balance the exploration and development capabilities of the algorithm and improve the convergence speed and optimization accuracy of the algorithm, we introduced an improved adaptive local search strategy into the algorithm; this strategy comprehensively considers the relationship between the current iteration stage, the individual fitness value and the optimal fitness value of the population, adaptively adjusts the scope and intensity of the local search, and dynamically balances the exploration and development of the algorithm at different stages and in different areas; For each individual x in the population i (i=1,2,…,N), its local search process is: in represents the new position obtained after local search, η is the search step, u is the search direction vector, and its components are randomly generated between [-1,1]. In order to ensure the rationality of the search direction, u is standardized, that is, divided by its two norm: In order to adaptively adjust the scope of local search at different stages of optimization, the calculation formula of the search step length η is designed as follows: where t and T max Respectively represent the current number of iterations and the maximum number of iterations, f(x i ) and f(x α ) represent the individual x i The fitness value and the optimal individual x of the population α The fitness value of The search step length η is related to the current number of iterations t and the individual fitness value f(x i ) is related to the problem of the optimization process. Specifically, as the number of iterations t increases, the term will gradually decrease, resulting in a gradual decrease in the search step η. This means that in the later stages of optimization, the algorithm will pay more attention to local development and conduct fine searches in the allowed areas. In addition, for individuals with higher fitness values, the step length of their local searches is relatively small. This helps to conduct in-depth searches near high-quality solutions and improve the convergence accuracy of the algorithm. For individuals with lower fitness values, the step length of their local searches is relatively large. This helps individuals to jump out of the local optimum and explore other areas of the solution space. By adaptively adjusting the search step length, the algorithm can achieve a dynamic balance between exploration and development in different stages and regions of optimization, thereby improving the optimization ability and convergence speed. In addition, the calculation of the search step length only depends on the number of iterations and the fitness value, without the need to introduce additional control parameters, making the strategy easy to implement and apply. The new position obtained after the local search The boundary of the search space may be exceeded; to ensure the feasibility of the solution, the new position needs to be bounded: Where lb and ub represent the lower and upper bounds of the search space, respectively. Through this boundary constraint processing, the components beyond the boundary can be truncated to the boundary, ensuring that the individual always searches within the feasible solution space. In order to avoid premature convergence of the algorithm, the present invention adopts a probabilistic trigger mechanism to decide whether to perform local search on individuals; specifically, in each iteration, half of the individuals are randomly selected for local search: Where rand() means to randomly generate a number between [0,1]; if the number is less than υ, then for individual x i Perform local search, otherwise remain unchanged; by introducing a probabilistic trigger mechanism, the original position information can be retained to a certain extent, increasing the diversity of the population while reducing computational overhead; the introduction of this randomness helps the algorithm to balance between exploration and development, improving the algorithm's robustness and global optimization capabilities; Step 5: The mutation strategy based on the neural plasticity mechanism integrated in the present invention comprehensively considers the individual fitness information, population diversity and the dynamic characteristics of the optimization process, adaptively guides the individual to perform directional mutation, and maintains the diversity of the population while improving the convergence speed; (1) Mutation operation For each individual x in the population i , and its variation process is: in represents the new position after mutation, ω is the neural plasticity weight vector, m i is a mutation vector consisting of exploration terms and utilization terms: m i =α·r1+(1-α)·(x α -x i ) Where α∈[0,1] is the weight coefficient for balancing exploration and utilization, is a standard normal distribution random vector, representing the exploration term; x α -x i It represents the utilization term, that is, the individual's deviation towards the current optimal solution. By adjusting the size of α, the algorithm's exploration and utilization tendencies can be flexibly controlled. (2) Adaptive weight adjustment In order to enable the mutation operation to adaptively respond to the individual fitness state and the dynamic characteristics of the optimization process, the present invention introduces an adaptive weight adjustment strategy based on the neural plasticity mechanism; the calculation formula of the neural plasticity weight ω is: That is the plasticity modulation factor of the jth dimension, s j ∈[0,1] is the success rate of the jth dimension; Plasticity modulators It reflects the relative relationship between individual fitness and the optimal fitness of the population. The calculation formula is: For individuals with lower fitness values, their plasticity modulation factor is larger, which means its neuroplasticity weight ω j is also larger; this helps to enhance the exploration ability of individuals and escape from the local optimum; on the contrary, for individuals with higher fitness values, their plasticity modulation factor Smaller, representing its neuroplasticity weight ω j This helps to reduce the variation of individuals and conduct fine searches within the allowed area. Success rate j It reflects the individual's historical variation experience in the jth dimension, and its calculation formula is: Where η∈(0,1) is the learning rate, is the indicative function, when Relative to x i,j If there is improvement, it takes 1, otherwise it takes 0; success rate s j An adaptive update mechanism is used; if historical mutations often lead to improvements in the jth dimension, then s j will continue to increase, otherwise it will gradually decrease; this feedback mechanism helps individuals dynamically adjust mutation strategies based on their own experience and speed up the convergence of the algorithm; The neural plasticity weight ω is adaptive and dynamic. On the one hand, it can adaptively adjust the variation range according to the individual's fitness state and balance exploration and utilization. On the other hand, it can dynamically adjust the variation strategy according to the individual's historical experience and accelerate the convergence of the algorithm. The new position after mutation It may exceed the boundary of the search space, so it needs to be bounded in the same way as in step 4; Step 6: This paper proposes a competition and cooperation mechanism based on hierarchical game to further improve the optimization performance of the gray wolf optimization algorithm; this mechanism divides the population into different levels according to individual fitness, and designs corresponding interaction rules within and between levels to achieve a dynamic balance between exploration and utilization; (1) Layered mechanism First, the algorithm is based on the individual fitness f(x i ) divides the population into three levels: elite layer P e , middle layer P m and exploration layer P l ; Among them, the elite layer contains individuals with the highest fitness, which are mainly responsible for leading the population to converge to the global optimal solution; the middle layer contains individuals with medium fitness, which are mainly responsible for searching in the allowed area of the solution space; the exploration layer contains individuals with the lowest fitness, which are mainly responsible for exploring in the unknown area of the solution space; The setting of stratification thresholds λ1 and λ2 needs to comprehensively consider the diversity and convergence speed of the population; this study adopts the following adaptive stratification thresholds: λ2=arg(f) Where μ and avg(f) represent the average values of population fitness, std(f) represents the standard deviation of population fitness, σ is the diversity control parameter, ∈ is a very small positive number to avoid the denominator being zero; the stratification thresholds λ1 and λ2 can be adaptively adjusted according to the diversity of the population; when the population diversity is large, the threshold λ1 increases accordingly, expanding the size of the elite layer and accelerating the convergence of the population; conversely, when the population diversity is small, the threshold λ1 decreases accordingly, reducing the size of the elite layer and maintaining the diversity of the population; (2) Intra-tier competition In each layer, individuals adopt competitive strategies and improve their search capabilities through mutual learning. e For individuals in the , an elite learning strategy with adaptive weights is adopted: x i =(1-ω i )·x i +oh i ·x α where ω i is the learning rate; individuals with higher fitness have a larger learning rate and are more likely to move towards the optimal solution x α Learning; individuals with lower fitness have smaller learning rates and retain more of their own position information; in addition, the learning process in the above formula can be regarded as a gradual position update, which is helpful for fine search in local areas; For the middle layer P m Individuals in the group adopt a learning strategy that balances exploration and utilization: x i =(1-r)·G(x i )+r·B(x i ) Where r∈[0,1] is the weight coefficient for balanced exploration and utilization, G(·) represents Gaussian mutation operation, which is used to expand the search range, and B(·) represents learning from randomly selected elite individuals, which is used to improve search accuracy. By adjusting the size of r, the exploration and utilization tendencies of middle-level individuals can be flexibly controlled. For the exploration layer P l Individuals in the range use the Lévy flight mutation strategy: x i =x i +α·LF(λ) Among them, α is the step size control parameter, and λ is the parameter of Lévy distribution. Lévy flight is a random walk with long tail characteristics, which can generate a wide range of search steps and help individuals jump out of local optimality. At the same time, in order to further maintain the diversity of the population, the exploration layer individuals also introduce a reinitialization strategy: x i =lb+r·(ub-lb) Among them, r~U(0,1) are uniformly distributed random numbers; by reinitialization, the exploration layer individuals can be randomly generated in the solution space, injecting new diversity into the population; (3) Inter-layer cooperation Between different levels, individuals adopt cooperative strategies to guide the population to converge to the global optimal solution through information sharing; The upper-level individuals influence the lower-level individuals through demonstration, and the lower-level individuals learn from the upper-level individuals with a certain probability: x i =(1-r)·x i +r·x j where x j is a randomly selected upper-layer individual, and r~U(0,1) is a uniformly distributed random number. Through inter-layer learning, the lower-layer individuals can learn from the excellent experience of the upper-layer individuals and accelerate the convergence speed of the population. In addition, the lower-level individuals influence the upper-level individuals through a feedback mechanism; when the fitness of the lower-level individuals is better than that of the corresponding upper-level individuals, the position information of the two is exchanged: By exchanging positions, individuals in the upper layer can obtain valuable information explored by individuals in the lower layer in a timely manner, thus avoiding premature convergence of the population; The competitive cooperation mechanism based on hierarchical game achieves a dynamic balance between exploration and utilization through intra-layer competition and inter-layer cooperation. On the one hand, the intra-layer competition strategy adopts different interaction rules according to the individual's level, which improves the individual's search ability. On the other hand, the inter-layer cooperation strategy effectively shares information within the population through upper-layer demonstration and lower-layer feedback, which accelerates the convergence speed of the population. Compared with the traditional GWO algorithm, this mechanism can better adapt to the needs of different optimization stages, thereby significantly improving the algorithm's optimization performance. The present invention proposes a charging station dynamic pricing method of a grey wolf algorithm integrating a game strategy; the method establishes a dynamic pricing model for charging stations and a Markov decision process model, introduces a double-layer decreasing population reduction strategy, an adaptive local search strategy and a neural plasticity mutation strategy, and integrates a competition and cooperation mechanism based on hierarchical game, thereby effectively solving the problems existing in the existing methods; the present invention has been experimentally verified to prove the superior performance of the proposed method; compared with traditional methods, the present invention can significantly improve the pricing efficiency and profitability of charging stations, which is of great significance to the intelligent operation of electric vehicle charging stations.
Citation Information
Cited By
Marketing prediction intelligent analysis method and system based on machine learning
CN120198167A
Logistics quotation management method and system
CN120725567A
Game optimization solving method for multi-user power control problem in wireless network
CN121146061A
Dynamic pricing and scheduling method for electric vehicle charging station
CN121526676A
A dynamic pricing and scheduling method for electric vehicle charging stations
CN121526676B