## 2 Materials and Methods
### Water Physical and Chemical Analysis  
Samples were collected for analysis from the vermifilter feed, the vermifilter effluent, and the hydroponic growth container, on the day after the addition of a new portion of piggery effluent to the mixing tank.  
Electrical conductivity (EC) and pH were measured directly by electrometric equipment. EC was measured by an Edge HI2030 conductometer connected to an HI763100 cell (Hanna Instruments). For pH measurements, a pH212 potentiometer with an HI1131 selective hydrogen electrode was used (Hanna Instruments).  
5-day biochemical oxygen demand (BOD\({}_{5}\)) was determined in water samples according to the International Standard ISO 5815-1:2019 [39].  
Nitrate was determined by the brucine colorimetric method according to the United States Environment Protection Agency (EPA) Method 352.1, with potassium nitrate used as a standard for calibration curves [40]. Nitrite (NO\({}_{2}\)-N) was determined colorimetrically according to the Standard Method for the Examination of Water and Wastewater (SMEWW) 4500-NO\({}_{2}\)\({}^{-}\).B; calibration curves were produced using sodium nitrite as standard [41]. Ammonia nitrogen (NH\({}_{3}\)-N) was determined colorimetrically according to the international standard ISO 7150-1:1984; calibration curves were made with ammonium chloride as standard [42]. Dissolved phosphorus was determined colorimetrically according to SMEWW-P E [41], with dihydrogen phosphate as standard, after filtration; total phosphorus was determined by the same method after digestion with 1:50 of concentrated sulphuric acid and 1:10 of concentrated nitric acid, heating until volume reduction to less than 20% and neutralizing with 1 mol/L NaOH, a procedure based on SMEWW-P E [41]. For all colorimetric determinations, the samples were previously filtered through Whatman Reeve Angel 0.8-0.9 \(\upmu\)m pore diameter glass fiber filters, followed by Neoreax or Normax 0.45 \(\upmu\)m pore diameter cellulose acetate or mixed cellulose esters (MCE) membranes to remove suspended solids.  
All determinations were performed in triplicate for each sample, unless stated otherwise. Standard concentrations were defined previously to present a good linearity (determination coefficients higher than 0.99) over an interval where a diluted or undiluted sample could fall. Sample concentration values were considered below the limit of quantification (LOQ) when undiluted samples yielded absorbance values below the lowest concentration calibration standard (0.05 mgNH\({}_{3}\)-N/L, 0.005 mgNO\({}_{2}\)-N/L, 1 mgNO\({}_{3}\)-N/L, or 0.100 mgP/L for both total and dissolved phosphorus).  
Relative change (RC) of each parameter through treatment in each stage was calculated using the formula:  
\[\mathrm{RC}=\frac{\mathrm{x_{\mathrm{eff}}-x_{\mathrm{feed}}}}{\mathrm{x_{ \mathrm{feed}}}}\times 100\%, \tag{1}\]  
where x\({}_{\mathrm{feed}}\) represents a parameter value in the feed, and x\({}_{\mathrm{eff}}\) is the corresponding value in the effluent in each treatment stage. Since the HRT resulted in being longer than the 7-day periods between manual wastewater dilutions, feed concentrations were calculated as average of values from the last three analysis dates (also 7 days apart), weighted for the time each concentration had been fed into the system.  
Standard error of the mean, or simply standard error (SE), was used as an uncertainty measure in all calculations.  
To test the significance of changes due to the treatment, an analysis of variance (ANOVA) was performed. \(p\)-values indicate the probability of the null hypothesis to be true (parameter values at the end of a treatment being equal to those at the start). Significance was considered low for \(p>0.05\) and very low for \(p>0.50\).