Abstract
Designing efficient water treatment and energy recovery networks involves solving complex non-linear optimization problems. This paper proposes reformulating these challenges into Quadratic Generalized Disjunctive Programs (QGDP) using quadratic and piecewise linear approximations. By leveraging modern solvers like Gurobi, the researchers demonstrate significant speedups in finding global optimal designs with minimal loss in accuracy compared to traditional non-linear methods.
Introduction
The design of water networks is a significant engineering challenge characterized by non-convexity. Balancing mass flows and contaminant concentrations introduces bilinear terms, while equipment costs often exhibit concave behavior. These features frequently lead standard optimizers to local optima rather than the global best solution. Traditionally, these problems are modeled as Generalized Disjunctive Programs (GDP), which are computationally expensive and slow to solve. This research aims to bridge the gap between high-fidelity, slow-solving models and simplified models that may overlook optimal engineering solutions by introducing efficient reformulations.
Methodology
The authors propose two primary reformulation strategies to transform non-linear terms into forms more suitable for modern solvers:
- Quadratic Approximation (QGDP-q): Non-linear terms are fitted to quadratic functions ($f(x) \approx x'Qx$) using SciPy’s
curve_fit. This allows the use of solvers optimized for quadratic programming. - Piecewise Linear Approximation (QGDP-pwl): Non-linear function curves are divided into 101 linear segments. Although this increases the model's variable count, it provides a tighter fit to the original physics.
Models were implemented in Pyomo and solved using Gurobi (for quadratic/linear efficiency) and BARON (for standard non-convex global optimization).
Case Studies
The approach was validated using two engineering case studies:
- Water Treatment Network (WTN): A system with five inlet streams, four contaminants, and four treatment units.
- Reverse Electrodialysis (RED) Process: A large-scale energy recovery system extracting salinity gradient energy from desalination brine and treated wastewater.
Results and Discussion
The results highlight a significant performance advantage when using quadratic reformulations with optimized solvers.
Water Treatment Network (WTN)
For the WTN case, the quadratic approximation (QGDP-q) solved by Gurobi showed a marked improvement in speed. As shown in Figure 1, Gurobi reached a solution in 6.44 seconds, compared to 16.12 seconds for the original GDP model solved by BARON. While the piecewise linear (pwl) model achieved 0.00% relative error, it significantly increased the number of binary variables and CPU time for the BARON solver.
Reverse Electrodialysis (RED) Process
The scaling benefits were even more pronounced in the RED process study. The original non-linear model was too complex for BARON to solve within a one-hour limit, leaving a 24% optimality gap. In contrast, the quadratic version (QNLP-q) was solved by Gurobi in just 115 seconds, as detailed in Figure 2.
Key Insights
- Solver Efficiency: Reformulating problems as quadratic allows solvers like Gurobi to operate much faster than traditional global solvers on original non-linear versions.
- Trade-offs: Quadratic approximations offer speed but may introduce small errors (0.35% to 3%). Piecewise linear models provide high accuracy but increase model complexity through additional binary variables.
- Physical Constraints: Quadratic functions may struggle with specific terms like natural logarithms in Nernst potential equations, indicating that approximation choices must be physics-informed.
Conclusion
This research demonstrates that quadratic and piecewise linear reformulations of water network design problems can significantly reduce computational time while maintaining engineering accuracy. While piecewise linear models face a "curse of dimensionality" as segments increase, quadratic reformulations offer a powerful "sweet spot" for speed. Future work will explore advanced decomposition strategies for larger, city-scale water-energy nexus problems.
Summary updated