Generalized additive models included a multi-year trend, a seasonal trend, and an autoregressive error term. The multi-year trend was estimated using a thin plate regression spline and the seasonal trend using a cyclic cubic regression spline. We fit separate cyclic splines to orthophosphate data collected at the treatment plant and in the distribution system, and we included a parametric term to model the difference in orthophosphate residual between these two groups. The autoregressive error term was second order in the models fitted to the temperature and orthophosphate product dose series and continuous-time first-order otherwise. Equation ( ) describes the basic model.