diff --git a/.gitignore b/.gitignore index 600d2d3..7e4833b 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,6 @@ -.vscode \ No newline at end of file +.vscode +.idea + +build +bin +output \ No newline at end of file diff --git a/README b/README index 0fd5bf1..930e352 100755 --- a/README +++ b/README @@ -31,9 +31,18 @@ running on a cluster you should You can then start the simulation using -$ mpiexec -n 4 bin/karl --parameter_file=simulation_config/test_parameter.json +$ mpiexec -n 4 bin/karl --parameter_file simulation_config/test_parameter.json You can of course specify some other number of MPI threads or use a different JSON file. If you have to use some non-standard method to start MPI programs (such as poe) instead of mpiexec you might need to check the relevant documentation. + +ANALYSIS OF THE SIMULATION OUTPUT: +Python scripts are provided to analyze the output of the simulation. They can be +found in the folder "analysis". The script require the python packages +numpy, matplotlib, scipy and h5py. + +An example of how to use the analysis scripts is provided in the file "analysis/plot_example.py". + + diff --git a/analysis/plot_example.py b/analysis/plot_example.py new file mode 100644 index 0000000..73f9db6 --- /dev/null +++ b/analysis/plot_example.py @@ -0,0 +1,10 @@ +import plot_densities as pd + +if __name__ == '__main__': + filename_simulation_output = input("Enter filename of simulation output: ") + output_folder = input("Enter output folder: ") + + species = pd.getSpecies(filename_simulation_output) + + pd.plotAllDensityVsZ(filename_simulation_output, "LastSyncPeriod", species, output_folder) + pd.plotAllSpectrumAtZ(filename_simulation_output, 8, "LastSyncPeriod", species, output_folder) diff --git a/include/simulation/vector_field.h b/include/simulation/vector_field.h index e0834ad..0c550f1 100755 --- a/include/simulation/vector_field.h +++ b/include/simulation/vector_field.h @@ -23,7 +23,6 @@ class VectorFieldFromArray : public VectorField { CylinderVector value(const Coordinate& coordinate) const; private: - // todo: make sure we use fast axis on z to reduce acess time const blitz::Array Fr_; const blitz::Array Fphi_; const blitz::Array Fz_;