perf(jacobian-action): major updates to jacobian action application by removing redudant quadrature work. ~5x increase in speed
This commit is contained in:
@@ -147,3 +147,42 @@ The executable needs the same dependencies, generated module mapping, and
|
||||
configuration registration as the existing Catch2 test executable. Add
|
||||
`experiment_main.cpp` and `gravity_accuracy_budget.cpp` as a second executable
|
||||
next to that target; do not add them to the ordinary test executable.
|
||||
|
||||
## P0 preconditioning baseline
|
||||
|
||||
The P0 diagnostic establishes the unpreconditioned reference for the complete,
|
||||
central-density-closed `n = 3` stellar equilibrium Jacobian. It uses an identity
|
||||
inverse preconditioner with FGMRES, recomputes the true residual independently,
|
||||
records every residual block, and counts and times Jacobian and preconditioner
|
||||
applications. A separate fixed-operator Arnoldi measurement acts explicitly on
|
||||
the right-preconditioned product `J M^-1`. Its singular-value ratio is a
|
||||
projected Krylov-space condition proxy, not the condition number of the full
|
||||
Jacobian. The same output records Ritz values, clustering about one,
|
||||
nonnormality, and the real extent of the projected field of values.
|
||||
|
||||
The extended baseline preserves the fixed 40-iteration FGMRES budget used by
|
||||
the original P0 run and increases the Arnoldi dimension from 12 to 48. It writes
|
||||
the complete reported FGMRES residual history, block-relative and
|
||||
manifest-scaled final residuals, the fraction of the squared residual in each
|
||||
physics block, timings for construction/projection/preparation/direct-residual
|
||||
measurement, and separate Arnoldi operator and orthogonalization timings. Live
|
||||
progress messages delimit every expensive phase and report every fourth
|
||||
Arnoldi application. The CSV records whether it came from a Debug or Release
|
||||
build.
|
||||
|
||||
Run the focused synthetic verification tests with:
|
||||
|
||||
```text
|
||||
./cmake-build-debug-homebrew/tests "[preconditioning][diagnostics][unit]"
|
||||
```
|
||||
|
||||
Run the performance and spectral measurement separately with:
|
||||
|
||||
```text
|
||||
mpirun -np 1 ./cmake-build-release-homebrew/experiments \
|
||||
--experiment-output preconditioning_p0_identity_extended.csv \
|
||||
--catch2 "[preconditioning][diagnostics][baseline]"
|
||||
```
|
||||
|
||||
Set `MEANFIELD_SINGLE_JACOBIAN_BENCHMARK=1` to stop after the initial prepared
|
||||
Jacobian timing instead of running FGMRES and Arnoldi.
|
||||
|
||||
Reference in New Issue
Block a user