Engineers increasingly turn years of plant sensor data into maps of where useful energy is wasted. Entropy generation analysis measures the irreversibility in each unit: how much work potential, or exergy, each pump, heat exchanger or reactor destroys. These maps show where exergy was lost. They do not show what would happen if an operator changed a setpoint, such as a chilled-water supply temperature or a steam-to-carbon ratio. Operators chose past setpoints in response to weather, load and equipment condition, and those same factors drive entropy generation. A comparison between historical operating periods therefore mixes the effect of the setpoint with the effect of the conditions that prompted it. Causal inference calls this confounding (or selection) bias.
We propose to estimate counterfactual entropy generation, meaning the irreversibility each component would produce under an intervened setpoint, from confounded logs. The method rests on one structural fact. The Second Law makes most of the outcome a known function of measured thermodynamic states. Given the temperatures, pressures, flows and compositions at a component's ports, its entropy generation follows from the balance equations, with nothing to learn. So the causal learning problem shrinks from "setpoint → irreversibility" to "setpoint → measurable states." That smaller problem obeys mass and energy conservation and is easier to learn. The process flowsheet also supplies built-in falsification checks: components that a given setpoint cannot physically affect must show zero causal effect.
Core Claim
Routing a debiased continuous-treatment estimator through the known state-to-entropy map should give lower error than learning entropy generation end to end, especially where historical operation rarely visited the setpoint of interest. Three ingredients make this work. The first is to predict counterfactual states rather than entropy directly. The second is to constrain those predictions to close mass and energy balances and to imply non-negative entropy generation in every component. The third is to target reference-free entropy generation $\dot S_{\text{gen}}$ rather than exergy destruction.
The third ingredient addresses a confounding channel specific to thermodynamics. Exergy destruction is defined as $\dot E_{\text{dest}} = T_0 \dot S_{\text{gen}}$ by the Gouy–Stodola relation, where $T_0$ is the environmental reference temperature. When the reference is taken as ambient conditions, the confounder (ambient temperature) appears inside the definition of the outcome itself. A model trained on raw exergy destruction partly learns weather arithmetic. We estimate $\dot S_{\text{gen}}$ under intervention and rescale it to a fixed reference afterward.
Formally, let $T$ be a continuous setpoint vector, $X$ the measured disturbances (ambient wet-bulb temperature, load, feed composition), and $S_k$ the measured port states of component $k$. Let $g_k$ be the known balance-equation map from those states to that component's entropy generation. The target is
$$\mu(t, x) = \mathbb{E}\Big[\textstyle\sum_k g_k(S_k) \,\Big|\, \text{do}(T=t), X=x\Big] = \int \textstyle\sum_k g_k(s_k)\, p(s \mid \text{do}(t), x)\, ds,$$
where the second equality holds under the usual no-unmeasured-confounding and overlap assumptions. Only the interventional state distribution $p(s \mid \text{do}(t), x)$ is learned, and it is learned subject to the conservation constraints.
Relation to Prior Work
The research file reports no published work combining Second-Law irreversibility analysis with formal confounding adjustment. The proposal sits between two groups of papers.
On the thermodynamic side, two papers motivate the work.
- Dynamic exergy analysis: From industrial data to exergy flows converts two years of data from 311 sensors in an ammonia plant into time-resolved exergy flows. It reports a 71% conventional efficiency against a 15% "transit" efficiency, a metric that excludes exergy passing through untransformed. Its analysis is explicitly descriptive: it says where exergy was lost, not what a different policy would have saved.
- Annual Operation Energy Efficiency Benchmarking of Chilled Water Plants pools 229 plant cases. Its gains are visibly entangled with baseline efficiency: plants starting below an annual efficiency ratio of 3.0 improve by 69.46%, those starting at or above 5.0 by only 13.29%. The authors flag this self-selection themselves.
Two further papers constrain the design.
- Pitfalls of Exergy Analysis proves that when temperature gradients exist, the operating point that minimizes entropy generation differs from the one that maximizes power. We therefore never treat minimum $\dot S_{\text{gen}}$ as the control objective on its own. Useful output and irreversibility are estimated as separate causal outcomes.
- Loss Analysis Of Centrifugal Compressor Volutes Based On A Second-Law Analysis Method finds that integrating local entropy production underestimates the solver's own pressure loss by 11–36%. We therefore compute $g_k$ from port-level balances, which close by construction, rather than from field gradients.
On the causal side, four papers supply the estimation machinery.
- Counterfactual regression (CFR), from Estimating individual treatment effect: generalization bounds and algorithms, bounds the error of individual effect estimates by factual loss plus the distance between treated and control representations. It does so for binary treatments with a generic learned outcome.
- SITE, from Representation Learning for Treatment Effect Estimation from Observational Data, adds preservation of local neighborhoods to avoid over-smoothing.
- ADMIT, from Generalization Bounds for Estimating Causal Effects of Continuous Treatments, extends balancing to continuous doses by re-weighting a finite set of treatment intervals. ADMIT is our backbone.
- G-learner, from Adjusting Prediction Model Through Wasserstein Geodesic for Causal Inference, adapts the predictor along an optimal-transport path. Its synthetic intermediate samples could violate physical balances, which is one reason we keep it as a baseline rather than a component.
All four treat the outcome as an unknown function to be learned. The new step here is that the outcome map is known physics, so learning moves to a conservation-constrained state space.
The closest physics-aware model, Monotonic Neural Network, enforces monotone input–output behaviour on chiller plants. It still fits the observational conditional expectation and optimizes First-Law power rather than irreversibility.
Research Program
We will build three things.
The estimator. It uses ADMIT's representation, re-weighting and varying-coefficient networks. Its output head predicts port states $S_k$ instead of a scalar outcome. A differentiable projection layer then enforces component mass and energy balances and penalizes any state that implies negative $g_k$. Fixed balance-equation code computes counterfactual $\dot S_{\text{gen},k}$ from the predicted states, followed by rescaling to a fixed reference temperature. A second head estimates the useful outcome (cooling delivered, or electrical power). The two together trace a causal Pareto front between useful output and irreversibility.
A semi-synthetic benchmark with known counterfactuals. It follows the logic of the semi-synthetic IHDP benchmark, where real covariates are paired with a simulated outcome mechanism. Two physical testbeds are used.
- Chiller plant. A first-principles model of chillers, cooling towers and pumps is driven by realistic weather and load traces. Confounded logs come from a legacy operator heuristic that sets supply temperature and pump speed from wet-bulb temperature and load, with a dial for confounding strength. A hidden fouling variable degrades heat-exchanger performance and also influences operator choices; it serves as an unmeasured confounder.
- Non-isothermal fuel cell. The analytical model from Pitfalls of Exergy Analysis is used, with operating temperature gradient and load as confounders. This tests whether the estimator recovers the known gap between the power-maximizing and entropy-minimizing settings.
A falsification layer for real data. For each setpoint, the flowsheet identifies components outside its physical influence, given the plant's topology and timescales. Their estimated effects act as negative controls: nonzero estimates signal residual confounding or sensor drift. Where effects are not identified because of hidden fouling, we report bounds instead of point estimates, in the spirit of Information-Theoretic Causal Bounds under Unmeasured Confounding. The ammonia dataset of Dynamic exergy analysis is the intended real-world target, subject to access. The data center chiller log of Monotonic Neural Network is a second target under the same caveat. Neither has ground-truth counterfactuals, so on these sources we report only negative-control effects and balance closure, not accuracy.
Baselines
The naive reference applies no causal adjustment.
- Historical-period comparison. We compare average $\dot S_{\text{gen}}$ across logged periods grouped by setpoint, which is what a descriptive dynamic exergy analysis implicitly supports.
- Plain regression. A neural regressor of exergy destruction on setpoint and covariates, trained by ordinary prediction loss.
- Monotone regressor. Its physically shaped variant, a Hard-MNN monotone network from Monotonic Neural Network. The paper reports an average PUE (power usage effectiveness) reduction of about 1.5% versus standard deep learning in a live trial. That is a First-Law control result, not a counterfactual-accuracy number. On our benchmark we expect this baseline's error to grow with confounding strength.
The classical causal reference is generalized-propensity inverse weighting, which re-weights each logged sample by the inverse estimated density of its setpoint given covariates. We will also run a doubly robust variant that pairs this weighting with an outcome model fitted on the same covariates.
The strongest existing method is ADMIT (Generalization Bounds for Estimating Causal Effects of Continuous Treatments), trained to predict $\dot S_{\text{gen}}$ end to end. It shares our backbone, so it isolates the physics routing. The paper claims the lowest dose-response error across News, TCGA and simulated data, but no reported numerical result was found on Lacuna for ADMIT's dose-response error, because the file's table is cut off. For binarized setpoint changes we add CFR (Estimating individual treatment effect) and G-learner (Adjusting Prediction Model Through Wasserstein Geodesic). G-learner reports errors "roughly 20–30% lower than the next best competitor" on its hardest simulated tasks.
A calibrated simulator baseline uses the benchmark's own physics model, fitted to the logs with the fouling mechanism misspecified.
Three ablations isolate the key ingredients: removing the conservation projection, targeting $\dot E_{\text{dest}}$ instead of $\dot S_{\text{gen}}$, and removing the debiasing (state routing kept, re-weighting off).
All learned methods receive the same training logs, covariates and number of hyperparameter trials. Tuning is selected on a held-out factual loss, never on counterfactual truth.
What counts as beating ADMIT. Lower dose-response error of $\dot S_{\text{gen}}$, averaged over at least ten benchmark seeds, with a gap that widens as overlap shrinks. Also lower regret of the chosen setpoint against the simulator's true optimum under a fixed cooling-delivery constraint.
Why not just…?
Why not just run a calibrated physics simulation instead? A simulator has no confounding, but it is only as right as its calibration. Dynamic exergy analysis found that real operating data gives a "less optimistic, but more realistic" picture than simulated studies, because unmodeled fluctuations and degradation hide inefficiencies. The misspecified-fouling simulator baseline tests this directly. If it matches our estimator when fouling is correctly modeled but loses when it is not, that is the regime where learning from logs is justified. If it wins even under misspecification, the proposal's value narrows to cases with no usable simulator.
Why not just fit a physics-constrained network to the logs? Monotonicity removes non-physical wiggles but does not change the fact that the training data pair low supply temperatures with hot, high-load days. The fitted curve is still the observational conditional, which is the failure CFR and SITE document for unadjusted regressors. The confounding-strength sweep shows this. Our prediction is that Hard-MNN's error grows with confounding while ours stays flat.
Why not just do covariate adjustment with propensity weighting or a doubly robust estimator? This is the most serious threat. With measured confounders, a low-dimensional setpoint and good overlap, a doubly robust estimator may match us, and we will report it if so. Our expected advantage lies elsewhere. Legacy controllers are nearly deterministic, so overlap is poor and inverse weights explode. The known state-to-entropy map extrapolates where a learned outcome model cannot. The overlap sweep and the comparison between the routing ablation and full ADMIT settle the question. If the advantage appears only at low overlap, the claim narrows to that regime.
Decisive Checks
The central experiment sweeps confounding strength and overlap on the chiller benchmark. It plots dose-response error of $\dot S_{\text{gen}}$ and setpoint regret for every baseline. The idea fails if state routing gives no gain over end-to-end ADMIT at low overlap.
Two further checks probe the specific claims.
- Reference-state check. We compare the estimated effect on $\dot E_{\text{dest}}$ with that on rescaled $\dot S_{\text{gen}}$ when ambient temperature varies widely. We should find a bias in the former that matches the $T_0$ scaling.
- Fuel-cell check. The method must place the power-maximizing and entropy-minimizing settings at different points, as Pitfalls of Exergy Analysis predicts, while unadjusted regression on the confounded logs misplaces at least one of them.
On real logs, success means two things: negative-control effects within noise, and counterfactual states that close the balances. Failure of either would be reported as evidence of unmeasured confounding rather than hidden.
References
- Dynamic exergy analysis: From industrial data to exergy flows
- Annual Operation Energy Efficiency Benchmarking of Chilled Water Plants: A Systematic Review of Global Cases (2014–2025)
- Pitfalls of Exergy Analysis
- Loss Analysis Of Centrifugal Compressor Volutes Based On A Second-Law Analysis Method
- Estimating individual treatment effect: generalization bounds and algorithms
- Representation Learning for Treatment Effect Estimation from Observational Data.
- Generalization Bounds for Estimating Causal Effects of Continuous Treatments
- Adjusting Prediction Model Through Wasserstein Geodesic for Causal Inference
- Monotonic Neural Network: combining Deep Learning with Domain Knowledge for Chiller Plants Energy Optimization
- Information-Theoretic Causal Bounds under Unmeasured Confounding