Peano
Loading...
Searching...
No Matches
convergence Namespace Reference

-study More...

Detailed Description

-study

Convergence study of the gauge wave with a scalar field

The script builds and runs gauge-wave-with-scalar-field.py for several couplings and mesh sizes. It measures the maximum error of the scalar field along the line y=z=0.5 at the end of the simulation against the exact solution, estimates the convergence orders, and writes convergence.png (error over mesh size) and convergence.md (table) into the output directory. The study doubles as the integration test of the couplings: The script exits with a non-zero status if the estimated order between the two finest meshes falls below the one in ExpectedOrders.

 python3 convergence-study.py --work-directory /scratch/gauge-wave-with-scalar-field

Runs which have completed before in the work directory are reused. Remove the run's directory (or results.json) to rerun it.

Exact solution

The scalar field obeys \( \\partial_t q + H \\partial_x q = 0 \) with \( H = 1 - A \\sin(2 \\pi (x-t)) \), the g_xx of the gauge wave. With \( \\theta = \\pi (x - t) \), the characteristics fulfil \( \\tan \\theta(t) = \\tan \\theta_0 \\ e^{-2 \\pi A t} \). The initial data are q_m = sin(2 pi x + m pi/4), m=0,...,3, i.e. q_m(x,t) = sin(2 theta_0 + m pi/4), where theta_0 is the foot point of the characteristic. See DESIGN.md.

Convergence study of the gauge wave benchmark

The script builds and runs gauge-wave.py for several numerical schemes and mesh sizes, measures the maximum error of the lapse along the line y=z=0.5 at the end of the simulation against the exact solution, estimates the convergence orders, and writes

  • convergence.png (error over mesh size),
  • convergence.md (table with errors, orders, runtimes and memory footprint),
  • results.json (everything in machine-readable form, in the work directory)

into the output directory. The study is the integration test for the correctness of the numerical schemes behind the benchmark: The script exits with a non-zero status if the estimated convergence order of a scheme falls below the one in ExpectedOrders. Runtimes and memory footprints are recorded, but are not an acceptance criterion.

 python3 convergence-study.py --work-directory /scratch/gauge-wave

Runs which have completed before in the work directory are reused. Remove the run's directory (or results.json) to rerun it.

Scheduling

Every scheme is studied by a worker of its own, and all workers run at the same time. A worker walks through the meshes from coarse to fine. Runs on coarse meshes cannot exploit many cores: With 27 mesh cells (the minimum, as Peano refines the root cell at least once) the scaling stagnates, and these runs use one thread. They are done long before the runs on the fine meshes get going, i.e. the biggest setups do not start at the same time. A run on a fine mesh gets its share of the cores, which grows as workers finish. At most two of them (–concurrent-large-runs) run at the same time, as they are memory hungry.

Memory

The memory footprint grows with the number of volumes. A watchdog observes the footprint of each run. If less than 1.5 GB remain available on the machine, the run with the biggest footprint is killed (typically right after its start, as the meshes allocate their memory early) and the study continues without that data point.

Convergence study of the entropy wave benchmark

Generates, builds and runs smooth-convergence-test.py for the three standard mesh widths (Convergence Tests (Euler Equations)), and hands the outcome to compute-errors.py. The script exits with a non-zero status if the order of the maximum error between the two finest meshes falls below the minimum order of the scheme (e.g. 3.5 for rk4fd4, which yields 4.0). By default, the study runs the Finite Difference schemes rk1fd4, rk2fd4, rk3fd4 and rk4fd4 one after another (each in a subdirectory of the work directory) and fails if any of them misses its minimum order.

This is part of the ExaHyPE 2 integration test (skill exahype2:integration-test).