|
Peano
|
Functions | |
| psi (r) | |
| Conformal factor of the Schwarzschild black hole in isotropic coordinates. | |
| build_and_run (directory, peano_installation, end_time, scheme, enforce, patch_size=PatchSize, load_balancing=False, threads=None) | |
| Generate, compile and run the tutorial setup within directory. | |
| probe (directory, point, output_file) | |
| Probe all snapshots at one point. | |
| profile (directory, volumes_per_axis=VolumesPerAxis) | |
| Probe lapse and phi in the centre of each volume along the line through the centres of the volumes next to the puncture, i.e. | |
| radius (x, line_offset=LineOffset) | |
| time_steps (directory) | |
| Number of time steps and average wall clock time per time step. | |
| plot_speeding_up (coarse, fine) | |
| Lapse next to the puncture over time, and along the x-axis at the end, for both meshes. | |
| plot_initial_data (x, lapse, phi) | |
| Initial lapse and conformal factor along the x-axis against the closed form. | |
| plot_lapse_profile (x, t, lapse) | |
| Lapse along the x-axis for several snapshots. | |
| plot_lapse_over_time (x, t, lapse) | |
| Lapse over time at a few distances from the puncture. | |
| plot_constraints (unconstrained, constrained) | |
| Lapse and phi next to the puncture over time with and without constraint enforcement. | |
Variables | |
| Here = os.path.dirname(os.path.abspath(__file__)) | |
| PeanoRoot = os.path.abspath(os.path.join(Here, "..", "..", "..", "..")) | |
| str | PatchFile = "solution-CCZ4.peano-patch-file" |
| float | Mass = 1.0 |
| float | DomainOffset = -9.0 |
| float | DomainSize = 18.0 |
| int | CellsPerAxis = 9 |
| int | PatchSize = 6 |
| int | VolumesPerAxis = CellsPerAxis * PatchSize |
| float | TimeInBetweenPlots = 0.5 |
| float | LineOffset = DomainSize / VolumesPerAxis / 2.0 |
| y and z coordinate of the line along which we probe: the centre of the first volume next to the origin | |
| int | DecomposedPatchSize = 10 |
| The run of the section "Speeding up": the plain Finite Volumes with 10x10x10 patches over the same 9x9x9 mesh cells, the domain decomposed by a load balancing strategy, and four OpenMP threads. | |
| int | DecomposedThreads = 4 |
| list | Runs |
| The runs: name, patch size, load balancing, threads, constraint enforcement. | |
| parser | |
| default | |
| help | |
| type | |
| float | |
| args = parser.parse_args() | |
| work_directory | |
| dict | runs = {} |
| directory = os.path.join(os.path.abspath(work_directory), name) | |
| runtime | |
| int | volumes_per_axis = CellsPerAxis * patch_size |
| x | |
| t | |
| lapse | |
| phi | |
| count | |
| average | |
| float | h = DomainSize / volumes_per_axis |
| int | centre = volumes_per_axis // 2 |
| 522_single-black-hole.build_and_run | ( | directory, | |
| peano_installation, | |||
| end_time, | |||
| scheme, | |||
| enforce, | |||
patch_size = PatchSize, |
|||
load_balancing = False, |
|||
threads = None |
|||
| ) |
Generate, compile and run the tutorial setup within directory.
| patch_size | int Number of volumes per axis within one patch. The mesh always has CellsPerAxis cells per axis. |
| load_balancing | bool If True, decompose the domain with toolbox::loadbalancing::strategies::SpreadOutOnceGridStagnates. |
| threads | int or None If not None, run with OMP_NUM_THREADS set to this value. |
| scheme | type Numerical scheme, i.e. a Finite Volume class from exahype2.api.fv. |
| enforce | exagrype.api.CCZ4Solver.EnforceCCZ4Constraint Constraint enforcement. |
Returns the runtime of the executable in seconds. If the directory holds the result of a previous run, we do not rerun but return the stored runtime.
Definition at line 104 of file 522_single-black-hole.py.
References float, and exagrype.api.initialvalues.single_black_hole().

| 522_single-black-hole.plot_constraints | ( | unconstrained, | |
| constrained | |||
| ) |
Lapse and phi next to the puncture over time with and without constraint enforcement.
Definition at line 431 of file 522_single-black-hole.py.
References radius().

| 522_single-black-hole.plot_initial_data | ( | x, | |
| lapse, | |||
| phi | |||
| ) |
Initial lapse and conformal factor along the x-axis against the closed form.
Definition at line 333 of file 522_single-black-hole.py.
References psi(), and radius().

| 522_single-black-hole.plot_lapse_over_time | ( | x, | |
| t, | |||
| lapse | |||
| ) |
Lapse over time at a few distances from the puncture.
Definition at line 406 of file 522_single-black-hole.py.
References radius().

| 522_single-black-hole.plot_lapse_profile | ( | x, | |
| t, | |||
| lapse | |||
| ) |
Lapse along the x-axis for several snapshots.
Definition at line 379 of file 522_single-black-hole.py.
| 522_single-black-hole.plot_speeding_up | ( | coarse, | |
| fine | |||
| ) |
Lapse next to the puncture over time, and along the x-axis at the end, for both meshes.
Definition at line 300 of file 522_single-black-hole.py.
References radius().

| 522_single-black-hole.probe | ( | directory, | |
| point, | |||
| output_file | |||
| ) |
Probe all snapshots at one point.
Returns the time stamps, the lapse and the conformal factor phi.
Definition at line 229 of file 522_single-black-hole.py.
References float.
| 522_single-black-hole.profile | ( | directory, | |
volumes_per_axis = VolumesPerAxis |
|||
| ) |
Probe lapse and phi in the centre of each volume along the line through the centres of the volumes next to the puncture, i.e.
along y=z=h/2
Returns the x coordinates, the time stamps and two 2d arrays lapse[snapshot,x] and phi[snapshot,x].
Definition at line 255 of file 522_single-black-hole.py.
| 522_single-black-hole.psi | ( | r | ) |
Conformal factor of the Schwarzschild black hole in isotropic coordinates.
Definition at line 73 of file 522_single-black-hole.py.
Referenced by plot_initial_data().

| 522_single-black-hole.radius | ( | x, | |
line_offset = LineOffset |
|||
| ) |
Definition at line 277 of file 522_single-black-hole.py.
Referenced by plot_constraints(), plot_initial_data(), plot_lapse_over_time(), and plot_speeding_up().

| 522_single-black-hole.time_steps | ( | directory | ) |
Number of time steps and average wall clock time per time step.
Both stem from the final report of peano4::DefaultStepReport in run.log, i.e. from the line "TimeStep: ...s (avg=...,#measurements=...".
Definition at line 281 of file 522_single-black-hole.py.
References float.
| 522_single-black-hole.args = parser.parse_args() |
Definition at line 487 of file 522_single-black-hole.py.
| 522_single-black-hole.average |
Definition at line 508 of file 522_single-black-hole.py.
| int 522_single-black-hole.CellsPerAxis = 9 |
Definition at line 63 of file 522_single-black-hole.py.
| int 522_single-black-hole.centre = volumes_per_axis // 2 |
Definition at line 519 of file 522_single-black-hole.py.
| 522_single-black-hole.count |
Definition at line 508 of file 522_single-black-hole.py.
| int 522_single-black-hole.DecomposedPatchSize = 10 |
The run of the section "Speeding up": the plain Finite Volumes with 10x10x10 patches over the same 9x9x9 mesh cells, the domain decomposed by a load balancing strategy, and four OpenMP threads.
Definition at line 81 of file 522_single-black-hole.py.
| int 522_single-black-hole.DecomposedThreads = 4 |
Definition at line 82 of file 522_single-black-hole.py.
| 522_single-black-hole.default |
Definition at line 476 of file 522_single-black-hole.py.
| 522_single-black-hole.directory = os.path.join(os.path.abspath(work_directory), name) |
Definition at line 495 of file 522_single-black-hole.py.
| float 522_single-black-hole.DomainOffset = -9.0 |
Definition at line 61 of file 522_single-black-hole.py.
| float 522_single-black-hole.DomainSize = 18.0 |
Definition at line 62 of file 522_single-black-hole.py.
| 522_single-black-hole.float |
Definition at line 485 of file 522_single-black-hole.py.
Referenced by build_and_run(), probe(), and time_steps().
| 522_single-black-hole.h = DomainSize / volumes_per_axis |
Definition at line 509 of file 522_single-black-hole.py.
| 522_single-black-hole.help |
Definition at line 477 of file 522_single-black-hole.py.
| 522_single-black-hole.Here = os.path.dirname(os.path.abspath(__file__)) |
Definition at line 43 of file 522_single-black-hole.py.
| 522_single-black-hole.lapse |
Definition at line 507 of file 522_single-black-hole.py.
| float 522_single-black-hole.LineOffset = DomainSize / VolumesPerAxis / 2.0 |
y and z coordinate of the line along which we probe: the centre of the first volume next to the origin
Definition at line 70 of file 522_single-black-hole.py.
| float 522_single-black-hole.Mass = 1.0 |
Definition at line 60 of file 522_single-black-hole.py.
| 522_single-black-hole.parser |
Definition at line 471 of file 522_single-black-hole.py.
| str 522_single-black-hole.PatchFile = "solution-CCZ4.peano-patch-file" |
Definition at line 59 of file 522_single-black-hole.py.
| int 522_single-black-hole.PatchSize = 6 |
Definition at line 64 of file 522_single-black-hole.py.
| 522_single-black-hole.PeanoRoot = os.path.abspath(os.path.join(Here, "..", "..", "..", "..")) |
Definition at line 44 of file 522_single-black-hole.py.
| 522_single-black-hole.phi |
Definition at line 507 of file 522_single-black-hole.py.
| list 522_single-black-hole.Runs |
The runs: name, patch size, load balancing, threads, constraint enforcement.
Definition at line 85 of file 522_single-black-hole.py.
| dict 522_single-black-hole.runs = {} |
Definition at line 493 of file 522_single-black-hole.py.
| 522_single-black-hole.runtime |
Definition at line 496 of file 522_single-black-hole.py.
| 522_single-black-hole.t |
Definition at line 507 of file 522_single-black-hole.py.
| float 522_single-black-hole.TimeInBetweenPlots = 0.5 |
Definition at line 66 of file 522_single-black-hole.py.
| 522_single-black-hole.type |
Definition at line 485 of file 522_single-black-hole.py.
| 522_single-black-hole.volumes_per_axis = CellsPerAxis * patch_size |
Definition at line 506 of file 522_single-black-hole.py.
| int 522_single-black-hole.VolumesPerAxis = CellsPerAxis * PatchSize |
Definition at line 65 of file 522_single-black-hole.py.
| 522_single-black-hole.work_directory |
Definition at line 490 of file 522_single-black-hole.py.
| 522_single-black-hole.x |
Definition at line 507 of file 522_single-black-hole.py.