## 4 Conclusions  
An optimized pre-treatment system able to remove trace contaminants found in biogas produced by a full-scale FW anaerobic digester was reported in this study. The trace compounds detected in biogas were H\({}_{2}\)S, VOCs, NH\({}_{3}\), HCl, H\({}_{2}\)O, and N\({}_{2}\) with an annual average concentration of 1207 (ppm\({}_{v}\)), 895 (mg/Nm\({}^{3}\)), 36 (mg/Nm\({}^{3}\)), 17 (mg/Nm\({}^{3}\)), 0.3 (%vol) and 0.2 (%vol), respectively. The goal of the AD plant was to upgrade biogas to biomethane using a membrane-based system and to inject it into the natural gas network for the transport sector. For this purpose, a pre-treatment system composed of micro-oxygenation, chemical scrubber, cooling, and activated carbon sections was optimized based on the type and concentration of the traces contaminants found in biogas and, of course, on the desired final biomethane fuel characteristics. Insufflating an O\({}_{2}\) volume of 0.3% in the digester headspace allowed for a reduction of H\({}_{2}\)S concentration by 69.3%. Biogas treatment in a chemical scrubber with FeCl\({}_{3}\) and NaOH solutions led to further H\({}_{2}\)S elimination and the partial abatement of VOCs, NH\({}_{3}\), HCl, and CO\({}_{2}\). The selected operating values of FeCl\({}_{3}\) and pH were the result of the balance between the H\({}_{2}\)S removal efficiency and the operating costs of the chemical scrubber. The subsequent cooling section was able not only to remove water vapor from the biogas but also to further reduce the concentration of H\({}_{2}\)S, VOCs, NH\({}_{3}\), and HCl. After the cooling unit, the H\({}_{2}\)S concentration in biogas had values lower than 30 mg/Nm\({}^{3}\). The activated carbon section allowed for the elimination of the last traces of biogas contaminants before biogas entered the upgrading system. At last, the membrane-based upgrading unit was able to separate the CO\({}_{2}\) stream and release biomethane, meeting national regulatory limits for trace contaminants. The biogas plant plans to improve some downstream processes of the entire purification system, such as the recovery and purification of elemental sulfur at the exit of the chemical scrubber and of CO2 at the exit of the membrane system for subsequent industrial uses.  
The following supporting information can be downloaded at: [[https://www.mdpi.com/article/10.3390/app14052053/s1](https://www.mdpi.com/article/10.3390/app14052053/s1)]([https://www.mdpi.com/article/10.3390/app14052053/s1](https://www.mdpi.com/article/10.3390/app14052053/s1)), Table S1: Analytical details; Table S2: Bio-CH4 specification.  
Conceptualization, A.L.P. and M.S.; methodology, A.L.P., M.S., C.L. and A.S.; validation, C.L. and A.S.; formal analysis, A.L.P. and M.S.; investigation, A.L.P. and M.S.; resources, C.P.; data curation, A.L.P.; writing--original draft preparation, A.L.P. and M.S.; writing--review and editing, M.S.; supervision, C.L. and A.S.; project administration, A.L.P. and C.P.; funding acquisition, C.P. All authors have read and agreed to the published version of the manuscript.  
This research was funded by MUR--Ministry of University and Research. Project name: WWGF--Gassificazione di rifuiti organici umidi con acqua supercritica per produzione di biometano e GNL, grant number ARSO1_00868.  
Not applicable.  
Data is contained within the article and Supplementary Materials.  
Authors [PERSON] and [PERSON] were employed by the company Calabra Maceri e Servizi s.p.a. Author [PERSON] was employed by the company Waste to Methane s.r.l. The remaining authors declare that the research was conducted in the absence of any commercial or financial relationships that could be construed as a potential conflict of interest.