A Total Energy Error Analysis of Dynamical Cores and PhysicsDynamics Coupling in the Community Atmosphere Model (CAM)
Abstract
A closed total energy (TE) budget is of utmost importance in coupled climate system modeling; in particular, the dynamical core or physicsdynamics coupling should ideally not lead to spurious TE sources/sinks. To assess this in a global climate model, a detailed analysis of the spurious sources/sinks of TE in National Center for Atmospheric Research's Community Atmosphere Model (CAM) is given. This includes spurious sources/sinks associated with the parameterization suite, the dynamical core, TE definition discrepancies, and physicsdynamics coupling. The latter leads to a detailed discussion of the pros and cons of various physicsdynamics coupling methods commonly used in climate/weather modeling.
Key Points
 Spurious total energy dissipation in dynamical core is 0.3 W/m^{2} to 1 W/m^{2} at 1 deg
 Constantpressure assumption in physics leads to 0.3 W/m^{2} spurious total energy source
 There can easily be compensating errors in total energy budget
1 Introduction
In coupled climate modeling with prognostic atmosphere, ocean, land, landice, and seaice components, it is important to conserve total energy (TE) to a high degree in each component individually and in the complete model to avoid spurious longterm trends in the simulated Earth system. Conservation of TE in this context refers to having a closed TE budget. For example, the TE change in a column in the atmosphere is exactly balanced by the net sources/sinks given by the fluxes through the column. The fluxes into the atmospheric component from the surface models must be balanced by the fluxes in the respective surface components and so on. Henceforth, we will focus only on the atmospheric component which, in a numerical model, is split into a resolvedscale component (the dynamical core) and a subgridscale component (parameterizations or, in modeling jargon, physics). While there have been many studies on energy flow in the Earth system through analysis of reanalysis data and observations (Trenberth & Fasullo, 2018, and references therein), there has been less focus on spurious TE sources/sinks in numerical models.
The atmospheric equations of motion conserve TE, but the discretizations used in climate and weather models are usually not inherently TE conservative. Exact conservation is probably not necessary but conservation to within ∼0.01 W/m^{2} has been considered sufficient to avoid spurious trends in century long simulations (Boville, 2000; Williamson et al., 2015). Spurious sources and sinks of TE can be introduced by the dynamical core, physics, physicsdynamics coupling (PDC), and discrepancies between the TE of the continuous and discrete equations of motion and for the physics. Hence, the study of TE conservation in comprehensive models of the atmosphere quickly becomes a quite complex and detailed matter. In addition there can easily be compensating errors in the system as a whole.
Here we focus on versions of the Community Atmosphere Model (CAM) that use the spectralelement (SE; Lauritzen et al., 2018) and finitevolume (FV; Lin, 2004) dynamical cores. These dynamical cores couple with physics in a timesplit manner; that is, physics receives a state updated by dynamics (see Williamson, 2002, for a discussion of timesplit versus process split PDC in the context of CAM). In its pure timesplit form the physics tendencies are added to the state previously produced by the dynamical core and the resulting state provides the initial state for the subsequent dynamical core calculation. We refer to this as stateupdating (ftype=1 in CAM code). Alternatively, when the dynamical core adopts a shorter time step than the physics, say nsplit substeps, then (1/nsplit)th of the physicscalculated tendency is added to the state before each dynamics substep. We refer to this modification of time splitting as dribbling (ftype=0). CAMFV uses the state update (ftype=1) approach while CAMSE has options to use state update (ftype=1), dribbling (ftype=0), or a combination of the two, that is, mass variables use stateupdating and remaining variables use dribbling. We refer to this as combination (ftype=2). The dribbling variants can lead to spurious sources or sinks of TE (and mass) referred to here as PDC errors. Any error in the water mass budget associated with dribbling affects the massweightening in the TE integral and hence introduces TE errors.
The dynamical core usually has inherent or specified filters to control spurious noise near the grid scale which will lead to energy dissipation (Jablonowski & Williamson, 2011; Thuburn, 2008). Similarly, models often have sponge layers to control the solution near the top of the model that may be a sink of TE. There are examples of numerical discretizations of the adiabatic frictionless equations motion that are designed so that TE is conserved in the absence of timetruncation and filtering errors, for example, mimetic spectralelement discretizations such as the one used in the horizontal in CAMSE (Eldred & Randall, 2017; McRae & Cotter, 2013; Taylor, 2011). These provide consistency between the discrete momentum and thermodynamic equations leading to global conservation associated with the conversion of potential to kinetic energy. In spectral transform models it is customary to add the energy change due to explicit diffusion on momentum back as heating (referred to as frictional heating), so that the diffusion of momentum does not affect the TE budget (see, e.g., p.71 in Neale et al., 2012). This is also done in CAMSE (Lauritzen et al., 2018).
The purpose of this paper is to provide a detailed global TE analysis of CAM. We assess TE errors due to various steps in the model algorithms. The paper is outlined as follows. In section 2 the continuous TE formulas are given and a detailed description of spurious TE sources/sinks that can occur in a model as a whole, and the associated diagnostics used to perform the TE analysis, are defined. In section 3 the model is run in various configurations to assess their effects on TE conservation. This includes various PDC experiments leading to a rather detailed discussion of mass budget closure. We also investigate the effect of using a limiter in the vertical remapping of momentum, assess energy discrepancy errors and impacts on TE of simplifying surface conditions and dry atmosphere experiments. The paper ends with conclusions.
2 Method
2.1 Defining TE
In a moist atmosphere, however, there are several definitions of TE used in the literature related to what heat capacity is used for water vapor and whether or not condensates are accounted for in the energy equation. To explain the details of that, we focus on the energy equation for CAMSE.
Define associated heat capacities at constant pressure . We refer to condensates as being thermodynamically and inertially active if they are included in the thermodynamic equation and momentum equations; for example, if the thermodynamic equation is formulated in terms of temperature, the energy conversion term includes a generalized heat capacity which is a function of the condensates and their associated heat capacities (see, e.g., section 2.3 in Lauritzen et al., 2018). Similarly, the weight of the condensates is included in the pressure field and pressure gradient force. How many condensates are thermodynamically/inertially active in the dynamical core, and which is controlled with namelist qsize_condensate_loading. If qsize_condensate_loading = 1, only water vapor (’wv') is active, if qsize_condensate_loading = 3, ‘wv,’ ‘cl,’ and ‘ci’ are active, and if qsize_condensate_loading = 5, then ‘wv,’ ‘cl,’ ‘ci,’ ‘rn,’ and ‘sw’ are included.
We note that earlier versions of CAM using the spectral transform dynamical core used c_{p} of moist air. The adiabatic, frictionless equations of motion in the CAMSE dynamical core can be made consistent with E_{phys} by not including condensates in the mass/pressure field as well as energy conversion term in the thermodynamic equation and setting the heat capacity for moisture to (Taylor, 2011). We refer to this version of CAMSE combined with stateupdating (ftype=1) PDC as the energy consistent version; that is, the same continuous formula for energy is used in both dynamics and physics, and there are no PDC errors.
2.2 Some Remarks on Local Energy Conservation
Although this paper focuses on global average TE errors, it is important to note that energy errors occur locally. For example, when an air parcel gains or loses water via evaporation or precipitation (or via a fixer or borrower to maintain some physical property like positive definiteness), there are implications for the mass, heat content, and heat capacity of the parcel. In turn, that affects the energy and mass of the column and thereby affects the global TE budget. So anything that changes these state variables locally has implications for the TE budget.
An example of an inconsistency in CAM physics is that surface pressure is held fixed during physical parameterization updates, but water vapor, and hence surface pressure, does change during evaporation/precipitation and an inconsistency appears in the mass and energy budget (see item 2 in section 2.3). Similarly, if a “clipper” is used on water vapor or condensates to avoid (unphysical) negative mixing ratios (more details in section 3.2) and this is not accounted for in the thermodynamics or through a surface flux, that “clipping” will produce an energy source via the mass weightening in the TE vertical integral. In the dynamical core TE is not conserved locally in each column as there is a horizontal flux of energy between columns; but the local energy budget should, ideally, be closed and thereby, globally, TE should be conserved. If a dynamical core does not inherently conserve dry air mass and/or water mass then a spurious source of TE is inevitable again through the mass weightening in the vertical integral (unless fixers are applied).
2.3 Spurious Energy Sources and Sinks
 Parameterization errors: Individual parameterizations may not have a closed energy budget; for example, they may not have been designed to conserve the discrete TE as defined in the model or they may conserve a discrete TE defined differently. CAM parameterizations are required to have a closed energy budget (based on the discrete TE definition in CAM) under the assumption that pressure remains constant during the computation of the subgridscale parameterization tendencies. In other words, the TE change in the column is exactly balanced by the net sources/sinks given by the fluxes through the column (If not, a fixer needs to be applied since the CAM global TE fixer as implemented does not include any errors from the parameterizations. For example, in CAM parameterizations occasionally produce negative water vapor. These are filled without compensation and therefore affect the TE, but errors tend to be small.).
 Pressure work: That said, if parameterizations update specific humidity then the surface pressure changes (e.g., moisture entering or leaving the column). In that case the pressure changes which, in turn, changes TE. This is referred to as pressure work (section 3.1.8 in Neale et al., 2012).
 Continuous TE formula discrepancy: If the continuous equations of motion for the dynamical core conserve a TE different from the one used in the parameterizations then an energy inconsistency is present in the system as a whole. This is the case with the new version of CAMSE that conserves a TE that is more accurate and comprehensive than that used in the CAM physics package as discussed above. As also noted above, this mismatch arose from the evolutionary nature of the model development and not by deliberate design; and should be eliminated in the future.

Dynamical core errors: Energy conservation errors in the dynamical core, not related to PDC errors, can arise in multiple parts of the algorithms used to solve the equations of motion. For dynamical cores employing filtering (e.g., limiters in flux operators, Lin, 2004) and/or possessing inherent damping which controls small scales, it is hard to isolate their energy dissipation from other errors in the discretization. If a hyperviscosity term or some other diffusion is added to the momentum equation, then one can diagnose the local energy dissipation from such damping and add a corresponding heating to balance it (frictional heating). There may also be energy loss from viscosity applied to other variables such a temperature or pressure which is harder to compensate. Here is a breakdown relevant to CAMSE using a floating Lagrangian vertical coordinate:

Horizontal inviscid dynamics: Energy errors resulting from solving the inviscid, adiabatic equations of motion.
 Hyperviscosity: Filtering errors.
 Vertical remapping: The vertical remapping algorithm from Lagrangian to Eulerian reference surfaces does not conserve TE.
 Near roundoff negative values of water vapor which are filled to a minimal value without compensation.
If a dynamical core is not inherently mass conservative with respect to dry air, water vapor, and condensates, then TE conservation is affected since
(9)is not conserved. Henceforth, we assume that the dynamical core is based on an inherently massconservative formulation which is the case for CAMSE, CAMSECSLAM (Conservative SemiLAgrangian Multitracer), and CAMFV. 

Physicsdynamics coupling (PDC): Assume that physics computes a tendency. Usually the tendency (forcing) is passed to the dynamical core which is responsible for adding the tendencies to the state. PDC energy errors can be split into three types:

“Dribbling” errors (or, equivalently, temporal PDC errors): If the TE increment from the parameterizations does not match the change in TE when the tendencies are added to the state in the dynamical core, then there will be a spurious PDC error. This will not happen with the stateupdate approach in which the tendencies are added immediately after physics and before the dynamical core advances the solution in time. The PDC “dribbling” errors can be split into three contributions:
Thermal energy dribbling error: PDC errors in temperature tendencies occur because the Tincrement (call it ΔT) that the parameterizations prescribe leads to a dry thermal energy change of ΔM^{(d)}ΔT which will not match the equivalent dry thermal energy change when the temperature tendency is added in smaller chunks in the dynamical core during the “dribbling” of ΔT. The discrepancy occurs because ΔM^{(d)} changes during each dynamics time step and hence the thermal energy change due to physics forcing accumulated during the “dribbling” will not equal ΔM^{(d)}ΔT. This error could possibly be eliminated by using thermal energy forcing instead of temperature increments.
Kinetic energy dribbling error: Similarly, PDC errors in velocity component forcing increments (Δu,Δv) occur because the dry kinetic energy change of will not match the equivalent dry kinetic energy change when dribbling velocity component forcing increments (Δu,Δv). It is less clear how to eliminate this error as kinetic energy is a quadratic quantity.
Mass clipping (affects all TE terms): A similar PDC error for mass variables such as vapor forcing and cloud liquid can occur when the mass tendencies are “dribbled” during the dynamical core integration. The dynamical core transport of mass variables will move mass around in the horizonal and vertical while the “dribbled” physics mass increments are applied in the same location; in that situation a negative mass increment from the parameterizations may be larger than the mass available to remove. This can lead to a spurious source mass if there is logic in the dynamical core preventing mixing ratios/mass to become negative. This is referred to as “clipping” PDC errors, and the process is described/discussed in detail in section 3.2.1. The “clipping” changes the water mass budget without accounting for it in water fluxes or in the thermodynamics and hence lead to TE conservation errors (both kinetic and thermal energy).
 Change of vertical grid/coordinate errors: If the vertical coordinates in physics and in the dynamical core are different, then there can be spurious PDC energy errors even when using the stateupdate method for adding tendencies to the dynamical core state. For example, many nonhydrostatic dynamical cores (e.g., Skamarock et al., 2012) use a terrainfollowing height coordinate whereas physics uses pressure.
 Change of horizontal grid errors: If the physics tendencies are computed on a different horizontal grid than the dynamical core, then there can be spurious energy errors from mapping tendencies and/or variables between horizontal grids (e.g., Herrington et al., 2019).

 Compensating energy fixers: To avoid TE conservation errors which could accumulate and ultimately lead to a climate drift, it is customary to apply an arbitrary energy fixer to restore TE conservation. Since the spatial distribution of many energy errors, in general, is not known, global fixers are used. In CAM a uniform increment is added to the temperature field to compensate for TE imbalance from all processes, that is, dynamical core, PDC, TE formula discrepancy, and energy change due to pressure work error.
2.4 Diagnostics
By computing the global TE averages at appropriate places in the model algorithms, we can directly compute due to various processes (such as viscosity, vertical remapping, PDC, and pressure work error) by differencing from after and before the algorithm takes place. This has been implemented using CAM history infrastructure by computing column integrals of energy at various places in CAM and outputting the 2D energy fields. CAM history internally handles accumulation and averaging in time at each horizontal grid point. The global averages are computed externally from the grid point vertical integrals on the history files (stored in double precision). The places in CAM where we compute/capture the grid point vertical integral E are named using three letters where the first letter refers to whether the vertical integral is performed in physics (“p”) or in the dynamical core (“d”). The trailing two letters refer to the specific location in dynamics or physics. For example, “BP” refers to “Before Physics” and “AP” to “After Physics”; the associated total energies are denoted E_{pBP} and E_{pAP}, respectively. The TE tendency from the parameterizations is the difference between E_{pBP} and E_{pAP} divided by the time step. The terms and tendencies are then averaged globally externally to the model. The pseudocode in Figure 1 defines the acronyms in terms of where in the CAMSE algorithm the TE vertical integrals are computed and output. For details on the CAMSE algorithm please see Lauritzen et al. (2018).
Before defining the individual terms in detail we briefly review the model timestepping sequence starting with the physics component as illustrated in Figure 1. The energy fixer is applied first to compensate for the spurious net energy change from all components introduced during the previous time step. We will describe this in more detail after the various sources and sinks are elucidated. The parameterizations are applied next and are required to be energy conserving. They update the state and accumulate the total physics tendency (forcing). At this stage the state is saved for use in the energy fixer in the next time step. Any changes in the global average energy after this are spurious and are compensated by the fixer. The parameterizations update the water vapor but not the moist pressure, implying a nonphysical change in the dry mass of the atmosphere. The dry mass correction corrects the dry mass back to its proper value.
The forcing (physics tendency) from the parameterizations is passed to the dynamical core. If the physics and dynamics operate on different grids, the forcing is remapped here. The dynamics operates on a shorter time step than the physics and is substepped. The remapped physics increment is applied to the dynamics state, saved from the end of the previous dynamics step, using either stateupdating, dribbling, or combination as described in section 1. The dynamics then advances the adiabatic frictionless flow in the floating Lagrangian layers over a further set of substeps. Hyperviscosity is applied next with further substepping required for computational stability of the explicit discrete approximations. The energy loss from the specified momentum viscosity is calculated locally and is balanced by adding a local change to the temperature, referred to as frictional heating. This set of dynamics substeps is followed by the vertical remapping from Lagrangian to Eulerian reference layers. The remapping is required to provide layers consistent with the parameterization formulations. The vertical remapping substeps are required for stability if the Lagrangian layers become too thin.
At the end of the dynamics, the state is saved to be used by the dynamics the next time step and is also passed to the physics, with a remapping if the dynamics and physics grids differ. At the beginning of the physics the difference in energy between this state and the state saved after the physics during the previous time step is the amount needed to be added or subtracted by the energy fixer. It represents the accumulation of all spurious sources from the dry mass correction, remappings between physics and dynamics grids (if applicable), dynamical core, differing energy definitions (if present), hyperviscosity, and vertical remapping.

: TE tendency due to parameterizations. In CAM the TE budget for each parameterization is closed (assuming pressure is unchanged) so
is balanced by net fluxes in/out of the physics columns. Note that this is the only energy tendency that is not spurious since CAM parameterizations have a closed TE budget. This TE tendency is discretely computed as
(11)where Δt_{phys} is the physics time step (default 1800 s) and the subscript “phys” on refers to the energy tendency computed in CAM physics. We include the tendency to provide a reference scaling for other errors.

: Total spurious energy tendency due to pressure work error
(12)Since CAMSE dynamical core is based on a drymass vertical coordinate, the pressure work error takes place implicitly in the dynamical core. But the TE tendency due to pressure work error is conveniently computed in physics since dynamical cores based on a moist vertical coordinate (e.g., CAMFV) require pressure and moist mixing ratios to be adjusted for dry mass conservation and tracer mass conservation (section 3.1.8 in Neale et al., 2012). The difference of TE after and before this adjustment is the TE tendency due to pressure work error. In a dry mass vertical coordinate based on dry mixing ratios, neither dry mass layer thickness nor dry mixing ratios, need to be adjusted to take into account moisture changes in the column. For labeling purposes, the “total forcing” associated with physics (at least in CAM) consists of parameterizations, pressure work error, and TE fixer, although strictly speaking the fixer includes components from the dynamics as will be seen.(13)where the energy fixer TE tendency is(14)After all the TE budget terms have been defined, the exact composition of will be presented.
 : If the physics uses a TE definition different from the TE that the continuous equations of motion in the dynamical core conserve (i.e., in the absence of discretization errors), then there is a TE discrepancy tendency. This complicates the energy analysis as one cannot compare TE computed in physics directly with TE computed in the dynamical core . This makes errors associated with this discrepancy tricky to assess. That said, the TE tendencies computed using the dynamical core TE formula are well defined (self consistent) and similarly for TE tendencies computed using the “physics formula” for TE, .

The TE tendency from the dynamical core is split into several terms: Horizontal adiabatic dynamics (dynamics excluding physics forcing tendency)
(15)where over a single dynamics substep (the loop bounds nsplit, rsplit, etc. are explained in Figure 1).In CAMSE the viscosity is explicit so one can compute the TE tendency due to hyperviscosity and its associated frictional heating
(16)which, in CAMSE, includes a frictional heating term from viscosity on momentum(17)where is the time step of the substepped viscosity. Since the viscosity on momentum is compensated for via heating (frictional heating) “only” has contributions from viscosity on temperature and pressurelevel thickness. In terms of TE conservation it would be beneficial if hyperviscosity on temperature and mass could be avoided. However, the hyperviscosity on mass and temperature is necessary to keep this model stable.The residual
(18)is the energy error due to inviscid dynamics and timetruncation errors.The energy tendency due to vertical remapping is
(19)where .The 3D adiabatic dynamical core (no physics forcing but including friction) energy tendency is denoted
(20) 
: Total spurious energy tendency due to PDC errors is the difference between the energy tendency from physics and the energy tendency in the dynamics resulting from adding the physics increment to the dynamical core state
(21)where(22)and Δt_{pdc} is the time step between physics increments being added to the dynamical core. Remember we are dealing with average rates so terms computed with different time steps can be compared, but differences cannot be taken between terms sampled with different time steps.The PDC TE tendency makes use of TE formulas in dynamics and in physics so 21 is only well defined if the TE formula discrepancy is zero, . As mentioned in section 2.1, CAMSE has the option to switch the continuous equations of motion conserving the TE used by CAM physics 8 instead of the more comprehensive TE formula 7.
In CAMSE there are three PDC algorithms described in detail in section 3.6 in Lauritzen et al. (2018) and reviewed in section 1 here. One is stateupdate in which the entire physics increments are added to the dynamics state at the beginning of dynamics (referred to as ftype=1), in which case Δt_{pdc} = Δt_{phys}. Another is dribbling in which the physics tendency is split into nsplit equal chunks and added throughout dynamics (more precisely after every vertical remapping; referred to as ftype=0 resulting in ), and then a combination of the two (referred to as ftype=2) where tracers (mass variables) use stateupdate (ftype=1) and all other physics tendencies use dribbling (ftype=0).
 : Global energy fixer tendency, defined in 14, is applied at the beginning of the parameterizations. The correction needed is the global average difference between the state passed from the dynamics and the state that was saved after the physics updated the state but before the dry mass correction. It includes all spurious sources from the dry mass correction, remappings between physics and dynamics, dynamical core, differing energy definitions (if present), hyperviscosity, and vertical remapping.
2.5 A Few Observations Regarding the Energy Budget Terms
Note that we cannot use 21 to compute since .
3 Results
A series of simulations have been performed with CESM2.1 using CAM version 6 (CAM6) physics (https://doi.org/10.5065/D67H1H0V) on NCAR's Cheyenne cluster (Computational and Information Systems Laboratory, 2017). All simulations are at nominally ∼1° horizontal resolution (for CAMSE that is 30 × 30 elements on each cubedsphere face and for CAMFV its 192 × 288 latitudeslongitudes) and using the standard 32 levels in the vertical. Unless otherwise noted all simulations are 13 months in duration and the last 12 months are used in the analysis. Total energy budgets are summarized in Table 1 and discussed below. The first column gives identifying “Descriptors” which are briefly summarized below and defined in more detail in the following sections. The section titles also include the “Descriptor” from Table 1 to make it easier for the reader to match table entries with discussion in the text. Important changes to TE errors are marked with bold font in Table 1.
Descriptor  lcp_moist  ftype  

TE consistent  1  false  1  0.312  0.300  0  −0.601  −0.608  0.565  0.007  −0.011  −0.613  0 
“dribbling” A  1  false  0  0.315  0.313  0  −0.577  −0.584  0.568  0.007  −0.011  −0.588  0.469 
“dribbling” B  1  false  2  0.316  0.341  0  −0.598  −0.606  0.563  0.008  −0.011  −0.609  0.484 
vert limiter  1  false  1  0.317  0.472  0  −0.590  −0.597  0.509  0.006  −0.199  −0.789  0 
smooth topo  1  false  1  0.315  −0.008  0  −0.295  −0.300  0.493  0.005  −0.012  −0.307  0 
energy discr  5  true  1  0.332  −0.313  0.594  −0.603  0.612  0.575  0.009  −0.011  −0.614  — 
default  5  true  2  0.316  −0.272  —  −0.578  −0.587  0.579  0.010  −0.012  −0.589  — 
QPC6  1  false  1  0.305  −0.169  0  −0.129  −0.131  0.477  0.001  −0.007  −0.136  0 
FHS94  1  false  2  0  −0.025  −0.025  0.122  0  0.005  −0.020  —  
FV  1  false  1  0.304  0.670  0  not impl.  not impl.  not impl.  not impl.  not impl.  −0.974  0 
CSLAM  1  false  1  0.312  0.239  0  −0.547  −0.557  0.620  0.010  −0.011  −0.558  −0.070 
CSLAM default  5  true  2  0.320  −0.342  —  −0.524  −0.537  0.641  0.013  −0.011  −0.535  — 
 Note. Column 1 is the identifier for the model configuration. See the text for a brief summary of these descriptors. They are defined in more detail in the following sections where the section titles also include the “Descriptor” from Table 1 to make it easier for the reader to match table entries with discussion in the text. Column 2 is qsize_condensate_loading identifying how many water species are thermodynamically/inertially active in the dynamical core (see section 2.1 for details). Column 3, lcp_moist, indicates whether or not the heat capacity includes water variables or not, and column 4 shows PDC method ftype. The TE tendencies in columns 5–14 are defined in section 2.4. If is less than 10^{−5} W/m^{2}, it is set to zero in the table. Significant changes compared to the baseline (TE consistent configuration) discussed in the main text are in bold font. Entries marked with “—” refer to TE tendencies that can not be directly calculated with the current framework, “not impl” refers to energy diagnostics not implemented in FV dynamical core, and blank in FHS94 refers to the fact that this setup is run without energy fixer (parameterization not consistent with energy fixer), and hence there are no energy fixer numbers.
Various configurations are used and referred to in terms of the COMPSET (Component Set) value used in CESM2.1. The COMPSET F2000climo configuration refers to “realworld” AMIP (Atmospheric Model Intercomparison Project) type simulations using perpetual year 2000 SST (sea surface temperature) boundary conditions. The first seven simulations in the table (those above the horizontal line) are such AMIPtype simulations (F2000climo) with the first serving as a control for the six following variants. The remaining five simulation descriptors (below the horizontal line in Table 1) list their COMPSET or dynamical core settings.
 TE consistent: The TE consistent version uses stateupdate PDC (ftype=1) described in section 3.1 (this configuration does not have PDC errors and it has the same TE definition in physics and dynamics; and hence the energetically most consistent setup in terms of least number of TE error terms);
 dribbling A: as TE consistent but with dribbling PDC (ftype=0) (section 3.2; this setup is used to assess PDC errors);
 dribbling B: as TE consistent but with dribbling combination PDC (ftype=2) (section 3.2; this setup is used to assess PDC errors);
 vert limiter: as TE consistent but using limiters in the vertical remapping of momentum (section 3.3; experiment is used to assess TE errors associated with shapepreserving limiters in vertical remapping);
 smooth topo: as TE consistent but using smoother topography (see section 3.4; experiment is used to assess TE sensitivity to surface roughness);
 energy discr: The version with energy discrepancy (but no PDC errors) described in section 3.5 (experiment is used to estimate energy discrepancy errors);
 default: as energy discr version but with ftype=2 which is the current default CAMSE (section 3.5; we assess this configuration since it is the default CAMSE configuration);
 QPC6: A simplified aquaplanet setup based on the TE consistent, that is, an aquaplanet setup using CAM6 physics; an ocean covered planet in perpetual equinox, with fixed, zonally symmetric SSTs (Medeiros et al., 2016; Neale & Hoskins, 2000; section 3.6; experiment is used to assess TE errors in a simplified moist environment);
 FSH94: Dry dynamical core configuration based on HeldSuarez forcing which relaxes temperature to a zonally symmetric equilibrium temperature profile and simple linear drag at the lower boundary (Held & Suarez, 1994; section 3.7; experiment is used to assess if TE errors in one of the simplest climate test cases is representative of full model TE errors);
 FV: A configuration with the SE dynamical core replaced with the finitevolume core (section 3.8; experiment is used to assess TE errors of a different dynamical core);
 CSLAM: The quasi equalarea physics grid configuration of CAMSE based on the TE consistent setup (section 3.9; used to assess TE errors associated with separating the dynamics grid from the physics grid); and
 CSLAM default: Same as CSLAM configuration but with ftype=2 and all forms of water thermodynamically/inertially active in the dynamical core (setup is evaluated since it is the default CAMSECSLAM setup).
3.1 TE Consistent: StateUpdate PDC (ftype=1) and No TE Formula Discrepancy
This configuration is the most energetically consistent in that the physical parameterizations and the continuous equations of motion on which the dynamical core is based, conserve the same TE (defined in equation 8); and there are no spurious sources/sinks in PDC. Energetic consistency in dynamics and physics is obtained by setting and in the dynamical core equations of motion and TE computations. Associated namelist changes resulting in this configuration are lcp_moist=.false., se_qsize_condensate_loading=1, and ftype=1. We use this configuration as a baseline since it has the least number of TE error terms ( ).
The TE consistent configuration in AMIPtype simulation (F2000climo) is used to compute baseline TE tendencies, which will be used to compare with other model configurations. First, we establish how long an average is needed to get robust TE tendency estimates. Figure 2 shows for various aspects of CAMSE as a function of time. The simulation length is 5 years and monthly average values are used for the analysis. First, consider the left plot. The TE tendency from parameterizations ( ) show significant variability with an amplitude of approximately 2.5 W/m^{2}. As noted above this term does not figure in the spurious TE budget. The net source/sink provides an equal and opposite term to balance it. That said, the variability is reflected onto the TE tendency due to pressure work error W/m^{2}. On the scale used in the lefthand plot the TE tendency of the adiabatic dynamical core does not seem to be affected by or in terms of variability, and remains stable at approximately −0.6 ± 0.02 W/m^{2}. The TE fixer, in this model configuration, fixes and . Since the TE imbalance in the adiabatic dynamics remains approximately constant and the TE tendency associated with pressure work error has variability, the TE tendency from the has variability; W/m^{2}. As a consistency check is plotted with asterisk's and they coincide (as expected) with fulfilling 23.
The righthand plot in Figure 2 shows a breakdown of the dynamical core TE tendencies. The majority of the TE errors are due to hyperviscosity on temperature and pressure, W/m^{2}. The diffusion of momentum is added back as frictional heating and is therefore not part of . The frictional heating is a significant term in the TE tendency budget W/m^{2} and exhibits some variability but with a rather small amplitude. The remaining TE error in the floating Lagrangian dynamics is inviscid dissipation and time truncation errors W/m^{2}. The TE tendency from vertical remapping is approximately W/m^{2}. To within ∼0.02 W/m^{2} the dynamical core TE tendency terms can be computed from just 1 month average TE integrals. The TE tendencies computed in physics, excluding , exhibit more variability and are only accurate to ∼0.1 W/m^{2} after a 1month average.
While it is advantageous to use stateupdate PDC algorithm (ftype=1) in terms of having no spurious TE tendency from coupling, , it does result in spurious gravity waves in the simulations (see, e.g., Figure 5 in Gross et al., 2018). Figure 3a shows a 1year average of , a measure of highfrequency gravity wave noise. It clearly exhibits unphysical oscillations coinciding with element boundaries. Details of the spectralelement method, its coupling to physics, and associated noise issues are discussed in detail in Herrington et al. (2019). The noise in the solutions is even visible in the 500hPa pressure velocity annual average (Figure 4a). This issue can be alleviated by using a shorter physics time step so that the physics increments are smaller (not shown). Climate modelers have historically not pursued a shorter physics time step in production configurations as climate parameterizations are computationally expensive and there is a large sensitivity to physics time steps in the simulated climate (e.g., Wan et al., 2015; Williamson & Olson, 2003).
3.2 “Dribbling” A/B: NonTE Conservative PDC (ftype=0,2)
Before discussing the impact of different PDC methods on the TE budget, we discuss element boundary noise issues in CAMSE which are related to PDC method. This motivates the different PDC methods implemented in CAMSE.
3.2.1 Spurious Element Boundary Noise From PDC
When switching to dribbling PDC algorithm (ftype=0) in which the tendencies from physics are added throughout the dynamics (in this case twice per physics time step), then the noise issues described in previous section disappear (Figures 3b and 4b). That said, there is a significant issue with this approach; the tracer mass budgets may not be closed. How this comes about is illustrated in Figure 5 and explained in the next paragraph.
The orange curve on Figures 5a, 5b, 5d, and 5e is the initial state of, for example, cloud liquid mixing ratio as a function of location, for example, longitude. Cloud liquid is zero outside of clouds and hence provides a good example for the purpose of this illustration. The light blue arrows show the increments (in terms of length of arrow) computed by the parameterizations based on the initial state and scaled for the partial update with dribbling (ftype=0). With stateupdate (ftype=1) the increments from physics are added to the dynamical core state (dotted line on Figure 5b) before the dynamical core advances the solution in time. The parameterizations are designed to not drive the mixing ratios negative so the stateupdate in dynamics will not generate negatives (or overshoots). Then the dynamical core advects the distribution (solid curve on Figure 5c). With dribbling(ftype=0) the physics increments are split into equal chunks (in this illustration two; blue arrows on Figure 5d). Half of the physics increments are added to the initial state (dotted line on Figure 5e), and then dynamics advects the distribution half of the total dynamical core steps (dashed line on Figure 5e). Then the other half of the physics increments are applied (in the same location as they were computed by physics). Now after the previous/first advection step the cloud liquid distribution has moved and the mixing ratio may be zero (or less than the increment prescribed by physics), where the physics forcing is applied (e.g., left side of dashed curve). Hence, the physics increment is driving the mixing ratios negative in those locations. Thereafter, the distribution is advected (solid curve on Figure 5f). In CAM the increments added in the dynamical core are limited so that they drive the mixing to zero (but not negative) if this problem occurs. This leads to a net source of mass compared to the mass change that the parameterizations prescribe (see Figure 6). Although the average source of mass is small each time step, it always has the same sign (i.e., it is a bias) and therefore accumulates. Zhang et al. (2018) estimated that this spurious source of mass is equivalent to ∼10cm sealevel rise per decade in coupled climate simulation experiments.
The majority of the noise with stateupdate (ftype=1) PDC method comes from momentum sources/sinks and heating/cooling. A way to alleviate noise problems and, at the same time, close the tracer mass budgets (in PDC) is to use stateupdate (ftype=1) coupling for tracers and dribbling (ftype=0) coupling for momentum and temperature (referred to as combination, ftype=2). Figure 3c shows the noise diagnostic for combination (ftype=2) coupling. Figure 3c looks very similar to Figure 3b but there is some noise near element boundaries. That said, in terms of vertical pressure velocities combination(ftype=2) and dribbling (ftype=0) climates are similar in terms of the level of noise (Figures 4b and 4c). The element noise in CAMSE with combination (ftype=2) seen in both and 500hPa pressure velocity can be “removed” by using CAMSECSLAM (Figure 3d), which uses a quasi equalarea physics grid and CSLAM (Lauritzen et al., 2010) consistently coupled to the SE method (Lauritzen et al., 2017). The noise patterns in vertical velocity off the western coast of South America are present in all CAMSE simulations (and hence not related to PDC algorithm) are also removed by using CAMSECSLAM (Herrington et al., 2019).
3.2.2 Spurious TE Tendencies From PDC
When using the same TE formula in the dynamical core and physics the spurious TE tendency from PDC can be assessed. As described in item 5 (section 2.3), PDC errors can be attributed to underlying pressure changes during the dribbling of temperature and velocity component increments as well as PDC clipping errors in the water variables (the process in which clipping occurs is described in detail in the previous subsection). The TE error associated with clipping PDC error occurs when the mass change prescribed by physics that is consistent with the fluxes in/out of the physics column does not equal the actual mass change applied to the dynamical core state due to clipping.
For ftype=2 PDC only the increment for temperature and momentum are dribbled, whereas tracer mass is stateupdated (no clipping errors). This results in a spurious PDC TE tendency of W/m^{2}. When using ftype=0 PDC also tracer increments are dribbled(hence there are clipping PDC errors) a similar TE tendency results W/m^{2}. The difference between the TE PDC tenendency for ftype=2 and ftype=0 provides an estimate of the TE PDC clipping error. The clipping PDC TE tenendency is very small 0.015 W/m^{2}.
3.3 Vert limiter: Limiters on Vertical Remapping of Momentum
CAMSE uses a floating Lagrangian vertical coordinate (Lin, 2004; Starr, 1945) which requires the remapping of the atmospheric state from floating levels back to reference levels to maintain computational stability and to provide state data consistent with the physics formulation. The mapping algorithm is based on the mass conservative PPM (Piecewise Parabolic Method) with options for shapepreserving limiters. In CAMSE momentum components and internal energy are used as the variables mapped in the vertical (Lauritzen et al., 2018) and, contrary to earlier versions of CAMSE, there is no limiter on the remapping of wind components. If the shapepreserving limiter is used for momentum mapping then the TE dissipation increases by over an order of magnitude from ∼0.01 W/m^{2} to ∼0.2 W/m^{2} (Table 1).
3.4 Smooth topo: Smoother Topography
Topography for CAM is generated using a new version of the software/algorithm described in Lauritzen et al. (2015) that is available at this website (https://github.com/NCAR/Topo). The updates to the software includes smoothing algorithms and the computation of subgridscale orientation of topography.
The default topography in CAMSE uses the same amount of topography smoothing as CAMFV (distance weighted smoother applied to the raw topography on ∼3 km cubedsphere grid with a smoothing radius of 180 km referred to as C60). When the topography is smoother (in this case using C92 smoothing, i.e., smoothing radius of approximately 276 km) the hyperviscosity operators are less active leading to reduced TE errors, that is, is reduced in half from approximately −0.6 W/m^{2} to −0.3 W/m^{2}. The vertical remapping TE error, however, remains approximately the same. Since the pressure work error is approximately 0.3 W/m^{2} it almost exactly compensates for the TE tendency from the dynamical core . Hence, if one would only diagnose the TE tendency from the energy fixer one could mistakenly conclude that the model universally conserves TE when, in fact, there are compensating TE errors in the system. These compensating errors can only be diagnosed through a careful breakdown of the total TE tendencies.
3.5 Default: TE Formula Discrepancy Errors
To assess the TE errors due to the discrepancy in the energy formula used by dynamics and physics, a simulation using stateupdating (ftype=1, no ‘dribbling’ errors) and thermodynamically/inertially active condensates in the dynamical core (qsize_condensate_loading = 5) and consistent/accurate associated heat capacities (namelist lcp_moist=.true.) has been performed. In this setup the continuous equations of motion in the dynamical core conserve an energy different from physics, and the energy fixer will restore the “physics” version of energy. Despite the dynamical core now using a more comprehensive formula for energy, the TE dissipation terms in the dynamical core are roughly the same as in the energy consistent versions of the model. Using 26 we can assess the TE energy discrepancy errors which result in ∼0.59 W/m^{2}. Taylor (2011) found a similar result just from using the more comprehensive formula for heat capacity (based on dry air and water vapor) and not including thermodynamically/inertially active condensates. As noted before this formulation inconsistency is due to the evolutionary nature of CAM development and it is the intention to remove this inconsistency in future versions of the model.
3.5.1 TwoDimensional Structure of TE Errors
Figure 7 shows the twodimensional spatial structure of columnintegrated TE tendencies for for the default configuration. The first plot (Figure 7a) shows column integrated ∂E^{(param)}, that is, the spatial structure of the “physical” TE tendency. Only contours from ±150 W/m^{2} are shown although the actual range (noted above color bar) is −148.3 W/m^{2} to 1,770 W/m^{2}. The larger positive values occur only at a small number of grid points (e.g., mountains of New Guinea). The columnintegrated dynamical core TE tendency (Figure 7c) approximately balances ∂E^{(param)}; this is expected in an AMIP simulation that, if integrated long enough, should reach radiative equilibrium. The TE pressure work error tendency ∂E^{(pwork)} (Figure 7b) is, as expected, largest where precipitation and evaporation is largest. The last three plots show terms in the dynamical core budget: columnintegrated TE tendency from the 2D adiabatic dynamical core, , vertical remapping, , and frictional heating, . The adiabatic dynamical core TE tendency is dominated by the tendencies from the floating Lagrangian (quasihorizonal) dynamics. The frictional heating TE tendency is largest over/near topography. Similarly for vertical remapping but, in addition, there are large TE tendencies in areas of large updrafts/downdrafts over ocean.
3.6 QPC6: Simplified Surface
By running the model in aquaplanet configuration one can assess the effect of simplifying the surface boundary condition. In particular, without topography forcing the dynamical core is not challenged with respect to stationary neargridscale forcing. The TE tendency with respect to pressure work error remains the same as the AMIPtype simulations; however, the adiabatic dynamical core TE tendency reduces to W/m^{2} (approximately a factor 4 reduction). Most of that reduction is due to viscosity W/m^{2}. The frictional heating is roughly the same as AMIP W/m^{2} as is the vertical remapping W/m^{2}. To evaluate the dynamical cores diffusion of TE it is therefore important to asses the model in a configuration with topography as the wave dynamics generated by topography leads to more active diffusion operators.
3.7 FHS94: Simplified Physics (No Moisture)
Simplifying the setup even further by replacing the parameterizations with relaxation toward a zonally symmetric temperature profile and simple boundary layer friction (HeldSuarez forcing) as well as excluding moisture, the TE errors in the dynamical core decreases even further to ∼0.002 W/m^{2}, since there is no small scale forcing. Small scales are only created by the nonlinear dynamics and the physics works to damp them. Hyperviscosity is less active leading to significant reductions compared to aquaplanet and ‘realworld’ simulation results. The TE diffusion in vertical remapping reduces by an order of magnitude compared to the aquaplanet simulations (∼0.0005 W/m^{2}). This further emphasizes that TE diffusion assessment in a simplified setup is not necessarily telling for the dynamical cores performance with moist physics and topography that challenge the dynamical core in terms of strong gridscale forcing.
3.8 FV: Changing Dynamical Core to FV
As a comparison the TE error characteristics of the CAMFV dynamical core are assessed. Although the TE diagnostics have not been implemented in the CAMFV dynamical core, the TE diagnostics in CAM physics are independent of dynamical core and can therefore be activated with CAMFV. The CAMFV dynamical core uses stateupdate PDC (ftype=1) ( ) and the same TE definition as CAM physics ( ). Hence 24 can be used to compute the TE errors of the CAMFV dynamical core, W/m^{2}. As we do not have the breakdown of it can not be determined how much of the TE errors are due to the vertical remapping. Furthermore, CAMFV contains intrinsic dissipation operators (limiters in the flux operators) making it difficult to assess TE sources/sinks due to dissipation. Note that the pressure work error even with a change of dynamical core remains approximately the same as the CAMSE configurations.
3.9 CSLAM: Quasi EqualArea Physics Grid
This configuration was discussed in the context of element noise in section 3.2.1. By averaging the dynamics state of an equalpartitioning (in central angle cubedsphere coordinates) of the elements, the elementboundary noise found in CAMSE can be removed. Lauritzen et al. (2018) argue that this way of computing the state for the physics is more consistent with physics in terms of providing a cellaveraged state instead of irregularly spaced point (quadrature) values. In order to achieve a closed mass budget, this configuration uses CSLAM for tracer transport rather than SE transport. That said, the physics columns no longer coincide with the quadrature grid and there are TE errors associated with mapping state and tendencies between the two grids.
In this configuration the energy diagnostics computed in the dynamical core are computed on the quadrature grid and the energy diagnostics computed in physics are on the physics grid. If the TE consistent configuration is used (ftype=1, qsize_condensate_loading=1, lcp_moist=.false.) then the PDC errors, , computed with 21 are entirely due to mapping state from quadrature grid to physics grid and mapping tendencies back the quadrature grid from the physics grid. The results is W/m^{2} which is a rather small error compared to other terms in the TE budget.
Due to similar noise problems with CAMSECSLAM when using ftype=1 that were observed in CAMSE (Figures 3 and 4), the default version of CAMSECSLAM uses ftype=2. Again, PDC errors and TE discrepancy errors cannot be separated; W/m^{2}.
4 Conclusions
A detailed TE error analysis of the CAM using version 6 physics (included in the CESM2.1 release) running at approximately 1° horizontal resolution has been presented. In the global climate model there can be many spurious contributions to the TE budget. These errors can be divided into four categories: physical parameterizations, adiabatic dynamical core, the coupling between physics and dynamics, and TE definition discrepancies between dynamics and physics. The latter is not by design but through the evolutionary nature of model development. By capturing the atmospheric state at various locations in the model algorithm, a detailed budget of TE errors can be constructed. The net spurious TE energy errors are compensated with a global energy fixer (providing a global uniform temperature increment) every physics time step.
In CAM physics the parameterizations have, by design, a closed energy budget (change in TE is balanced by fluxes in/out the top and bottom of physics columns) if it is assumed that pressure is not modified. However, the pressure changes due to fluxes of mass (e.g., water vapor) in/out of the column which changes energy (referred to as pressure work error). The pressure work error with the full moist physics configuration is very stable across different configurations at ∼0.3 W/m^{2}. The TE errors in the SE dynamical core varies across configurations. Aspects that influence TE is the presence of topography, the amount of topography smoothing and moist physics. By smoothing topography more the TE error is cut in half from ∼ − 0.6 W/m^{2} to ∼ − 0.3 W/m^{2}; and reduces by a factor of 6 (∼ − 0.1 W/m^{2}) if no topography is present at all (aquaplanet configuration). Moist physics forcing also contributes significantly to the TE budget. For example, in the dry HeldSuarez setup TE dissipation of the SE dynamical core reduces to −0.03 W/m^{2}. Topography and moist physics force the dynamical core at the grid scale and hence the viscosity operators are more active. Consistent with this statement is that the changes in TE discussed so far are almost entirely due to the viscosity operator TE dissipation. For CAMSE the spurious TE dissipation in the adiabatic dynamical core is ∼ − 0.6W/m^{2} in “realworld” configurations. For comparison, CAMFV's spurious TE change due to the adiabatic dynamical core is ∼ − 1 W/m^{2}.
By further breaking down the TE dissipation in the SE dynamical core it is observed the vertical remapping accounts for only ∼ − 0.01 W/m^{2}. That said, if the shapepreserving limiters in the vertical remapping are invoked the TE dissipation increases 20fold to ∼ − 0.2 W/m^{2}. In CAMSE the kinetic energy dissipation is added as heating in the thermodynamic equation (also referred to as frictional heating). The frictional heating remains very stable across configurations that include moisture (∼0.5 W/m^{2}) and reduces drastically for dry atmosphere setups (factor 4 reduction to (∼0.12 W/m^{2})). Hence, this term is an important term in the TE budget. The TE budget for the dynamical core is dominated by TE change due to hyperviscosity; TE errors due to timetruncation and frictionless equations of motion are negligible. Errors associated with PDC (if applicable) are approximately 0.5 W/m^{2}. Due to the evolutionary nature of model development the SE dynamical core's continuous equation of motion conserve a more comprehensive TE compared to the physical parameterizations. This TE discrepancy leads to an approximately 0.5 W/m^{2} total energy source. Running physics on a different grid than the dynamical introduces TE mapping errors such as in CAMSECSLAM. These errors are, however, rather small −0.07 W/m^{2}.
A purpose of this paper is to better understand the energy characteristics of CAM and to encourage modeling groups to perform similar analysis to better understand the total energy flow in the atmospheric component of Earth system models. As has been demonstrated in this paper there can easily be compensating errors in the system which can not be identified without a detailed TE analysis. The analysis in this paper only considers 1° horizontal resolution and 32 levels in the vertical. The TE numbers and clipping results may not be accurate for other choices of horizontal and vertical resolutions.
Acknowledgments
We thank one anonymous reviewer, Hui Wan, and Phil Rasch for their helpful comments that significantly improved the clarity of the manuscript. The National Center for Atmospheric Research is sponsored by the National Science Foundation. Computing resources (doi:10.5065/D6RX99HX) were provided by the Climate Simulation Laboratory at NCAR's Computational and Information Systems Laboratory, sponsored by the National Science Foundation and other agencie\uline{}s. The data used to perform the energy analysis can be found at this website (https://github.com/PeterHjortLauritzen/2018JAMESenergy).