A method for optimizing energy dispatch in residential areas under power outage scenarios

By establishing a three-stage optimization model under a power outage scenario, using electric vehicles, battery swap station batteries and photovoltaic power generation resources, the power consumption strategy in residential areas is optimized in real time, solving the power dispatching problem during the power outage and achieving load optimization and cost reduction.

CN117424211BActive Publication Date: 2025-01-24EAST CHINA ELECTRIC POWER TEST & RES INST +2
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311319590.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-10-12
Publication Date
2025-01-24
Estimated Expiration
2043-10-12

Smart Images

  • Figure CN117424211B_ABST
    Figure CN117424211B_ABST
Patent Text Reader

Abstract

A method for optimizing energy dispatch in a residential area under a power outage scenario comprises the following steps: (1) determining the current and future power grid status for several time periods, and judging the optimization period and energy dispatch optimization method according to the power grid status; (2) updating relevant data of the residential area and its surrounding power swap stations, and predicting data such as residential power load, power swap demand of power swap stations, and photovoltaic output within the optimization period; (3) establishing a real-time optimization model for power dispatch in combination with corresponding constraints and objective functions; (4) solving the real-time optimization model, executing the energy dispatch optimization method within the current time period according to the solution results, and collecting relevant data of the residential area and its surrounding power swap stations at the end of the time period; (5) repeating the above steps at the beginning of each subsequent time period until the entire optimization time domain ends, thereby completing a process of optimizing energy dispatch in a residential area.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of power distribution of electric power systems, and in particular to a method for optimizing energy dispatching in residential areas under power outage scenarios. Background Art

[0002] With the rapid popularization of electric vehicles, the disorderly charging and battery swapping of residential electric vehicles may increase the power load during the peak hours of the urban power grid, affecting the stability of the power grid. However, the charging and discharging of residential electric vehicles and battery swap stations have high dispatchable potential and can be used to optimize the energy dispatching method of residential areas in power outage scenarios.

[0003] When the power system is operating normally, users in residential areas hope to fully meet their electricity needs while minimizing electricity costs, while the power supplier hopes to minimize the peak-to-valley difference in electricity load to ensure the safety and reliability of power supply. When a power outage warning or notification is issued in advance, users in residential areas first hope to fully charge the energy storage equipment to cope with the next possible power outage period, and then consider electricity costs and related issues of orderly charging. When the power grid stops supplying electricity, users in residential areas can use the electricity stored in the energy storage equipment in advance and possible photovoltaic power generation and other resources to give priority to maintaining the continued operation of the first and second level loads until the power outage ends and the power grid returns to normal operation.

[0004] At the same time, considering the working conditions of the battery swap stations in the residential area and its surrounding areas, the original load of the residential area, the charging and discharging conditions of electric vehicles, the photovoltaic output of the residential area and the battery swap demand of the battery swap station, it is particularly important to adopt a residential area energy scheduling optimization method in real time under the power outage scenario when the power outage time is known. Summary of the invention

[0005] The purpose of the present invention is to give full play to the scheduling potential of electric vehicles in residential areas and batteries of surrounding battery swap stations, while considering the original load and photovoltaic output of the residential area and the battery swap demand of the battery swap station, and to provide a residential area energy scheduling optimization method for power outage scenarios.

[0006] To achieve the above object, the technical solution of the present invention is:

[0007] The present invention provides Figure 1 A method for optimizing energy dispatch in a residential area under a power outage scenario is shown, comprising the following steps:

[0008] Step S1, determining the current and future power grid status, and judging the optimization cycle and energy scheduling optimization method according to the power grid status;

[0009] Step S2, updating the relevant data of the residential area and its surrounding battery swap stations, and predicting the data such as the residential power load, the battery swap demand of the battery swap station, and the photovoltaic output during the optimization period;

[0010] Step S3, combining corresponding constraints and objective functions to establish a real-time optimization model for power dispatching;

[0011] Step S4, solving the real-time optimization model, executing the power dispatch strategy within the time period according to the solution result, and collecting relevant data of the residential area and its surrounding battery swap stations at the end of the time period;

[0012] Step S5, repeat the above steps at the beginning of each subsequent time period until the entire optimization time domain is completed, completing a residential area energy scheduling optimization process.

[0013] In one embodiment of the present invention, the specific implementation of step S1 is as follows:

[0014] Step S11, according to the different demands of residential users and power systems for power supply in different situations, the power grid status is divided into three categories: economic dispatch, active defense and load recovery.

[0015] Most of the time, the power grid works normally and is in a state of economic dispatch. Residential users hope to fully meet their electricity needs while reducing electricity costs as much as possible, while the power supply party hopes to reduce the peak-to-valley difference of electricity load as much as possible to ensure the safety and reliability of power supply. When predictable natural disasters or power outages such as typhoons and snowstorms are about to occur, residential users first hope to fully charge the energy storage equipment to cope with the next possible power outage. At this time, the power grid is in a state of active defense. When the entire residential area is out of power, in order to maintain the continued operation of some important loads, residential electric vehicles discharge through the V2G function, photovoltaic power generation and battery replacement station discharge, and at this time it is in a state of load recovery.

[0016] The present invention is mainly aimed at the energy dispatch optimization method of residential areas under the power outage scenario, so the power grid state is mainly in an active defense state. This step collects the power outage information and power outage warnings issued by the power company, determines the current and future power grid states, and determines the time of the power outage.

[0017] Step S12: To ensure the real-time performance of the optimization strategy, relevant data needs to be updated and optimized again after a certain time interval to achieve the purpose of rolling optimization. After determining the power grid status of the current period, in order to start a new round of optimization, the optimization cycle of this optimization needs to be determined first. The duration of the optimization cycle in the active defense state is selected as follows:

[0018] The active defense stage is a transitional stage between the economic dispatch and load recovery states. Therefore, even if the power company announces the time of the power outage several days in advance, residential areas generally only need to make active defense-related responses within 1 day before the power outage. Considering that the entire active defense stage lasts for a short time, the optimization cycle in this state is set to the time between the current moment and the start of the power outage. If the power outage time is fixed, the optimization cycle in the active defense stage will gradually decrease as time goes by, indicating that the power outage event is gradually approaching.

[0019] Preferably, the specific implementation of step S2 is as follows:

[0020] Step S21: If the time period is the first time period to be optimized, directly collect data of the residential area and its surrounding battery swap stations. If the time period before this time period has been optimized and the optimization results have been executed, update the relevant data according to the results of the previous optimization.

[0021] The data that needs to be collected or updated include the number of electric vehicles, battery capacity and SOC in the residential area at the beginning of the period; the number, capacity and SOC of batteries in the battery swap station.

[0022] Step S22, predict and obtain the relevant data required by the model within the optimization period, the required prediction data are as follows: the entry and exit of electric vehicles in the residential area, the load curve of the residential area, the load classification of the residential area, the photovoltaic output of the residential area, and the battery replacement demand of the battery replacement station.

[0023] Preferably, the specific implementation of step S3 is as follows:

[0024] The optimization model in the active defense state is divided into three stages, with the goals of maximizing power load, minimizing power purchase costs, and minimizing load peak-valley differences. As in the economic dispatch stage, the priorities of the three goals decrease in turn. That is, the first priority is to meet the maximum power consumption within the optimization cycle and then consider factors such as power purchase costs. This is because during the active defense stage, the primary demand of residential users is to meet normal power demand while reserving as much power as possible to cope with the upcoming power outage.

[0025] (1) Phase I:

[0026] Step S31, the objective function of the first stage is as follows:

[0027]

[0028] The objective function of the first stage is formula (1): Indicates that during the xth optimization process, t c The optimized scheduling period set for the start time period. are the purchased power and photovoltaic power generation at time t, respectively. The objective function of the first stage is to maximize the sum of photovoltaic power generation and purchased power consumed by the residential area during the optimization period. Considering that the load in the residential area and the demand for battery swapping at the battery swapping station will not change due to the state of the power grid, the setting of this objective function will enable the residential electric vehicles and battery swapping station batteries to be charged as much as possible during the optimization period to cope with the impending power outage.

[0029] The constraints for the first stage are as follows:

[0030]

[0031]

[0032]

[0033]

[0034]

[0035]

[0036] The above equations (2)-(6) are the constraints related to the battery swapping operation of the battery swapping station, where N BSS,b (x), N BSS,ev (x) represents the set of battery swap stations and electric vehicles with battery swap needs in the xth optimization process. are 0 / 1 variables. The first two represent whether the i-th battery and the j-th electric vehicle of the battery swap station are swapped at time t. The variable corresponds the battery that is ready to be replaced at time t to the electric vehicle. If the element in the ath row and bth column in the matrix is ​​1, it means that the corresponding two batteries have been exchanged, and if it is 0, it means that they have not been exchanged. For example, formula (7) means that when t = 1, the battery swap station swaps the first battery with the battery of the first electric vehicle that needs to be swapped, while other batteries and electric vehicles that need to be swapped are not swapped. Formula (2) means that the battery swap station does not swap batteries before they are fully charged, where represents the SOC of the i-th battery at time t. Formulas (3) and (4) indicate that a battery replacement operation corresponds to a battery and an electric vehicle with a battery replacement demand. In formula (4), It represents the difference between the SOC of the i-th battery and the battery on the j-th electric vehicle during the battery swap operation at time t, that is, the difference between the SOC of the two batteries during a battery swap process. If the corresponding battery and the electric vehicle do not swap, its value is 0. In formula (6) It is the difference in SOC before and after the i-th battery is replaced at time t. If the battery is not replaced, its value is 0.

[0037]

[0038]

[0039]

[0040]

[0041]

[0042] The above equations (8)-(12) are the constraints related to battery charging in the battery swap station. Equation (8) limits the maximum and minimum values ​​of the battery SOC. is the charging power of the ith battery at time t, η ch and are charging efficiency and battery capacity respectively. In formula (10) is a 0 / 1 variable, indicating whether the i-th battery is being charged at time t at the battery swap station. is the maximum value of battery charging power. In formula (11) is the maximum charging power of the battery swap station. This formula indicates that the total charging power of all batteries in the battery swap station cannot exceed Formula (12) indicates that at any time, a battery cannot be charged and replaced at the same time.

[0043]

[0044]

[0045]

[0046] The above equations (13)-(15) are charging constraints for residential electric vehicles, which are similar to equations (8)-(12). During the active defense period, the V2G function of electric vehicles may cause them to charge and discharge repeatedly to obtain subsidies and fill the battery as much as possible. However, the active defense state lasts for a short time, the benefits of subsidies are not obvious, repeated charging and discharging will affect the battery life, and the user's first demand is still to maximize energy storage rather than minimize electricity costs. Therefore, the V2G function of electric vehicles is not considered during the active defense stage. is the charging power of the electric vehicle battery at time t, and the 0 / 1 variable It represents whether the electric vehicle battery is charged at time t.

[0047]

[0048]

[0049] In the above formula, and represents the photovoltaic power generation and abandoned light value at time t, is the maximum photovoltaic power generation power at time t.

[0050]

[0051] Formula (18) is the power balance constraint, where is the total load of the residential area at time t. The three items on the left side of the formula provide power, and the three items on the right side consume power. Therefore, at any time, both sides of the formula are equal and the power remains balanced.

[0052] Step S32, the objective function of the second stage is as follows:

[0053]

[0054]

[0055]

[0056] The objective function of the second stage is shown in formula (19): are the total electricity purchase cost and photovoltaic power generation cost at time t respectively. The specific algorithm is as follows: (20)-(21), where k PV are the grid time-of-use electricity price and photovoltaic power generation cost respectively, and are the purchased electricity power and photovoltaic power generation power at time t respectively.

[0057] The constraints for the second stage are as follows:

[0058]

[0059] The constraints of the second stage include all the constraints of the first stage, and the new formula (22) is added. In order to calculate the objective function of the first stage, it is necessary to first ensure the optimization result of the first stage.

[0060] Step S33, the objective function of the third stage is as follows:

[0061]

[0062]

[0063] In formula (23) To optimize the dispatch period, the purchased power is aggregated The average value is calculated as shown in formula (24). Since the power outage time is not fixed, the time period of the active defense state may also be at different times of the day. At the same time, since it is necessary to store as much energy as possible while meeting normal power demand, the grid load during the active defense period is generally higher than the load when the grid is working normally. Therefore, if the active defense time coincides with the peak power consumption time, it is more necessary to optimize this stage to avoid the peak situation caused by disordered charging as much as possible.

[0064] The constraints for the third phase are as follows:

[0065]

[0066] In addition to all the constraints in the second stage, the constraints in the third stage also need to consider equation (25), where is the calculated objective function of the second stage.

[0067] Preferably, the specific implementation of step S4 is as follows:

[0068] Step S41, solving the real-time optimization model, solving the optimization model established in step 3 through Matlab, Yalmip and Gurobi.

[0069] Step S42: According to the model solution results, the charging and discharging behaviors of electric vehicles in residential areas, the utilization of photovoltaic power in residential areas, and the charging, discharging and battery swapping behaviors of batteries in battery swap stations are regulated.

[0070] Step S43: At the end of this time period, collect data such as the number of electric vehicles in the residential area, battery capacity and SOC; the number of batteries in the battery swap station, capacity and SOC, etc.

[0071] Preferably, the specific implementation of step S5 is as follows:

[0072] At the beginning of each subsequent time period, the process continues from step S1 until the entire optimization time domain is completed, thus completing a real-time optimization process for power dispatching.

[0073] Compared with the prior art, the present invention has the following beneficial effects:

[0074] The present invention takes into account the different states of the power grid and classifies and judges them: for the active defense stage, a method for optimizing the energy dispatch of residential areas in power outage scenarios is proposed. By establishing a three-stage optimization model, the dispatchability of the power swap station near the residential area is taken into account. Under the premise of ensuring the power demand of users in power outage scenarios as much as possible, the power cost of users and the peak-to-valley difference of power load in residential areas are reduced at the same time. BRIEF DESCRIPTION OF THE DRAWINGS

[0075] Figure 1 Flow chart of the energy dispatch optimization method for residential areas under power outage scenarios DETAILED DESCRIPTION

[0076] The present invention is described in detail below in conjunction with the accompanying drawings and specific embodiments. Note that the following embodiments are merely illustrative in nature, and the present invention is not intended to limit the applicable objects or their uses, and the present invention is not limited to the following embodiments.

[0077] The present invention provides Figure 1 A method for optimizing energy dispatch in a residential area under a power outage scenario is shown, comprising the following steps:

[0078] Step S1, determining the current and future power grid status, and judging the optimization cycle and energy scheduling optimization method according to the power grid status;

[0079] Step S2, updating the relevant data of the residential area and its surrounding battery swap stations, and predicting the data such as the residential power load, the battery swap demand of the battery swap station, and the photovoltaic output during the optimization period;

[0080] Step S3, combining corresponding constraints and objective functions to establish a real-time optimization model for power dispatching;

[0081] Step S4, solving the real-time optimization model, executing the power dispatch strategy within the time period according to the solution result, and collecting relevant data of the residential area and its surrounding battery swap stations at the end of the time period;

[0082] Step S5, repeat the above steps at the beginning of each subsequent time period until the entire optimization time domain is completed, completing a residential area energy scheduling optimization process.

[0083] In one embodiment of the present invention, the specific implementation of step S1 is as follows:

[0084] Step S11, for the convenience of research, according to the different demands of residential users and power systems for power supply in different situations, the power grid status is divided into three categories, namely: economic dispatch, active defense and load recovery.

[0085] Most of the time, the power grid works normally and is in a state of economic dispatch. Residential users hope to fully meet their electricity needs while reducing electricity costs as much as possible, while the power supply party hopes to reduce the peak-to-valley difference of electricity load as much as possible to ensure the safety and reliability of power supply. When predictable natural disasters or power outages such as typhoons and snowstorms are about to occur, residential users first hope to fully charge the energy storage equipment to cope with the next possible power outage. At this time, the power grid is in a state of active defense. When the entire residential area is out of power, in order to maintain the continued operation of some important loads, residential electric vehicles discharge through the V2G function, photovoltaic power generation and battery replacement station discharge, and at this time it is in a state of load recovery.

[0086] The present invention is mainly aimed at the energy dispatch optimization method of residential areas under the power outage scenario, so the power grid state is mainly in an active defense state. This step collects the power outage information and power outage warnings issued by the power company, determines the current and future power grid states, and determines the time of the power outage.

[0087] Step S12: To ensure the real-time performance of the optimization strategy, relevant data needs to be updated and optimized again after a certain time interval to achieve the purpose of rolling optimization. After determining the power grid status of the current period, in order to start a new round of optimization, the optimization cycle of this optimization needs to be determined first. The duration of the optimization cycle in the active defense state is selected as follows:

[0088] The active defense stage is a transitional stage between the economic dispatch and load recovery states. Therefore, even if the power company announces the time of the power outage several days in advance, residential areas generally only need to make active defense-related responses within 1 day before the power outage. Considering that the entire active defense stage lasts for a short time, the optimization cycle in this state is set to the time between the current moment and the start of the power outage. If the power outage time is fixed, the optimization cycle in the active defense stage will gradually decrease as time goes by, indicating that the power outage event is gradually approaching.

[0089] In one embodiment of the present invention, the specific implementation of step S2 is as follows:

[0090] Step S21: If the time period is the first time period to be optimized, directly collect data of the residential area and its surrounding battery swap stations. If the time period before this time period has been optimized and the optimization results have been executed, update the relevant data according to the results of the previous optimization.

[0091] The data that needs to be collected or updated include the number of electric vehicles, battery capacity and SOC in the residential area at the beginning of the period; the number, capacity and SOC of batteries in the battery swap station.

[0092] Step S22, predict and obtain the relevant data required by the model within the optimization period, the required prediction data are as follows: the entry and exit of electric vehicles in the residential area, the load curve of the residential area, the load classification of the residential area, the photovoltaic output of the residential area, and the battery replacement demand of the battery replacement station.

[0093] In one embodiment of the present invention, the specific implementation of step S3 is as follows:

[0094] The optimization model in the active defense state is divided into three stages, with the goals of maximizing power load, minimizing power purchase costs, and minimizing load peak-valley differences. As in the economic dispatch stage, the priorities of the three goals decrease in turn. That is, the first priority is to meet the maximum power consumption within the optimization cycle and then consider factors such as power purchase costs. This is because during the active defense stage, the primary demand of residential users is to meet normal power demand while reserving as much power as possible to cope with the upcoming power outage.

[0095] (1) Phase I:

[0096] Step S31, the objective function of the first stage is as follows:

[0097]

[0098] The objective function of the first stage is formula (1): Indicates that during the xth optimization process, t c The optimized scheduling period set for the start time period. are the purchased power and photovoltaic power generation at time t, respectively. The objective function of the first stage is to maximize the sum of photovoltaic power generation and purchased power consumed by the residential area during the optimization period. Considering that the load in the residential area and the demand for battery swapping at the battery swapping station will not change due to the state of the power grid, the setting of this objective function will enable the residential electric vehicles and battery swapping station batteries to be charged as much as possible during the optimization period to cope with the impending power outage.

[0099] The constraints in the first stage are as follows:

[0100]

[0101]

[0102]

[0103]

[0104]

[0105]

[0106] The above equations (2)-(6) are the constraints related to the battery swapping operation of the battery swapping station, where NBSS,b (x), N BSS,ev (x) represents the set of battery swap stations and electric vehicles with battery swap needs in the xth optimization process. are 0 / 1 variables. The first two represent whether the i-th battery and the j-th electric vehicle of the battery swap station are swapped at time t. The variable corresponds the battery that is ready to be replaced at time t to the electric vehicle. If the element in the ath row and bth column in the matrix is ​​1, it means that the corresponding two batteries have been exchanged, and if it is 0, it means that they have not been exchanged. For example, formula (7) means that when t = 1, the battery swap station swaps the first battery with the battery of the first electric vehicle that needs to be swapped, while other batteries and electric vehicles that need to be swapped are not swapped. Formula (2) means that the battery swap station does not swap batteries before they are fully charged, where represents the SOC of the i-th battery at time t. Formulas (3) and (4) indicate that a battery replacement operation corresponds to a battery and an electric vehicle with a battery replacement demand. In formula (4), It represents the difference between the SOC of the i-th battery and the battery on the j-th electric vehicle during the battery swap operation at time t, that is, the difference between the SOC of the two batteries during a battery swap process. If the corresponding battery and the electric vehicle do not swap, its value is 0. In formula (6) It is the difference in SOC before and after the i-th battery is replaced at time t. If the battery is not replaced, its value is 0.

[0107]

[0108]

[0109]

[0110]

[0111]

[0112] The above equations (8)-(12) are the constraints related to battery charging in the battery swap station. Equation (8) limits the maximum and minimum values ​​of the battery SOC. is the charging power of the ith battery at time t, η ch and are charging efficiency and battery capacity respectively. In formula (10) is a 0 / 1 variable, indicating whether the i-th battery is being charged at time t at the battery swap station. is the maximum value of battery charging power. In formula (11) is the maximum charging power of the battery swap station. This formula indicates that the total charging power of all batteries in the battery swap station cannot exceed Formula (12) indicates that at any time, a battery cannot be charged and replaced at the same time.

[0113]

[0114]

[0115]

[0116] The above equations (13)-(15) are charging constraints for residential electric vehicles, which are similar to equations (8)-(12). During the active defense period, the V2G function of electric vehicles may cause them to charge and discharge repeatedly to obtain subsidies and fill the battery as much as possible. However, the active defense state lasts for a short time, the benefits of subsidies are not obvious, repeated charging and discharging will affect the battery life, and the user's first demand is still to maximize energy storage rather than minimize electricity costs. Therefore, the V2G function of electric vehicles is not considered during the active defense stage. is the charging power of the electric vehicle battery at time t, and the 0 / 1 variable It represents whether the electric vehicle battery is charged at time t.

[0117]

[0118]

[0119] In the above formula, and represents the photovoltaic power generation and abandoned light value at time t, is the maximum photovoltaic power generation power at time t.

[0120]

[0121] Formula (18) is the power balance constraint, where is the total load of the residential area at time t. The three items on the left side of the formula provide power, and the three items on the right side consume power. Therefore, at any time, both sides of the formula are equal and the power remains balanced.

[0122] Step S32, the objective function of the second stage is as follows:

[0123]

[0124]

[0125]

[0126] The objective function of the second stage is shown in formula (19): are the total electricity purchase cost and photovoltaic power generation cost at time t respectively. The specific algorithm is as follows: (20)-(21), where k PV are the grid time-of-use electricity price and photovoltaic power generation cost respectively, and are the purchased electricity power and photovoltaic power generation power at time t respectively.

[0127] The constraints for the second stage are as follows:

[0128]

[0129] The constraints of the second stage include all the constraints of the first stage, and the new formula (22) is added. In order to calculate the objective function of the first stage, it is necessary to first ensure the optimization result of the first stage.

[0130] Step S33, the objective function of the third stage is as follows:

[0131]

[0132]

[0133] In formula (23) To optimize the dispatch period, the purchased power is aggregated The average value is calculated as shown in formula (24). Since the power outage time is not fixed, the time period of the active defense state may also be at different times of the day. At the same time, since it is necessary to store as much energy as possible while meeting normal power demand, the grid load during the active defense period is generally higher than the load when the grid is working normally. Therefore, if the active defense time coincides with the peak power consumption time, it is more necessary to optimize this stage to avoid the peak situation caused by disordered charging as much as possible.

[0134] The constraints for the third phase are as follows:

[0135]

[0136] In addition to all the constraints in the second stage, the constraints in the third stage also need to consider equation (25), where is the calculated objective function of the second stage.

[0137] In one embodiment of the present invention, the specific implementation of step S4 is as follows:

[0138] Step S41, solving the real-time optimization model, solving the optimization model established in step 3 through Matlab, Yalmip and Gurobi.

[0139] Step S42: According to the model solution results, the charging and discharging behaviors of electric vehicles in residential areas, the utilization of photovoltaic power in residential areas, and the charging, discharging and battery swapping behaviors of batteries in battery swap stations are regulated.

[0140] Step S43: At the end of this time period, collect data such as the number of electric vehicles in the residential area, battery capacity and SOC; the number of batteries in the battery swap station, capacity and SOC, etc.

[0141] In one embodiment of the present invention, the specific implementation of step S5 is as follows:

[0142] At the beginning of each subsequent time period, the process continues from step S1 until the entire optimization time domain is completed, thus completing a real-time optimization process for power dispatching.

[0143] Finally, it should be noted that the above is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the aforementioned embodiments, it is still possible for those skilled in the art to modify the technical solutions described in the aforementioned embodiments or to make equivalent substitutions for some of the technical features therein. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.

Claims

1. A method for optimizing energy dispatch in residential areas under power outage scenarios, characterized in that: The steps include: Step S1: Obtain the start of power outages in residential areas and their surrounding battery swap stations in the current and preset future time periods With duration T cut , active defense period T1 and load recovery period T2, used to confirm the state of the power grid, and determine the optimization period and energy scheduling optimization method according to the state of the power grid; the optimization period is the time between the current moment and the start moment of the power outage; Step S2, updating the relevant data of the residential area and its surrounding battery swap stations, predicting the residential power load, battery swap demand of the battery swap station and photovoltaic output data within the optimization period; Step S3, combining corresponding constraints and objective functions to establish a real-time optimization model for power dispatching; Step S4, solving the real-time optimization model of power dispatching, executing the power dispatching strategy in the current time period according to the solution result, and collecting relevant data of the residential area and its surrounding battery swap stations at the end of the time period; Step S5, repeating steps S1-S4 until the optimization time domain ends, completing a residential area energy scheduling optimization process; The step S3 combines the corresponding constraints and the objective function to establish a real-time optimization model for power dispatching, which specifically includes: Step S31, the objective function of the first stage is as follows: Indicates that during the xth optimization process, t c is the set of optimized scheduling periods for the starting time period, are the purchased electricity power and photovoltaic power generation power at time t respectively; The objective function of the first stage is to maximize the sum of photovoltaic power generation and purchased power consumed by the residential area during the optimization period. The setting of this objective function will enable the residential electric vehicles and battery swap station batteries to be charged as much as possible during the optimization period to cope with the impending power outage; The constraints for the first stage are as follows: The above equations (2)-(6) are the constraints related to the battery swapping operation of the battery swapping station, where N BSS,b (x), N BSS,ev (x) represents the set of battery swap stations and electric vehicles with battery swap requirements in the xth optimization process; are 0 / 1 variables. The first two represent whether the i-th battery and the j-th electric vehicle of the battery swap station are swapped at time t. The variable corresponds the battery ready for replacement at time t to the electric vehicle one by one; If the element in the ath row and bth column of the matrix is ​​1, it means that the corresponding two batteries have been swapped, and if it is 0, it means that they have not been swapped; Formula (2) indicates that the battery of the battery swap station will not be swapped before it is fully charged, where represents the SOC of the i-th battery at time t; Formulas (3) and (4) indicate that a battery replacement operation corresponds to a battery and an electric vehicle with a battery replacement demand. In formula (4), It indicates the difference between the SOC of the i-th battery and the battery on the j-th electric vehicle that is swapped at time t, that is, the difference between the SOCs of the two batteries during one swap. If the corresponding battery and the electric vehicle are not swapped, its value is 0. In formula (6) The SOC difference of the i-th battery before and after the battery replacement operation at time t. If the battery is not replaced, its value is 0; The above equations (8)-(12) are the constraints related to battery charging in the battery swap station. Equation (8) limits the maximum and minimum values ​​of the battery SOC; in equation (9) is the charging power of the ith battery at time t, η ch and are charging efficiency and battery capacity respectively; in formula (10) is a 0 / 1 variable, indicating whether the i-th battery is being charged at time t at the battery swap station. is the maximum value of battery charging power; in formula (11) is the maximum charging power of the battery swap station. This formula indicates that the total charging power of all batteries in the battery swap station cannot exceed Formula (12) indicates that at any time, a battery cannot be charged and replaced at the same time; The above formulas (13)-(15) are the charging constraints of residential electric vehicles. During the active defense period, the V2G function of electric vehicles may cause them to charge and discharge repeatedly to achieve the effect of obtaining subsidies and filling the battery as much as possible. The V2G function of electric vehicles is not considered in the active defense stage. is the charging power of the electric vehicle battery at time t, and the 0 / 1 variable It represents whether the electric vehicle battery is charged at time t; In the formula, and represents the photovoltaic power generation and abandoned light value at time t, is the maximum photovoltaic power generation power at time t; Formula (18) is the power balance constraint, where is the total load of the residential area at time t; the three items on the left side provide power, and the three items on the right side consume power. At any time, both sides of the equation are equal and the power remains balanced; Step S32, the objective function of the second stage is shown in formula (19): are the total electricity purchase cost and photovoltaic power generation cost at time t respectively; (20)-(21) are the algorithms, k PV are the grid time-of-use electricity price and photovoltaic power generation cost, are the purchased electricity power and photovoltaic power generation power at time t respectively; The constraints for the second stage are as follows: The constraints of the second stage include all the constraints of the first stage. To calculate the objective function of the first stage, the optimization result of the first stage must be ensured first; Step S33, the objective function of the third stage is as follows: In the formula To optimize the dispatch period, the purchased power is aggregated The average value of The constraints for the third phase are as follows: In the formula is the calculated objective function of the second stage.

2. The method for optimizing energy scheduling in residential areas under power outage scenarios according to claim 1 is characterized in that: The step S1 specifically includes: S11. Determine the state of the power grid, including the economic dispatch state, active defense state, and load recovery state; The economic dispatch state is the state that the power grid is in for a long time when it is working normally. If the power grid has no power outage risk, it is always in the economic dispatch state. If the power grid has a power outage risk, When , the power grid is in the economic dispatch state; The active defense state is a transitional stage between economic dispatch and load recovery. If there is a risk of power outage in the power grid, When , the power grid is in active defense state; In the load recovery state, the main grid no longer provides electricity to the residential area. In order to keep the important loads working, the residential area uses the energy storage of batteries in electric vehicles and battery swap stations and possible photovoltaic output to meet its own electricity needs as much as possible in the event of a power outage. When , the power grid is in load recovery state; S12. When the residential area and its surrounding power exchange stations are in active defense mode, the duration of the optimization cycle is selected as follows: The optimization period is the time between the current time and the start time of the power outage. If the power outage time is fixed, the optimization period in the active defense stage will gradually decrease as time goes by, indicating that the power outage event is gradually approaching; S13. After determining that the power grid is in the active defense stage, an energy scheduling optimization method is used to control the charging power of batteries of electric vehicles in residential areas and nearby battery swap stations, and consider the electricity cost and the peak-to-valley difference of electricity load, so as to accumulate as much electric energy as possible in a short period of active defense to restore the load during power outages.

3. The method for optimizing energy scheduling in residential areas under power outage scenarios according to claim 1 is characterized in that: The step S2 specifically includes: S21. If the time period is the first time period for optimization, data of the residential area and its surrounding battery swap stations are collected; if the time period before the time period has been optimized and the optimization results have been executed, the relevant data is updated according to the results of the previous optimization; The data collected or updated include the number of electric vehicles, battery capacity and SOC in the residential area at the beginning of the period, and the number, capacity and SOC of batteries in the battery swap station; Step S22, predict and obtain the relevant data required by the model within the optimization period, the required prediction data are as follows: the entry and exit of electric vehicles in the residential area, the load curve of the residential area, the load classification of the residential area, the photovoltaic output of the residential area, and the battery replacement demand of the battery replacement station.

4. The method for optimizing energy dispatch in residential areas under power outage scenarios according to claim 1 is characterized in that: The step S4 specifically includes: Step S41, solving the real-time optimization model, solving the optimization model established in step 3 by using Matlab, Yalmip and Gurobi; Step S42: According to the model solution results, the charging and discharging behaviors of electric vehicles in the residential area, the utilization of photovoltaic power in the residential area, and the charging and discharging behaviors of batteries in the battery swap station are regulated; Step S43: At the end of the time period, collect the number of electric vehicles, battery capacity and SOC in the residential area; as well as the number, capacity and SOC data of batteries in the battery swap station.

Citation Information

Patent Citations

  • Micro grid daily ahead economy optimal dispatch method based on islanding partition

    CN105117797A

  • Joint optimization scheduling method, system, equipment and medium

    CN116316607A