|
29 | 29 | ("TENO7", ["--order", "7", "--teno", "--teno-ct", "1e-9", "--cfl", "0.005"], 7, 0.5, 64, 128), |
30 | 30 | ] |
31 | 31 |
|
32 | | -# 2D isentropic vortex (eps=0.01, hcid=283 Gauss-Legendre IC). WENO7/TENO7 |
33 | | -# excluded — covariance floor O(eps^3 h^2) dominates at N=32..128. |
| 32 | +# 2D diagonal advection (rho = 1 + 0.2 sin(2pi(x+y)), v=(1,1), period T=0.5): |
| 33 | +# linear primitives mean no covariance floor — clean asymptotic rates for all |
| 34 | +# WENO/MUSCL/TENO orders. WENO3 reduces to 2nd at smooth extrema (Henrick 2005). |
| 35 | +# 4 ranks (2x2 decomp): per-rank stencil constraint n+1 >= 5*weno_order/2. |
| 36 | +# WENO5/TENO5 use [64, 96, 128] (33>=25 at N=64). WENO7/TENO7 use [80, 96] |
| 37 | +# (41>=35 at N=80) and CFL=0.005 to push RK3 temporal error below O(h^7). |
| 38 | +# (label, extra_args, expected_order, tol, resolutions) |
34 | 39 | _CONS_VARS_2D = [("density", 1), ("energy", 4)] |
35 | | -_RES_2D_DEFAULT = [32, 64, 128] |
36 | 40 | _CONVERGENCE_2D_SCHEMES = [ |
37 | | - ("WENO5", ["--order", "5"], 5, 1.0, 64, None), |
38 | | - ("WENO3", ["--order", "3"], 3, 1.2, 32, None), |
39 | | - ("WENO1", ["--order", "1"], 1, 0.4, 32, None), |
40 | | - ("MUSCL2", ["--muscl"], 2, 0.5, 32, None), |
41 | | - ("TENO5", ["--order", "5", "--teno", "--teno-ct", "1e-6"], 5, 1.0, 64, None), |
| 41 | + ("WENO5", ["--order", "5", "--cfl", "0.02"], 5, 0.3, [64, 96, 128]), |
| 42 | + ("WENO3", ["--order", "3", "--cfl", "0.02"], 2, 0.3, [32, 64, 128]), |
| 43 | + ("WENO1", ["--order", "1", "--cfl", "0.02"], 1, 0.2, [32, 64, 128]), |
| 44 | + ("MUSCL2", ["--muscl", "--muscl-lim", "0", "--cfl", "0.02"], 2, 0.1, [32, 64, 128]), |
| 45 | + ("TENO5", ["--order", "5", "--teno", "--teno-ct", "1e-6", "--cfl", "0.02"], 5, 0.3, [64, 96, 128]), |
| 46 | + ("WENO7", ["--order", "7", "--cfl", "0.005"], 7, 0.5, [80, 96]), |
| 47 | + ("TENO7", ["--order", "7", "--teno", "--teno-ct", "1e-9", "--cfl", "0.005"], 7, 0.5, [80, 96]), |
42 | 48 | ] |
43 | 49 |
|
44 | 50 | # Sod L1 self-convergence: any conservative monotone scheme converges at L1 |
@@ -104,21 +110,19 @@ def add_convergence_cases(cases): |
104 | 110 | ) |
105 | 111 | ) |
106 | 112 |
|
107 | | - for label, extra_args, expected, tol, min_N, max_N in _CONVERGENCE_2D_SCHEMES: |
| 113 | + for label, extra_args, expected, tol, resolutions in _CONVERGENCE_2D_SCHEMES: |
108 | 114 | cases.append( |
109 | 115 | define_convergence_case( |
110 | 116 | f"Convergence -> 2D -> {label}", |
111 | 117 | spec={ |
112 | | - "runner": "2d_vortex", |
113 | | - "case_path": "examples/2D_isentropicvortex_convergence/case.py", |
| 118 | + "runner": "2d_advection", |
| 119 | + "case_path": "examples/2D_advection_convergence/case.py", |
114 | 120 | "extra_args": extra_args, |
115 | 121 | "expected_order": expected, |
116 | 122 | "tol": tol, |
117 | | - "resolutions": _RES_2D_DEFAULT, |
118 | | - "min_N": min_N, |
119 | | - "max_N": max_N, |
| 123 | + "resolutions": resolutions, |
120 | 124 | "ndim": 2, |
121 | | - "domain_len": 10.0, |
| 125 | + "domain_len": 1.0, |
122 | 126 | "cons_vars": _CONS_VARS_2D, |
123 | 127 | "primary_idx": 1, |
124 | 128 | "num_ranks": num_ranks, |
@@ -165,30 +169,6 @@ def add_convergence_cases(cases): |
165 | 169 | ) |
166 | 170 | ) |
167 | 171 |
|
168 | | - # 2D diagonal advection — same 4-rank decomposition as the rest of the suite. |
169 | | - for label, extra_args, expected, tol, min_N, max_N in _CONVERGENCE_2D_ADV_SCHEMES: |
170 | | - cases.append( |
171 | | - define_convergence_case( |
172 | | - f"Convergence -> 2D Adv -> {label}", |
173 | | - spec={ |
174 | | - "runner": "2d_vortex", |
175 | | - "case_path": "examples/2D_advection_convergence/case.py", |
176 | | - "extra_args": extra_args, |
177 | | - "expected_order": expected, |
178 | | - "tol": tol, |
179 | | - "resolutions": _RES_2D_ADV_DEFAULT, |
180 | | - "min_N": min_N, |
181 | | - "max_N": max_N, |
182 | | - "ndim": 2, |
183 | | - "domain_len": 1.0, |
184 | | - "cons_vars": _CONS_VARS_2D, |
185 | | - "primary_idx": 1, |
186 | | - "num_ranks": num_ranks, |
187 | | - }, |
188 | | - ppn=num_ranks, |
189 | | - ) |
190 | | - ) |
191 | | - |
192 | 172 |
|
193 | 173 | def get_bc_mods(bc: int, dimInfo): |
194 | 174 | params = {} |
@@ -1763,7 +1743,6 @@ def foreach_example(): |
1763 | 1743 | "1D_titarevtorro_analytical", |
1764 | 1744 | "2D_acoustic_pulse_analytical", |
1765 | 1745 | "2D_isentropicvortex_analytical", |
1766 | | - "2D_isentropicvortex_convergence", |
1767 | 1746 | "1D_euler_convergence", |
1768 | 1747 | "1D_advection_convergence", |
1769 | 1748 | "1D_sod_convergence", |
|
0 commit comments