A method and system for intelligent monitoring and optimal scheduling of energy consumption of photovoltaic storage and charging equipment
By analyzing historical charging records and deep reinforcement learning models to optimize the charging plan, the problem of insufficient utilization of energy storage resources and high energy consumption in the optical storage and charging system is solved, and more efficient energy management and battery health protection are achieved.
Patent Information
- Application Number
- CN202410910484.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-09
- Publication Date
- 2024-10-22
- Estimated Expiration
- 2044-07-09
AI Technical Summary
The existing optical storage and charging system lacks fine control in the management of energy storage devices, resulting in insufficient utilization of energy storage resources, high system energy consumption, and failure to effectively match charging demand and photovoltaic power generation, affecting system efficiency and battery health, and increasing maintenance costs. and environmental burden.
By collecting and analyzing historical charging records, we calculate the user's average charging cycle, set the charging power level, and combine it with the deep reinforcement learning model to generate a charging plan, dynamically adjust the charging power to match the photovoltaic power generation forecast, optimize system energy consumption, and avoid overcharging. Take risks.
It improves the energy utilization efficiency of the system, reduces charging costs, extends the service life of the energy storage device, and enhances the economic and environmental performance of the system.
Smart Images

Figure CN118472940B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of integrated photovoltaic storage and charging systems, and in particular to a method and system for intelligent monitoring and optimal scheduling of energy consumption of photovoltaic storage and charging equipment. Background Art
[0002] In recent years, with the improvement of environmental awareness and the promotion of policies, electric vehicles have ushered in unprecedented growth worldwide. To support this trend, the integrated photovoltaic storage and charging system, as an intelligent solution integrating photovoltaic power generation, energy storage and electric vehicle charging, has gradually become a hot spot for research and application. Such systems usually include photovoltaic panels, energy storage devices (such as battery energy storage systems) and electric vehicle charging piles, aiming to achieve energy self-sufficiency and optimized scheduling, reduce dependence on the power grid, and improve energy efficiency.
[0003] Although the integrated photovoltaic storage and charging system has shown great potential, it still faces many challenges and shortcomings in practical applications. The volatility of natural light intensity leads to unstable photovoltaic power generation, while the demand for electric vehicle charging is often concentrated in specific time periods, resulting in a mismatch in supply and demand time, affecting the overall efficiency of the system. At present, many photovoltaic storage and charging systems lack fine control in the management of energy storage devices, and fail to fully utilize energy storage resources to balance the grid load and photovoltaic output, resulting in a shortened charging and discharging cycle life of energy storage devices and increased maintenance costs. The existing scheduling strategy is too simple, only considering the immediate balance of energy supply and demand, ignoring long-term energy management optimization, such as the failure to effectively use historical data to predict user charging behavior, resulting in unreasonable charging power allocation and high system energy consumption. When formulating the charging strategy, the economic and environmental impact assessment of the entire system operation is not comprehensive enough, especially the impact of overcharging and over-discharging of energy storage devices on battery health, as well as the resulting long-term maintenance costs and environmental burdens are not fully considered.
[0004] For example, the Chinese patent with the authorization announcement number CN111900727B discloses a PSO-based coordinated optimization scheduling method and device for an integrated photovoltaic, storage and charging station. The method includes the following steps: obtaining the measurement point information of each photovoltaic power generation module, energy storage module and electric vehicle charging module in the integrated photovoltaic, storage and charging station; establishing a coordinated scheduling strategy model based on the acquired information, and the coordinated scheduling strategy model includes the objective function and constraints for minimizing the operating cost of the integrated photovoltaic, storage and charging station; solving the coordinated scheduling strategy model through a particle swarm algorithm; and formulating the grid power input and energy storage output plan of the integrated photovoltaic, storage and charging station based on the optimal solution obtained. This invention reduces the impact of the integrated charging station on the stability of the power grid system and also ensures the safe and stable operation of the integrated charging station.
[0005] For example, the patent application with publication number CN116470478A discloses a real-time charging scheduling method for a photovoltaic storage and charging smart microgrid, including: obtaining various historical data of the photovoltaic storage and charging smart microgrid, including topology, operating cost data, power status data, load status data and meteorological data; establishing a photovoltaic power prediction model and a load demand prediction model corresponding to the photovoltaic storage and charging smart microgrid based on historical data; establishing a charging scheduling optimization model corresponding to the photovoltaic storage and charging smart microgrid considering battery loss and primary frequency regulation backup service based on historical data; establishing a charging scheduling real-time control framework using a mobile time window based on the photovoltaic power prediction model, the load demand prediction model and the charging scheduling optimization model; and cyclically operating the charging scheduling real-time control framework to generate a real-time charging scheduling plan for the photovoltaic storage and charging smart microgrid in a rolling manner. This invention improves the prediction accuracy, accurately evaluates and optimizes the operating cost, and effectively reduces the system comprehensive operating cost of the microgrid.
[0006] The above patents all have the problems raised by this background technology: they ignore long-term energy management optimization, fail to effectively use historical data to predict user charging behavior, have high system energy consumption, and do not fully consider the impact of overcharging and over-discharging of energy storage devices on battery health, as well as the resulting long-term maintenance costs and environmental burdens.
[0007] The information disclosed in this background technology section is only intended to enhance the understanding of the overall background of the invention and should not be regarded as an acknowledgement or any form of suggestion that the information constitutes the prior art already known to ordinary technicians in this field. Summary of the invention
[0008] The technical problem to be solved by the present invention is to overcome the defects of the prior art, provide a method and system for intelligent monitoring and optimal scheduling of energy consumption of photovoltaic storage and charging equipment, efficiently integrate and utilize photovoltaic resources, overcome the problem of mismatch between charging demand and renewable energy supply in the prior art, and enhance the economy and environmental performance of the photovoltaic storage and charging system.
[0009] In order to solve the above technical problems, the present invention provides the following technical solutions:
[0010] On the one hand, the present invention provides a method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device, comprising the following steps:
[0011] S1: Collect and analyze historical charging records and calculate the user's average charging cycle;
[0012] S2: Setting a charging power level for the user based on the average charging cycle;
[0013] S3: Collect light intensity data, make photovoltaic power generation predictions, and generate photovoltaic power generation prediction sequences;
[0014] S4: Based on the charging power level and the photovoltaic power generation prediction sequence, a charging plan is generated through a deep reinforcement learning model;
[0015] S5: Execute and update the charging plan until charging is completed.
[0016] As a preferred solution of the method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device described in the present invention, the method for calculating the average charging cycle of a user is as follows:
[0017] The historical charging records are counted, and the charging cycle of each historical charging record is obtained by subtracting the time point when the electric vehicle is connected to the charging pile from the time point when the electric vehicle is disconnected from the charging pile in each historical charging record; and the average of the charging cycles of all historical charging records is calculated as the average charging cycle of the user.
[0018] As a preferred solution of the method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device described in the present invention, the method for setting the charging power level for the user is as follows:
[0019] Let the rated charging power of the user's electric vehicle be , the average charging cycle is ; The amount of electricity required to charge an electric vehicle from empty to full is ; Calculate the minimum charging power , the formula is as follows:
[0020] ;
[0021] Assume that there are m charging power levels, where the power value of level i charging power is recorded as , i ranges from 1, 2, ..., m, where m is a positive integer; The fixed length is evenly divided into m-1 sub-intervals, and the power value corresponding to the right endpoint of the i-th sub-interval is recorded as ; The power value calculation formula for any level of charging power is as follows:
[0022] .
[0023] As a preferred solution of the method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device described in the present invention, the specific method for generating a photovoltaic power generation prediction sequence is as follows:
[0024] Collect historical light intensity data and historical power generation data, and perform data cleaning;
[0025] Arrange the historical light intensity data into a historical light intensity sequence in chronological order, and arrange the historical power generation data into a historical power generation sequence in chronological order;
[0026] Extracting a daily light intensity sequence from the historical light intensity sequence, and evenly dividing the daily light intensity sequence into n time slices, where n is a positive integer; calculating the mean of the light intensity data in each time slice, and arranging the mean of the n light intensity data of each day into a daily light intensity subsequence in chronological order;
[0027] Extracting a daily power generation sequence from the historical power generation sequence, and evenly dividing the daily power generation sequence into n time slices; calculating the mean of the power generation data in each time slice, and arranging the mean of the n power generation data of each day into a daily power generation quantum sequence in chronological order;
[0028] Training a light intensity prediction model for light intensity prediction, and outputting a light intensity subsequence for the next day as a light intensity prediction sequence; the light intensity prediction model is a time series prediction model, and the input is a light intensity subsequence for each day;
[0029] A photovoltaic power generation prediction model is trained to predict power generation and output a power generation quantum sequence for the next day as a photovoltaic power generation prediction sequence; the photovoltaic power generation prediction model is any one of a time convolutional network model, a recurrent neural network, and a support vector regression model, and the input is the light intensity prediction sequence.
[0030] As a preferred solution of the method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device described in the present invention, the charging scheme is the charging power level in any time slice, the proportion of power generation directly supplied to electric vehicles in power generation, the proportion of power generation stored in the energy storage device in power generation, and the power supply of the energy storage device to the electric vehicle; let the proportion of power generation directly supplied to the electric vehicle in the jth time slice in the photovoltaic power generation be , the value range of j is 1, 2, ..., n; then the proportion of power generation used for energy storage in the jth time slice to the total power generation is 1- , the calculation formula of the power supply from the energy storage device to the electric vehicle is as follows:
[0031] ;
[0032] in, represents the power supplied by the energy storage device to the electric vehicle in the jth time slice; represents the charging power level in the jth time slice; represents the power generation in the jth time slice;
[0033] The state space of the deep reinforcement learning model includes photovoltaic power generation prediction sequence, energy storage device charge state, and electric vehicle remaining power;
[0034] The action space of the deep reinforcement learning model is the set of charging power levels, the current time slice A set of values.
[0035] As a preferred solution of the method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device described in the present invention, the training method of the deep reinforcement learning model is as follows:
[0036] S100: construct the state space, action space, and policy network, and initialize the parameters of the policy network;
[0037] The strategy network includes: an input layer for inputting feature vectors of the state space; a hidden layer for further extracting features of the state space; and an output layer for outputting the selection probability of each action in the action space;
[0038] S200: Select and execute an action through the policy network, calculate the reward value based on the reward function and update the state space;
[0039] S300: Calculate the cumulative reward value and update the parameters of the policy network according to the cumulative reward value; the method for updating the parameters of the policy network is the gradient ascent method;
[0040] S400: Repeat steps S200-S300 until the cumulative reward value converges and the training of the policy network is completed;
[0041] S500: Save the trained policy network and deploy the application.
[0042] As a preferred solution of the method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device described in the present invention, the formula of the reward function is as follows:
[0043] ;
[0044] in, Indicates the state of the environment Next action The reward value of represents the power consumption penalty coefficient; Indicates the overcharge penalty coefficient, Indicates the over-discharge penalty coefficient; It means taking the larger value of the two elements in the brackets; Indicates the state of charge of the energy storage device at the end of the jth time slice; is a first threshold value of the state of charge of the energy storage device; is a second threshold value of the state of charge of the energy storage device; represents the total power loss of the jth time slice, and the calculation formula is as follows:
[0045] ;
[0046] in, represents the charging efficiency of the energy storage device, represents the discharge efficiency of the energy storage device, Indicates the conversion efficiency of the charging pile.
[0047] As a preferred solution of the method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device described in the present invention, the method for updating the state space is as follows: the charge state of the energy storage device is read and updated based on the battery management system of the energy storage device; the remaining power of the electric vehicle is read and updated based on the battery management system of the electric vehicle; the method for updating the photovoltaic power generation prediction sequence is to record the real-time light intensity, and when any time slice ends, calculate the mean of the real-time light intensity, and replace the light intensity prediction value of the corresponding time slice in the light intensity prediction sequence, to obtain an updated light intensity prediction sequence and input it into the photovoltaic power generation prediction model to obtain an updated photovoltaic power generation prediction sequence.
[0048] As a preferred solution of the method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device described in the present invention, the calculation formula of the cumulative reward value is as follows:
[0049] ;
[0050] in, represents the cumulative reward value; N represents the number of actions that have been executed; β represents the discount factor, which ranges from (0, 1], represents the discount factor β raised to the kth power; Indicates the state of the environment Next action The reward value of k is in the range of 1, 2, …, N.
[0051] In a second aspect, the present invention provides an intelligent monitoring and optimization scheduling system for energy consumption of a photovoltaic storage and charging device, including a data acquisition module, a data processing module, a prediction model module, a reinforcement learning module, a charging monitoring module, and a display control module; wherein:
[0052] The data acquisition module is used to collect historical charging records, historical light intensity data, and historical power generation data;
[0053] The data processing module is used to clean the historical charging records, calculate the average charging cycle of the user, and set the charging power level for the user;
[0054] The prediction model module is used to perform photovoltaic power generation prediction and generate a photovoltaic power generation prediction sequence;
[0055] The reinforcement learning module is used to train and deploy a deep reinforcement learning model for generating a charging solution;
[0056] The charging monitoring module is used to monitor the state of charge of the energy storage device and the remaining power of the electric vehicle in real time, and control the execution of the charging plan;
[0057] The display control module is used to visually display the charging plan, photovoltaic power generation prediction sequence, charge state of the energy storage device, and remaining power of the electric vehicle, and provides an interface for users to interact with the system and a function for modifying the charging plan.
[0058] Compared with the prior art, the beneficial effects achieved by the present invention are as follows:
[0059] By collecting and analyzing historical charging records to calculate the user's average charging cycle and setting the charging power level accordingly, it is possible to more accurately match user demand with system supply and reduce unnecessary energy waste. It ensures that electric vehicles can obtain the best charging service during efficient periods according to user habits, reducing waiting time. At the same time, intelligent management reduces charging costs and improves user satisfaction with charging services.
[0060] Combining historical and real-time light intensity data to predict photovoltaic power generation ensures that the charging plan can dynamically adapt to changes in lighting conditions, and ensures the continuity and stability of electric vehicle charging even in insufficient light conditions. The deep reinforcement learning model is used to generate the charging plan, which not only considers the matching of charging power and photovoltaic power generation prediction, but also minimizes system energy loss through a carefully designed reward function, while avoiding the risk of overcharging and over-discharging of energy storage devices, extending their service life, and improving the economy and sustainability of the system. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for describing the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative labor. Among them:
[0062] Figure 1 A flow chart of the method for intelligent monitoring and optimal scheduling of energy consumption of photovoltaic storage and charging equipment provided by the present invention;
[0063] Figure 2 A flowchart of a training method for a deep reinforcement learning model provided by the present invention;
[0064] Figure 3 This is a structural schematic diagram of the intelligent monitoring and optimization scheduling system for energy consumption of photovoltaic storage and charging equipment provided by the present invention. DETAILED DESCRIPTION
[0065] The technical solution of the present invention is described in detail below through the accompanying drawings and specific embodiments. It should be understood that the embodiments of the present invention and the specific features in the embodiments are detailed descriptions of the technical solution of the present invention, rather than limitations on the technical solution of the present invention. The embodiments of the present invention and the technical features in the embodiments may be combined with each other unless there is a conflict.
[0066] Example 1
[0067] This embodiment introduces a method for intelligent monitoring and optimization of energy consumption of a photovoltaic storage and charging device. Figure 1 , the method comprises the following steps:
[0068] S1: Collect and analyze historical charging records and calculate the user's average charging cycle; the method is as follows:
[0069] The historical charging records are counted, and the charging cycle of each historical charging record is obtained by subtracting the time point when the electric vehicle is connected to the charging pile from the time point when the electric vehicle is disconnected from the charging pile in each historical charging record; and the average of the charging cycles of all historical charging records is calculated as the average charging cycle of the user.
[0070] S2: Based on the average charging cycle, setting a charging power level for the user; the method is as follows:
[0071] Let the rated charging power of the user's electric vehicle be , the average charging cycle is ; The amount of electricity required to charge an electric vehicle from empty to full is ;
[0072] Calculate the minimum charging power , the formula is as follows:
[0073] ;
[0074] Assume that there are m charging power levels, where the power value of level i charging power is recorded as , i ranges from 1, 2, ..., m, where m is a positive integer; The fixed length is evenly divided into m-1 sub-intervals, and the power value corresponding to the right endpoint of the i-th sub-interval is recorded as ; The power value calculation formula for any level of charging power is as follows:
[0075] .
[0076] S3: Collect light intensity data, perform photovoltaic power generation prediction, and generate photovoltaic power generation prediction sequence; the method is as follows:
[0077] Collect historical light intensity data and historical power generation data, and perform data cleaning;
[0078] Arrange the historical light intensity data into a historical light intensity sequence in chronological order, and arrange the historical power generation data into a historical power generation sequence in chronological order;
[0079] Extracting a daily light intensity sequence from the historical light intensity sequence, and evenly dividing the daily light intensity sequence into n time slices, where n is a positive integer; calculating the mean of the light intensity data in each time slice, and arranging the mean of the n light intensity data of each day into a daily light intensity subsequence in chronological order;
[0080] A daily power generation sequence is intercepted from the historical power generation sequence, and the daily power generation sequence is evenly divided into n time slices; the mean of the power generation data in each time slice is calculated, and the mean of the n power generation data of each day is sorted into a daily power generation quantum sequence in chronological order; the power generation data, historical power generation data, and power generation described in this embodiment are all expressed as the average power in a time slice, that is, the value is equal to the total electric energy generated by photovoltaic power generation in a time slice divided by the duration of the time slice.
[0081] Training a light intensity prediction model for light intensity prediction, and outputting a light intensity subsequence for the next day as a light intensity prediction sequence; the light intensity prediction model is a time series prediction model, and any one of a SARIMA model, a long short-term memory network, and a gated recurrent unit can be selected, and the input is a light intensity subsequence for each day;
[0082] A photovoltaic power generation prediction model is trained to predict power generation and output a power generation quantum sequence for the next day as a photovoltaic power generation prediction sequence; the photovoltaic power generation prediction model is any one of a time convolutional network model, a recurrent neural network, and a support vector regression model, and the input is the light intensity prediction sequence.
[0083] S4: Based on the charging power level and the photovoltaic power generation prediction sequence, a charging plan is generated through a deep reinforcement learning model;
[0084] The state space of the deep reinforcement learning model includes photovoltaic power generation prediction sequence, energy storage device charge state, and electric vehicle remaining power;
[0085] The charging scheme is the charging power level in any time slice, the proportion of the power generation used to directly supply power to the electric vehicle to the power generation, the proportion of the power generation stored by the energy storage device to the power generation, and the power supply of the energy storage device to the electric vehicle;
[0086] Let the proportion of power generation directly supplied to electric vehicles in the jth time slice to the photovoltaic power generation be , the value range of j is 1, 2, ..., n; then the proportion of power generation used for energy storage in the jth time slice to the total power generation is 1- , the calculation formula of the power supply from the energy storage device to the electric vehicle is as follows:
[0087] ;
[0088] in, represents the power supplied by the energy storage device to the electric vehicle in the jth time slice; represents the charging power level in the jth time slice; represents the power generation in the jth time slice;
[0089] Based on the above charging plan, even when there is insufficient sunlight, the energy storage device must be partially powered, sacrificing energy consumption in exchange for equipment life to prevent the energy storage device from over-discharging when there is insufficient sunlight. Using different charging power levels can prevent the current state of photovoltaic power generation and energy storage devices from being insufficient to quickly supply power, causing the energy storage device to over-discharge when there is sunlight.
[0090] The action space of the deep reinforcement learning model is the set of charging power levels, the current time slice The value set of Evenly extract h values from The value set of , h is a positive integer;
[0091] At the beginning of each time slice, the average power generation of the time slice is not available. Therefore, this embodiment uses the photovoltaic power generation prediction sequence to calculate the probability of action selection. The obtained action only provides the proportional distribution of photovoltaic power generation, and does not directly provide the specific amount of photovoltaic power generation used for charging and energy storage, which can minimize the impact of the error between the actual photovoltaic power generation energy and the predicted value. The deep reinforcement learning model knows the future photovoltaic power generation trend in advance and can make decisions earlier, such as arranging more energy storage in advance when the photovoltaic power generation is expected to be high, or adjusting the power supply plan to avoid energy storage depletion when the power generation is low, thereby reducing unnecessary energy loss, improving the overall efficiency of the system, and achieving more efficient and intelligent energy management and distribution.
[0092] Reference Figure 2 , the training method of the deep reinforcement learning model is as follows:
[0093] S100: construct the state space, action space, and policy network, and initialize the parameters of the policy network;
[0094] The strategy network includes: an input layer for inputting feature vectors of the state space; a hidden layer for further extracting features of the state space; and an output layer for outputting the selection probability of each action in the action space;
[0095] S200: Select and execute an action through the policy network, calculate the reward value based on the reward function and update the state space;
[0096] To select an action:
[0097] Set a threshold parameter ε, with a value range of (0, 0.2];
[0098] Generate a random number r in the range of [0, 1]; if r is greater than or equal to ε, execute the action with the highest selection probability; if r is less than ε, randomly select an action to execute;
[0099] By introducing randomness, we avoid simply selecting the action with the highest probability calculated by the policy network, avoid falling into the local optimal solution, and improve the global search capability.
[0100] The formula of the reward function is as follows:
[0101] ;
[0102] in, Indicates the state of the environment Next action The reward value of Represents the power consumption penalty coefficient, in units of ; Indicates the overcharge penalty coefficient, Indicates the over-discharge penalty coefficient; , , The value of is set by technicians in this field based on actual needs; It means taking the larger value of the two elements in the brackets; Indicates the state of charge of the energy storage device at the end of the jth time slice; is the first threshold value of the state of charge of the energy storage device. When , the energy storage device is overcharged; is the second threshold value of the state of charge of the energy storage device. When the energy storage device is over-discharged; , The value of is set by a person skilled in the art based on experience; represents the total power loss of the jth time slice, and the calculation formula is as follows:
[0103] ;
[0104] in, represents the charging efficiency of the energy storage device, represents the discharge efficiency of the energy storage device, Indicates the conversion efficiency of the charging pile; , , All are determined by those skilled in the art through experiments;
[0105] The method for updating the state space is as follows: the state of charge of the energy storage device is read and updated based on the battery management system of the energy storage device; the remaining power of the electric vehicle is read and updated based on the battery management system of the electric vehicle; the method for updating the photovoltaic power generation prediction sequence is to record the real-time light intensity, and when any time slice ends, calculate the mean of the real-time light intensity, and replace the light intensity prediction value of the corresponding time slice in the light intensity prediction sequence, obtain the updated light intensity prediction sequence and input it into the photovoltaic power generation prediction model to obtain the updated photovoltaic power generation prediction sequence;
[0106] S300: Calculate the cumulative reward value and update the parameters of the policy network according to the cumulative reward value;
[0107] The calculation formula of the cumulative reward value is as follows:
[0108] ;
[0109] in, represents the cumulative reward value; N represents the number of actions that have been executed; β represents the discount factor, which ranges from (0, 1], represents the discount factor β raised to the kth power; Indicates the state of the environment Next action The reward value of k is in the range of 1, 2, ..., N;
[0110] The calculation formula for the parameters of the update strategy network is as follows:
[0111] ;
[0112] Among them, δ represents any parameter in the policy network; Indicates the gradient of the function in the brackets with respect to δ; is the learning rate; is the loss function, and the calculation formula is as follows:
[0113] ;
[0114] in, Indicates the state of the environment Next action The probability of selection;
[0115] After the above parameter updates, the policy network will assign a greater selection probability to actions with low total energy consumption. This update process will be repeated continuously, and the policy network will gradually learn the optimal probability distribution of each action in different state spaces to minimize the negative cumulative reward.
[0116] S400: Repeat steps S200-S300 until the cumulative reward value converges and the training of the policy network is completed;
[0117] After multiple iterations, the cumulative reward value tends to be stable and no longer fluctuates significantly. In other words, the cumulative reward value is considered to have converged, and the policy network is able to make a charging plan that minimizes energy consumption.
[0118] S500: Save the trained policy network and deploy the application.
[0119] S5: Execute and update the charging plan until charging is completed. The details are as follows:
[0120] At the beginning of each time slice, the policy network based on the deep reinforcement learning model calculates the selection probability of all actions in the action space; the action with the highest selection probability is converted into a charging plan, and the charging of the electric vehicle is controlled based on the charging plan; when entering the next time slice, the state space of the deep reinforcement learning model is updated and a new charging plan is generated; the charging plan is executed and updated until the remaining power of the electric vehicle reaches the maximum power of the electric vehicle and the charging is completed.
[0121] Example 2
[0122] This embodiment is the second embodiment of the present invention; it is based on the same inventive concept as embodiment 1, Figure 3 This embodiment introduces an intelligent monitoring and optimization scheduling system for energy consumption of a photovoltaic storage and charging device, including a data acquisition module, a data processing module, a prediction model module, a reinforcement learning module, a charging monitoring module, and a display control module; wherein:
[0123] The data acquisition module is used to collect historical charging records, historical light intensity data, and historical power generation data;
[0124] The data processing module is used to clean the historical charging records, calculate the average charging cycle of the user based on the pre-processed historical charging records, and set the charging power level for the user based on the average charging cycle;
[0125] The prediction model module is used to predict photovoltaic power generation and generate a photovoltaic power generation prediction sequence; it includes a preprocessing unit, a light intensity prediction unit, and a power generation prediction unit; wherein:
[0126] The preprocessing unit is used to clean and sort the historical light intensity data and the historical power generation data to generate a light intensity subsequence and a power generation quantum sequence;
[0127] The light intensity prediction unit is used to train a light intensity prediction model, calculate and output a light intensity prediction sequence;
[0128] The power generation quantum sequence is used to train the photovoltaic power generation prediction model, calculate and output the photovoltaic power generation prediction sequence;
[0129] The reinforcement learning module is used to train and deploy a deep reinforcement learning model for generating a charging solution;
[0130] The charging monitoring module is used to monitor the charge state of the energy storage device and the remaining power of the electric vehicle in real time, and control the execution of the charging scheme; including allocating the power supply ratio of photovoltaic power generation to the energy storage device and the charging pile, controlling the charging power of the electric vehicle and the power supply of the energy storage device to the charging pile;
[0131] The display control module is used to visually display the charging plan, photovoltaic power generation prediction sequence, charge state of the energy storage device, and remaining power of the electric vehicle, and provides an interface for users to interact with the system and a function for modifying the charging plan.
[0132] The specific functions of the above modules are realized by referring to the relevant contents of the method for intelligent monitoring and optimal scheduling of energy consumption of photovoltaic storage and charging equipment described in Example 1, which will not be elaborated here.
[0133] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0134] The embodiments of the present invention are described above in conjunction with the accompanying drawings, but the present invention is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present invention, ordinary technicians in this field can also make many forms without departing from the purpose and scope of protection of the present invention, which are all within the protection of the present invention.
Claims
1. A method for intelligent monitoring and optimization of energy consumption of photovoltaic storage and charging equipment, characterized in that: include: S1: Collect and analyze historical charging records and calculate the user's average charging cycle; S2: Based on the average charging cycle, a charging power level is set for the user, as follows: Let the rated charging power of the user's electric vehicle be , the average charging cycle is ; The amount of electricity required to charge an electric vehicle from empty to full is ; Calculate the minimum charging power , the formula is as follows: ; Assume that there are m charging power levels, where the power value of level i charging power is recorded as , i ranges from 1, 2, ..., m, where m is a positive integer; The fixed length is evenly divided into m-1 sub-intervals, and the power value corresponding to the right endpoint of the i-th sub-interval is recorded as ; The power value calculation formula for any level of charging power is as follows: ; S3: Collect light intensity data, make photovoltaic power generation predictions, and generate photovoltaic power generation prediction sequences; S4: Based on the charging power level and the photovoltaic power generation prediction sequence, a charging plan is generated through a deep reinforcement learning model; The charging scheme is the charging power level in any time slice, the proportion of power generation directly supplied to electric vehicles in power generation, the proportion of power generation stored in the energy storage device in power generation, and the power supply of the energy storage device to the electric vehicle; let the proportion of power generation directly supplied to the electric vehicle in the jth time slice in the photovoltaic power generation be , the value range of j is 1, 2, ..., n; then the proportion of power generation used for energy storage in the jth time slice to the total power generation is , the calculation formula of the power supply from the energy storage device to the electric vehicle is as follows: ; in, represents the power supplied by the energy storage device to the electric vehicle in the jth time slice; represents the charging power level in the jth time slice; represents the power generation in the jth time slice; The state space of the deep reinforcement learning model includes photovoltaic power generation prediction sequence, energy storage device charge state, and electric vehicle remaining power; The action space of the deep reinforcement learning model is the set of charging power levels, the current time slice The value set of ; S5: Execute and update the charging plan until charging is completed.
2. The method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device according to claim 1, characterized in that: The method for calculating the average charging cycle of a user is as follows: The historical charging records are counted, and the charging cycle of each historical charging record is obtained by subtracting the time point when the electric vehicle is connected to the charging pile from the time point when the electric vehicle is disconnected from the charging pile in each historical charging record; and the average of the charging cycles of all historical charging records is calculated as the average charging cycle of the user.
3. A method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device as claimed in claim 2, characterized in that: The specific method for generating the photovoltaic power generation prediction sequence is as follows: Collect historical light intensity data and historical power generation data, and perform data cleaning; Arrange the historical light intensity data into a historical light intensity sequence in chronological order, and arrange the historical power generation data into a historical power generation sequence in chronological order; Extracting a daily light intensity sequence from the historical light intensity sequence, and evenly dividing the daily light intensity sequence into n time slices, where n is a positive integer; calculating the mean of the light intensity data in each time slice, and arranging the mean of the n light intensity data of each day into a daily light intensity subsequence in chronological order; Extracting a daily power generation sequence from the historical power generation sequence, and evenly dividing the daily power generation sequence into n time slices; Calculate the mean of the power generation data in each time slice, and organize the mean of the n power generation data of each day into a power generation quantum sequence for each day in chronological order; Training a light intensity prediction model for light intensity prediction, and outputting a light intensity subsequence for the next day as a light intensity prediction sequence; the light intensity prediction model is a time series prediction model, and the input is a light intensity subsequence for each day; A photovoltaic power generation prediction model is trained to predict power generation and output a power generation quantum sequence for the next day as a photovoltaic power generation prediction sequence; the photovoltaic power generation prediction model is any one of a time convolutional network model, a recurrent neural network, and a support vector regression model, and the input is the light intensity prediction sequence.
4. A method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device as claimed in claim 3, characterized in that: The training method of the deep reinforcement learning model is as follows: S100: construct the state space, action space, and policy network, and initialize the parameters of the policy network; The strategy network includes: an input layer for inputting feature vectors of the state space; a hidden layer for further extracting features of the state space; and an output layer for outputting the selection probability of each action in the action space; S200: Select and execute an action through the policy network, calculate the reward value based on the reward function and update the state space; S300: Calculate the cumulative reward value and update the parameters of the policy network according to the cumulative reward value; the method for updating the parameters of the policy network is the gradient ascent method; S400: Repeat steps S200-S300 until the cumulative reward value converges and the training of the policy network is completed; S500: Save the trained policy network and deploy the application.
5. The method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device according to claim 4, characterized in that: The formula of the reward function is as follows: ; in, Indicates the state of the environment Next action The reward value of represents the power consumption penalty coefficient; Indicates the overcharge penalty coefficient, Indicates the over-discharge penalty coefficient; It means taking the larger value of the two elements in the brackets; Indicates the state of charge of the energy storage device at the end of the jth time slice; is a first threshold value of the state of charge of the energy storage device; is a second threshold value of the state of charge of the energy storage device; represents the total power loss of the jth time slice, and the calculation formula is as follows: ; in, represents the charging efficiency of the energy storage device, represents the discharge efficiency of the energy storage device, Indicates the conversion efficiency of the charging pile.
6. A method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device as claimed in claim 5, characterized in that: The method for updating the state space is as follows: the charge state of the energy storage device is read and updated based on the battery management system of the energy storage device; the remaining power of the electric vehicle is read and updated based on the battery management system of the electric vehicle; the method for updating the photovoltaic power generation prediction sequence is to record the real-time light intensity, and when any time slice ends, calculate the mean of the real-time light intensity and replace the light intensity prediction value of the corresponding time slice in the light intensity prediction sequence to obtain an updated light intensity prediction sequence and input it into the photovoltaic power generation prediction model to obtain an updated photovoltaic power generation prediction sequence.
7. A method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device as claimed in claim 6, characterized in that: The calculation formula of the cumulative reward value is as follows: ; in, represents the cumulative reward value; N represents the number of actions that have been executed; β represents the discount factor, which ranges from (0, 1], represents the discount factor β raised to the kth power; Indicates the state of the environment Next action The reward value of k is in the range of 1, 2, …, N.
8. A system for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device, which is implemented based on a method for intelligent monitoring and optimal scheduling of energy consumption of a photovoltaic storage and charging device according to any one of claims 1 to 7, characterized in that: It includes data acquisition module, data processing module, prediction model module, reinforcement learning module, charging monitoring module and display control module; among which: The data acquisition module is used to collect historical charging records, historical light intensity data, and historical power generation data; The data processing module is used to clean the historical charging records, calculate the average charging cycle of the user, and set the charging power level for the user; The prediction model module is used to perform photovoltaic power generation prediction and generate a photovoltaic power generation prediction sequence; The reinforcement learning module is used to train and deploy a deep reinforcement learning model for generating a charging solution; The charging monitoring module is used to monitor the state of charge of the energy storage device and the remaining power of the electric vehicle in real time, and control the execution of the charging plan; The display control module is used to visually display the charging plan, photovoltaic power generation prediction sequence, charge state of the energy storage device, and remaining power of the electric vehicle, and provides an interface for users to interact with the system and a function for modifying the charging plan.
