Tree structure

At the top of SpeedyWeather's type tree sits the Simulation, containing variables and model, which in itself contains model components with their own fields and so on. (Note that we are talking about the structure of structs within structs not the type hierarchy as defined by subtyping abstract types.) This can quickly get complicated with a lot of nested structs. The following is to give users a better overview of how simulation, variables and model are structured within SpeedyWeather. Many types in SpeedyWeather have extended Julia's show function to give you an overview of its contents, e.g. a clock::Clock is printed as

using SpeedyWeather
clock = Clock()
Clock
├ time::DateTime = 2000-01-01T00:00:00
├ start::DateTime = 2000-01-01T00:00:00
├ period::Second = 0 seconds
├ timestep_counter::Int64 = 0
├ n_timesteps::Int64 = 0
└ Δt::Dates.Millisecond = 0 milliseconds

illustrating the fields within a clock, their types and (unless they are an array) also their values. For structs within structs however, this information, would not be printed by default. You could use Julia's autocomplete like clock.<tab> by hitting tab after the . to inspect the fields of an instance but that would require you to manually go down every branch of that tree. To better visualise this, we have defined a tree(S) function for any instance S defined in SpeedyWeather which will print every field, and also its containing fields if they are also defined within SpeedyWeather. The "if defined in SpeedyWeather" is important because otherwise the tree would also show you the contents of a complex number or other types defined in Julia Base itself that we aren't interested in here. But let's start at the top.

Simulation

When creating a Simulation, its fields are

spectral_grid = SpectralGrid(nlayers = 1)
model = BarotropicModel(spectral_grid)
simulation = initialize!(model)
Simulation{BarotropicModel}
├ prognostic_variables::PrognosticVariables{...}
├ diagnostic_variables::DiagnosticVariables{...}
└ model::BarotropicModel{...}

the prognostic_variables, the diagnostic_variables and the model (that we just initialized). We could now do tree(simulation) but that gets very lengthy and so will split things into tree(simulation.prognostic_variables), tree(simulation.diagnostic_variables) and tree(simulation.model) for more digestible chunks. You can also provide the with_types=true keyword to get also the types of these fields printed, but we'll skip that here.

Prognostic variables

The prognostic variables struct is parametric on the model type, model_type(model) (which strips away its parameters), but this is only to dispatch over it. The fields are for all models the same, just the barotropic model would not use temperature for example (but you could use nevertheless).

tree(simulation.prognostic_variables)
PrognosticVariables{Float32, Array, 2, LowerTriangularMatrix{ComplexF32}, LowerTriangularArray{ComplexF32, 2, Matrix{ComplexF32}}, OctahedralGaussianGrid{Float32}, Vector{Particle{Float32}}}
├ trunc
├ nlat_half
├ nlayers
├ nparticles
├ vor
├ div
├ temp
├ humid
├ pres
├ random_pattern
├┐ocean
│├ nlat_half
│├ sea_surface_temperature
│└ sea_ice_concentration
├┐land
│├ nlat_half
│├ land_surface_temperature
│├ snow_depth
│├ soil_moisture_layer1
│└ soil_moisture_layer2
├ particles
├ scale
└┐clock
 ├ time
 ├ start
 ├ period
 ├ timestep_counter
 ├ n_timesteps
 └ Δt

The prognostic variable struct can be mutated (e.g. to set new initial conditions) with the SpeedyWeather.set! function.

Diagnostic variables

Similar for the diagnostic variables, regardless the model type, they contain the same fields but for the 2D models many will not be used for example.

tree(simulation.diagnostic_variables)
DiagnosticVariables{Float32, Array, OctahedralGaussianGrid, LowerTriangularMatrix{ComplexF32}, LowerTriangularArray{ComplexF32, 2, Matrix{ComplexF32}}, OctahedralGaussianGrid{Float32}, OctahedralGaussianArray{Float32, 2, Matrix{Float32}}, Vector{Particle{Float32}}, Vector{Float32}, Matrix{Float32}}
├ trunc
├ nlat_half
├ nlayers
├ nparticles
├┐tendencies
│├ trunc
│├ nlat_half
│├ nlayers
│├ vor_tend
│├ div_tend
│├ temp_tend
│├ humid_tend
│├ u_tend
│├ v_tend
│├ pres_tend
│├ u_tend_grid
│├ v_tend_grid
│├ temp_tend_grid
│├ humid_tend_grid
│└ pres_tend_grid
├┐grid
│├ nlat_half
│├ nlayers
│├ vor_grid
│├ div_grid
│├ temp_grid
│├ temp_virt_grid
│├ humid_grid
│├ u_grid
│├ v_grid
│├ pres_grid
│├ random_pattern
│├ temp_grid_prev
│├ humid_grid_prev
│├ u_grid_prev
│├ v_grid_prev
│└ pres_grid_prev
├┐dynamics
│├ trunc
│├ nlat_half
│├ nlayers
│├ a
│├ b
│├ a_grid
│├ b_grid
│├ a_2D
│├ b_2D
│├ a_2D_grid
│├ b_2D_grid
│├ uv∇lnp
│├ uv∇lnp_sum_above
│├ div_sum_above
│├ temp_virt
│├ geopot
│├ σ_tend
│├ ∇lnp_x
│├ ∇lnp_y
│├ u_mean_grid
│├ v_mean_grid
│├ div_mean_grid
│└ div_mean
├┐physics
│├ nlat_half
│├ precip_large_scale
│├ precip_convection
│├ cloud_top
│├ soil_moisture_availability
│├ surface_flux_heat
│├ surface_flux_humid
│├ outgoing_shortwave_radiation
│├ outgoing_longwave_radiation
│└ cos_zenith
├┐particles
│├ nparticles
│├ nlat_half
│├ locations
│├ u
│├ v
│├ σ_tend
│└ interpolator
├┐column
│├ nlayers
│├ nbands_shortwave
│├ nbands_longwave
│├ ij
│├ jring
│├ lond
│├ latd
│├ land_fraction
│├ orography
│├ u
│├ v
│├ temp
│├ humid
│├ ln_pres
│├ pres
│├ u_tend
│├ v_tend
│├ temp_tend
│├ humid_tend
│├ flux_u_upward
│├ flux_u_downward
│├ flux_v_upward
│├ flux_v_downward
│├ flux_temp_upward
│├ flux_temp_downward
│├ flux_humid_upward
│├ flux_humid_downward
│├ random_value
│├ boundary_layer_depth
│├ boundary_layer_drag
│├ surface_geopotential
│├ surface_u
│├ surface_v
│├ surface_temp
│├ surface_humid
│├ surface_wind_speed
│├ skin_temperature_sea
│├ skin_temperature_land
│├ soil_moisture_availability
│├ surface_air_density
│├ sat_humid
│├ dry_static_energy
│├ temp_virt
│├ geopot
│├ cloud_top
│├ precip_convection
│├ precip_large_scale
│├ cos_zenith
│├ albedo
│├ outgoing_longwave_radiation
│├ outgoing_shortwave_radiation
│├ optical_depth_shortwave
│├ optical_depth_longwave
│├ a
│├ b
│├ c
│└ d
├ temp_average
└ scale

BarotropicModel

The BarotropicModel is the simplest model we have, which will not have many of the model components that are needed to define the primitive equations for example. Note that forcing or drag aren't further branched which is because the default BarotropicModel has NoForcing and NoDrag which don't have any fields. If you create a model with non-default conponents they will show up here. tree dynamicallt inspects the current contents of a (mutable) struct and that tree may look different depending on what model you have constructed!

model = BarotropicModel(spectral_grid)
tree(model)
BarotropicModel{...}
├┐spectral_grid
│├ NF
│├ device
│├ ArrayType
│├ trunc
│├ Grid
│├ dealiasing
│├ radius
│├ nparticles
│├ nlat_half
│├ nlat
│├ npoints
│├ nlayers
│├┐vertical_coordinates
││├ nlayers
││└ σ_half
│├ VectorType
│├ MatrixType
│├ SpectralVariable2D
│├ SpectralVariable3D
│├ SpectralVariable4D
│├ GridVariable2D
│├ GridVariable3D
│├ GridVariable4D
│└ ParticleVector
├┐device_setup
│├ device
│├ device_KA
│└ n
├┐geometry
│├┐spectral_grid
││├ NF
││├ device
││├ ArrayType
││├ trunc
││├ Grid
││├ dealiasing
││├ radius
││├ nparticles
││├ nlat_half
││├ nlat
││├ npoints
││├ nlayers
││├┐vertical_coordinates
│││├ nlayers
│││└ σ_half
││├ VectorType
││├ MatrixType
││├ SpectralVariable2D
││├ SpectralVariable3D
││├ SpectralVariable4D
││├ GridVariable2D
││├ GridVariable3D
││├ GridVariable4D
││└ ParticleVector
│├ nlat_half
│├ nlon_max
│├ nlon
│├ nlat
│├ nlayers
│├ npoints
│├ radius
│├ colat
│├ lat
│├ latd
│├ lond
│├ londs
│├ latds
│├ lons
│├ lats
│├ sinlat
│├ coslat
│├ coslat⁻¹
│├ coslat²
│├ coslat⁻²
│├ σ_levels_half
│├ σ_levels_full
│├ σ_levels_thick
│├ ln_σ_levels_full
│└ full_to_half_interpolation
├┐planet
│├ rotation
│├ gravity
│├ daily_cycle
│├ length_of_day
│├ seasonal_cycle
│├ length_of_year
│├ equinox
│├ axial_tilt
│└ solar_constant
├┐atmosphere
│├ mol_mass_dry_air
│├ mol_mass_vapour
│├ heat_capacity
│├ R_gas
│├ R_dry
│├ R_vapour
│├ mol_ratio
│├ μ_virt_temp
│├ κ
│├ water_density
│├ latent_heat_condensation
│├ latent_heat_sublimation
│├ stefan_boltzmann
│├ pres_ref
│├ temp_ref
│├ moist_lapse_rate
│├ dry_lapse_rate
│└ layer_thickness
├┐coriolis
│├ nlat
│└ f
├ forcing
├ drag
├ particle_advection
├┐initial_conditions
│├┐vordiv
││├ power
││└ amplitude
│├ pres
│├ temp
│└ humid
├ random_process
├┐time_stepping
│├ trunc
│├ nsteps
│├ Δt_at_T31
│├ radius
│├ adjust_with_output
│├ robert_filter
│├ williams_filter
│├ Δt_millisec
│├ Δt_sec
│└ Δt
├ spectral_transform
├ implicit
├┐horizontal_diffusion
│├ trunc
│├ nlayers
│├ power
│├ time_scale
│├ time_scale_div
│├ resolution_scaling
│├ power_stratosphere
│├ tapering_σ
│├ expl
│├ impl
│├ expl_div
│└ impl_div
├┐output
│├ active
│├ path
│├ id
│├ run_path
│├ filename
│├ write_restart
│├ pkg_version
│├ startdate
│├ output_dt
│├ variables
│├ output_every_n_steps
│├ timestep_counter
│├ output_counter
│├ netcdf_file
│├ interpolator
│├ grid2D
│└ grid3D
├ callbacks
└┐feedback
 ├ verbose
 ├ debug
 ├ output
 ├ id
 ├ run_path
 ├ progress_meter
 ├ progress_txt
 └ nars_detected

ShallowWaterModel

The ShallowWaterModel is similar to the BarotropicModel, but it contains for example orography, that the BarotropicModel doesn't have.

model = ShallowWaterModel(spectral_grid)
tree(model)
ShallowWaterModel{...}
├┐spectral_grid
│├ NF
│├ device
│├ ArrayType
│├ trunc
│├ Grid
│├ dealiasing
│├ radius
│├ nparticles
│├ nlat_half
│├ nlat
│├ npoints
│├ nlayers
│├┐vertical_coordinates
││├ nlayers
││└ σ_half
│├ VectorType
│├ MatrixType
│├ SpectralVariable2D
│├ SpectralVariable3D
│├ SpectralVariable4D
│├ GridVariable2D
│├ GridVariable3D
│├ GridVariable4D
│└ ParticleVector
├┐device_setup
│├ device
│├ device_KA
│└ n
├┐geometry
│├┐spectral_grid
││├ NF
││├ device
││├ ArrayType
││├ trunc
││├ Grid
││├ dealiasing
││├ radius
││├ nparticles
││├ nlat_half
││├ nlat
││├ npoints
││├ nlayers
││├┐vertical_coordinates
│││├ nlayers
│││└ σ_half
││├ VectorType
││├ MatrixType
││├ SpectralVariable2D
││├ SpectralVariable3D
││├ SpectralVariable4D
││├ GridVariable2D
││├ GridVariable3D
││├ GridVariable4D
││└ ParticleVector
│├ nlat_half
│├ nlon_max
│├ nlon
│├ nlat
│├ nlayers
│├ npoints
│├ radius
│├ colat
│├ lat
│├ latd
│├ lond
│├ londs
│├ latds
│├ lons
│├ lats
│├ sinlat
│├ coslat
│├ coslat⁻¹
│├ coslat²
│├ coslat⁻²
│├ σ_levels_half
│├ σ_levels_full
│├ σ_levels_thick
│├ ln_σ_levels_full
│└ full_to_half_interpolation
├┐planet
│├ rotation
│├ gravity
│├ daily_cycle
│├ length_of_day
│├ seasonal_cycle
│├ length_of_year
│├ equinox
│├ axial_tilt
│└ solar_constant
├┐atmosphere
│├ mol_mass_dry_air
│├ mol_mass_vapour
│├ heat_capacity
│├ R_gas
│├ R_dry
│├ R_vapour
│├ mol_ratio
│├ μ_virt_temp
│├ κ
│├ water_density
│├ latent_heat_condensation
│├ latent_heat_sublimation
│├ stefan_boltzmann
│├ pres_ref
│├ temp_ref
│├ moist_lapse_rate
│├ dry_lapse_rate
│└ layer_thickness
├┐coriolis
│├ nlat
│└ f
├┐orography
│├ path
│├ file
│├ file_Grid
│├ scale
│├ smoothing
│├ smoothing_power
│├ smoothing_strength
│├ smoothing_fraction
│├ orography
│└ geopot_surf
├ forcing
├ drag
├ particle_advection
├┐initial_conditions
│├┐vordiv
││├ latitude
││├ width
││├ umax
││├ perturb_lat
││├ perturb_lon
││├ perturb_xwidth
││├ perturb_ywidth
││└ perturb_height
│├ pres
│├ temp
│└ humid
├ random_process
├┐time_stepping
│├ trunc
│├ nsteps
│├ Δt_at_T31
│├ radius
│├ adjust_with_output
│├ robert_filter
│├ williams_filter
│├ Δt_millisec
│├ Δt_sec
│└ Δt
├ spectral_transform
├┐implicit
│├ trunc
│├ α
│├ H
│├ ξH
│├ g∇²
│├ ξg∇²
│└ S⁻¹
├┐horizontal_diffusion
│├ trunc
│├ nlayers
│├ power
│├ time_scale
│├ time_scale_div
│├ resolution_scaling
│├ power_stratosphere
│├ tapering_σ
│├ expl
│├ impl
│├ expl_div
│└ impl_div
├┐output
│├ active
│├ path
│├ id
│├ run_path
│├ filename
│├ write_restart
│├ pkg_version
│├ startdate
│├ output_dt
│├ variables
│├ output_every_n_steps
│├ timestep_counter
│├ output_counter
│├ netcdf_file
│├ interpolator
│├ grid2D
│└ grid3D
├ callbacks
└┐feedback
 ├ verbose
 ├ debug
 ├ output
 ├ id
 ├ run_path
 ├ progress_meter
 ├ progress_txt
 └ nars_detected

PrimitiveDryModel

The PrimitiveDryModel is a big jump in complexity compared to the 2D models, but because it doesn't contain humidity, several model components like evaporation aren't needed.

spectral_grid = SpectralGrid()
model = PrimitiveDryModel(spectral_grid)
tree(model)
PrimitiveDryModel{...}
├┐spectral_grid
│├ NF
│├ device
│├ ArrayType
│├ trunc
│├ Grid
│├ dealiasing
│├ radius
│├ nparticles
│├ nlat_half
│├ nlat
│├ npoints
│├ nlayers
│├┐vertical_coordinates
││├ nlayers
││└ σ_half
│├ VectorType
│├ MatrixType
│├ SpectralVariable2D
│├ SpectralVariable3D
│├ SpectralVariable4D
│├ GridVariable2D
│├ GridVariable3D
│├ GridVariable4D
│└ ParticleVector
├┐device_setup
│├ device
│├ device_KA
│└ n
├ dynamics
├┐geometry
│├┐spectral_grid
││├ NF
││├ device
││├ ArrayType
││├ trunc
││├ Grid
││├ dealiasing
││├ radius
││├ nparticles
││├ nlat_half
││├ nlat
││├ npoints
││├ nlayers
││├┐vertical_coordinates
│││├ nlayers
│││└ σ_half
││├ VectorType
││├ MatrixType
││├ SpectralVariable2D
││├ SpectralVariable3D
││├ SpectralVariable4D
││├ GridVariable2D
││├ GridVariable3D
││├ GridVariable4D
││└ ParticleVector
│├ nlat_half
│├ nlon_max
│├ nlon
│├ nlat
│├ nlayers
│├ npoints
│├ radius
│├ colat
│├ lat
│├ latd
│├ lond
│├ londs
│├ latds
│├ lons
│├ lats
│├ sinlat
│├ coslat
│├ coslat⁻¹
│├ coslat²
│├ coslat⁻²
│├ σ_levels_half
│├ σ_levels_full
│├ σ_levels_thick
│├ ln_σ_levels_full
│└ full_to_half_interpolation
├┐planet
│├ rotation
│├ gravity
│├ daily_cycle
│├ length_of_day
│├ seasonal_cycle
│├ length_of_year
│├ equinox
│├ axial_tilt
│└ solar_constant
├┐atmosphere
│├ mol_mass_dry_air
│├ mol_mass_vapour
│├ heat_capacity
│├ R_gas
│├ R_dry
│├ R_vapour
│├ mol_ratio
│├ μ_virt_temp
│├ κ
│├ water_density
│├ latent_heat_condensation
│├ latent_heat_sublimation
│├ stefan_boltzmann
│├ pres_ref
│├ temp_ref
│├ moist_lapse_rate
│├ dry_lapse_rate
│└ layer_thickness
├┐coriolis
│├ nlat
│└ f
├┐geopotential
│├ nlayers
│├ Δp_geopot_half
│└ Δp_geopot_full
├┐adiabatic_conversion
│├ nlayers
│├ σ_lnp_A
│└ σ_lnp_B
├ particle_advection
├┐initial_conditions
│├┐vordiv
││├ η₀
││├ u₀
││├ perturb_lat
││├ perturb_lon
││├ perturb_uₚ
││└ perturb_radius
│├ pres
│├┐temp
││├ η₀
││├ σ_tropopause
││├ u₀
││├ ΔT
││└ Tmin
│└ humid
├ random_process
├┐orography
│├ path
│├ file
│├ file_Grid
│├ scale
│├ smoothing
│├ smoothing_power
│├ smoothing_strength
│├ smoothing_fraction
│├ orography
│└ geopot_surf
├┐land_sea_mask
│├ path
│├ file
│├ file_Grid
│└ mask
├┐ocean
│├ nlat_half
│├ path
│├ file
│├ varname
│├ file_Grid
│├ missing_value
│└ monthly_temperature
├┐land
│├ nlat_half
│├ path
│├ file
│├ varname
│├ file_Grid
│├ missing_value
│└ monthly_temperature
├┐solar_zenith
│├ length_of_day
│├ length_of_year
│├ equation_of_time
│├ seasonal_cycle
│├┐solar_declination
││├ axial_tilt
││├ equinox
││├ length_of_year
││└ length_of_day
│├┐time_correction
││├ a
││├ s1
││├ c1
││├ s2
││└ c2
│└ initial_time
├┐albedo
│├ nlat_half
│├ path
│├ file
│├ varname
│├ file_Grid
│└ albedo
├ physics
├┐boundary_layer_drag
│├ κ
│├ z₀
│├ Ri_c
│└ drag_max
├ temperature_relaxation
├┐vertical_diffusion
│├ nlayers
│├ κ
│├ z₀
│├ Ri_c
│├ fb
│├ diffuse_static_energy
│├ diffuse_momentum
│├ diffuse_humidity
│├ logZ_z₀
│├ sqrtC_max
│├ ∇²_above
│└ ∇²_below
├ surface_thermodynamics
├┐surface_wind
│├ f_wind
│├ V_gust
│├ use_boundary_layer_drag
│├ drag_land
│└ drag_sea
├┐surface_heat_flux
│├ use_boundary_layer_drag
│├ heat_exchange_land
│└ heat_exchange_sea
├┐convection
│├ nlayers
│├ time_scale
│└ surface_temp
├ optical_depth
├ shortwave_radiation
├┐longwave_radiation
│├ α
│├ temp_tropopause
│└ time_scale
├┐stochastic_physics
│├ nlayers
│├ tapering
│└ taper
├┐time_stepping
│├ trunc
│├ nsteps
│├ Δt_at_T31
│├ radius
│├ adjust_with_output
│├ robert_filter
│├ williams_filter
│├ Δt_millisec
│├ Δt_sec
│└ Δt
├ spectral_transform
├┐implicit
│├ trunc
│├ nlayers
│├ α
│├ temp_profile
│├ ξ
│├ R
│├ U
│├ L
│├ W
│├ L0
│├ L1
│├ L2
│├ L3
│├ L4
│├ S
│└ S⁻¹
├┐horizontal_diffusion
│├ trunc
│├ nlayers
│├ power
│├ time_scale
│├ time_scale_div
│├ resolution_scaling
│├ power_stratosphere
│├ tapering_σ
│├ expl
│├ impl
│├ expl_div
│└ impl_div
├ vertical_advection
├┐output
│├ active
│├ path
│├ id
│├ run_path
│├ filename
│├ write_restart
│├ pkg_version
│├ startdate
│├ output_dt
│├ variables
│├ output_every_n_steps
│├ timestep_counter
│├ output_counter
│├ netcdf_file
│├ interpolator
│├ grid2D
│└ grid3D
├ callbacks
└┐feedback
 ├ verbose
 ├ debug
 ├ output
 ├ id
 ├ run_path
 ├ progress_meter
 ├ progress_txt
 └ nars_detected

PrimitiveWetModel

The PrimitiveWetModel is the most complex model we currently have, hence its field tree is the longest, defining many components for the physics parameterizations.

model = PrimitiveWetModel(spectral_grid)
tree(model)
PrimitiveWetModel{...}
├┐spectral_grid
│├ NF
│├ device
│├ ArrayType
│├ trunc
│├ Grid
│├ dealiasing
│├ radius
│├ nparticles
│├ nlat_half
│├ nlat
│├ npoints
│├ nlayers
│├┐vertical_coordinates
││├ nlayers
││└ σ_half
│├ VectorType
│├ MatrixType
│├ SpectralVariable2D
│├ SpectralVariable3D
│├ SpectralVariable4D
│├ GridVariable2D
│├ GridVariable3D
│├ GridVariable4D
│└ ParticleVector
├┐device_setup
│├ device
│├ device_KA
│└ n
├ dynamics
├┐geometry
│├┐spectral_grid
││├ NF
││├ device
││├ ArrayType
││├ trunc
││├ Grid
││├ dealiasing
││├ radius
││├ nparticles
││├ nlat_half
││├ nlat
││├ npoints
││├ nlayers
││├┐vertical_coordinates
│││├ nlayers
│││└ σ_half
││├ VectorType
││├ MatrixType
││├ SpectralVariable2D
││├ SpectralVariable3D
││├ SpectralVariable4D
││├ GridVariable2D
││├ GridVariable3D
││├ GridVariable4D
││└ ParticleVector
│├ nlat_half
│├ nlon_max
│├ nlon
│├ nlat
│├ nlayers
│├ npoints
│├ radius
│├ colat
│├ lat
│├ latd
│├ lond
│├ londs
│├ latds
│├ lons
│├ lats
│├ sinlat
│├ coslat
│├ coslat⁻¹
│├ coslat²
│├ coslat⁻²
│├ σ_levels_half
│├ σ_levels_full
│├ σ_levels_thick
│├ ln_σ_levels_full
│└ full_to_half_interpolation
├┐planet
│├ rotation
│├ gravity
│├ daily_cycle
│├ length_of_day
│├ seasonal_cycle
│├ length_of_year
│├ equinox
│├ axial_tilt
│└ solar_constant
├┐atmosphere
│├ mol_mass_dry_air
│├ mol_mass_vapour
│├ heat_capacity
│├ R_gas
│├ R_dry
│├ R_vapour
│├ mol_ratio
│├ μ_virt_temp
│├ κ
│├ water_density
│├ latent_heat_condensation
│├ latent_heat_sublimation
│├ stefan_boltzmann
│├ pres_ref
│├ temp_ref
│├ moist_lapse_rate
│├ dry_lapse_rate
│└ layer_thickness
├┐coriolis
│├ nlat
│└ f
├┐geopotential
│├ nlayers
│├ Δp_geopot_half
│└ Δp_geopot_full
├┐adiabatic_conversion
│├ nlayers
│├ σ_lnp_A
│└ σ_lnp_B
├ particle_advection
├┐initial_conditions
│├┐vordiv
││├ η₀
││├ u₀
││├ perturb_lat
││├ perturb_lon
││├ perturb_uₚ
││└ perturb_radius
│├ pres
│├┐temp
││├ η₀
││├ σ_tropopause
││├ u₀
││├ ΔT
││└ Tmin
│└┐humid
│ └ relhumid_ref
├ random_process
├┐orography
│├ path
│├ file
│├ file_Grid
│├ scale
│├ smoothing
│├ smoothing_power
│├ smoothing_strength
│├ smoothing_fraction
│├ orography
│└ geopot_surf
├┐land_sea_mask
│├ path
│├ file
│├ file_Grid
│└ mask
├┐ocean
│├ nlat_half
│├ path
│├ file
│├ varname
│├ file_Grid
│├ missing_value
│└ monthly_temperature
├┐land
│├ nlat_half
│├ path
│├ file
│├ varname
│├ file_Grid
│├ missing_value
│└ monthly_temperature
├┐solar_zenith
│├ length_of_day
│├ length_of_year
│├ equation_of_time
│├ seasonal_cycle
│├┐solar_declination
││├ axial_tilt
││├ equinox
││├ length_of_year
││└ length_of_day
│├┐time_correction
││├ a
││├ s1
││├ c1
││├ s2
││└ c2
│└ initial_time
├┐albedo
│├ nlat_half
│├ path
│├ file
│├ varname
│├ file_Grid
│└ albedo
├┐soil
│├ nlat_half
│├ D_top
│├ D_root
│├ W_cap
│├ W_wilt
│├ path
│├ file
│├ varname_layer1
│├ varname_layer2
│├ file_Grid
│├ missing_value
│├ monthly_soil_moisture_layer1
│└ monthly_soil_moisture_layer2
├┐vegetation
│├ nlat_half
│├ low_veg_factor
│├ path
│├ file
│├ varname_vegh
│├ varname_vegl
│├ file_Grid
│├ missing_value
│├ high_cover
│└ low_cover
├ physics
├┐clausius_clapeyron
│├ e₀
│├ T₀
│├ Lᵥ
│├ cₚ
│├ R_vapour
│├ R_dry
│├ Lᵥ_Rᵥ
│├ T₀⁻¹
│└ mol_ratio
├┐boundary_layer_drag
│├ κ
│├ z₀
│├ Ri_c
│└ drag_max
├ temperature_relaxation
├┐vertical_diffusion
│├ nlayers
│├ κ
│├ z₀
│├ Ri_c
│├ fb
│├ diffuse_static_energy
│├ diffuse_momentum
│├ diffuse_humidity
│├ logZ_z₀
│├ sqrtC_max
│├ ∇²_above
│└ ∇²_below
├ surface_thermodynamics
├┐surface_wind
│├ f_wind
│├ V_gust
│├ use_boundary_layer_drag
│├ drag_land
│└ drag_sea
├┐surface_heat_flux
│├ use_boundary_layer_drag
│├ heat_exchange_land
│└ heat_exchange_sea
├┐surface_evaporation
│├ use_boundary_layer_drag
│├ moisture_exchange_land
│└ moisture_exchange_sea
├┐large_scale_condensation
│├ relative_humidity_threshold
│└ time_scale
├┐convection
│├ nlayers
│├ time_scale
│├ relative_humidity
│└ surface_temp_humid
├ optical_depth
├ shortwave_radiation
├┐longwave_radiation
│├ α
│├ temp_tropopause
│└ time_scale
├┐stochastic_physics
│├ nlayers
│├ tapering
│└ taper
├┐time_stepping
│├ trunc
│├ nsteps
│├ Δt_at_T31
│├ radius
│├ adjust_with_output
│├ robert_filter
│├ williams_filter
│├ Δt_millisec
│├ Δt_sec
│└ Δt
├ spectral_transform
├┐implicit
│├ trunc
│├ nlayers
│├ α
│├ temp_profile
│├ ξ
│├ R
│├ U
│├ L
│├ W
│├ L0
│├ L1
│├ L2
│├ L3
│├ L4
│├ S
│└ S⁻¹
├┐horizontal_diffusion
│├ trunc
│├ nlayers
│├ power
│├ time_scale
│├ time_scale_div
│├ resolution_scaling
│├ power_stratosphere
│├ tapering_σ
│├ expl
│├ impl
│├ expl_div
│└ impl_div
├ vertical_advection
├ hole_filling
├┐output
│├ active
│├ path
│├ id
│├ run_path
│├ filename
│├ write_restart
│├ pkg_version
│├ startdate
│├ output_dt
│├ variables
│├ output_every_n_steps
│├ timestep_counter
│├ output_counter
│├ netcdf_file
│├ interpolator
│├ grid2D
│└ grid3D
├ callbacks
└┐feedback
 ├ verbose
 ├ debug
 ├ output
 ├ id
 ├ run_path
 ├ progress_meter
 ├ progress_txt
 └ nars_detected

Size of a Simulation

The tree function also allows for the with_size::Bool keyword (default false), which will also print the size of the respective branches to give you an idea of how much memory a SpeedyWeather simulation uses.

tree(simulation, max_level=1, with_size=true)
Simulation{BarotropicModel} (1.25 MB)
├┐prognostic_variables (131.48 KB)
├┐diagnostic_variables (648.97 KB)
└┐model (473.84 KB)

And with max_level you can truncate the tree to go down at most that many levels. 1MB is a typical size for a one-level T31 resolution simulation. In comparison, a higher resolution PrimitiveWetModel would use

spectral_grid = SpectralGrid(trunc=127, nlayers=8)
model = PrimitiveWetModel(spectral_grid)
simulation = initialize!(model)
tree(simulation, max_level=1, with_size=true)
Simulation{PrimitiveWetModel} (64.31 MB)
├┐prognostic_variables (5.48 MB)
├┐diagnostic_variables (36.42 MB)
└┐model (22.41 MB)