A multi-element flexible resource-oriented building direct-current power distribution system flexible capacity dynamic evaluation method
By constructing a token passing synchronous communication network based on the RS485 physical layer and adaptive voltage partition droop control, combined with distributed consensus iteration and centralized optimization control, the problems of insufficient heterogeneous communication, droop control and protection coordination in the flexible capability assessment of building DC power distribution systems are solved, and efficient flexible capability assessment and prediction are achieved.
Patent Information
- Application Number
- CN202610834779.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-10
- Publication Date
- 2026-08-25
AI Technical Summary
Existing methods for assessing the flexibility of building DC power distribution systems struggle to achieve efficient and flexible capability assessments when faced with challenges such as heterogeneous communication protocols, insufficient coordination between droop control and protection, difficulties in aggregating discrete resources, lack of voltage reference value optimization in prediction models, and absence of multi-timescale collaborative protection.
A token passing synchronous communication network based on the RS485 physical layer is constructed. By combining adaptive voltage partition droop control, distributed consistency iteration and centralized optimization control, the adjustable up and down capacity of each node is synchronized through the token passing protocol. The dynamic evaluation and closed-loop correction of the network's flexibility are realized by using Metropolis weight iteration and mixed integer prediction model.
It solves the problems of large delays in heterogeneous communication, the impact of single-point failures on the whole system, interference protection actions of droop control, difficulty in aggregating discrete resources, and lack of multi-timescale collaborative protection. It achieves second-level flexibility assessment and minute-level flexibility prediction, thereby improving the system's flexibility response capability and stability.
Smart Images

Figure CN122638982A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the technical field of building DC power distribution systems, specifically relating to a dynamic evaluation method for the flexibility capability of building DC power distribution systems oriented towards diverse flexible resources. Background Technology
[0002] Building DC power distribution systems are gradually becoming an important development direction for building energy systems due to their advantages such as high efficiency, flexibility, and ease of access to renewable energy and energy storage devices. In this type of system, various types of flexible resources are usually connected to the DC bus, including energy storage units, photovoltaic power generation units, continuously adjustable loads (such as variable frequency air conditioners and dimmable LED lighting), and loads that only support switching or step-by-step adjustment (such as fixed frequency fans and switchable lighting).
[0003] To achieve flexible interaction between the system and the power grid, it is necessary to dynamically assess the overall network flexibility (i.e., the ability to increase and decrease power). Existing methods for assessing the flexibility of building DC distribution systems have the following shortcomings: First, centralized polling-based communication methods are difficult to adapt to heterogeneous protocols such as Modbus, CAN, and KNX. With an increase in nodes, synchronization delays are large, and single-point failures affect the entire system. Second, traditional droop control does not consider the timing coordination with protection devices under large disturbances; output power regulation during sudden voltage changes may interfere with the selective operation of circuit breakers. Furthermore, capacity jumps in switch-type or tap-type resources make distributed consensus iteration convergence difficult, lacking engineering-applicable convergence criteria. Additionally, rolling optimization models typically ignore discrete tap resources and fix the voltage reference value to the rated value, failing to achieve closed-loop correction to improve flexibility by shifting the droop interval. Summary of the Invention
[0004] The purpose of this invention is to provide a dynamic evaluation method for the flexibility of building DC power distribution systems oriented towards diverse flexible resources, in order to solve problems in the existing technology such as resource heterogeneity, inconsistent communication protocols, insufficient coordination between droop control and protection, difficulty in aggregating discrete resources, lack of voltage reference value optimization in prediction models, and lack of multi-timescale collaborative protection.
[0005] The objective of this invention can be achieved through the following technical solutions: This application provides a method for dynamically evaluating the flexibility of a building DC power distribution system oriented towards diverse flexible resources, the specific steps of which include: S1. During system initialization, network scale parameters are obtained, and a token passing synchronous communication network based on the serial communication physical layer is constructed. The converter controller or edge agent gateway corresponding to the multiple flexible resources connected to the DC bus is used as a node to periodically broadcast the local adjustable capacity and adjustable capacity through the token passing protocol. S2. Each node detects the local DC bus voltage and performs adaptive voltage partition droop control within five voltage ranges preset with the current reference voltage as the center and a fixed difference. Combined with the highest priority voltage change rate transient blocking logic, the local adjustable capacity and adjustable capacity of each flexible resource are calculated. S3. Each node takes the local adjustable capacity and adjustable capacity as the initial state, uses the neighbor data synchronized by the token passing protocol, performs distributed consensus iteration based on Metropolis weights, multiplies the converged state variables with the network size parameters to obtain the estimated values of the total network power adjustment capability and total power reduction capability, and outputs the second-level dynamic flexibility capability assessment results. S4. The centralized optimization controller receives the second-level dynamic flexibility capability assessment result as feedback, constructs a system aggregated mixed integer prediction model containing continuous state variables and discrete gear variables, and performs rolling optimization in the prediction time domain with the goal of maximizing the weighted sum of the power adjustment capability and the power reduction capability, and suppressing the voltage reference value from deviating from the rated value. The optimal DC bus voltage reference value and the timing boundaries of the power adjustment capability and the power reduction capability for multiple future control cycles are obtained as the minute-level dynamic flexibility capability assessment result. S5. The centralized optimization controller sends the optimal DC bus voltage reference value to each node. Each node shifts all thresholds of the voltage partition according to the fixed difference to complete the closed-loop correction. When the system suffers a large disturbance, a three-layer collaborative protection is formed by physical layer voltage change rate blocking, distribution layer aggregate value returning to zero, and centralized layer pausing measurement updates.
[0006] Preferably, in the token passing synchronous communication network described in step S1, the fixed time slot length is preset based on the RS485 bus baud rate and the maximum message length; the token is passed cyclically according to the node address order; if a node does not receive a valid token frame within two consecutive time slots, it actively initiates a token request frame, and the active node with the smallest address regenerates the token; the network size parameter is the total number of global nodes, which is broadcast by the centralized optimization controller through the RS485 bus configuration frame, and each node simultaneously runs a consensus algorithm with a constant of 1 to estimate the number of active nodes as a verification.
[0007] Preferably, the fixed difference in step S2 includes a first fixed difference and a second fixed difference, wherein the first fixed difference is greater than the second fixed difference; the five voltage ranges from low to high are: emergency low voltage range, drooping low voltage range, normal range, drooping high voltage range, and emergency high voltage range, wherein the emergency low voltage range and the emergency high voltage range are defined by the first fixed difference, the drooping low voltage range and the drooping high voltage range are defined by the second fixed difference, and the normal range is symmetrically defined by the second fixed difference.
[0008] Preferably, the voltage change rate transient blocking logic in step S2 is as follows: the absolute value of the voltage change rate is calculated using the multi-sampling point differential method in each control cycle. When the absolute value exceeds the preset transient threshold, the blocking flag is set, the local adjustable capacity and adjustable capacity are forcibly set to zero, and the droop power regulation output is blocked. The blocking release condition is that the absolute value of the voltage change rate falls back below the preset transient threshold and is maintained for a preset number of control cycles. The preset transient threshold is determined jointly based on the system short-circuit capacity and the protection device operation time.
[0009] As a preferred option, the maximum available gear mapping method in step S2 is as follows: For flexible resources with a finite number of discrete operating gears, a dynamic prediction model of the power and comfort state of each gear is established. The current comfort dead zone is used as a constraint to traverse all switchable gears and predict whether the comfort state will remain within the dead zone in a certain period of time after switching. The difference between the maximum achievable power and the current power is taken as the adjustable capacity, and the difference between the current power and the minimum achievable power is taken as the adjustable capacity. A switching life constraint is introduced that the number of switching times per unit time does not exceed a preset upper limit.
[0010] Preferably, in the distributed consensus iteration based on Metropolis weights described in step S3, the set of neighbor nodes is determined by the fully connected logic of the token passing protocol to include all other nodes in the network except itself; weights ,in They are nodes , The degree of a node in a fully connected topology is equal to the total number of nodes in the world minus one; its own weight. The iterative convergence criterion is that the maximum absolute value of the difference between the current state and the previous state of all nodes is less than the preset convergence error threshold and the iteration continues for a preset number of times.
[0011] Preferably, in step S3, the estimated values of the total power up-adjustment capability and total power down-adjustment capability of the entire network obtained after convergence are subjected to moving average filtering. The time constant of the moving average filtering is set to the second level, and the length of the filtering window is determined according to the token cycle period, so that the filtering time constant is approximately the second level. The filtering only applies to the final estimated value output to the centralized optimization controller and does not participate in the internal calculation of the consistency iteration.
[0012] Preferably, in step S4, the state variables of the system aggregated mixed integer prediction model include the state of charge of the energy storage unit and the indoor temperature characterizing the thermodynamic state of the building's virtual energy storage. The input variables include the power regulation amount of continuous resources and the discrete power values corresponding to each level of switchable or tiered resources. The level switching constraints are described by binary logic variables. The state update equation adopts a first-order or second-order thermodynamic model. The objective function consists of three weighted terms: the first term is the negative value of the sum of the power adjustment capabilities in the prediction time domain multiplied by a first weight coefficient; the second term is the negative value of the sum of the power adjustment capabilities multiplied by a second weight coefficient; and the third term is the square of the difference between the voltage reference value and the rated voltage multiplied by a penalty coefficient. The DC bus voltage reference value is used as an independent optimization variable and is limited to a preset allowable adjustment range.
[0013] As a preferred embodiment, the specific timing sequence of the three-layer collaborative protection in step S5 is as follows: when a large disturbance occurs, the physical layer sets the local flexible capacity to zero through voltage change rate blocking within milliseconds; the distributed aggregation layer converges to zero through consistency iteration within seconds until the total up-adjustment power capacity and total down-adjustment power capacity of the entire network are both zero; when the centralized optimization layer detects that the aggregation value is zero and accompanied by voltage over-limit signals in multiple consecutive control cycles, it determines that the system is in a fault or recovery transition process, suspends the measurement update of the state estimator, and continues until the aggregation value returns to normal and there are no over-limit alarms.
[0014] A dynamic evaluation system for the flexibility capability of building DC power distribution systems oriented towards diverse flexible resources includes: The distributed communication network consists of converter controllers and edge agent gateways corresponding to each flexible resource as nodes. It is built through a token passing synchronous communication protocol running on the RS485 physical layer and is used to periodically broadcast the local adjustable capacity and adjustable capacity of each node. The physical response layer controller, built into each converter or proxy gateway, is used to detect the local DC bus voltage and perform adaptive voltage partition droop control, calculate the local adjustable capacity and adjustable capacity of each flexible resource, determine the discrete capacity value by the maximum available range mapping method for switch-type or range-type resources, and perform the highest priority transient blocking when the voltage change rate exceeds the limit. The distributed aggregation layer module runs on each node and is used to aggregate the local adjustable capacity and adjustable capacity into the total adjustable power capacity and total adjustable power capacity of the entire network through distributed consensus iteration. After moving average filtering, it outputs the second-level dynamic flexibility assessment result. A centralized optimization controller is used to receive the second-level dynamic flexibility assessment results, construct a system aggregated mixed integer prediction model and perform rolling optimization to obtain the optimal DC bus voltage reference value and the minute-level dynamic flexibility assessment results, and then send the optimal DC bus voltage reference value to each node to complete the closed-loop correction by shifting the voltage partition threshold.
[0015] The beneficial effects of this invention are as follows: By constructing a token-passing synchronous communication network based on the RS485 physical layer, and utilizing edge proxy gateways as virtual nodes to connect non-consistent communication protocol-based switch-type or tiered resources to a unified broadcast network, the problems of large latency, poor synchronization, and single-point failure affecting the whole system when the number of nodes increases are solved. Token cyclical passing has no central node, avoiding single-point failure; adding nodes only linearly extends the cycle period, and the latency is controllable.
[0016] By setting the highest priority voltage change rate transient blocking logic at the physical response layer, when the voltage change rate exceeds the preset threshold, the local adjustable capacity and adjustable capacity are immediately forced to zero and the droop power regulation output is blocked. The action time is in the millisecond range and much faster than the protection device, which solves the problem of the droop controller output power interfering with the selective operation of the circuit breaker under large disturbances.
[0017] By adopting the maximum available gear mapping method, a dynamic prediction model of the power and comfort state of each gear is established. With the current comfort dead zone as a constraint, all switchable gears are traversed to predict whether the comfort state will remain within the dead zone in the future time period after switching. This determines the actual up-adjustment and down-adjustment capacity that discrete resources can provide, and solves the problem of difficulty in distributed consistency iterative convergence caused by the capacity jump of switch-type or geared resources.
[0018] By constructing a system aggregated mixed integer prediction model containing continuous state variables and discrete range variables in a centralized optimization controller, the DC bus voltage reference value is used as an independent optimization variable. The goal is to maximize the weighted sum of the upward and downward adjustment capabilities and suppress the deviation of the voltage reference value from the rated value through rolling optimization. The optimal voltage reference value is obtained by solving the problem and then distributed to all thresholds of the voltage partition at each node. This solves the closed-loop correction problem of existing models that cannot improve flexibility by shifting the droop range due to the fixed voltage reference value.
[0019] By constructing a three-layer collaborative protection architecture consisting of a physical layer, a distributed aggregation layer, and a centralized optimization layer, and clarifying the recovery timing of each layer, the problem of lacking a cross-timescale collaborative mechanism from instantaneous response to second-level aggregation and then to minute-level estimation protection when large disturbances occur is solved. Attached Figure Description
[0020] To better understand and implement this application, the technical solution is described in detail below with reference to the accompanying drawings.
[0021] Figure 1 The flowchart of a dynamic evaluation method for the flexibility capability of a building DC power distribution system oriented towards multiple flexible resources is provided in Embodiment 1 of this application. Detailed Implementation
[0022] To further illustrate the technical means and effects adopted by the present invention to achieve its intended purpose, exemplary embodiments will be described in detail below, examples of which are illustrated in the accompanying drawings. In the following description, when referring to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application.
[0023] The terminology used in this application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. The singular forms “a,” “the,” and “the” used herein are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to and includes any and all possible combinations of one or more of the associated listed items.
[0024] The following detailed description of the specific implementation methods, features, and effects of the present invention, in conjunction with the accompanying drawings and preferred embodiments, is provided in detail.
[0025] Example 1 Please see Figure 1 This embodiment provides a method for dynamically evaluating the flexibility of a building DC power distribution system oriented towards multiple flexible resources. The building DC power distribution system includes a DC bus, and the multiple flexible resources connected to the bus include: energy storage units, power generation units, at least one continuously adjustable load-type resource, and at least one switchable or tiered adjustable load-type resource. Each flexible resource is connected to the DC bus via a converter or edge proxy gateway. Each converter controller and proxy gateway constitutes a distributed communication node, and a centralized optimization controller communicates with at least one of these nodes. The method includes the following steps: S1. The system initializes and obtains network scale parameters, and constructs a synchronous communication network based on RS485 token passing; After system startup, the centralized optimization controller broadcasts a configuration frame to the entire network via the RS485 bus, distributing the initial value of the total number of global nodes stored locally; each node receives and stores this value. During network operation, the centralized optimization controller detects node offline by monitoring response timeouts during the token polling process: if no data is received from a node for three consecutive complete token cycles, it is determined to be offline, and the updated total number of nodes is rebroadcast. A custom lightweight token passing synchronization communication protocol runs on the RS485 bus: tokens are passed sequentially according to node addresses, and the node holding the token broadcasts its current adjustable capacity and adjustable capacity data within a time slot; the other nodes receive this simultaneously, achieving network-wide data synchronization.
[0026] Each node independently runs a lightweight consensus algorithm for constant 1 in the background (sharing communication data with step S3), estimating the current number of active nodes every ten token cycles. When the estimated value differs from the number of nodes issued by the central controller for two consecutive verification cycles, the node generates an alarm flag and proactively sends a "parameter inconsistency" message to the central optimization controller. Upon receiving such a message from any node, the central controller triggers a network-wide recount process: broadcasting a "reset count" request, all active nodes reply with their own identifiers, and the controller recounts and issues accurate values.
[0027] Data exchange between nodes is achieved through a custom lightweight token-passing synchronous communication protocol running on top of the RS485 physical layer. The specific mechanism is as follows: the system assigns a unique address number (0 to N-1) to each node; tokens are passed cyclically among nodes in address order; within a fixed time slot (e.g., 50 milliseconds), the node holding the token broadcasts its current adjustable capacity and adjustable capacity data. A complete token cycle equals the total number of nodes multiplied by the fixed time slot length. When a new node joins, it sends a "join request" on the bus, and the controller assigns it a new address and broadcasts the updated total number of nodes in the next token cycle.
[0028] By constructing an RS485-based token-passing synchronous communication network, the problems of large communication latency and single-point failure affecting the entire network caused by heterogeneous protocols in the existing centralized polling method are solved. The edge proxy gateway accesses as a virtual node, realizing unified management of inconsistent communication resources, ensuring data synchronization of all nodes in the network, and laying a low-latency, highly reliable communication foundation for subsequent consistency iterations.
[0029] S2. Each node detects the local DC bus voltage and performs adaptive voltage partition droop control within five voltage ranges preset with the current reference voltage as the center and a fixed difference. Combined with the highest priority voltage change rate transient blocking logic, the local adjustable capacity and adjustable capacity of each flexible resource are calculated. For switch-type or segmented resources, the maximum available segment mapping method is used to determine their discrete capacity value. Each node detects its local DC bus voltage at a fixed control cycle (e.g., 10 milliseconds). The voltage zone reference is the current valid reference voltage, with the initial value set to the system rated voltage. Four voltage thresholds are defined by fixed differences from the reference voltage: the first fixed difference is greater than the second fixed difference, for example, the first difference is 20 volts and the second difference is 5 volts. This forms five voltage zones: Emergency Low Voltage Zone (from 0 to the reference voltage minus the first difference), Drooping Low Voltage Zone (from the reference voltage minus the first difference to the reference voltage minus the second difference), Normal Zone (from the reference voltage minus the second difference to the reference voltage plus the second difference), Drooping High Voltage Zone (from the reference voltage plus the second difference to the reference voltage plus the first difference), and Emergency High Voltage Zone (above the reference voltage plus the first difference).
[0030] Sag coefficient Method for determining: For energy storage converters: ,in Rated charge and discharge power, The second difference; For photovoltaic power generation: , This is the current maximum power point power. The second difference; For continuously adjustable air conditioning / lighting: , , The upper and lower limits of equipment output. The second difference; If the resources only support discrete gears, then no droop coefficient is needed, and its adjustment is accomplished through the prediction model in step S4.
[0031] Within each control cycle, the following priority order will be followed: First priority: Transient blocking due to large disturbances; Each control cycle uses the voltage difference of three consecutive sampling points divided by the time interval to obtain the absolute value of the voltage change rate. The preset transient threshold is determined jointly based on the system short-circuit capacity and the protection device's operating time: the estimated voltage change amplitude during a short circuit (approximately 1.2 times the rated voltage) is divided by the protection device's operating time (e.g., 50 milliseconds), and then multiplied by a reliability coefficient less than 1. When the absolute value of the voltage change rate exceeds this threshold, the system is determined to be in a fault transient process. At this time, regardless of the current voltage range, the "transient lockout" flag is immediately set, blocking the power regulation output, maintaining the current power command unchanged, and forcibly setting the local adjustable capacity and adjustable capacity of this node to zero. The lockout state continues until the absolute value of the voltage change rate falls below 80% of the threshold and remains continuously for five control cycles (i.e., 50 milliseconds), after which the lockout flag is cleared. This lockout logic has the highest priority across all components, ensuring that the droop controller does not generate any power disturbances that may interfere with the selective operation of the protection device during a fault. Second priority: Voltage droop control during normal operation; If the DC bus voltage is lower than or equal to the droop low voltage zone threshold (i.e., located in the droop low voltage zone or emergency low voltage zone), the system has a power deficit, and resources should increase output or reduce power consumption. The power adjustment amount is the smaller of the following two values: the maximum power that the resource can increase, and the droop factor multiplied by the difference between the droop low voltage zone threshold and the current voltage. If the DC bus voltage is higher than or equal to the droop high voltage zone threshold (i.e., located in the droop high voltage zone), the system has a power surplus, and resources should reduce output or increase charging. The power adjustment amount (negative value) is the smaller of the following two values (with a negative sign): the maximum power that the resource can decrease, and the droop factor multiplied by the difference between the current voltage and the droop high voltage zone threshold.
[0032] Furthermore, after completing and executing the power regulation calculation, the remaining flexible capacity that each resource can provide to the entire network is calculated.
[0033] For continuously adjustable resources, the locally adjustable capacity equals the maximum adjustable power of the resource minus the currently executed power adjustment (positive for upward adjustment). The locally adjustable capacity equals the maximum adjustable power of the resource plus the currently executed power adjustment (negative for downward adjustment). For switchable or graded adjustable resources, the maximum available grade mapping method is adopted. The specific steps are as follows: The resource has a finite number of discrete operating grades (e.g., grades 0, 1, ..., m), each grade corresponding to a defined power consumption or output. First, a dynamic prediction model is established for the power and comfort state variables (e.g., indoor temperature, water temperature) of each grade. The model adopts a simplified first-order inertial form, and the parameters are obtained through offline identification. Using the current comfort dead zone as a constraint, all switchable grades are traversed to predict whether the comfort state will remain within the dead zone for a period of time after switching. If the prediction result meets the comfort requirements, the achievable grade is recorded. The difference between the maximum achievable power and the current power is taken as the adjustable capacity, and the difference between the current power and the minimum achievable power is taken as the adjustable capacity. At the same time, a switch life constraint is introduced: the number of switching times per unit time does not exceed a preset upper limit (e.g., 6 times per hour). If the upper limit is reached in a certain direction, the corresponding capacity is forcibly reset to zero. Priority coordination: Transient blocking has the highest priority, followed by droop control (which only applies to continuously adjustable resources). Discrete resources do not participate in real-time droop adjustment, and their capacity is only used for steps S3 and S4.
[0034] Each node updates its calculated local upscaling and downscaling capacities to the communication interface for use by S3.
[0035] Through adaptive voltage droop control, the system can automatically adjust the power output of each resource according to the DC bus voltage, achieving stable voltage support. The highest priority transient blocking logic blocks the output and sets the capacity to zero within 10ms when a sudden voltage change (such as a short circuit) is detected, solving the problem of selective operation of interference protection devices under large disturbances in traditional droop control. For switch-type and segmented resources, the maximum available segment mapping method accurately quantifies the actual up-adjustment and down-adjustment capacity that discrete resources can provide under current operating conditions through dynamic prediction and comfort dead-zone constraints, avoiding aggregation difficulties caused by capacity jumps.
[0036] S3. Each node takes the local adjustable capacity and adjustable capacity as the initial state, uses the neighbor data synchronized by the token passing protocol, performs distributed consensus iteration based on Metropolis weights, multiplies the converged state variables with the network size parameters to obtain the estimated values of the total network power adjustment capability and total power reduction capability, and outputs the second-level dynamic flexibility capability assessment results after moving average filtering. In the communication network constructed by S1, within each token transmission cycle, each node broadcasts the updated local adjustable capacity and adjustable capacity from S2 to all other nodes in the network via token broadcast. Each node maintains two state variables locally, corresponding to the iterations of adjustable capacity and adjustable capacity, respectively, with their initial values set to their respective local capacity values. After receiving a complete round of broadcasts (i.e., one token cycle, equal to the total number of nodes multiplied by a fixed time slot length), the node performs an iterative update. Taking adjustable capacity as an example, nodes The state variable is updated to: ,in For nodes The set of neighboring nodes, under a fully connected logical topology of the token broadcast protocol, Includes all other nodes in the network except i (the total number of global nodes minus one); weight Determined using Metropolis rules: ;in For nodes In the degree of the communication graph, when fully connected This equals the total number of global nodes minus one. , Convergence criterion: The maximum absolute value of the difference between the current state and the previous state of all nodes is calculated as the residual. Convergence is determined when the residual is less than the preset convergence error threshold (0.01 kW) and remains so for 3 consecutive iterations. Since each token cycle is 450 ms, 3 iterations correspond to approximately 1.35 seconds of physical time. If convergence is not achieved after exceeding the preset maximum number of iterations, the current average value is forcibly taken as the convergence result and an alarm is triggered.
[0037] Since the Metropolis weights satisfy the double random matrix condition, after a sufficient number of iterations, the state variables of all nodes will be... The arithmetic mean of the asymptotically convergent values of all nodes in the network is: Where N is the total number of global nodes; Furthermore, nodes Therefore, the estimated value of the total power upscaling capacity of the entire network is equal to the total number of nodes multiplied by the current upscaling capacity state variable of that node; in the actual system, the average value of the estimates of all nodes can be taken as the final total power upscaling capacity.
[0038] The iterative and aggregation processes for adjustable capacity are fully parallel, with each node maintaining another state variable. Using the same weight matrix and iteration mechanism, they converge synchronously to the estimated value of the total power reduction capability of the entire network.
[0039] To further smooth out transient fluctuations in aggregate values that may be caused by sudden changes in the capacity of switching resources, a moving average filter is applied to the converged estimate. The filter only applies to the final stage of the output to the centralized optimization controller and does not participate in the internal calculations of the consistency iteration. The arithmetic mean of the estimates from the most recent several iterations is calculated, resulting in a filtering time constant of approximately 1 second.
[0040] Through distributed consensus iteration, each node can converge to an unbiased estimate of the total network flexibility within seconds without a central aggregator, avoiding single points of failure. Furthermore, the consensus algorithm automatically verifies network scale parameters when nodes change dynamically. A clear convergence criterion (residual less than a threshold and maintained for a preset number of consecutive iterations) solves the algorithm instability problem caused by ambiguity in convergence conditions in engineering applications. Moving average filtering is applied only to the output, smoothing fluctuations caused by discrete resource switching without affecting the unbiasedness and convergence of the iteration. The second-level evaluation results provide real-time and stable flexibility feedback to the centralized optimization layer.
[0041] S4. The centralized optimization controller receives the second-level dynamic flexibility capability assessment result as feedback, constructs a system aggregated mixed integer prediction model containing continuous state variables and discrete gear variables, and performs rolling optimization in the prediction time domain with the goal of maximizing the weighted sum of the power adjustment capability and the power reduction capability, and suppressing the voltage reference value from deviating from the rated value. The optimal DC bus voltage reference value and the timing boundaries of the power adjustment capability and the power reduction capability for multiple future control cycles are obtained as the minute-level dynamic flexibility capability assessment result. The centralized optimization controller acquires the filtered total up-adjustment power capability and total down-adjustment power capability uploaded from S3 every macro control cycle (e.g., 5 minutes) as feedback on the current system's flexible state and constructs a system aggregate prediction model. Since the system contains both continuously adjustable resources and on / off / tiered resources, the prediction model adopts a hybrid logic dynamic framework, introducing binary logic variables to describe discrete tier states based on the continuous state equations.
[0042] The model's state variables include continuous quantities such as the state of charge of each energy storage unit, the equivalent thermodynamic state of the building's virtual energy storage (e.g., indoor temperature), and the current operating level of the switch-type load; the input variables include energy storage charging power, discharging power, and air conditioning power.
[0043] State update equation:
[0044] in In a charged state, For energy storage capacity, For charging and discharging efficiency, For macro-control cycle, parameters , , Obtained through identification of building thermodynamic properties. This represents the predicted outdoor temperature; for on / off resources such as air conditioners, their power is expressed as... , Let be a binary variable, representing whether it is in the j-th level and satisfies . Gear shifting constraints: , For auxiliary binary variables, and total number of switches .
[0045] Power balance constraints: ,in The direction of flow into the busbar is taken as positive. The method for predicting baseline power is as follows: For predictable loads (such as lighting and conventional sockets), historical average values for the same period are used, combined with meteorological correction factors; for photovoltaics, a short-term irradiance prediction model is used; for air conditioning, the baseline power is defined as the power required to maintain the set temperature, which is inversely derived from the thermodynamic model. In the optimization model, the power up-adjustment capability and power down-adjustment capability are directly defined through constraints:
[0046]
[0047] in As decision variables, , Dynamic boundaries defined for physical and comfort constraints.
[0048] The prediction time domain covers multiple future control cycles (e.g., 12 macro-control cycles corresponding to 60 minutes); at each macro-control moment, the centralized optimization controller solves the following mixed-integer optimization problem, where the DC bus voltage reference value is treated as an independent optimization variable:
[0049] Limited by
[0050] upper and lower limits of power for each resource and logic constraints for discrete gear switching; DC bus power balance equation:
[0051] in , The weighting coefficients for increasing and decreasing power capabilities are respectively, and can be flexibly set according to ancillary service market prices or system operation strategies; This is the penalty factor for the voltage reference value deviating from the rated value; and The allowable adjustment range for the voltage reference value is based on system presets. This is the system's rated voltage; Solution method: A mixed-integer programming solver is used for branch and bound solution, with appropriate MIP gaps and maximum solution time set. If the solution fails or no feasible solution is found, a rollback strategy is implemented: the DC bus voltage reference value is fixed equal to the system rated voltage, discrete gear switching is ignored (keeping the current gear unchanged), only continuous variables are optimized, and a quadratic programming solver is used. If there is still no solution, the control command from the previous cycle remains unchanged, and a warning is issued.
[0052] Specifically, solving this mixed integer programming problem yields outputs at two levels: One is the optimal DC bus voltage reference value for the current control cycle, which is used for closed-loop correction in step five; Secondly, the future The minute-level dynamic flexibility assessment results of the system within each control cycle include: The time series for increasing and decreasing power capacity, as well as the maximum sustainable duration corresponding to each power capacity segment, are determined by the bottleneck moments of each resource constraint.
[0053] The evaluation results directly reflect the upper and lower adjustable power boundaries and their temporal evolution characteristics that the system can continuously provide over a period of time, provided that all safety and comfort constraints are met.
[0054] By employing a mixed-integer prediction model and rolling optimization, the DC bus voltage reference value is treated as an independent optimization variable. The goal is to maximize both upward and downward adjustment capabilities, overcoming the limitation of existing methods that cannot shift the droop range to improve flexibility due to fixed voltage. The objective function uses weighting coefficients α and β to flexibly adapt to different operating scenarios (e.g., emphasizing upward adjustment capability during peak electricity demand), and a penalty term γ suppresses excessive voltage deviation, ensuring voltage quality. Minute-level evaluation results include the time-series boundaries of future power capacity for multiple time periods and the maximum sustainable duration, providing forward-looking information for grid dispatching and demand response. A rollback strategy (first fixing the voltage to optimize continuous variables, then maintaining the previous instruction) ensures stable system operation even in the event of solution failure, enhancing engineering practicality.
[0055] S5. The centralized optimization controller sends the optimal DC bus voltage reference value to each node. Each node shifts all thresholds of the voltage partition according to the fixed difference to complete the closed-loop correction. When the system is subjected to a large disturbance, a three-layer collaborative protection is formed by physical layer voltage change rate blocking, distribution layer aggregate value returning to zero, and centralized layer pausing measurement updates. The centralized optimization controller transmits the optimal DC bus voltage reference value obtained from S4 to all distributed nodes via RS485 broadcast frames; after receiving the new voltage reference value, each node synchronously shifts all four thresholds of the voltage partition according to the fixed difference rule defined in S2: The new emergency low voltage zone threshold is equal to the optimal reference voltage minus the first fixed difference; the new droop low voltage zone threshold is equal to the optimal reference voltage minus the second fixed difference; the new droop high voltage zone threshold is equal to the optimal reference voltage plus the second fixed difference; the new emergency high voltage zone threshold is equal to the optimal reference voltage plus the first fixed difference.
[0056] The centralized optimization controller transmits the optimal DC bus voltage reference value obtained from S4 to all distributed nodes via RS485 broadcast frames. Upon receiving the new voltage reference value, each node synchronously shifts all four thresholds of the voltage zone according to the fixed difference rule defined in S2: the new upper limit of the emergency low voltage zone equals the optimal reference voltage minus the first fixed difference; the new upper limit of the drooping low voltage zone equals the optimal reference voltage minus the second fixed difference; the new lower limit of the drooping high voltage zone equals the optimal reference voltage plus the second fixed difference; and the new lower limit of the emergency high voltage zone equals the optimal reference voltage plus the first fixed difference. The shift takes effect immediately, while the fixed differences themselves remain unchanged.
[0057] When the system suffers major disturbances such as DC bus short circuits or sudden disconnection of large-capacity power supplies, the three-layer architecture provides coordinated protection according to the following timing sequence: The first layer, the physical response layer: When each node detects that the voltage change rate exceeds the transient threshold, the highest priority transient blocking logic takes effect immediately, blocking all drooping power regulation outputs and forcing the local adjustable capacity and local adjustable capacity to zero; the action time is within 10 milliseconds, which is much faster than the action time of the protection device.
[0058] The second layer, the distributed aggregation layer: Since the local flexible capacity of each node is set to zero, the consistency iteration converges to zero after several iterations (usually within 1 second); the second-level evaluation value uploaded to the central controller is then set to zero.
[0059] The third layer, the centralized optimization layer: The centralized controller detects the uploaded aggregated value in each macro control cycle; the "voltage over-limit signal" is generated by the physical layer node when it detects that the DC bus voltage is lower than the emergency low voltage zone threshold or higher than the emergency high voltage zone threshold, and is actively reported via RS485; when the total power adjustment capability and the total power reduction capability are both zero for two consecutive control cycles, and a voltage over-limit alarm flag is received from the physical layer at the same time, the system is determined to be in a fault or fault recovery transition process. At this time, the model predictive control state estimator suspends the use of measured values for state updates and switches to model-based predictive estimation: the estimated value for the next moment is obtained by multiplying the state transition matrix by the estimated value for the previous moment, adding the control matrix by the current control input, and no longer fusing real-time measured values. At the same time, the flexibility assessment result is set to a conservative value of the most recent normal state (e.g., reduced by a preset ratio). When no over-limit alarm is received for several consecutive cycles and the total power adjustment capability is greater than zero or the total power reduction capability is greater than zero, normal measurement updates resume.
[0060] Since the centralized optimization period is much longer than the duration of the disturbance, the centralized optimization layer will not initiate new optimization calculations during the actual disturbance. The aforementioned actions such as "pausing measurement updates" are performed in the first optimization period after the disturbance, based on the judgment and degradation processing according to the event record flags, thereby achieving collaborative protection across time scales.
[0061] Through closed-loop correction, after the optimal voltage reference value of the centralized optimization layer is issued, each node synchronously shifts the droop partition threshold, causing the system operating point to continuously shift towards the optimal flexibility direction: adjusting the voltage reference value upwards enhances the flexibility of downward adjustments (absorbing excess power), and adjusting it downwards enhances the flexibility of upward adjustments (supporting power deficits). The three-layer collaborative protection mechanism achieves multi-timescale coordination from millisecond-level physical blocking and second-level aggregation to minute-level centralized control pause updates: the physical layer ensures protection selectivity, the distribution layer avoids false capacity aggregation, and the centralized layer pauses measurement updates to prevent fault conditions from contaminating state estimates. Automatic recovery occurs layer by layer after disturbance elimination, ensuring the accuracy of flexibility assessment and system stability under all operating conditions.
[0062] Example 2 This embodiment provides a specific application of a dynamic assessment method for the flexibility of a building's DC power distribution system, oriented towards diverse flexible resources, in a commercial office building. The rated voltage of this building's DC power distribution system is ±375V (i.e., the positive terminal of the DC bus is +375V to the neutral point, the negative terminal is -375V, and the inter-bus voltage is 750V). The diverse flexible resources connected to the DC bus include: Energy storage unit: a set of lithium iron phosphate batteries with a rated capacity of 200kWh and a rated charge / discharge power of 50 kW, connected to the bus via a bidirectional DC / DC converter; Photovoltaic power generation unit: rooftop photovoltaic array, peak power 30kWp, connected to the bus via a Boost converter; Continuously adjustable load: Two inverter air conditioners: each with a rated power of 8kW and a continuously adjustable power range of 2~8kW and a set of dimmable LED lighting: total power 0~5kW continuously adjustable; Switch-type / division-type load: Four fixed-frequency fans: each with a power of 0.15 kW, supporting only two on / off speeds; Two-speed electric water heater: power of 0kW / 1.5kW / 3.0kW (three speeds).
[0063] Each flexible resource is connected to the RS485 bus via a converter controller or an edge proxy gateway, with a total of 9 communication nodes (1 energy storage, 1 photovoltaic, 2 air conditioning, 1 lighting, and 4 fans). A centralized optimization controller is provided, which is located in the same cabinet as the edge proxy gateways of the energy storage nodes and is also connected to the RS485 bus.
[0064] The specific process is as follows: After the system powers on, the centralized optimization controller broadcasts a configuration frame at address 0, indicating a total global node count of N=9. Each node stores this parameter. The RS485 bus baud rate is set to 115200 bps, and the fixed timeslot length is set to 50 ms (maximum message size approximately 40 bytes, transmission time approximately 3.5 ms, with ample margin). Tokens are passed cyclically in address order 1-9. A complete token cycle is 9 × 50 ms = 450 ms. During system operation, if a node goes offline (e.g., a fan controller malfunctions), the centralized optimization controller determines it is offline after not receiving data from it for three consecutive complete token cycles and rebroadcasts the updated node count N=8, updating the remaining nodes accordingly. Simultaneously, each node runs a consistency algorithm with a constant of 1 in the background, estimating the current number of active nodes every ten token cycles and comparing it with the issued N value. If they do not match, an alarm is issued.
[0065] Each node monitors its local DC bus voltage every 10 ms. The initial reference voltage is 750 V (rated). A first fixed differential value is set. 20V, second fixed difference If the voltage is 5 V, then the five voltage ranges are: Emergency low voltage zone: [0, 730V) Droop low voltage region: [730 V, 745 V] Normal range: [745V, 755V] Droop high voltage region: (755V, 770V) Emergency High Voltage Zone: (770V, ∞) The droop factor is calculated according to the formula in Example 1. Taking an energy storage converter as an example: rated charge / discharge power 50 kW, =5V, then the droop coefficient =50kW / 5V=10 kW / V. Inverter air conditioner: maximum power 8 kW, minimum power 2kW, difference 6kW. =6 / 5=1.2 kW / V.
[0066] Within each control cycle, the following priority order will be followed: First priority: Transient blocking due to large disturbances. The absolute value of the voltage change rate is obtained by dividing the voltage difference of three consecutive sampling points by the time interval. The preset transient threshold is determined jointly based on the system short-circuit capacity and the protection device's operating time; in this embodiment, it is set to 200V / s. When the absolute value of the voltage change rate exceeds this threshold, the "transient blocking" flag is set, blocking the power regulation output and forcibly setting the local adjustable capacity to zero. The blocking is released when the absolute value of the voltage change rate falls back to below 80% of the threshold (i.e., 160V / s) and remains there for 5 consecutive control cycles (50ms).
[0067] Second priority: Voltage droop control during normal operation. If the bus voltage is in the droop low voltage zone or emergency low voltage zone, the power output is increased or the power consumption is reduced according to the above droop coefficient. The adjustment amount is the smaller of the maximum adjustable capacity and the calculated droop value. If it is in the droop high voltage zone or emergency high voltage zone, the power output is reduced or the charging is increased.
[0068] For on / off or adjustable power supplies (fans, electric water heaters), the maximum available power level mapping method is adopted: a dynamic prediction model (first-order inertial form) is established for the power and comfort state variables (indoor wind speed, water temperature) of each power level. Using the current comfort dead zone as a constraint, all switchable power levels are traversed to predict whether the comfort state will remain within the dead zone for a period of time after switching. If the comfort requirements are met, the achievable power level is recorded. The difference between the maximum achievable power and the current power is taken as the adjustable capacity, and the difference between the current power and the minimum achievable power is taken as the adjustable capacity. Simultaneously, a switch lifespan constraint is introduced: the number of switching times per unit time does not exceed a preset upper limit (e.g., 6 times per hour); if the upper limit is reached in a certain direction, the corresponding capacity is forcibly reset to zero.
[0069] Priority coordination: Transient blocking has the highest priority, followed by droop control (which only applies to continuously adjustable resources), while discrete resources do not participate in real-time droop adjustment; One day at noon, the photovoltaic output was 30kW, the office air conditioning averaged 5kW, lighting was 3kW, only two fans were on (0.3kW), and the electric water heater was not used. The measured bus voltage was 752V, which is within the normal range, and no additional adjustment was made to the droop control. Calculate the local capacity of each resource at this time: Energy storage: Current SOC = 60%, maximum charging power 50kW (limited by the inverter), maximum discharging power 50kW. Adjustable capacity (discharging) = 50kW; Adjustable capacity (charging) = 50kW.
[0070] Photovoltaics: Current MPPT power is 30 kW, adjustable capacity = 0 (photovoltaics can only be reduced, not increased), adjustable capacity = 30 kW (can be reduced to 0).
[0071] Inverter air conditioners: Currently 5kW each, can be increased to 8kW → increased capacity 3kW / unit; can be decreased to 2kW → decreased capacity 3kW / unit.
[0072] Lighting: Currently at 3kW, can be increased to 5kW → increased capacity by 2kW; can be decreased to 0kW → decreased capacity by 3kW.
[0073] Fixed-frequency fans (on / off type): Utilizes a maximum available speed mapping method. Currently, two fans are off (0kW), and two are on (0.15kW). Considering comfort constraints (indoor airflow speed, noise), if it is predicted that the indoor airflow speed will remain within a comfortable range for the next 5 minutes, the on fan can provide an increased capacity of 0.15kW / unit; the off fan can provide a decreased capacity of 0.15kW / unit. Simultaneously, due to switch lifespan constraints (no more than 6 switches per hour), switching is permitted at the current moment.
[0074] Electric water heater (three settings): Currently 0kW, water temperature in tank 45℃, dead zone set 43~47℃. If it is predicted that the water temperature will not exceed 47℃ within 10 minutes when switched to 1.5kW, the capacity will be increased to 1.5kW; if it is predicted that the temperature will exceed 47℃ after 6 minutes when switched to 3.0kW, it will not be allowed. The capacity can be reduced to 0 (already the lowest setting).
[0075] Suppose that at a certain moment the bus voltage suddenly drops to 740V (a low-voltage droop zone), and the energy storage and air conditioning increase their output according to the droop factor: the energy storage increases by (745-740)×10=50kW (reaching the upper limit), and the air conditioning increases by (745-740)×1.2=6kW each. However, the air conditioning capacity increase is only 3kW, so the actual increase is 3kW each, raising the power to 8kW. After execution, the remaining local capacity is recalculated: the adjustable capacity of energy storage becomes 0, and the adjustable capacity of air conditioning becomes 0.
[0076] If a DC bus short-circuit fault occurs and the voltage change rate exceeds the preset transient threshold of 200V / s, all nodes will have a built-in lockout flag within 10ms, forcing the local adjustable / lower capacity to 0 and locking the droop power regulation output. After the fault is cleared, the voltage recovers, the change rate drops and remains below 160V / s for 5 consecutive cycles (50ms), and the lockout is cleared.
[0077] In each token cycle (450ms), each node performs a consensus iteration after obtaining local capacity data from all other nodes. Taking adjustable capacity as an example, the initial state vector... (Unit: kW). In a fully connected topology, the node degree d_i = 8, and the weight... , Iteration formula: The convergence criterion is that after each iteration, the state of each node becomes the average of the current states of all nodes. The maximum absolute value (residual) of the difference between the current state and the previous state of all nodes is less than the preset convergence error threshold of 0.01 kW, and this remains true for 3 consecutive iterations. After approximately 15 iterations (about 6.75 seconds), the state of each node converges to an average value of approximately 6.644 kW. Multiplying this by the number of nodes N=9, the total power up-adjustment capacity of the entire network is approximately 59.8 kW. Similarly, the total power down-adjustment capacity is approximately (50+30+3+3+3+0.15+0.15+0+0) / 9≈9.81×9=88.3 kW. A moving average filter is applied to the converged estimate, with a filter window length of M=3 iteration periods (corresponding to approximately 1.35 seconds of physical time, making the filter time constant approximately on the order of seconds). After smoothing, the second-level evaluation result is output.
[0078] The centralized optimization controller performs rolling optimization every 5 minutes. The filtered total up-adjustment capacity of 59.8kW and total down-adjustment capacity of 88.3kW are used as current feedback. A mixed-integer prediction model is constructed, with a prediction time domain H=12 (corresponding to 60 minutes). State variables include: energy storage SOC (0~1), indoor temperature in two offices (comfortable range of 22~26℃), water temperature of electric water heater (43~47℃), fan on / off status, etc. Input variables include: energy storage charging / discharging power (-50~50kW), air conditioning power (2~8kW continuous), lighting power (0~5kW continuous), fan on / off status, and electric water heater setting (0 / 1 / 2). The thermodynamic model adopts a first-order RC model, and parameters are identified through historical data. Weights in the objective function... =0.6 (Capacity weight increased because buildings need to respond to grid peak shaving requirements). =0.4, =0.01. The allowable adjustment range of the voltage reference value is [730V, 770V]. Solving the mixed integer programming problem, the optimal voltage reference value of 762V is obtained (higher than the rated value to enhance the flexibility of downward adjustment to cope with midday photovoltaic excess). At the same time, the minute-level flexibility capability time-series boundary for the next 60 minutes is output: for example, the total upward adjustment capability gradually decreases from 59.8kW to 45kW in the next 15 minutes (due to the reduced adjustable space of air conditioning as it approaches the set temperature), and the total downward adjustment capability increases from 88.3kW to 95kW (due to the increase in photovoltaic predicted output). This minute-level assessment result is reported to the building energy management system for participation in grid demand response.
[0079] The centralized optimization controller broadcasts the optimal voltage reference value of 762V via RS485. Upon receiving this value, each node immediately shifts the voltage zone thresholds: the new upper limit of the emergency low voltage zone = 762 - 20 = 742V, the new upper limit of the drooping low voltage zone = 762 - 5 = 757V, the new lower limit of the drooping high voltage zone = 762 + 5 = 767V, and the new lower limit of the emergency high voltage zone = 762 + 20 = 782V. The normal zone becomes [757V, 767V]. The overall upward shift of the droop control range prompts energy storage and air conditioning to begin charging or reducing power when the voltage is higher than 767V, thus proactively absorbing excess photovoltaic power.
[0080] When the system suffers a large disturbance, the specific timing of the three-layer coordinated protection is as follows: Physical layer: When each node detects that the voltage change rate exceeds the transient threshold (200V / s), it sets the local flexible capacity to zero within milliseconds (10ms) by blocking the voltage change rate and blocking the droop power regulation output.
[0081] Distributed aggregation layer: Since the local capacity of each node is set to zero, the consistency iteration converges to zero within about 1 second when the total power adjustment and reduction capabilities of the entire network are both zero, and the second-level evaluation value uploaded to the central controller is zero.
[0082] Centralized Optimization Layer: The centralized controller detects the aggregated value in each macro-control cycle. When the total upward / downward adjustment capability is zero for two consecutive control cycles, and a voltage over-limit alarm flag is received from the physical layer (bus voltage is below the emergency low-voltage zone threshold or above the emergency high-voltage zone threshold), the system is determined to be in a fault or recovery transition process. The measurement update of the state estimator is paused, and model-based predictive estimation is used instead. The flexibility capability output is set to a conservative value from the most recent normal operation (e.g., reduced by a preset ratio). Measurement updates resume when there are no over-limit alarms for several consecutive cycles and the aggregated value returns to normal.
[0083] One afternoon, an air conditioner suddenly disconnected from the grid due to a malfunction, causing the bus voltage to surge to 775V (exceeding the new emergency high-voltage zone threshold of 782V; however, 775V < 782V, still within the drooping high-voltage zone). The voltage change rate was as high as 300V / s, and the physical layer transient blockade reset the local capacity of each node to zero within 10ms. After approximately 1 second of consensus iteration, the distribution layer's total up / down adjustment capacity returned to zero. In the next 5-minute cycle, the central controller detected a zero aggregate value and received a voltage over-limit alarm, classifying it as a disturbance. It suspended measurement updates, switched to model prediction estimation, and set the flexibility output to a conservative value (down 20%). After the fault was cleared, the voltage recovered, the blockade was cleared, the local capacity recovered, the aggregate value was rebuilt, and the central controller resumed normal measurement updates.
[0084] Through the application of this embodiment, the building's DC power distribution system can achieve dynamic assessment of flexibility capabilities at the second and minute levels during normal operation, supporting flexible interaction with the power grid; under large disturbances, the three-layer collaborative protection ensures selective operation of the protection device and system stability, verifying the effectiveness of the proposed method.
[0085] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention in any way. Although the present invention has been disclosed above with reference to preferred embodiments, it is not intended to limit the present invention. Any person skilled in the art can make some modifications or alterations to the above-disclosed technical content to create equivalent embodiments without departing from the scope of the present invention. Any simple modifications, equivalent changes and alterations made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the scope of the present invention.
Claims
1. A method for dynamically evaluating the flexibility of a building DC power distribution system oriented towards diverse flexible resources, characterized in that, Includes the following steps: S1. During system initialization, network scale parameters are obtained, and a token passing synchronous communication network based on the serial communication physical layer is constructed. The converter controller or edge agent gateway corresponding to the multiple flexible resources connected to the DC bus is used as a node to periodically broadcast the local adjustable capacity and adjustable capacity through the token passing protocol. S2. Each node detects the local DC bus voltage and performs adaptive voltage partition droop control within five voltage ranges preset with the current reference voltage as the center and a fixed difference. Combined with the highest priority voltage change rate transient blocking logic, the local adjustable capacity and adjustable capacity of each flexible resource are calculated. S3. Each node takes the local adjustable capacity and adjustable capacity as the initial state, uses the neighbor data synchronized by the token passing protocol, performs distributed consensus iteration based on Metropolis weights, multiplies the converged state variables with the network size parameters to obtain the estimated values of the total network power adjustment capability and total power reduction capability, and outputs the second-level dynamic flexibility capability assessment results. S4. The centralized optimization controller receives the second-level dynamic flexibility capability assessment result as feedback, constructs a system aggregated mixed integer prediction model containing continuous state variables and discrete gear variables, and performs rolling optimization in the prediction time domain with the goal of maximizing the weighted sum of the power adjustment capability and the power reduction capability, and suppressing the voltage reference value from deviating from the rated value. The optimal DC bus voltage reference value and the timing boundaries of the power adjustment capability and the power reduction capability for multiple future control cycles are obtained as the minute-level dynamic flexibility capability assessment result. S5. The centralized optimization controller sends the optimal DC bus voltage reference value to each node. Each node shifts all thresholds of the voltage partition according to the fixed difference to complete the closed-loop correction. When the system suffers a large disturbance, a three-layer collaborative protection is formed by physical layer voltage change rate blocking, distribution layer aggregate value returning to zero, and centralized layer pausing measurement updates.
2. The method according to claim 1, characterized in that, In the token passing synchronous communication network described in step S1, the fixed time slot length is preset according to the RS485 bus baud rate and the maximum message length; The token is passed around in order of node address. If a node does not receive a valid token frame within two consecutive time slots, it will actively initiate a token request frame, and the active node with the smallest address will regenerate the token. The network size parameter is the total number of global nodes, which is broadcast by the centralized optimization controller via an RS485 bus configuration frame. Each node simultaneously runs a consensus algorithm with a constant of 1 to estimate the number of active nodes as a verification.
3. The method according to claim 1, characterized in that, The fixed difference mentioned in step S2 includes a first fixed difference and a second fixed difference, with the first fixed difference being greater than the second fixed difference. The five voltage ranges, from low to high, are: emergency low voltage range, drooping low voltage range, normal range, drooping high voltage range, and emergency high voltage range. The emergency low voltage range and the emergency high voltage range are defined by the first fixed difference, the drooping low voltage range and the drooping high voltage range are defined by the second fixed difference, and the normal range is symmetrically defined by the second fixed difference.
4. The method according to claim 1, characterized in that, The voltage change rate transient blocking logic in step S2 is as follows: In each control cycle, the absolute value of the voltage change rate is calculated using the multi-sampling point differential method. When the absolute value exceeds the preset transient threshold, the blocking flag is set, the local adjustable capacity and adjustable capacity are forcibly set to zero, and the droop power regulation output is blocked. The blocking release condition is that the absolute value of the voltage change rate falls back below the preset transient threshold and is maintained for a preset number of control cycles. The preset transient threshold is determined jointly based on the system short-circuit capacity and the protection device operation time.
5. The method according to claim 1, characterized in that, The maximum available gear mapping method described in step S2 is as follows: For flexible resources with a finite number of discrete operating gears, a dynamic prediction model of the power and comfort state of each gear is established. The current comfort dead zone is used as a constraint to traverse all switchable gears. The model predicts whether the comfort state will remain within the dead zone in the future after switching. The difference between the maximum achievable power and the current power is taken as the adjustable capacity, and the difference between the current power and the minimum achievable power is taken as the adjustable capacity. A switching life constraint is introduced that the number of switching times per unit time does not exceed a preset upper limit.
6. The method according to claim 1, characterized in that, In step S3, during the distributed consensus iteration based on Metropolis weights, the set of neighbor nodes is determined by the fully connected logic of the token passing protocol, comprising all other nodes in the network except itself; weights ,in They are nodes , The degree of a node in a fully connected topology is equal to the total number of nodes in the world minus one; its own weight. The iterative convergence criterion is that the maximum absolute value of the difference between the current state and the previous state of all nodes is less than the preset convergence error threshold and the iteration continues for a preset number of times.
7. The method according to claim 1, characterized in that, In step S3, the estimated values of the total power up-adjustment capability and total power down-adjustment capability of the entire network obtained after convergence are subjected to moving average filtering. The time constant of the moving average filtering is set to the second level, and the length of the filtering window is determined according to the token cycle period, so that the filtering time constant is approximately the second level. The filtering only applies to the final estimated value output to the centralized optimization controller and does not participate in the internal calculation of the consistency iteration.
8. The method according to claim 1, characterized in that, In step S4, the state variables of the system aggregated mixed integer prediction model include the state of charge of the energy storage unit and the indoor temperature characterizing the thermodynamic state of the building's virtual energy storage. The input variables include the power regulation amount of continuous resources and the discrete power values corresponding to each level of switchable or tiered resources. The level switching constraints are described by binary logic variables. The state update equation adopts a first-order or second-order thermodynamic model. The objective function consists of three weighted terms: the first term is the negative value of the sum of the power adjustment capabilities in the prediction time domain multiplied by the first weight coefficient; the second term is the negative value of the sum of the power adjustment capabilities multiplied by the second weight coefficient; and the third term is the square of the difference between the voltage reference value and the rated voltage multiplied by the penalty coefficient. The DC bus voltage reference value is used as an independent optimization variable and is limited to a preset allowable adjustment range.
9. The method according to claim 1, characterized in that, The specific timing sequence of the three-layer collaborative protection in step S5 is as follows: when a large disturbance occurs, the physical layer sets the local flexible capacity to zero through voltage change rate blocking within milliseconds; the distributed aggregation layer converges to zero through consistency iteration within seconds. When the centralized optimization layer detects that the aggregate value is zero for several consecutive control cycles and is accompanied by a voltage over-limit signal, it determines that the system is in a fault or recovery transition process, suspends the measurement update of the state estimator, and continues until the aggregate value returns to normal and there is no over-limit alarm.
10. A dynamic evaluation system for the flexibility of a building DC power distribution system oriented towards diverse flexible resources, used to execute the method according to any one of claims 1-9, characterized in that, include: The distributed communication network consists of converter controllers and edge agent gateways corresponding to each flexible resource as nodes. It is built through a token passing synchronous communication protocol running on the RS485 physical layer and is used to periodically broadcast the local adjustable capacity and adjustable capacity of each node. The physical response layer controller, built into each converter or proxy gateway, is used to detect the local DC bus voltage and perform adaptive voltage partition droop control, calculate the local adjustable capacity and adjustable capacity of each flexible resource, determine the discrete capacity value by the maximum available range mapping method for switch-type or range-type resources, and perform the highest priority transient blocking when the voltage change rate exceeds the limit. The distributed aggregation layer module runs on each node and is used to aggregate the local adjustable capacity and adjustable capacity into the total adjustable power capacity and total adjustable power capacity of the entire network through distributed consensus iteration. After moving average filtering, it outputs the second-level dynamic flexibility assessment result. A centralized optimization controller is used to receive the second-level dynamic flexibility assessment results, construct a system aggregated mixed integer prediction model and perform rolling optimization to obtain the optimal DC bus voltage reference value and the minute-level dynamic flexibility assessment results, and then send the optimal DC bus voltage reference value to each node to complete the closed-loop correction by shifting the voltage partition threshold.
