Pycham (V2.0.4): a Python Box Model for Simulating Aerosol Chambers
Total Page:16
File Type:pdf, Size:1020Kb
The University of Manchester Research PyCHAM (v2.0.4): a Python box model for simulating aerosol chambers DOI: 10.5194/gmd-14-675-2021 Document Version Final published version Link to publication record in Manchester Research Explorer Citation for published version (APA): O'Meara, S., Xu, S., Topping, D., Alfarra, M. R., Capes, G., Lowe, D., Shao, Y., & McFiggans, G. (2021). PyCHAM (v2.0.4): a Python box model for simulating aerosol chambers. Geoscientific Model Development. https://doi.org/10.5194/gmd-14-675-2021 Published in: Geoscientific Model Development Citing this paper Please note that where the full-text provided on Manchester Research Explorer is the Author Accepted Manuscript or Proof version this may differ from the final Published version. If citing, it is advised that you check and use the publisher's definitive version. General rights Copyright and moral rights for the publications made accessible in the Research Explorer are retained by the authors and/or other copyright owners and it is a condition of accessing publications that users recognise and abide by the legal requirements associated with these rights. Takedown policy If you believe that this document breaches copyright please refer to the University of Manchester’s Takedown Procedures [http://man.ac.uk/04Y6Bo] or contact [email protected] providing relevant details, so we can investigate your claim. Download date:29. Sep. 2021 Geosci. Model Dev., 14, 675–702, 2021 https://doi.org/10.5194/gmd-14-675-2021 © Author(s) 2021. This work is distributed under the Creative Commons Attribution 4.0 License. PyCHAM (v2.1.1): a Python box model for simulating aerosol chambers Simon Patrick O’Meara1,2, Shuxuan Xu1, David Topping1, M. Rami Alfarra1,2, Gerard Capes3, Douglas Lowe3, Yunqi Shao1, and Gordon McFiggans1 1Department for Earth and Environmental Sciences, University of Manchester, Manchester, M13 9PL, UK 2National Centre for Atmospheric Science, University of Manchester, Manchester, M13 9PL, UK 3Research Computing Services, University of Manchester, Manchester, M13 9PL, UK Correspondence: Gordon McFiggans (g.mcfi[email protected]) Received: 13 July 2020 – Discussion started: 20 August 2020 Revised: 2 November 2020 – Accepted: 10 December 2020 – Published: 2 February 2021 Abstract. In this paper the CHemistry with Aerosol Mi- 1 Introduction crophysics in Python (PyCHAM) box model software for aerosol chambers is described and assessed against bench- mark simulations for accuracy. The model solves the coupled Many major advances in atmospheric modelling have arisen system of ordinary differential equations for gas-phase chem- from chamber observations: for example, the partitioning of istry, gas–particle partitioning and gas–wall partitioning. Ad- vapours to particles (Odum et al., 1996), the gas-phase chem- ditionally, it can solve for coagulation, nucleation and parti- istry of ozone as part of the Master Chemical Mechanism cle loss to walls. PyCHAM is open-source, whilst the graph- (MCM) (Jenkin et al., 1997), and the gas-phase chemistries ical user interface, modular structure, manual, example plot- of limonene (Carslaw et al., 2012) and β-caryophyllene ting scripts, and suite of tests for troubleshooting and track- (Jenkin et al., 2012). Such advances can be incorporated into ing the effect of modifications to individual modules have improved chamber models (e.g. Charan et al., 2019), aiding been designed for optimal usability. In this paper, the mod- the design of experiments to interrogate further processes elled processes are individually assessed against benchmark and systems (e.g. Peräkylä et al., 2020). As chamber use simulations, and key parameters are described. Examples of has multiplied, so too have chamber models, with many now output when processes are coupled are also provided. Sensi- published (Naumann, 2003; Pierce et al., 2008; Lowe et al., tivity of individual processes to relevant parameters is illus- 2009; Roldin et al., 2014; Sunol et al., 2018; Topping et al., trated along with convergence of model output with increas- 2018; Charan et al., 2019; Roldin et al., 2019). Chamber sci- ing temporal resolution and number of size bins. The latter entists without modelling expertise or access may be limited sensitivity analysis informs our recommendations for model in the design, interpretation and advancement of both cham- setup. Where appropriate, parameterisations for specific pro- ber experiments and their contribution to models. To address cesses have been chosen for their general applicability, with this requirement PyCHAM (CHemistry with Aerosol Micro- their rationale detailed here. It is intended for PyCHAM to physics in Python) has been developed in the framework of aid the design and analysis of aerosol chamber experiments, the EUROCHAMP2020 Simulation Chamber Research In- with comparison of simulations against observations allow- frastructure (Oliveri, 2018). ing improvement of process understanding that can be trans- In this paper the processes represented in PyCHAM are ferred to ambient atmosphere simulations. described, along with details of software application. Where relevant, equations are presented and output from PyCHAM is compared against benchmark simulations to assess accu- racy and determine whether calculations are performing as intended. It is not the intention of this paper to compare Py- CHAM against observations, which is the focus of future Published by Copernicus Publications on behalf of the European Geosciences Union. 676 S. P. O’Meara et al.: PyCHAM (v2.1.1): Chemistry and Aerosol Microphysics in Python work. In the following two sections the objectives, rationale action modules. PyCHAM treats gas-phase photochemistry, and structure of the software are explained. gas–particle and gas–wall partitioning, coagulation, nucle- ation, and particle deposition to walls in zero dimensions. A key feature is its aim to be generally applicable such that gas– 2 Purpose and scientific basis wall partitioning, particle deposition to walls and nucleation – all processes with outstanding uncertainties – are param- Consistent with the criteria set by the EUROCHAMP2020 eterised and may be fitted to observations. Below we detail research project (Oliveri, 2018), PyCHAM is open-source the constraint necessary for fitting the relevant parameters. (available at https://github.com/simonom/PyCHAM, last ac- The full list of PyCHAM applications is numerous and will cess: 27 January 2021), user-friendly and aims to be capa- increase as chamber experiments evolve. Key applications in- ble of representing the latest scientific understanding. It has clude designing chamber experiments, developing gas-phase been designed and tested on desktop computers for Win- photochemistry mechanisms, quantifying gas–wall partition- dows, Linux and Mac operating systems. Python is the cho- ing parameters, developing nucleation models and interrogat- sen language for two key reasons: code can be transferred be- ing the effects of processes on secondary particulate matter tween computers without the limitation of requiring a native (SPM) evolution. or proprietary compiler (thereby improving ease of use and The processes included in PyCHAM are typically a sub- portability), and the relatively versatile parsing capability al- set of those represented in large-scale (regional and global) lows the user to readily vary model inputs. The accessibility, atmospheric models, and it is intended that once a process usability and basic functionality of PyCHAM have been re- has been successfully modelled by PyCHAM it can be trans- viewed in O’Meara et al.(2020). The current paper presents ferred, possibly via parameterisation, to a large-scale model a detailed description and introductory analysis of the Py- for evaluation and application (as illustrated by the gas– CHAM functionality that was not the focus of O’Meara et al. particle partitioning and gas-phase chemistry advances cited (2020). in the Introduction). When interrogating the simulation of a Aerosol chambers (interchangeably called smog cham- given process it is necessary that conflating processes are bers), defined as those used for interrogating gas- and modelled accurately such that uncertainty around their ef- particle-phase processes, provide a method for isolating spe- fects is not compromising. Therefore, the main objective of cific processes of interest without the conflating effects this paper is to assess the accuracy and precision of the fun- present in the ambient atmosphere. Ultimately, the goal of damental representation of the individual processes consid- the chamber is to improve understanding and quantitative ered in PyCHAM through comparison with benchmark sim- constraints on the evolution of the physicochemical proper- ulations. Comparison of some results presented below with ties of the gas and particle phase (Schwantes et al., 2017; experimental observations is possible; however, it is beyond Charan et al., 2019; Hidy, 2019). A description of chamber the scope of this paper to investigate the accuracy of chem- processes first requires consideration of the chamber char- ical mechanisms or estimation methods that PyCHAM can acteristics, including wall material (frequently fluorinated use. Rather, the examples below illustrate the utility of Py- ethylene–propene film – FEP Teflon – though others are CHAM to test the sensitivity of such techniques. used), lighting and dimensions. Two approaches are used to An example of PyCHAM application in which several ma- inlet components: