- The paper's main contribution is the development of a stochastic MPC that optimizes battery power intervals using mixed random variables.
- It integrates probabilistic forecasts via bimodal Gaussian mixtures to handle both discrete and continuous uncertainties in battery and grid operations.
- Simulation results show a cost regret reduction of 6.8% compared to ideal forecasts, outperforming conventional deterministic controllers.
Stochastic Model Predictive Control with Mixed Random Variables for Economic Energy Management
Introduction
"Stochastic Model Predictive Control based on Mixed Random Variables for Economic Energy Management" (2603.29586) addresses the challenge of battery scheduling under renewable and load uncertainty in residential energy systems. The paper shifts from traditional point-wise scheduling to the optimization of battery power intervals, exploiting mixed random variables to capture both discrete and continuous components in battery and grid operation. The proposed model jointly considers physical constraints, uncertainty quantification, and an explicit mechanism for downstream system behavior under forecast error—a major departure from conventional deterministic and interval-based MPC paradigms.
The system consists of a residential building equipped with PV generation and a battery, interacting with the external power grid. The core operational constraint is instantaneous power balance:
pL​(k)=pB​(k)+pG​(k)
where pL​ is the net load (demand minus PV generation), pB​ is battery power, and pG​ is grid exchange at time k. In contrast to classical MPC that schedules setpoints, this approach optimizes over battery power intervals $[{p}_B, \Bar{p}_B]$ and a target grid setpoint pGdes​.
Uncertainty in future net load is modeled via probabilistic forecasts, parameterized by bimodal Gaussian mixtures. The key innovation is the use of mixed random variables to describe the distributions of realized battery and grid power under these forecasts. For a given realization of net load, the actual battery and grid power depend on the feasibility of tracking pGdes​ within the battery's physical limits; infeasibility is handled via explicit probability mass at the interval endpoints.
Figure 1: General system structure and power flow balance among net-load, battery, and grid.

Figure 2: Transformation of continuous net-load uncertainty into battery and grid power distributions, each exhibiting both continuous and discrete characteristics due to physical constraints and operational strategy.
Probabilistic representations for both PB​ (battery) and PG​ (grid) are constructed, with PDFs that have singular components (Dirac deltas) at interval ends, and absolutely continuous segments within feasible operation. This detailed characterization respects actuator saturation and maintains closed-form tractability for expectation computations.
Stochastic MPC Framework
The mixed random variable formulation is embedded into a receding-horizon stochastic MPC, where at each optimization step the controller minimizes expected cost over a forecast horizon. Objective function components are:
pL​0
Here, asymmetric time-varying prices are modeled, and expected values for import/export are computed analytically from the mixed PDFs.
Figure 3: Illustration of time-dependent import and export tariffs based on actual wholesale prices, highlighting the economic context for optimization.
The MPC does not return a deterministic trajectory of setpoints but prescribes interval-based policies that link the battery response directly to realized net load, ensuring the downstream control action is both feasible and cost-motivated, obviating the need for a post-optimality correction layer.
Probabilistic Forecasting and Experimental Setup
Net-load forecasts are generated via a Kolmogorov-Arnold Network (KAN), outputting quantile-based probabilistic predictions, which are subsequently fit with bimodal Gaussian mixtures per hour. The validation uses real-world data from 15 distinct buildings without installed PV, with simulated PV profiles mapped in for realism. Test periods span five months, with rolling cross-validation for model selection.
Figure 4: Example probabilistic net-load forecast, showing forecasted PDF at an hourly interval, including quantiles and observed realization.
Extensive simulations benchmark the proposed SMPC-FG (Stochastic MPC-Fixed Grid, using mixed random variables) against five alternative strategies: MPC with perfect foresight, deterministic/probabilistic MPCs in both Fixed-Grid and Fixed-Battery (compensation assigned either to battery or grid), and a Rule-Based heuristic.
The SMPC-FG controller achieves a mean electricity cost regret of 6.8% over the ideal forecast baseline, clearly outperforming all other non-ideal controllers. Notably, deterministic MPC-FG incurs 12.4% regret, and the probabilistic SMPC-FB (Fixed-Battery version) reaches 19.7%. The Fixed-Battery strategies exhibit high cost due to increased import-then-export cycles, which are penalized by asymmetric tariffs.
Operational traces (Figure 5) highlight the practical impact of the interval policy: the SMPC-FG maintains battery flexibility into the night, reducing unnecessary grid import even at the cost of lower export revenue, while deterministic controllers expose the system to extra cost by aggressively discharging early.
Figure 5: Operation trace for a single building; deterministic MPC-FG results in repeated grid imports due to full battery discharge, while SMPC-FG maintains state-of-energy for plausible future demand, lowering cost.
Theoretical and Practical Implications
This work demonstrates that inclusion of mixed random variables—explicitly capturing both discrete probability masses at operational boundaries and continuous densities within intervals—provides a substantially richer and more realistic modeling framework for constrained control under uncertainty. Within the MPC context, this bridges the traditional gap between upstream optimization and downstream real-time feasibility correction, leading to superior economic outcomes, especially under asymmetric cost structures.
The approach is theoretically extensible to other domains with hard constraints and forecast uncertainty, including microgrid dispatch, flexible industrial scheduling, and robust grid services. A critical advantage is the generality of the mixed random variable machinery, which does not rely on restrictive assumptions about linearity, normality, or convexity.
Future Directions
Research should explore scalability of this stochastic MPC paradigm to larger aggregations (district-level coordination), more complex device ensembles (including flexible loads, multi-stage storage), and integration with robust learning-based forecast generators. Further, adapting the mixed random variable formalism to other nonconvex physical systems could unlock new synergies between probabilistic modeling and optimal control, particularly as power systems face increasing penetrations of inverter-based resources and distributed assets.
Conclusion
The integration of mixed random variables into stochastic MPC constitutes a significant advancement for uncertainty-aware energy management in residential buildings. Explicitly modeling battery and grid actions as interval-valued policies, rather than fixed setpoints, yields robustly lower operating costs when compared to conventional deterministic and even prior probabilistic controllers. The general framework for mixed discrete-continuous probability modeling is directly applicable to any optimization-driven control task with hard constraints and random forecasts, suggesting broad impact potential across energy systems and beyond.