MDPPT is a command-line tool that aids the calculation of global mean physical quantities such as the mean kinetic energy or the mean strain rate tensor. The hypothesis is that the system is ergodic therefore means are carried on over both all particles and all timesteps in the system (all possible configurations).
The tool was written mainly to aid calculations in a turbulence MD system. It was designed to adhere as much as possible to UNIX principles.
The INPUT of MDPPT is a folder in which an input.dat and .pos files are found.
The input.dat has a very specific format used by the MDConstants library.
The .pos files are binary files where the format is:
- kDIM positions followed by kDIM directions OR
- kDIM positions OR (TODO)
- kDIM directions (TODO)
where kDIM is the number of dimensions the system has.
CAUTION:
before running the program make sure that in main.c kDIM has the correct value.
NOTE:
positions in .pos files are in [-L/2, L/2] (where L is the box length). During calculations they are stored in memory in the [-0.5, 0.5] interval.
The outputs are printed to stdout by design. To print them to file, simply pipe the output where desired. (TODO bash script)
NOTE
The post_processing quantities are calculated at the next possible timestep.
e.g. if the available snapshots are
t = 5000, 10000, ..., 95000, 100000;
then the quantities will be calculated at
t' = 5001, 10001, ..., 95001, 100001;
COMMENT FOR THE CODER:
This doesn't pose any physical problem but it affects the implementation.
COMMENT FOR THE PHYSICIST:
- Sampling at t or t+1 is irrelevant as long as there's consistency in the sampling.
- Generally the sampled quantities are averaged so the single fluctuation MUST not be relevant.
(read also Modularity and Extensions)
The goal is to have UNIX like processing tools for MD. As long as a simulation generates data, the data can be piped in the chosen post-processing tools. Consider tools just as matrix operators.
e.g.
v_f = S v_0; read S applied on v_0 gives v_f
where: v_0 = initial positions .pos file S = simulation processing, basically time evolution of v_0 through differential equations v_f = time evolved positions
OPERATIVE NOTE: v_0 can be either existing or generated by another tool v_f could be piped into another chain of processing like v_n = O v_f where v_n is the nth modification of v_0 and O is a general operation.
Chains will cause many unneeded I/O therefore it is very useful to use a RAMDISK to reduce wearing of SSDs and increase overall speed. Please always remember that RAMDISKS have volatile memory, so pipe the FINAL output into a reliable block.
The goal is to ultimately have a modular and reusable toolset that performs even better than the monolithic counterparts due to OS parallelisation.
- C99
also make check will require the following tools:
- cram: to run tests
- valgrind: to profile and check for memleaks
- MDPPT doesn't reproduce exactly the same turbulent directions as the simulation tool
- periodic boundary conditions and scaling calculations need to be reviewed
- make MDLoad more flexible and smaller
- make faster with sine/cosine lookup table
iteration_num
N[kDIM]; particle in each direction
L[kDIM]; length of the box in each direction
dcut; cutoff range for geometric interactions
starting_branch; restart options;
v_0; constant step of each particle
gamma_tilde; relaxation contant in geometric interactions
delta_t; length of a timestep
kappa NF; turbulent field intensity modes used to compute it
t_gap deltaS calculate mean physical quantities every t_gap timesteps then print them to disk every deltaS timesteps