embedded3 S2-1 remedy: the reconstructed wall route on the cut geometry's polygons (two probes along the interpolant normal) — sphere MMS 11.3/8.3 % (the best route); wired into the DFG and flag drivers
CI / Python Bindings (maturin) (ubuntu-latest) (push) Blocked by required conditions
CI / Test (macos-latest) (push) Blocked by required conditions
CI / Test (ubuntu-latest) (push) Blocked by required conditions
CI / Python Bindings (maturin) (macos-latest) (push) Blocked by required conditions
CI / Build (macos-latest) (push) Waiting to run
CI / WASM Build + Size Check (push) Blocked by required conditions
CI / Distributed Training Tests (push) Blocked by required conditions
CI / CI Success (push) Blocked by required conditions
Performance Benchmarks / Run Benchmarks (push) Failing after 4s
CI / Build (ubuntu-latest) (push) Failing after 3s
CI / Format Check (push) Failing after 3s
CI / Clippy Check (push) Failing after 3s
Documentation / Build User Guide (push) Successful in 5s
Documentation / Build API Documentation (push) Failing after 14s
CI / Build CPU-Only (Explicit) (push) Failing after 54s

Co-Authored-By: Claude Fable 5.1 <[email protected]>
This commit is contained in:
Omar Sobh
2026-09-17 23:18:21 -05:00
co-authored by Claude Fable 5.1
parent f2cdda4691
commit b34f6ad966
4 changed files with 99 additions and 5 deletions
@@ -141,7 +141,15 @@ fn dfg_3d_2z_on_the_device() {
);
let fcv =
mask.control_volume_force_with_walls(&field, dt, RHO, RHO * NU, None, bx, true);
let fs = mask.surface_force(body, &field, RHO * NU, t, 0.5 * h);
// The reconstructed wall route (two probes on the cut polygons).
let fr = mask
.cut_wall_force_reconstructed(body, &field, RHO * NU, t, None)
.expect("reconstructed");
let fs = rtx_cfd::solvers::incompressible::embedded3::SurfaceForce {
f: fr,
samples: 0,
skipped: 0,
};
let (cd_s, cl_s) = (coef * fs.f[0], coef * fs.f[1]);
let zc = 0.5 * H;
let p_front = mask
@@ -153,7 +161,7 @@ fn dfg_3d_2z_on_the_device() {
let dp = p_front - p_back;
let (cd, cl, cd_cv, cl_cv) = (coef * fw[0], coef * fw[1], coef * fcv[0], coef * fcv[1]);
println!(
" t {t:8.4}: c_D {cd:.4} (CV {cd_cv:.4}, sampler {cd_s:.4} skipped {}) c_L {cl:.5} (CV {cl_cv:.5}, sampler {cl_s:.5}) Δp {dp:.4} residual {:.1e} CG {} [{:.0} s]",
" t {t:8.4}: c_D {cd:.4} (CV {cd_cv:.4}, reconstructed {cd_s:.4} skipped {}) c_L {cl:.5} (CV {cl_cv:.5}, reconstructed {cl_s:.5}) Δp {dp:.4} residual {:.1e} CG {} [{:.0} s]",
fs.skipped,
r.final_residual,
r.poisson_iterations,
@@ -194,7 +202,7 @@ fn dfg_3d_2z_on_the_device() {
}
let (cd, cl, cd_cv, cl_cv, dp) = last.expect("samples");
println!(
" FINAL ny {ny}: c_D {cd:.4} (CV {cd_cv:.4}, routes {:.2e} apart; sampler {:.4}, {:.2e} from CV) c_L {cl:.5} (CV {cl_cv:.5}, sampler {:.5}) Δp {dp:.4} — reference c_D 6.056.25, c_L 0.0080.010, Δp 0.1650.175; {:.0} s",
" FINAL ny {ny}: c_D {cd:.4} (CV {cd_cv:.4}, routes {:.2e} apart; reconstructed {:.4}, {:.2e} from CV) c_L {cl:.5} (CV {cl_cv:.5}, reconstructed {:.5}) Δp {dp:.4} — reference c_D 6.056.25, c_L 0.0080.010, Δp 0.1650.175; {:.0} s",
((cd - cd_cv) / cd).abs(),
last_sampler.0,
((last_sampler.0 - cd_cv) / cd_cv).abs(),
@@ -60,7 +60,7 @@ fn ladder(resolutions: &[usize], scheme: WallScheme) -> Ladder {
mm.force_sampler[2] - fe[2],
]) / f_scale;
println!(
" n = {n:3} L2 u {:.4e} (order {rate}) max div {:.2e} ghost corr {:.2e} F_surface {:.4?} rel {s:.3e} (skipped {}) F_cv {:.4?} rel {c:.3e} F_sampler rel {a:.3e}",
" n = {n:3} L2 u {:.4e} (order {rate}) max div {:.2e} ghost corr {:.2e} F_surface {:.4?} rel {s:.3e} (skipped {}) F_cv {:.4?} rel {c:.3e} F_reconstructed rel {a:.3e}",
mm.l2_velocity,
mm.max_div,
mm.ghost_correction,
@@ -258,7 +258,9 @@ pub fn measure(n: usize, scheme: WallScheme, c: (f64, f64, f64)) -> Measurement
let force_cv = mask.control_volume_force(&f, dt, RHO, MU, Some(&src), (i0, i1, i0, i1, i0, i1));
let force_sampler = match scheme {
WallScheme::GhostBinary => surface.f,
WallScheme::CutCell => mask.surface_force(body, &f, MU, t, 0.5 * h).f,
WallScheme::CutCell => mask
.cut_wall_force_reconstructed(body, &f, MU, t, None)
.expect("reconstructed"),
};
Measurement {
l2_velocity: (sq / vol).sqrt(),