Filters

In this tutorial we show the result of applying filters available in the CliMA codebase in a 1 dimensional box advection setup. See Filters API for filters interface details.

using ClimateMachine
const clima_dir = dirname(dirname(pathof(ClimateMachine)));
include(joinpath(clima_dir, "tutorials", "Numerics", "DGMethods", "Box1D.jl"))

const FT = Float64

output_dir = @__DIR__;
mkpath(output_dir);

The unfiltered result of the box advection test for order 4 polynomial with central flux is

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_no_filter.svg"),
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 7.0629054001769553e+00
│     norm(Q) / norm(Q₀) = 9.9694358982360365e-01
│     norm(Q) - norm(Q₀) = -2.1653317359556112e-02
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0190972222224218e+01
│     difference            = 1.6129320101754274e-12
│     normalized difference = 3.2135898922900007e-14
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

The unfiltered result of the box advection test for order 4 polynomial with Rusanov flux (aka upwinding for advection) is

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_no_filter_upwind.svg"),
    numerical_flux_first_order = RusanovNumericalFlux(),
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 7.0513534001494440e+00
│     norm(Q) / norm(Q₀) = 9.9531300131582312e-01
│     norm(Q) - norm(Q₀) = -3.3205317387067446e-02
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0190972222224502e+01
│     difference            = 1.8971491044794675e-12
│     normalized difference = 3.7798612389490313e-14
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

Below we show results for the same box advection test but using different filters.

As seen in the results, when the TMAR filter is used mass is not necessarily conserved (mass increases are possible).

TMARFilter() with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_tmar.svg");
    tmar_filter = true,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 7.0284834766751603e+00
│     norm(Q) / norm(Q₀) = 9.9208486468994217e-01
│     norm(Q) - norm(Q₀) = -5.6075240861351183e-02
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0273717773327995e+01
│     difference            = 8.2745551105389836e-02
│     normalized difference = 1.6486142316397157e-03
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

Running the TMAR filter with Rusanov the mass conservation since some of the are reduced, but mass is still not conserved. TMARFilter() with Rusanov numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_tmar_upwind.svg");
    tmar_filter = true,
    numerical_flux_first_order = RusanovNumericalFlux(),
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 7.0195965557948750e+00
│     norm(Q) / norm(Q₀) = 9.9083045757234889e-01
│     norm(Q) - norm(Q₀) = -6.4962161741636493e-02
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0231802188006426e+01
│     difference            = 4.0829965783821365e-02
│     normalized difference = 8.1349222730822993e-04
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

CutoffFilter(grid, Nc=1) with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_cutoff_1.svg");
    cutoff_filter = true,
    cutoff_param = 1,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 4.3749269099690329e+00
│     norm(Q) / norm(Q₀) = 6.1752991038661487e-01
│     norm(Q) - norm(Q₀) = -2.7096318075674786e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0190972222251148e+01
│     difference            = 2.8542501695483224e-11
│     normalized difference = 5.6867799988233175e-13
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

CutoffFilter(grid, Nc=3) with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_cutoff_3.svg");
    cutoff_filter = true,
    cutoff_param = 3,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 7.0138240459748733e+00
│     norm(Q) / norm(Q₀) = 9.9001565596646868e-01
│     norm(Q) - norm(Q₀) = -7.0734671561638152e-02
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0190972222237605e+01
│     difference            = 1.4999557151895715e-11
│     normalized difference = 2.9884970319930354e-13
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

ExponentialFilter(grid, Nc=1, s=4) with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_exp_1_4.svg");
    exp_filter = true,
    exp_param_1 = 1,
    exp_param_2 = 4,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 6.9333444856518298e+00
│     norm(Q) / norm(Q₀) = 9.7865580088843374e-01
│     norm(Q) - norm(Q₀) = -1.5121423188468164e-01
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0190972222230513e+01
│     difference            = 7.9083406490099151e-12
│     normalized difference = 1.5756500220787536e-13
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

ExponentialFilter(grid, Nc=1, s=8) with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_exp_1_8.svg");
    exp_filter = true,
    exp_param_1 = 1,
    exp_param_2 = 8,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 7.0143099503303743e+00
│     norm(Q) / norm(Q₀) = 9.9008424236328940e-01
│     norm(Q) - norm(Q₀) = -7.0248767206137153e-02
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0190972222235352e+01
│     difference            = 1.2747136679536197e-11
│     normalized difference = 2.5397269897657535e-13
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

ExponentialFilter(grid, Nc=1, s=32) with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_exp_1_32.svg");
    exp_filter = true,
    exp_param_1 = 1,
    exp_param_2 = 32,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 7.0543517922299213e+00
│     norm(Q) / norm(Q₀) = 9.9573623051047366e-01
│     norm(Q) - norm(Q₀) = -3.0206925306590193e-02
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0190972222228595e+01
│     difference            = 5.9898752624576446e-12
│     normalized difference = 1.1934168630839076e-13
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

BoydVandevenFilter(grid, Nc=1, s=4) with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_boyd_1_4.svg");
    boyd_filter = true,
    boyd_param_1 = 1,
    boyd_param_2 = 4,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 6.9612435701243669e+00
│     norm(Q) / norm(Q₀) = 9.8259381390870526e-01
│     norm(Q) - norm(Q₀) = -1.2331514741214455e-01
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0190972222241932e+01
│     difference            = 1.9326762412674725e-11
│     normalized difference = 3.8506451572814101e-13
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

BoydVandevenFilter(grid, Nc=1, s=8) with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_boyd_1_8.svg");
    boyd_filter = true,
    boyd_param_1 = 1,
    boyd_param_2 = 8,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 6.9798736717003287e+00
│     norm(Q) / norm(Q₀) = 9.8522349097381967e-01
│     norm(Q) - norm(Q₀) = -1.0468504583618277e-01
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0190972222212103e+01
│     difference            = -1.0501821634534281e-11
│     normalized difference = -2.0923726259051192e-13
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

BoydVandevenFilter(grid, Nc=1, s=32) with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_boyd_1_32.svg");
    boyd_filter = true,
    boyd_param_1 = 1,
    boyd_param_2 = 32,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 7.0120419256462405e+00
│     norm(Q) / norm(Q₀) = 9.8976410602529563e-01
│     norm(Q) - norm(Q₀) = -7.2516791890270937e-02
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0190972222235835e+01
│     difference            = 1.3230305739853065e-11
│     normalized difference = 2.6359931186977886e-13
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

ExponentialFilter(grid, Nc=1, s=8) and TMARFilter() with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_tmar_exp_1_8.svg");
    exp_filter = true,
    tmar_filter = true,
    exp_param_1 = 1,
    exp_param_2 = 8,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 6.9859473293750973e+00
│     norm(Q) / norm(Q₀) = 9.8608080021733469e-01
│     norm(Q) - norm(Q₀) = -9.8611388161414126e-02
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0255956701552577e+01
│     difference            = 6.4984479329972089e-02
│     normalized difference = 1.2947443823612466e-03
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276

BoydVandevenFilter(grid, Nc=1, s=8) and TMARFilter() with central numerical flux:

run_box1D(
    4,
    FT(0.0),
    FT(1.0),
    FT(1.0),
    joinpath(output_dir, "box_1D_4_tmar_boyd_1_8.svg");
    boyd_filter = true,
    tmar_filter = true,
    boyd_param_1 = 1,
    boyd_param_2 = 8,
)
ClimateMachine.array_type() = Array
┌ Info: Model composition
│     param_set = Main.##398.EarthParameterSet()
│     init_q = 0.0
│     amplitude = 1.0
│     velo = 1.0
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:188
┌ Info: Defining `prognostic_vars` and
│ `eq_tends` for Box1D will
│ enable printing a table of tendencies.
└ @ ClimateMachine.BalanceLaws /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/BalanceLaws/show_tendencies.jl:65
┌ Info: Establishing single stack configuration for Box1D
│     precision               = Float64
│     horiz polynomial order  = 4
│     vert polynomial order   = 4
│     domain_min              = 0.00 m, 0.00 m, 0.00 m
│     domain_max              = 1.00 m, 1.00 m, 350.00 m
│     # vert elems            = 128
│     MPI ranks               = 1
│     min(Δ_horz)             = 0.17 m
│     min(Δ_vert)             = 0.47 m
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/driver_configs.jl:612
┌ Info: Initializing Box1D
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/solver_configs.jl:185
┌ Info: Starting Box1D
│     dt              = 4.71698e-01
│     timeend         =   450.00
│     number of steps = 954
│     norm(Q)         = 7.0845587175365115e+00
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:802
┌ Info: Finished
│     norm(Q)            = 6.9548646819374671e+00
│     norm(Q) / norm(Q₀) = 9.8169342075209132e-01
│     norm(Q) - norm(Q₀) = -1.2969403559904435e-01
└ @ ClimateMachine /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/src/Driver/Driver.jl:853
┌ Info: Mass Conservation:
│     initial mass          = 5.0190972222222605e+01
│     final mass            = 5.0269145317345739e+01
│     difference            = 7.8173095123133862e-02
│     normalized difference = 1.5575130678285977e-03
└ @ Main.##398 /central/scratch/climaci/climatemachine-docs/1430/climatemachine-docs/tutorials/Numerics/DGMethods/Box1D.jl:276


This page was generated using Literate.jl.