Method and system for optimal control of electrical energy of building energy system based on limited adaptive dynamic programming
By establishing linear iterative matrix equations and self-learning optimization control based on finite adaptive dynamic programming, the problem of existing technologies being unable to optimize discrete state space building energy systems is solved, and more efficient power optimization control is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- INST OF AUTOMATION CHINESE ACAD OF SCI
- Filing Date
- 2025-09-25
- Publication Date
- 2026-04-17
AI Technical Summary
Existing adaptive dynamic programming methods cannot effectively optimize the power control of building energy systems with discrete state spaces.
A finite adaptive dynamic programming approach is adopted to calculate the optimal control scheme for the building energy system in discrete state space by establishing linear iterative matrix equations and self-learning optimization control. This includes the battery system model and load balance equations, and the design of the optimal control sequence to minimize the performance index function.
This expands the application scope of adaptive dynamic programming, enables optimized control of discrete state space building energy systems, and improves the efficiency of power utilization.
Smart Images

Figure CN121216544B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of energy utilization technology and relates to a method and system for optimizing the control of electrical energy in building energy systems based on finite adaptive dynamic programming. Background Technology
[0002] Rapid economic and social development has driven the continuous growth of global energy consumption, making energy conservation, emission reduction, and green, low-carbon development a focus of attention for countries worldwide. Therefore, efficient use of building energy is crucial for achieving energy conservation. Against this backdrop, developing building energy-saving technologies is urgently needed.
[0003] Existing adaptive dynamic programming-based methods for building energy system power optimization control mostly address power optimization and management problems in continuous state spaces. However, real-world building energy systems exist with discrete state spaces, for which traditional adaptive dynamic programming methods cannot achieve optimal control. Summary of the Invention
[0004] To address the aforementioned problems, this invention proposes a power optimization control method and system for building energy systems based on finite adaptive dynamic programming. The aim is to provide a power optimization control method applicable to building energy systems with discrete state spaces, and the research problem broadens the application scope of adaptive dynamic programming theory.
[0005] The technical solution of this invention includes:
[0006] A method for optimizing the control of electrical energy in a building energy system based on finite adaptive dynamic programming includes the following steps:
[0007] S110, Establish a building energy system electricity optimization and management model, including:
[0008] The battery system model is as follows:
[0009] (1)
[0010] In the formula, Indicates the battery's time The amount of electricity, measured in kWh. The charging and discharging power of the battery, measured in kW. For the battery's charge and discharge efficiency; , and These represent battery discharge, charging, and idle states, respectively.
[0011] For building energy systems, the load balance equation is as follows:
[0012] (5)
[0013] In the formula, Indicates the electrical energy required by the load. Electrical energy comes from the power grid;
[0014] Define the state variable as , Is the system in time state, This is the desired energy storage value of the energy storage device, set as... The control variable is , Is the system in time With control, the nonlinear system equation of the building energy system is obtained as follows:
[0015] (6)
[0016] The performance index function is:
[0017] (7)
[0018] In the formula, This represents the decision value, where n is the operating time of the building's energy system. It is the building energy system at the initial time and initial state The performance index function below;
[0019] S120 executes building energy system optimization control based on the building energy system power optimization management model.
[0020] A building energy system power optimization control system based on finite adaptive dynamic programming, comprising:
[0021] The model building module is used to build a building energy system power optimization and management model, including:
[0022] The battery system model is as follows:
[0023] (1)
[0024] In the formula, Indicates the battery's time The amount of electricity, measured in kWh. The charging and discharging power of the battery, measured in kW. For the battery's charge and discharge efficiency; , and These represent battery discharge, charging, and idle states, respectively.
[0025] For building energy systems, the load balance equation is as follows:
[0026] (5)
[0027] In the formula, Indicates the electrical energy required by the load. Electrical energy comes from the power grid;
[0028] Define the state variable as , Is the system in time state, This is the desired energy storage value of the energy storage device, set as... The control variable is , Is the system in time With control, the nonlinear system equation of the building energy system is obtained as follows:
[0029] (6)
[0030] The performance index function is:
[0031] (7)
[0032] In the formula, This represents the decision value, where n is the operating time of the building's energy system. It is the building energy system at the initial time and initial state The performance index function below;
[0033] The execution module is used to perform optimal control of the building energy system based on the building energy system power optimization and management model.
[0034] A computing device includes: at least one processor and a memory storing program instructions; when the program instructions are read and executed by the processor, the computing device performs the building energy system power optimization control method based on finite adaptive dynamic programming.
[0035] A readable storage medium storing program instructions, which, when read and executed by a computing device, cause the computing device to perform the power optimization control method for a building energy system based on finite adaptive dynamic programming.
[0036] A computer program product includes a computer program that, when executed by a processor, implements the aforementioned energy optimization control method for building energy systems based on finite adaptive dynamic programming.
[0037] Beneficial effects:
[0038] This invention proposes an optimized control method for building energy systems, making it applicable to power optimization scenarios with discrete state spaces. Compared to existing optimization control methods based on adaptive dynamic programming, this invention broadens the application scope of the algorithm and achieves better optimization results. Attached Figure Description
[0039] Figure 1 A schematic diagram of the building's energy system is shown.
[0040] Figure 2 A schematic diagram showing the division of the building's energy system is provided. Detailed Implementation
[0041] Exemplary embodiments of the present disclosure will now be described in more detail with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be implemented in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
[0042] This invention designs a novel power optimization control method for building energy systems based on finite adaptive dynamic programming. Unlike existing self-learning optimization control methods, it innovates in the following aspects: it establishes linear iterative matrix equations to calculate the value functions of each subsystem; and it proposes a self-learning optimization control method to obtain a power optimization control scheme for building energy systems in discrete state space.
[0043] Figure 1 A schematic diagram of the building's energy system is shown. (For example...) Figure 1 As shown, the system includes a power grid, an energy management unit, loads (lights, televisions, etc.), and batteries (for storing and releasing electrical energy). The power grid provides electricity to the building's energy system. The batteries can be charged from the power grid through the energy management unit and can release electrical energy to supply the loads. The loads can use electrical energy from the power grid or the batteries. The flow of electrical energy is shown by the arrows.
[0044] The present invention provides a method for optimizing the power control of building energy systems based on finite adaptive dynamic programming, comprising the following steps:
[0045] S110, Establish a building energy system electricity optimization and management model, including:
[0046] The battery system model is as follows:
[0047] (1)
[0048] In the formula, Indicates the battery's time The amount of electricity, measured in kWh. The charging and discharging power of the battery, measured in kW. This refers to the battery's charge and discharge efficiency. , and These represent battery discharge, charging, and idle, respectively.
[0049] The charge / discharge efficiency of a battery can be expressed as:
[0050] (2)
[0051] In the formula This refers to the battery's rated output power.
[0052] In practice, the energy storage and charge / discharge power of a battery are constrained within certain ranges to avoid excessive charging and discharging affecting battery life. Therefore, the following constraints need to be considered for batteries:
[0053] (3)
[0054] (4)
[0055] In the formula, and These are the maximum and minimum battery capacity storage values, respectively. and This refers to the battery's maximum and minimum charge / discharge power.
[0056] For building energy systems, all energy supplied by the grid and batteries must meet the load demand, and the load balance equation can be given as follows:
[0057] (5)
[0058] In the formula, Indicates the electrical energy required by the load. It is electrical energy from the power grid.
[0059] Define the state variable as , Is the system in time state, This is the desired energy storage value of the energy storage device, set as... , and The maximum and minimum battery capacities are stored separately, and the control variables are... , Is the system in time With proper control, the nonlinear system equations of the building energy system can be obtained as follows:
[0060] (6)
[0061] The performance index function can be written as:
[0062] (7)
[0063] In the formula, This represents the decision value, where n is the operating time of the building's energy system. It is the building energy system at the initial time and initial state The performance index function below.
[0064] For building energy systems, the research objective is to design the optimal control sequence for the building energy system. Minimize the performance metric function (7).
[0065] S120, Execute building energy system optimization control based on the building energy system power optimization management model. This process may include:
[0066] S120-1, Symbol Definition and Algorithm Preparation:
[0067] Define symbols , Let be the set of nonnegative real numbers. , , , For the system shown in formula (6), the state set can be defined as follows: In the formula and These represent the initial state, the final state, and the intermediate state, respectively. The control set is defined as follows: The set of decision values is .make Given the initial state, it is known that .for and ,make To make control decisions for a system state At this point, the system reaches the state. At the same time, a decision value can be obtained. Symbols can be used. A building energy system can be represented as a triplet. .
[0068] Define the set of states The optimal performance index function is .for We can obtain:
[0069] (8)
[0070] In the formula:
[0071] ,
[0072] According to the optimality criterion, for The following Bellman equation can be obtained:
[0073] (9)
[0074] In the formula:
[0075] (10)
[0076] S120-2, Establish the linear iterative matrix equation:
[0077] First, choose A set of states The system can Divided into Subsystem .definition and It can be known that the subsystem The set of states is The control set is The set of decision values is According to the partitioning criteria, subsystems can be divided into... Divided into Part For subsystems Its set of states can be represented as .for intermediate state set It consists of two parts: (1) Starting from the set of intermediate states, define It can be controlled Set of Termination States (2) Starting from the set of intermediate states, define It cannot be controlled Set of Termination States The state. Based on the above definition, the system partitioning criteria can be given as follows:
[0078] I) ;
[0079] II) For State set include By controlling All reachable states, and Controllable Reaching these states.
[0080] definition Subsystem The set of states can be written as:
[0081] (11)
[0082] In the formula , , , .
[0083] Define subsystem The control set is The set of decision values is Define subsystems The value function is .for State set The value function can be written as We can obtain:
[0084] (12)
[0085] By repeating the above process, we can obtain:
[0086] (13)
[0087] In the formula, and This is a suitable coefficient matrix. For ease of representation, we will... Represented as We can obtain:
[0088] (14)
[0089] In the formula, for The The right side of equation (14) is expressed as follows: We can obtain:
[0090] (15)
[0091] At this time, for According to (15), the linear iterative matrix equation can be obtained as follows:
[0092] (16)
[0093] In the formula:
[0094] (17)
[0095] S120-3, Optimal Control of Building Energy Systems Based on Finite Adaptive Dynamic Programming:
[0096] First, initialize the algorithm, let In the formula For all elements The appropriate dimension column vector. According to equations (16) and (17), the subsystem can be obtained. Value function .
[0097] for For subsystems Set the termination state set The value function is:
[0098] (18)
[0099] (19)
[0100] In the formula, , At this time, the subsystem Value function It can be calculated using equations (16) and (17). For Set up subsystem Termination State Set The value function is:
[0101] (20)
[0102] (twenty one)
[0103] in, At this time, the subsystem Value function It can be calculated using equations (16) and (17).
[0104] Repeat formulas (18)-(21) until... It converges to a stable value. We can obtain:
[0105] (twenty two)
[0106] In S120-3, the criteria for convergence to a stable value include: each subsystem The value function changes with the number of iterations The increase remains unchanged, that is .
[0107] The objective of the above optimization control is to minimize the performance index function. .
[0108] Based on the above analysis, a self-learning optimization control algorithm for building energy systems based on finite adaptive dynamic programming can be given, as shown in Algorithm 1.
[0109] Algorithm 1: Optimal control algorithm for building energy systems based on finite adaptive dynamic programming:
[0110] initialization:
[0111] Given system ;
[0112] Iteration:
[0113] 1: System Divided into Subsystems;
[0114] 2: Order Assignment function ;
[0115] 3: Calculate the value function according to equations (16) and (17). ;
[0116] 4: Order Assign value functions according to equations (18)-(21) According to equations (16) and (17), the value function is calculated. ;
[0117] 5: If Proceed to the next step; otherwise, return to step 4.
[0118] 6: Return .
[0119] The effectiveness of the building energy system optimization control algorithm based on finite adaptive dynamic programming proposed in this invention is verified through experiments below.
[0120] Building energy systems Divide into subsystems ,like Figure 2 As shown. The initialization algorithm is as follows:
[0121] ,
[0122] Iterative value function It can be calculated according to equations (16) and (17). For Subsystem and The iterative value function for the termination state can be assigned the following values:
[0123] ,
[0124] at this time, It can be calculated according to equations (16) and (17). Subsystem and The iterative value function for the termination state can be assigned the following values:
[0125] ,
[0126] at this time, It can be calculated according to equations (16) and (17).
[0127] Repeating the above process, we can obtain It converges to a stable value.
[0128] The present invention also provides a building energy system power optimization control system based on finite adaptive dynamic programming, comprising:
[0129] The model building module is used to build an energy optimization and control model for building energy systems. Please refer to the detailed description of the above implementation method for the model built by this module.
[0130] The execution module is used to perform optimal control of the building energy system based on the building energy system power optimization and management model.
[0131] The present invention also provides a computing device, comprising: at least one processor and a memory storing program instructions; when the program instructions are read and executed by the processor, the computing device performs the building energy system power optimization control method based on finite adaptive dynamic programming as described above.
[0132] A readable storage medium storing program instructions, which, when read and executed by a computing device, cause the computing device to perform the power optimization control method for a building energy system based on finite adaptive dynamic programming as described above.
[0133] A computer program product includes a computer program that, when executed by a processor, implements the power optimization control method for a building energy system based on finite adaptive dynamic programming as described above.
[0134] Numerous specific details are set forth in the specification provided herein. However, it will be understood that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures, and techniques have not been shown in detail so as not to obscure the understanding of this specification.
[0135] Although the invention has been described with respect to a limited number of embodiments, those skilled in the art will understand from the foregoing description that other embodiments are conceivable within the scope of the invention described herein. Furthermore, it should be noted that the language used in this specification has been chosen primarily for readability and instructional purposes, and not for the purpose of explaining or limiting the subject matter of the invention.
Claims
1. A method for building energy system power optimization control based on limited adaptive dynamic programming, characterized in that, Includes the following steps: S110, Establish a building energy system electricity optimization and management model, including: The battery system model is as follows: (1) In the formula, Indicates the battery's time The amount of electricity, measured in kWh. The charging and discharging power of the battery, measured in kW. For the battery's charge and discharge efficiency; , and These represent battery discharge, charging, and idle states, respectively. For building energy systems, the load balance equation is as follows: (5) wherein represents the required electrical energy to be supplied, is the electrical energy from the grid; Define the state variable as , Is the system in time state, This is the desired energy storage value of the energy storage device, set as... , and These are the maximum and minimum battery capacity storage values, respectively; the control variable is... , Is the system in time With control, the nonlinear system equation of the building energy system is obtained as follows: (6) The performance index function is: (7) In the formula, denotes the decision value, n is the time of building energy system operation, is the performance index function of the building energy system at the initial time and the initial state . S120 executes building energy system optimization control based on the building energy system power optimization management model; S120 includes: S120-1, Symbol Definition and Algorithm Preparation: Define symbols , Let be the set of nonnegative real numbers. , , , For the system shown in equation (6), the state set is defined as follows: In the formula and Represent the initial state, the final state, and the intermediate state, respectively; define the control set as... The set of decision values is ;make Given an initial state, we know ;for and ,make To make control decisions for a system state At this point, the system reaches the state. At the same time, a decision value is obtained. ; use symbols To represent a building energy system, write it as a triplet. ; Definition of the set of states The optimal performance index function is ; for , we obtain: (8) In the formula: , According to the optimality criterion, for The Bellman equation is obtained as follows: (9) In the formula: (10) S120-2, Establish the linear iterative matrix equation; First, choose A set of states , will system Divided into Subsystem ;definition and Subsystem The set of states is The control set is The set of decision values is According to the partitioning criteria, the subsystems are divided into subsystems. Divided into Part For subsystems Its set of states is represented as ;for intermediate state set It consists of two parts: a) Starting from the set of intermediate states, defining... In order to control Set of Termination States b. Starting from the set of intermediate states, define It cannot be controlled Set of Termination States The state; Definitions , subsystem The set of states of the subsystem is written as: (11) In the formulae, , , , ; Define subsystem The control set is The set of decision values is Define subsystem The value function is ,for State set The value function is written as ;get: (12) Repeat the above process to obtain: (13) where and are suitable coefficient matrices; and is expressed as resulting in: (14) wherein is the first column; and expressing the right side of equation (14) as , we obtain: (15) At this time, for , the linear iterative matrix equation is obtained according to formula (15) as follows: (16) In the formula: (17) S120-3, Optimal Control of Building Energy Systems Based on Finite Adaptive Dynamic Programming: First, initialize the algorithm, let In the formula For all elements The appropriate dimension column vector; according to equations (16) and (17), the subsystem is obtained. Value function ; for For subsystems Set the termination state set The value function is: (18) (19) In the formula, , At this time, the subsystem Value function Calculated from equations (16) and (17); for Set up subsystem Termination State Set The value function is: (20) (21) in, At this time, the subsystem Value function It is obtained by calculation from equations (16) and (17); Repeat steps (18) - (21) until Converge to a stable value, yielding: (22)。 2. The method of claim 1, wherein, The charge / discharge efficiency of a battery is expressed as: (2) In the formula, P is the rated output power of the battery; For the battery, consider the following constraints: (3) (4) wherein, and are the maximum and minimum power storage of the battery, respectively, and are the maximum and minimum charge and discharge power of the battery.
3. The method of claim 1, wherein, In S120-2, the system Divided into The criteria for dividing a subsystem include: I) ; II) For State set include By controlling All reachable states, and Controllable Reaching these states.
4. The energy optimization control method for building energy systems based on finite adaptive dynamic programming according to claim 1, characterized in that, In S120-3, the criterion for judging convergence to a stable value includes: the value function of each subsystem remains unchanged with the increase of the number of iterations , i.e. .
5. The method of claim 1, wherein, The objective of the optimization control is to minimize a performance index function .
6. A building energy system electric energy optimal control system based on limited adaptive dynamic programming, characterized in that, include: The model building module is used to build a building energy system power optimization and management model, including: The battery system model is as follows: (1) In the formula, Indicates the battery's time The amount of electricity, measured in kWh. The charging and discharging power of the battery, measured in kW. For the battery's charge and discharge efficiency; , and These represent battery discharge, charging, and idle states, respectively. For building energy systems, the load balance equation is as follows: (5) wherein represents the required electrical energy to be supplied, is the electrical energy from the grid; Define the state variable as , Is the system in time state, This is the desired energy storage value of the energy storage device, set as... , and The maximum and minimum battery capacities are stored separately, and the control variables are... , Is the system in time With control, the nonlinear system equation of the building energy system is obtained as follows: (6) The performance index function is: (7) wherein denotes the decision value, n is the time of operation of the building energy system, is the performance index function of the building energy system at the initial time and initial state . The execution module is used to perform optimal control of the building energy system based on the building energy system power optimization and management model, including: S120-1, Symbol Definition and Algorithm Preparation: Define symbols , Let be the set of nonnegative real numbers. , , , For the system shown in equation (6), the state set is defined as follows: In the formula and Represent the initial state, the final state, and the intermediate state, respectively; define the control set as... The set of decision values is ;make Given an initial state, we know ;for and ,make To make control decisions for a system state At this point, the system reaches the state. At the same time, a decision value is obtained. ; use symbols To represent a building energy system, write it as a triplet. ; Definition of the set of states The optimal performance index function is ; for , we obtain: (8) In the formula: , According to the optimality criterion, for The Bellman equation is obtained as follows: (9) In the formula: (10) S120-2, Establish the linear iterative matrix equation; First, choose A set of states , will system Divided into Subsystem ;definition and Subsystem The set of states is The control set is The set of decision values is According to the partitioning criteria, the subsystems are divided into subsystems. Divided into Part For subsystems Its set of states is represented as ;for intermediate state set It consists of two parts: a) Starting from the set of intermediate states, defining... In order to control Set of Termination States b. Starting from the set of intermediate states, define It cannot be controlled Set of Termination States The state; Definitions , subsystem The set of states of the subsystem is written as: (11) In the formulae, , , , ; Define subsystem The control set is The set of decision values is Define subsystem The value function is ,for State set The value function is written as ;get: (12) Repeat the above process to obtain: (13) where and are suitable coefficient matrices; and is expressed as , resulting in: (14) wherein is the first column; the right side of equation (14) is expressed as , which gives (15) At this time, for , the linear iterative matrix equation is obtained according to formula (15) as follows: (16) In the formula: (17) S120-3, Optimal Control of Building Energy Systems Based on Finite Adaptive Dynamic Programming: First, initialize the algorithm, let In the formula For all elements The appropriate dimension column vector; according to equations (16) and (17), the subsystem is obtained. Value function ; for For subsystems Set the termination state set The value function is: (18) (19) In the formula, , At this time, the subsystem Value function Calculated from equations (16) and (17); for Set up subsystem Termination State Set The value function is: (20) (21) in, At this time, the subsystem Value function It is obtained by calculation from equations (16) and (17); Repeat steps (18) - (21) until Converge to a stable value, yielding: (22)。 7. A computing device, comprising: include: At least one processor and a memory storing program instructions; When the program instructions are read and executed by the processor, the computing device performs the building energy system power optimization control method based on finite adaptive dynamic programming as described in any one of claims 1-5.
8. A readable storage medium storing program instructions, characterized in that, When the program instructions are read and executed by the computing device, the computing device performs the building energy system power optimization control method based on finite adaptive dynamic programming as described in any one of claims 1-5.
9. A computer program product comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the power optimization control method for building energy systems based on finite adaptive dynamic programming as described in any one of claims 1-5.
Citation Information
Patent Citations
Building integrated energy system optimization method based on deep reinforcement learning
CN118381729A
Optimization and adjustment method, device and equipment for building flexible energy consumption and storage medium
CN118674233A