JolWatch Edge: Offline-First Water Intelligence and Deterministic Leak Detection for Low-Connectivity Facilities

Shawon Khan
Independent Developer & Engineering Researcher
Dhaka, Bangladesh
GitHub: @shawonsmith · Email: smithitcompany@gmail.com
Abstract

Undetected distribution leaks and overhead reservoir overflows in community facilities across low-connectivity regions lead to acute resource wastage and substantial financial liabilities. Conventional IoT water management architectures impose heavy prerequisites on continuous cloud connectivity, commercial cellular bandwidth, and centralized telemetry. These dependencies frequently fail in off-grid environments. This paper presents JolWatch Edge, an open-source, deterministic water intelligence prototype designed for fully decentralized edge execution. By computing discrete flow balances between a primary inlet meter and monitored downstream sub-zones, the system applies transparent mathematical rules to identify normal flow, structural pipe leaks, tank overflows, and sensor calibration discrepancies without cloud connectivity. Furthermore, an Essential Reserve Clock projects usable endurance hours during municipal outages while enforcing a protected buffer. Synthetic benchmarks across boundary conditions validate the system's deterministic decision boundaries with a 28-test automated verification suite, establishing an extensible foundation for subsequent physical sensor test-rig validation.

1. Introduction & Problem Statement

Water distribution systems in schools, primary healthcare clinics, and community facilities in developing economies frequently operate under intermittent municipal supply or decentralized tube-well pumping. Community facilities frequently experience critical water, sanitation, and hygiene (WASH) infrastructure limitations (World Health Organization, 2019). Furthermore, achieving universal water access under Sustainable Development Goal 6 targets requires substantial capital investment and proactive loss mitigation (Hutton and Varughese, 2016). Facilities store water in overhead reservoirs to buffer against supply disruptions. However, piping infrastructure in these settings suffers from high rates of hidden leakage behind walls and underground, as well as mechanical float-valve failures that cause undetected overflows. Empirical plumbing end-use studies demonstrate that fixture leakage and unmonitored line failures represent significant fractions of aggregate municipal draw (Mayer et al., 2016).

Traditional monitoring relies on delayed utility billing, leaving leaks undetected for weeks. Modern commercial IoT monitoring solutions, while technologically advanced, are engineered for high-bandwidth cloud backends with recurring SaaS subscription fees. In resource-constrained facilities throughout the Global South, where internet outages are common, cloud-dependent alert pipelines fail to provide timely intervention.

2. Mathematical Formulation

2.1 Flow-Balance & Loss Rate Derivation

Consider a facility plumbing network with an instantaneous volumetric inflow \(Q_{in}(t)\) (L/min) and \(k\) monitored downstream sub-zones \(Q_{z,i}(t)\) (e.g., washrooms, kitchens, outdoor grounds, drinking points). The recorded aggregate demand \(Q_{zones}(t)\) is:

Q_zones(t) = ∑ Q_{z,i}(t) [for i = 1 to k]
EstimatedLoss(t) = max(0, Q_in(t) - Q_zones(t))
LossRate(t) = (EstimatedLoss(t) / Q_in(t)) × 100 [if Q_in(t) > 0]

2.2 Decision Classification Rules

To maintain operational transparency, JolWatch Edge avoids opaque machine learning models in favor of five deterministic, explainable rules:

2.3 Essential Reserve Clock Projection

Given reservoir capacity \(C\) (L), level \(H(t)\) (%), and protected reserve fraction \(\beta\) (\(0.20\) for schools, \(0.30\) for clinics):

V_usable(t) = max(0, C × (H(t)/100) - C × β)
T_reserve(t) = V_usable(t) / (Demand_hourly + 60 × EstimatedLoss(t))

3. System Architecture & Edge Feasibility

The reference software implementation for JolWatch Edge (Khan, 2026) is designed for deployment on low-cost ESP32-class microcontrollers interfacing with hall-effect pulse flow sensors (YF-S201) and waterproof ultrasonic depth sensors (JSN-SR04T). The computation engine is fully self-contained in js/engine.js, requiring zero external runtime dependencies. Local persistence utilizes client-side storage with an exportable JSON schema, ensuring zero telemetry leakage.

4. Validation & Deterministic Benchmarking

Case Scenario Inlet Zones Loss Rate Duration Decision
TC-01 Normal Usage 32.0 L/min 30.5 L/min 4.7% 20 min Normal
TC-02 Hidden Leak 44.0 L/min 30.0 L/min 31.8% 35 min Possible hidden leak
TC-03 Tank Overflow 52.0 L/min 20.0 L/min 61.5% 20 min Possible tank overflow
TC-04 Sensor Mismatch 25.0 L/min 34.0 L/min 0.0% 10 min Sensor mismatch
TC-05 Elevated Short Gap 40.0 L/min 34.0 L/min 15.0% 5 min Monitor
Table 1: Canonical deterministic evaluation dataset validated by automated test suite (28/28 tests passing).

5. Honest Disclosures & Research Roadmap

Current Prototype Status: This work represents a validated software implementation using synthetic benchmarks. Physical sensor rig deployment, empirical calibration of thresholds against physical pipeline friction, and long-term field validation remain subsequent milestones.

Water Potability Disclaimer: The tank maintenance attention indicator evaluates physical observational proxies (turbidity, TDS shift, temperature, inspection intervals). It cannot detect microbiological pathogens, viruses, or dissolved arsenic, and does not certify drinking water safety.

6. Conclusion

JolWatch Edge demonstrates that practical water conservation and leak mitigation in developing facilities do not require continuous cloud access or expensive proprietary hardware. By running transparent flow-balance heuristics on edge runtimes, facilities can safeguard essential water reserves, detect infrastructure failures early, and verify maintenance outcomes locally.

References

  1. World Health Organization (WHO), "Water, Sanitation, and Hygiene in Health Care Facilities: Practical Steps to Achieve Universal Access," 2019.
  2. Hutton, G., & Varughese, M., "The Costs of Meeting the 2030 Sustainable Development Goal Targets on Drinking Water, Sanitation, and Hygiene," World Bank, 2016.
  3. Mayer, P. W., et al., "Residential End Uses of Water, Version 2," Water Research Foundation, 2016.
  4. Khan, S., "JolWatch Edge: Offline-First Water Intelligence and Deterministic Leak Detection Prototype," Zenodo, 2026. DOI: 10.5281/zenodo.23071819