OpenSCM Two Layer Model: A Python implementation of the two-layer climate model

The evolution of the climate is controlled by highly complex physical dynamics. However, simplified representations are surprisingly powerful tools for understanding these dynamics (Held et al., 2010) and making climate projections (Meinshausen, Smith, et al., 2011). The field of simple climate modelling is widely used, in particular for assessing the climatic implications of large numbers of different emissions scenarios, a task that cannot be performed with more complex models because of computational constraints.


Summary
The evolution of the climate is controlled by highly complex physical dynamics. However, simplified representations are surprisingly powerful tools for understanding these dynamics (Held et al., 2010) and making climate projections (Meinshausen, Smith, et al., 2011). The field of simple climate modelling is widely used, in particular for assessing the climatic implications of large numbers of different emissions scenarios, a task that cannot be performed with more complex models because of computational constraints.
One of the most commonly used models of the climate's response to changes in the "Earth's energy balance" (energy input compared to energy output of the earth system) is the two-layer model originally introduced by Held et al. (2010). While this model must be given energy imbalances (more precisely, radiative forcing) rather than emissions, it is nonetheless a widely used tool within climate science. Approximately speaking, the model represents the Earth System as an ocean with two-layers. The upper layer absorbs excess heat in the Earth System and then exchanges heat with the deep layer. As a result, in response to a perturbation, the model responds with a distinctive two-timescale response, commonly referred to as the "fast" and "slow" warming components. Since Held et al. (2010), the model has been extended to include updated representations of the efficiency of ocean heat uptake  as well as a state-dependent response to radiative forcing (Bloch-Johnson et al., 2015;Rohrschneider et al., 2019).
There are many simple climate models in the scientific literature . Given the context of this paper, we provide below a table of openly accessible models, their programming language, and their approach. These models are conceptually similar to the two-layer model implemented here except they use different parameterisations for ocean heat uptake and the relationship between ocean heat uptake and warming. On top of the relationship between ocean heat uptake and warming, these models also implement many other components of the climate system, e.g., carbon cycle, methane cycle, and the relationship between changes in atmospheric greenhouse gas concentrations and atmospheric energy fluxes. The exception is the FaIR model (Smith et al., 2018), which uses the two-layer model as its thermal core.
OpenSCM Two Layer Model is an object-oriented and open-source implementation of the two-layer model. It is written in Python, a user-friendly open-source language that is popular in the climate sciences, and uses the Pint package (Grecco & others, 2020), a widely used units library, for unit handling. It provides an extensible interface for the two-layer model, which could then be coupled with other modules as researchers see fit. The implementation also provides an easy way to convert between the two-layer model of Held et al. (2010) and the mathematically equivalent two-timescale impulse response model, used most notably as the thermal core of the FaIR model (Smith et al., 2018). The conversion between the two is an implementation of the proof by . Table 1: Brief overview of other simple climate models available in the scientific literature. Shown is the model name, a brief description and relevant URL(s), and the programming language in which the model is written. The programming language shown is the one used for the model's core; other languages might be used in the development repositories for, e.g., plotting. For a more extensive list of simple climate models and references which describe the models in detail, see Table 1 of Nicholls et al. (2020).

Statement of need
OpenSCM Two Layer Model was designed to provide a clean, modularised, extensible interface for one of the most commonly used simple climate models. It was used in Phase 1 of the Reduced Complexity Model Intercomparison Project  as a point of comparison for the other participating models.
The FaIR model (Smith et al., 2020) implements a mathematically equivalent model (under certain assumptions) but does not provide as clear a conversion between the two-layer model and the two-timescale response as is provided here. We hope that this implementation could interface with other simple climate models like FaIR to allow simpler exploration of the combined behaviour of interacting climate components with minimal coupling headaches.
As implemented here, the OpenSCM Two Layer Model interface is intended to be used in research or education.