Shallow aquifers in intensively managed alluvial plains worldwide are increasingly impacted by inorganic nitrogen, yet the simultaneous occurrence and interconversion of nitrate (NO3−–N), nitrite (NO2−–N) and ammonium (NH4+–N) often confound source attribution when single indicators are used. Here, we present a transferable, process-linked framework for diagnosing “tri-nitrogen” (tri-N) pollution that integrates hydrogeochemical evolution, data-driven pattern discovery and receptor-model apportionment. We analyzed 409 shallow-groundwater samples from Shijiazhuang City (central North China Plain) for major ions and tri-N species, interpreted within Piper facies and salinization gradients, and then applied a Gaussian mixture model (GMM) to resolve multivariate hydrochemical–nitrogen end-members. Six clusters (I–VI) depict an interpretable progression from background Ca–HCO3/Ca·Mg–HCO3 waters to agricultural NO3−–N enrichment under oxic conditions and a distinct NH4+–N-rich point-source end-member under reducing conditions. An attention-based attribution model indicates that total tri-N, Na+, NO3−–N, the NO2− fraction and SO42− are the primary discriminators of cluster structure. Species-resolved positive matrix factorization (US EPA PMF 5.0) quantifies dominant controls, with agricultural leaching–nitrification explaining most NO3−–N (Factor 6, 87.9%) and sewage/manure inputs dominating NH4+–N (Factor 3, 95.3%), while NO2−–N reflects mixed contributions consistent with redox-interface transitions. Beyond this case study, the combined GMM–interpretability–PMF workflow provides a general template for separating non-point versus point tri-N inputs and for prioritizing management actions in shallow aquifers where isotope or tracer data are limited.
Wu et al. (Tue,) studied this question.