THERMO-ROUTER is an AI-controlled retrofit that decides every 30 seconds whether low-grade industrial waste heat should be used directly to preheat a cold process stream, stored, or bypassed, maximising net energy benefit (heating avoided minus pumping minus storage losses) under temperature and safety constraints. We reviewed the evidence on heat-recovery loops and stratified storage, supervisory control (rules, MPC, imitation MPC, safe reinforcement learning, grey-box and physics-informed models), fouling soft sensors, low-cost instrumentation, thermally enhanced reverse osmosis and Gulf desalination data, and combined it with the team's own simulations. Four findings reshape the earlier proposal. First, a 20 L tank stratifies only if it is tall (height-to-diameter about 3.5) with low-momentum diffusers. Second, the earlier heat-recovery loop sends every joule through two exchangers and gives up about a quarter of the direct preheat whenever source and demand coincide. Third, at tabletop scale pumping is about 1% of recovered heat, so routing intelligence pays only when the value of heat is non-linear or costed; in the team's simulation the learned controller is within 1% of a threshold rule on energy but 3–23% better when costed. Fourth, seawater RO energy bottoms out near 30 °C and one week at 40 °C caused a permanent 7.5% penalty in a Red Sea pilot, so preheating is seasonal and capped. We propose a "direct-first, store-the-surplus" cascade with a tall stratified tank, controlled by a grey-box model with a learned residual inside an economic MPC teacher, distilled into a decision tree behind a hard-coded shield, with Kalman tank-state and recursive UA estimators. The plant mapping for a 100,000 m³/day RO train at a hybrid MSF/RO site gives about 2.7 GWh/yr (AED 0.5–1.2 million), replacing the earlier AED 6.4 million estimate. A bill of materials of about AED 970, a calibration plan that cuts measurement uncertainty from 8% to 2%, a 36-run paired A/B/C protocol resolving differences of about 2%, a nine-week timeline and a risk register complete the methodology.
| Quantity | Value | Basis |
|---|---|---|
| Preheat lost by the loop vs direct (45 °C source, 25 °C feed, ε 0.70) | 3.2 K (23%) | ε-NTU est, Fig. 9 |
| v2 utilisation advantage over the loop at 50% overlap | +0.12 (0.58 vs 0.50) | Fig. 10 est |
| Pump energy as share of recovered heat, tabletop | ≈ 1% | Fig. 20 prior |
| Learned controller vs threshold, energy-weighted | −0.3% to 0.0% | Fig. 11 prior |
| Learned controller vs threshold, cost-weighted | +0.4% to +22.8% | Fig. 12–13 prior |
| Oracle vs threshold, cost-weighted | +13.8% to +40.9% | Fig. 13 prior |
| Fouling detection at 20% UA loss / false alarms | 100% / 0% | Fig. 16 prior |
| Net-benefit uncertainty, uncalibrated → calibrated | 7.7% → 2.1% | Fig. 17 prior |
| Seawater RO energy minimum | ≈ 30 °C feed | Koutsou et al. 2020 model |
| Permanent SEC penalty after 7 days at 40 °C | +7.5% | Altmann et al. 2022 meas |
| Usable preheat season, Abu Dhabi | November–May, ≤ 6 K | Fig. 5–6 est |
| Plant saving, 100,000 m³/day RO train | 2.7 GWh/yr; AED 0.5–1.2 M/yr | Fig. 19 est |
| Rig bill of materials | ≈ AED 970 | Section 7 unverified prices |
| Team effort | ≈ 86 hours over 9 weeks | Fig. 23 |
The hackathon is large and explicitly evidence-driven. Its chair has said the goal is proposals that researchers, policymakers and industry can seriously assess, and that water solutions succeed only when technical performance fits infrastructure, regulation, economics and community needs. Three Strategic Recognition Awards cover UAE water priorities, climate and environmental resilience, and potential for industry adoption. THERMO-ROUTER fits the desalination and digital/AI-enabled themes; its best route to a strategic award is an honestly bounded link to RO feed preheating at hybrid thermal/RO sites and a controller that runs on commodity hardware and refuses unsafe actions by construction.
The earlier framing ("84% thermal") is outdated. EWEC's 2024 statistical leaflet reports 1,174 million m³ of water produced, 41% of it by reverse osmosis, with Taweelah RO (909,201 m³/day nameplate) alone producing about 297 million m³ meas. The thermal fleet still dominates installed heat rejection, but it is shrinking, so the MSF-reject heat source is a transitional, site-specific opportunity. Hybrid sites such as Fujairah F2 (591,500 m³/day, of which 136,500 RO) already place a warm thermal reject next to an RO intake.
Inside a brine-recirculation MSF plant the heat-rejection section dumps the heat added by the brine heater into a large cooling-seawater stream. A Gulf performance test shows how the outgoing energy splits:
Peer-reviewed Gulf MSF models use a 38 °C brine blowdown against 28 °C seawater; industry text describes reject brine cooled to about 33 °C and discharges 5–8 K above ambient unverified. The usable excess over intake is therefore about 7–10 K, which with ε ≈ 0.7 exchangers caps realistic feed preheat at 5–7 K est. DEWA's industrial tariff is 0.23 AED/kWh up to 10,000 kWh per month and 0.38 above, plus a 0.06 fuel surcharge, giving a 0.44 AED/kWh marginal price; utility-internal electricity at a plant is cheaper, bracketed here at 0.20 AED/kWh est.
Warmer feed lowers viscosity and raises water permeability, but also raises osmotic pressure and salt passage. The net effect depends on salinity and on whether the plant is re-optimised. Maisonneuve's group (Desalination 573, 2024) reports up to 24% specific-energy savings for seawater heated 20→50 °C and 33% for brackish water, falling to 12% and 18% once the thermal input is counted model. An exergy study of a triple-pass seawater plant found exergetic efficiency rising from 27.8% to 29.9% as feed went from 15 to 33 °C. The limits matter just as much:
Because the benefit is a property of the operating point rather than a law, the value of heat delivered to an RO feed is capped and non-monotone. That is the single most important input to the controller design in Section 6: above the SEC-optimal temperature, more heat is worth nothing, and above about 35–40 °C it is harmful.
Industrial heat-recovery loops (University of Waikato, dairy factories) show that a relatively small buffer tank can support more than 90% of targeted recovery, with a modelled loop reaching 94% of the recovery target model. The same group records the failure mode that matters most for a small rig: when layers mix, the loop is shut down until hot and cold regions re-form. Stratification is therefore a control problem as much as a design detail.
Design rules from the literature: inlet densimetric Froude number at or below 2 (chilled-water practice), inlet Richardson number above about 10 for negligible mixing (Bahnfleth), radial disc or ring-opening plate diffusers, plastic walls to avoid axial wall conduction, and an aspect ratio of 3–4. The proposed tank is a 200 mm PVC tube about 0.68 m tall with 25 mm closed-cell foam and 3-D printed radial disc diffusers sized for Fr below 1 at 2 L/min est.
| Issue | Evidence | Consequence |
|---|---|---|
| Double-approach penalty in the heat-recovery loop | Two equal exchangers in series halve the effective NTU (Fig. 9) | Feed reaches 35.8 °C instead of 39.0 °C in the 45/25 °C example; 23% less lift whenever source and demand coincide est |
| Stratification at 20 L | Optimum H/D 3–4; diffusers and Fr ≤ 2; loops shut down when stratification is lost (Fig. 7–8) | A squat cooler box behaves as a mixed tank; a tall tube with printed diffusers is needed and must be measured |
| AI advantage driven by price, not physics | Pumping ≈ 1% of recovered heat; learned ≈ threshold on energy (Fig. 11, 20) | Judges may read the result as tariff-engineered; value must come from caps, intermittency and non-monotone heat value |
| RO preheat oversold | SEC minimum ≈ 30 °C; +7.5% after 40 °C; Gulf summer 32–34 °C (Fig. 4–6) | The earlier AED 6.4 M/yr assumed 10 K all year; revised to AED 0.5–1.0 M/yr (Section 10) |
| Data scarcity | Black-box surrogate needed ≈ 24 simulated hours for 30–60% gap closure (Fig. 13) | Too much rig time in nine weeks; use physics structure plus residual learning and active excitation |
| Safety of learned control | Shielded-RL literature; no hardware RL precedent for small stores | A learned policy driving a 1.5 kW heater needs a verified shield and an interpretable policy |
Three principles define v2. Never pass heat through two exchangers when one will do: when hot source and cold demand coincide, waste heat goes straight to the feed through HX-D. Store only what the feed cannot take now: surplus charges the tank through HX-C and returns through HX-S when the source is absent. Cascade the feed from cold to hot: it meets HX-S (cooler) first and HX-D (hotter) second, so each exchanger works across the smallest useful temperature difference and the top-up heater only trims.
The desalination twist is a capped, non-monotone value of heat. The feed-outlet cap (30–32 °C at plant, scaled to 35 °C on the rig) becomes an active constraint; when the direct path would overshoot, the controller must divert surplus to storage or bypass. This is the constraint-switching situation in which prediction has real value: charge the tank now because the source will vanish in ten minutes and the feed will need it then. A hardware-in-the-loop "virtual RO" layer converts the measured feed temperature into kWh/m³ using a published-shape SEC(T) curve, so the controller is scored on physics-driven value while every claim stays traceable to measured temperatures.
| Metric | (a) 3-way valve | (b) Heat recovery loop | (c) v2 cascade |
|---|---|---|---|
| Exchangers in the heat path | 1 | 2 | 1 (overlap) / 2 (stored) |
| Feed outlet, 45/25 °C, ε 0.70 est | 39.0 °C | 35.8 °C | 39.0 °C direct |
| Recover and store at once | No | Yes | Yes |
| Utilisation at f = 0.5 est | 0.35 | 0.50 | 0.58 |
| Handles a feed temperature cap without dumping heat | No | Partly | Yes (surplus → tank) |
| Actuators | 1 pump + 3-way valve | 3 pumps | 5 PWM pumps |
| Rig cost est | ≈ AED 700 | ≈ AED 900 | ≈ AED 970 |
| Training data est | n/a | ≈ 24 h black-box prior | ≈ 6–8 h grey-box + residual |
| Deployable policy | Fixed / threshold | Surrogate-in-the-loop search | Distilled tree + shield |
| Main risk | No storage benefit | Double approach; stratification | More plumbing; five pumps to tune |
The team's simulation (10-node stratified tank, ε-NTU exchangers with UA 180 W/K, 2-hour runs on four disturbance profiles, four controllers on identical inputs) is the best current evidence on what the AI can and cannot deliver. The results are shown without adjustment.
| Profile | Learned vs B, energy | Oracle vs B, energy | Learned vs B, cost | Oracle vs B, cost | Gap closed by learned |
|---|---|---|---|---|---|
| steady | +0.0% | +0.0% | +0.4% | +14.1% | 3% |
| steps | +0.0% | +0.1% | +3.2% | +13.8% | 23% |
| intermittent | -0.3% | +0.0% | +14.0% | +26.4% | 53% |
| day_cycle | -0.3% | -1.1% | +22.8% | +40.9% | 56% |
The reading for the report: adaptive control cannot beat a good rule by more than about 1% on energy alone at this scale, and saying so is consistent with Zotica, Pérez-Piñeiro and Skogestad's finding that systematically designed classical control matches MPC for a storage tank. The gains appear when heat and electricity are priced differently, when the profile is intermittent, and, in v2, when a temperature cap makes "when not to recover" a real decision.
Model. The base is the existing 10-node tank with a fitted vertical mixing coefficient, ε-NTU exchangers with UA = a·ṁn, and pump power P = p0 + p3·PWM³: about 8–10 physically meaningful parameters identified by least squares from about three hours of excitation. A five-member gradient-boosted ensemble then learns only the residual between measured and grey-box predictions. The ensemble's disagreement drives active learning: candidate ten-minute action sequences with the highest predicted disagreement are run next. A real borehole store modelled with a physics-informed network reached an outlet MAE of 0.3 °C versus 0.6 °C for a plain network and degraded less with fewer data meas; that is the closest evidence for the expected data efficiency.
Teacher. Every 30 s, an economic MPC maximises Σ[value of feed heat via SEC(T) − electricity price × pump energy − heater energy] + terminal value of stored exergy − switching penalty over a 10–20 minute horizon, subject to the feed cap, tank limits and minimum flows, over discrete pump levels with a beam search. The oracle is the same MPC with the true model and perfect forecast, used only for gap accounting.
Student. A decision tree of depth at most 6 (about 64 leaves) is trained by DAgger: run the tree on the rig, let the teacher label the states it visits, repeat for three or four rounds. In an office and a lecture theatre, an approximate MPC trained on MPC data retained 88–99% of full MPC's cooling-energy savings meas, which is the evidence that distillation costs little. The tree fits on a poster, and interpretable rules behind a shield are an adoption argument industry understands.
Shield. A fixed set of overrides after the policy (feed ≤ cap, tank ≤ 60 °C, heater only with measured flow, dry-run and sensor-sanity checks), following the shielded-reinforcement-learning pattern in which a shield corrects only unsafe actions and agents never violated safety model.
Estimators. An extended Kalman filter on the 10-node model, corrected by four tank probes, gives state of charge and thermocline position with uncertainty. A recursive least-squares estimate of each exchanger's UA, normalised by its clean fit, feeds a CUSUM fouling detector and, because the controller's model uses the same UA, fouling changes routing automatically.
| Item | Qty | AED (est.) | Note |
|---|---|---|---|
| ESP32 development board | 1 | 25 | Wi-Fi logging to a laptop |
| DS18B20 waterproof probes | 8 | 80 | 4 in the tank, 4 at exchanger ports; 11-bit mode (0.125 °C, ≈375 ms) |
| Low-flow Hall sensors (≈0.3–6 L/min) | 3 | 60 | YF-S201 is weak below 1 L/min |
| INA219 power sensors | 4 | 48 | Pump power; heater via SSR duty × measured element power |
| 12 V brushless DC pumps, PWM | 5 | 175 | MOSFET driver boards ≈ 20 |
| Brazed-plate exchangers, 10–20 plates | 2 | 220 | HX-D and HX-S |
| Copper coil exchanger (6 m × 8 mm) | 1 | 60 | HX-C in an insulated box |
| 200 mm PVC tube 0.75 m, caps, foam | 1 | 110 | H/D ≈ 3.5 tank |
| 3-D printed diffusers, manifolds, probe glands | — | 20 | PETG, keep below 70 °C |
| Hot reservoir, 1.5 kW element, SSR, thermal fuse | 1 | 90 | Source emulator on an RCD-protected outlet |
| 12 V 10 A supply, tubing, fittings, shunt valve | — | 80 | Plus makerspace stock |
| Total | ≈ 968 | Prices unverified; about AED 30 of slack |
Temperature: all probes in a stirred, insulated bath at about 20, 30, 40 and 55 °C against one reference, with a per-probe affine correction (a 2026 metrology study found linear correction cut DS18B20 mean error from 3% to 0.85%), then matched in situ under isothermal circulation because heat rates depend on differences. Flow: gravimetric (bucket and scale, 60 s timings) at five flows per sensor in the installed plumbing, since the calibration slope shifts with pipe size. Power: each INA219 against a bench meter at three loads. Closure: hot-side heat released must equal cold-side heat gained within ±5% per exchanger at steady state; failing runs are excluded.
Log at 1 Hz: all temperatures, flows, PWM commands, INA219 readings, SSR state, ambient, run ID, profile phase, controller ID and shield-override flags, as raw CSV with a JSON metadata header. Downsample to 10 s for modelling; control at 30 s. Budget about 7 h of excitation in three active-learning rounds plus 3 h of commissioning and stratification tests (charge at 1, 2 and 3 L/min; compute the MIX number and thermocline thickness from the four probes). Split by run, never by sample: leave-one-run-out for model accuracy and a held-out test day of two unseen profiles. Report grey-box only, black-box only and grey-box plus residual at 2, 4 and 7 h of data (Fig. 15). Policy metrics: net benefit in Wh and virtual-RO kWh-equivalent, cap-violation integral (K·min), switches, shield overrides, and gap closure G = (JC − JB)/(Joracle − JB).
Four 60-minute profiles: step changes, intermittent source (15 min on/off), cap-active (source hot enough that direct use would exceed the cap), and a compressed day cycle. Before each run, circulate the tank to 25.0 ± 0.5 °C uniform with the source off and verify all four probes within 0.5 K. Design: 4 profiles × 3 controllers (A fixed, B the best threshold/selector scheme tunable in four hours, C the distilled tree) × 3 repeats = 36 runs in randomised blocks, plus four teacher-reference runs; about 50 h of rig time at 75 min per run including reset. Analyse paired differences (C − B) per profile with bootstrap 95% confidence intervals.
Emulate fouling with a calibrated shunt valve bypassing a fraction of hot flow around HX-D, mapped to equivalent UA loss with the clean ε-NTU fit. Test 0, 10, 20 and 30% equivalent loss, three runs each; report detection probability, median time to detect and false alarms per clean hour; compare the residual rule with RLS-UA plus CUSUM; and show that routing shifts as UA falls.
| Assumption | Value | Basis |
|---|---|---|
| RO train | 100,000 m³/day permeate, 42% recovery | Earlier case prior |
| Baseline specific energy | 3.0 kWh/m³ | Between Taweelah 2.77 and contractual 3.10 unverified |
| Sensitivity | 0.8 %/K (range 0.5–1.0) | 24% over 30 K in the thermally enhanced RO model; flattens near 30 °C model |
| Target and cap | 30 °C; lift ≤ 6 K | SEC minimum; reject excess 7–10 K × ε 0.7 est |
| Electricity value | 0.20–0.44 AED/kWh | Utility-internal estimate to DEWA industrial marginal |
| Sensitivity | Annual saving | AED/yr at 0.20 | AED/yr at 0.44 | kWh/m³ annual average |
|---|---|---|---|---|
| 0.5 %/K | 1.7 GWh | 0.34 M | 0.74 M | 0.046 |
| 0.8 %/K | 2.7 GWh | 0.54 M | 1.19 M | 0.074 |
| 1.0 %/K | 3.4 GWh | 0.67 M | 1.48 M | 0.092 |
The required thermal duty is about 2,830 kg/s × 4.0 kJ/kg·K × 6 K ≈ 68 MW, of the order of one large MSF unit's heat rejection (cooling flow four to seven times distillate flow at 7–10 K above intake) est. Payback cannot be stated responsibly without vendor quotes for titanium plate exchangers and seawater piping at that duty; only the revenue side is presented.
| Risk | Likelihood / impact | Mitigation and fallback |
|---|---|---|
| Tank does not stratify (poor MIX number) | Medium / medium | Lower charge flow, wider diffuser gap, perforated baffle; fall back to a mixed-tank model with reduced storage efficiency |
| Exchanger ε low at 0.5–2 L/min | Medium / medium | Measure ε(ṁ) in week 3; rescale profiles to flows with ε ≥ 0.5; the grey-box absorbs the fitted UA(ṁ) |
| Flow-sensor inaccuracy at low flow | High / medium | Low-flow sensors; gravimetric calibration; energy-balance cross-check |
| Heater or electrical hazard | Low / high | RCD outlet, thermal fuse, SSR on a heatsink, shield interlock (heater needs measured flow), never unattended |
| Learned controller ≈ threshold | Medium / medium | Report it honestly; cap-active and intermittent profiles are where a difference is expected; gap closure and data efficiency remain valid results |
| Schedule slip from coursework | High / high | Freeze design in week 1; cut the day-cycle profile and one repeat (24 runs) if behind; simulation results as backup |
| Leaks or softened printed parts | Medium / low | Keep printed parts ≤ 60 °C; pressure-test at commissioning; drip trays |
| Budget overrun | Medium / low | Drop to four pumps by charging through an immersed coil; reuse makerspace stock |
Build the v2 cascade: a tall 20 L plastic tank with printed radial diffusers, a priority direct path through HX-D, surplus charging through HX-C, cold-to-hot feed staging through HX-S then HX-D, five PWM pumps, eight calibrated probes, low-flow sensors and power metering. Build the ML stack: grey-box model plus residual ensemble, economic MPC teacher with a virtual-RO value curve and a feed cap, a DAgger-distilled decision tree on the ESP32, a hard-coded shield, a Kalman tank-state estimator and a recursive UA estimator that doubles as the fouling monitor.
Claim, if the data support it: measured net-benefit differences between A, B and C with pooled confidence intervals; the fraction of the oracle gap closed by the deployable tree; a data-efficiency curve showing the grey-box-plus-residual model reaching target accuracy with less rig data than a black-box model; zero cap violations under the shield; fouling detection rates and automatic re-routing; and a screening-level plant estimate of about 2.7 GWh/yr (AED 0.5–1.2 million) for a 100,000 m³/day RO train at a hybrid site, explicitly seasonal and capped near 30 °C.
Do not claim large energy savings from AI at tabletop scale; year-round RO benefit or preheating to 40–45 °C; that reinforcement learning is necessary; that the rig measures membrane performance; or any payback period before exchanger and piping quotes exist.
The defensible pitch: a safe, interpretable, data-efficient learned router that knows when not to recover heat, demonstrated on real hardware and mapped honestly to a UAE desalination use case.