From 6c91c9223feba7f7bf745c03d676b07dfa8b61db Mon Sep 17 00:00:00 2001 From: Peter Teuben Date: Thu, 29 Jun 2023 21:25:40 -0400 Subject: [PATCH] another cleanup --- README.md | 57 ++++++++++++++++++++++++++++++++++++------------------- 1 file changed, 38 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index 7982c0e..58a9e6a 100644 --- a/README.md +++ b/README.md @@ -17,15 +17,19 @@ into the executable. Some older comments on athena++ can be found below. Again, an example how to compile and run the code +```bash git clone --recursive https://gitlab.com/theias/hpc/jmstone/athena-parthenon/athenak mkdir athenak/build cd athenak/build cmake .. make -j +``` or if you're lazy, use the Makefile in this directory: +```bash make build +``` this takes a bit longer than athena++, mostly because the kokkos library has to be compiled with). The binary is @@ -67,22 +71,28 @@ build/src/athena -i inputs/hydro/viscosity.athinput -d run8 First we grab and compile the code for the linear wave problem +```bash git clone https://github.com/PrincetonUniversity/athena cd athena ./configure.py --prob linear_wave make clean make -j +``` Compiling the code takes the most time, but on a typical laptop well under 30 seconds. After this we can run it +```bash bin/athena -i inputs/hydro/athinput.linear_wave1d -d run1 +``` but the default output from that **athinput** file is the **vtk** data format, which for this demo will be too complex to parse. TBD. For now we switch to the ascii table format, viz. +```bash bin/athena -i inputs/hydro/athinput.linear_wave1d -d run2 output2/file_type=tab +``` ### Animations @@ -91,24 +101,31 @@ in each table shows the columns names: ```text - # Athena++ data at time=0.000000e+00 cycle=0 variables=prim - # i x1v rho press vel1 vel2 vel3 +# Athena++ data at time=0.000000e+00 cycle=0 variables=prim +# i x1v rho press vel1 vel2 vel3 ``` +this would be an animation of *x1v* vs. *vel1* + ```bash -for f in LinWave*.tab; do - tabplot $f xcol=2 ycol=5 -done + for f in LinWave*.tab; do + tabplot $f xcol=2 ycol=5 + done ``` or using our sample script + ```bash - ../../animate1 xcol=2 ycol=5 + ../../animate1 xcol=x1v ycol=vel1 ``` if **tkrun** is enabled, use - tkrun ../../animate1 +```bash + tkrun ../../animate1 +``` + +but this may be broken by now. ### Statistics @@ -116,16 +133,18 @@ if **tkrun** is enabled, use The history (hst) keeps track of a number of variables of which we can obtain the statistics (agui/show_stats) ```text -# [1]=time [2]=dt [3]=mass [4]=1-mom [5]=2-mom [6]=3-mom [7]=1-KE [8]=2-KE [9]=3-KE [10]=tot-E [11]=max-v2 -npt: 501 501 501 501 501 501 501 501 501 501 501 -min: 0 1.31217e-05 1 -3.14329e-22 0 0 2.49497e-13 0 0 0.9 0 -max: 5 0.003125 1 3.19912e-22 0 0 2.5e-13 0 0 0.9 0 -sum: 1253.43 1.56251 501 -1.56725e-20 0 0 1.25127e-10 0 0 450.9 0 -mean: 2.50186 0.00311879 1 -3.12825e-23 0 0 2.49754e-13 0 0 0.9 0 -disp: 1.44625 0.00013889 0 8.61373e-23 0 0 1.46346e-16 0 0 0 0 -skew: -4.15046e-05 -22.316 0 0.0211432 0 0 -0.0439997 0 0 0 0 -kurt: -1.20002 496.002 0 0.579502 0 0 -1.23003 0 0 0 0 -min/sig: -1.72989 -22.3607 -nan -3.28599 -nan -nan -1.75681 -nan -nan inf -nan -max/sig: 1.72732 0.0447214 -nan 4.07715 -nan -nan 1.68025 -nan -nan inf -nan -median: 2.50312 0.003125 1 -3.21566e-23 0 0 2.49757e-13 0 0 0.9 0 +#col [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] +#name time dt mass 1-mom 2-mom 3-mom 1-KE 2-KE 3-KE tot-E max-v2 + +npt: 501 501 501 501 501 501 501 501 501 501 501 +min: 0 1.31217e-05 1 -3.14329e-22 0 0 2.49497e-13 0 0 0.9 0 +max: 5 0.003125 1 3.19912e-22 0 0 2.5e-13 0 0 0.9 0 +sum: 1253.43 1.56251 501 -1.56725e-20 0 0 1.25127e-10 0 0 450.9 0 +mean: 2.50186 0.00311879 1 -3.12825e-23 0 0 2.49754e-13 0 0 0.9 0 +disp: 1.44625 0.00013889 0 8.61373e-23 0 0 1.46346e-16 0 0 0 0 +skew: -4.15046e-05 -22.316 0 0.0211432 0 0 -0.0439997 0 0 0 0 +kurt: -1.20002 496.002 0 0.579502 0 0 -1.23003 0 0 0 0 +min: -1.72989 -22.3607 -nan -3.28599 -nan -nan -1.75681 -nan -nan inf -nan +max: 1.72732 0.0447214 -nan 4.07715 -nan -nan 1.68025 -nan -nan inf -nan +median: 2.50312 0.003125 1 -3.21566e-23 0 0 2.49757e-13 0 0 0.9 0 ```