As the penetration of renewable energy continues to rise, the demand for rapid and precise frequency regulation from thermal power units becomes more stringent. The hybrid energy storage system, composed of lithium-ion batteries and flywheels, has emerged as a key enabling technology due to its superior power response and energy regulation capabilities. In this study, we focus on the layout design of such hybrid energy storage systems within the confined space of a thermal power plant. Based on facility layout problem formulations, we develop a method that integrates exact mixed-integer linear programming with metaheuristic strategies to generate practical layout schemes. Two real-world engineering scenarios with different energy storage configurations are used to validate the effectiveness of the proposed approach.
1. Introduction
With the dual‑carbon strategy, the installed capacity of wind and photovoltaic power has grown substantially. By the end of 2024, renewable energy capacity reached 1.889 billion kW, accounting for 56% of total installed capacity in China. The stochastic and intermittent nature of renewables imposes greater challenges on grid frequency stability. Thermal power units, constrained by their inherent characteristics, suffer from slow response and low accuracy in automatic generation control (AGC) regulation. Introducing electrochemical energy storage, such as lithium‑ion batteries, can improve regulation performance but may still be insufficient for short‑period, high‑amplitude fluctuations. Flywheel energy storage, with its fast response and high cycle life, complements batteries effectively. A hybrid energy storage cell system combining both technologies offers an ideal solution for thermal power frequency regulation.
However, the physical layout of these energy storage cells—comprising battery containers, power conversion system (PCS) cabins, flywheel modules, and auxiliary cabins—must satisfy multiple constraints: safety distances, maintainability, cable routing costs, and aesthetic alignment. This is a typical facility layout problem, known to be NP‑hard. Exact methods become intractable for more than about 25 facilities. Metaheuristic approaches such as particle swarm optimization, ant colony optimization, and genetic algorithms have been applied, but they often suffer from premature convergence and lack of interpretability. In this work, we combine the strengths of mixed‑integer linear programming (MILP) and metaheuristic ideas to design a practical layout optimization framework.
2. Problem Modeling
2.1 Site and Facility Representation
The layout area is modeled as a rectangle with known length \(B_x\) and width \(B_y\). Each prefabricated cabin (energy storage cell, PCS cabin, flywheel cabin, etc.) is represented as an axis‑aligned rectangle with length \(L_{\text{length}}\) and width \(L_{\text{width}}\). The position is defined by the coordinates of its lower‑left corner \((O_x, O_y)\). Each facility can be placed in two orientations: length along X‑axis (orientation 0) or length along Y‑axis (orientation 1). Obstacles within the site are also treated as rectangles. The geometric center of each facility is used as the connection point for cable routing.
2.2 Constraints
Boundary clearance: Every facility must maintain a minimum safety distance \(D_B\) from the site boundary. The constraints are:
$$O_x \ge D_B$$
$$O_y \ge D_B$$
$$O_x + O_{\text{length}} + D_B \le B_x$$
$$O_y + O_{\text{width}} + D_B \le B_y$$
where \(O_{\text{length}}\) and \(O_{\text{width}}\) are the effective dimensions after orientation:
$$O_{\text{length}} = \text{Orient} \cdot L_{\text{width}} + (1-\text{Orient}) \cdot L_{\text{length}}$$
$$O_{\text{width}} = \text{Orient} \cdot L_{\text{length}} + (1-\text{Orient}) \cdot L_{\text{width}}$$
Non‑overlap and safety distance between facilities: For any two facilities A and B, we introduce binary variables to indicate their relative positions (north, south, west, east) and the direction in which the safety distance \(D_{AB}\) must be enforced. The constraints are linearized as:
$$D_{AB} + (\text{right} – 1)M \le O_{Bx} – (O_{Ax} + O_{A,\text{length}})$$
$$D_{AB} + (\text{left} – 1)M \le O_{Ax} – (O_{Bx} + O_{B,\text{length}})$$
$$D_{AB} + (\text{up} – 1)M \le O_{By} – (O_{Ay} + O_{A,\text{width}})$$
$$D_{AB} + (\text{down} – 1)M \le O_{Ay} – (O_{By} + O_{B,\text{width}})$$
where \(M\) is a large constant (e.g., 5–10 times \(B_x\)). Additional logical constraints ensure exactly one horizontal and one vertical direction pair is active. For example, for two facilities, at most one of the four distance constraints is enforced while the others are relaxed.
2.3 Objective Function
We consider three objectives and combine them with dynamic weights.
(1) Cable trench cost: Analogous to material flow cost in classical facility layout. The set of electrical connections \(E\) includes: {main electrical cabin ↔ station transformer cabin}, {main electrical cabin ↔ secondary electrical cabin}, {main electrical cabin ↔ PCS cabin}, {PCS cabin ↔ battery energy storage cell}, {main electrical cabin ↔ flywheel PCS cabin}, {flywheel PCS cabin ↔ flywheel cabin}. The cost is:
$$C_1 = \sum_{(i,j) \in E} L(i,j) \cdot f_1(i,j)$$
where \(L(i,j)\) is the Manhattan distance between the geometric centers of facilities \(i\) and \(j\), and \(f_1(i,j)\) is the unit cost of cable and trench construction.
(2) Operation and maintenance (O&M) cost: This captures non‑flow relationships. Closely related facilities (e.g., battery energy storage cells and their PCS cabins) should be clustered. For battery energy storage cells and PCS cabins:
$$l_{\text{bat, pcs}} = \frac{1}{2} \sum_{i=1}^{n_{\text{bat}}} \sum_{j=1}^{n_{\text{pcs}}} \big| O_{\text{mid, bat},i} – O_{\text{mid, pcs},j} \big| \quad (i,j) \in E$$
$$l_{\text{bat, bat}} = \sum_{i=1}^{n_{\text{bat}}} \big| O_{\text{mid, bat},i} – O_{\text{mid, bat, centre}} \big|$$
For flywheel groups (e.g., one‑to‑four connection):
$$l_{\text{fw, pcs}} = \frac{1}{2} \sum_{k} \sum_{j=1}^{n_{\text{fpcs}}} \big| O_{\text{mid, fw, centre},k} – O_{\text{mid, fpcs},j} \big| \quad (j,k) \in E$$
$$l_{\text{fw, others}} = \sum_{i=1}^{n_{\text{fw}}} \big| O_{\text{mid, fw},i} – O_{\text{mid, others}} \big|$$
The total O&M objective is:
$$C_2 = \sum f_2(\cdot) \cdot l(\cdot)$$
where \(f_2\) are non‑flow relationship factors.
(3) Aesthetic alignment: For each connection pair in \(E\), we penalize misalignment. Let \(\text{tilt}_x(i,j)\) and \(\text{tilt}_y(i,j)\) be binary indicators of deviation in x‑ and y‑ direction. The aesthetic penalty is:
$$C_3 = \sum_{(i,j) \in E} f_{\text{align}} \cdot \text{tilt}(i,j)$$
with \(\text{tilt}(i,j) = \text{tilt}_x(i,j) + \text{tilt}_y(i,j) \ge 1\) if misalignment exists; \(f_{\text{align}}\) is a large penalty factor.
Dynamic multi‑objective weight: To balance the three objectives during optimization, we use a normalized formulation:
$$F = \alpha^{(s)} \frac{C_1}{L_0} + \beta^{(s)} \frac{C_2}{L_0} + \gamma^{(s)} C_3$$
where \(L_0\) is the perimeter of the site, \(s\) is the current iteration step, \(S\) is total steps, and:
$$\alpha^{(s)} = \alpha_0 + (\alpha_{\text{fin}} – \alpha_0) \frac{s}{S}$$
$$\beta^{(s)} = \beta_0 + (\beta_{\text{fin}} – \beta_0) \frac{s}{S}$$
$$\gamma^{(s)} = \gamma_0 + (\gamma_{\text{fin}} – \gamma_0) \frac{s}{S}$$
with \(\alpha_0 + \beta_0 + \gamma_0 = 1\) and \(\alpha_{\text{fin}} + \beta_{\text{fin}} + \gamma_{\text{fin}} = 1\).
3. Optimization Strategy
Our algorithm combines MILP with a metaheuristic iterative reduction procedure:
- Step 1: Perform an initial MILP solve for a limited time (e.g., 1–3 minutes) to generate a pool of candidate solutions. If no optimal solution is found, select the top \(M_0\) solutions as initial population \(S_0\).
- Step 2: For each individual in the population, randomly lock the position and orientation of one facility. Solve the reduced MILP again within a given time limit.
- Step 3: Collect the top \(M_1\) solutions from the new pool.
- Step 4: With a probability (e.g., 0.2), mutate the orientation of the locked facility to generate \(M_2\) additional solutions. Combine with \(M_1\) to form population \(S_1\).
- Step 5: Lock a second facility (preferably of the same type or connected to the first) and repeat Steps 2–4 to obtain population \(S_3\).
- Step 6: If the objective value reduction over two consecutive iterations is below a threshold (indicating local optimum), unlock one randomly chosen facility and continue.
- Step 7: Iterate until all facilities are locked or the time limit is reached. Output the best solution.
This approach progressively reduces problem complexity while leveraging the exactness of MILP for subproblems, and uses mutation to escape local optima.
4. Case Study Validation
We apply the proposed method to two real‑world engineering scenarios. The first scenario is a pure lithium‑ion battery frequency regulation system; the second is a hybrid system with both batteries and flywheels. The following table summarizes the facility types and quantities for Case 1 (pure battery).
| Cabinet Type | Quantity | Dimensions (mm × mm) |
|---|---|---|
| Main Electrical Cabin | 1 | 13000 × 3300 |
| Secondary Electrical Cabin | 1 | 12192 × 2800 |
| Station Transformer Cabin | 1 | 5850 × 2800 |
| PCS Step‑up Cabin | 7 | 6058 × 2438 |
| Battery Energy Storage Cell | 7 | 12192 × 2438 |
The site dimensions are 40.3 m × 33.5 m with a 3.5 m wide road crossing horizontally through the center. After running the optimization with initial weights \(\alpha_0=0.7, \beta_0=0.2, \gamma_0=0.1\) and final weights \(\alpha_{\text{fin}}=0.5, \beta_{\text{fin}}=0.2, \gamma_{\text{fin}}=0.3\), and using a 1‑minute initial solve, we obtained a layout that closely matches the actual engineering design. The main discrepancy was the position of the station transformer cabin; in the real design it was placed near the left boundary to connect with an external pole‑mounted switch. The optimization result placed it near the center, but the overall arrangement of battery energy storage cells and PCS cabins was consistent.
The second case involves a hybrid system with both battery energy storage cells and flywheel groups. The site is 66.7 m × 43.6 m with a 5 m wide road at 35.2 m from the left boundary. The facilities are listed in Table 2.
| Cabinet Type | Quantity | Dimensions (mm × mm) |
|---|---|---|
| Large Main Electrical Cabin | 1 | 13400 × 3500 |
| Small Main Electrical Cabin | 1 | 7000 × 3500 |
| Secondary Electrical Cabin | 1 | 12192 × 3000 |
| Station Transformer Cabin | 1 | 5500 × 2800 |
| PCS Step‑up Cabin | 5 | 9125 × 2438 |
| Battery Energy Storage Cell | 5 | 12192 × 2438 |
| Flywheel PCS Cabin | 2 | 16000 × 3800 |
| Flywheel Cabin | 8 | 5000 × 5000 |
The initial population size was 24. We set initial weights \(\alpha_0=0.7, \beta_0=0.2, \gamma_0=0.1\) and final weights \(\alpha_{\text{fin}}=0.4, \beta_{\text{fin}}=0.4, \gamma_{\text{fin}}=0.2\). The initial MILP solve time was 3 minutes. During the iteration, we observed that after locking the flywheel PCS cabin and its associated flywheel cabins, the algorithm converged to a local optimum where the battery area was not well‑aligned. By unlocking the flywheel PCS cabin and re‑solving, the final layout achieved a balanced arrangement. The final solution placed all flywheel cabins in a compact cluster on the right side of the road, with battery energy storage cells and PCS cabins in two orderly rows on the left side, satisfying both safety distances and O&M convenience.
An example visual representation of the optimized layout for the hybrid case is shown below (the image illustrates the final placement of all energy storage cells and related cabins).

The results confirm that the proposed method can generate practical layout designs that meet safety, cost, and operational requirements in both pure battery and hybrid configurations. The dynamic weighting mechanism effectively balances cable cost, maintenance convenience, and aesthetic alignment.
5. Conclusion and Outlook
We have presented a facility layout design method tailored for thermal power + hybrid energy storage frequency regulation systems. By modeling the problem as a mixed‑integer linear program with safety constraints and multi‑objective functions, and by integrating a metaheuristic reduction procedure, we achieve efficient and practical layouts. Two real‑world case studies demonstrate the applicability of the approach. Future work will extend the method to handle irregular site boundaries, multi‑site joint layouts, and the integration of molten salt thermal storage systems for combined heat and power applications.
