Skip to content

dani11torres/Project-II

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

127 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Van der Waals gas of particle

Van der Waals gas of particle is a Fortran/Python program that allow us to study the interaction of hard sppheres subjected to a Leenard-Jones potential

animated

GitHub forks GitHub issues GitHub pull requests GitHub stars GitHub repo size GitHub license GitHub language count

Fortran Python

Table of Contents
  1. Pre-requirements
  2. Usage
  3. Wiki
  4. Distribution of tasks
  5. FAQs
  6. Contributing

Pre-requirements 📋

In order to run the program it is necessary to have the following requirements installed:

The program is written in Fortran language so a compiler like gfortran or equivalent is needed.

Python programs are used to perform statistical analysis of the obtained data. Therefore, Python version 3 or higher is required. Also, for python programs to work properly the following libraries are needed:

To be able to use these libraries, it is recommended to work with anaconda environment.

In case the user wishes to see the trajectory generated in the simulation program, the use of the VMD program is recommended.

The option of a parallelisable code can be used, using the code in the parallel folder. To use it, you must have the following installed on your operating system Open MPI

Usage ⚙️

In order to run this program, the necessary files are found in the Working_area directory.

This directory contains the following files:

  • Makefile: Compiles and executes the whole program. It is also designed to manage all the generated files for a more user-friendly experience.
  • parameters.txt: Data file that contains all the parameters related to the system of study (Number of particles, geometry of the lattice (at the moment only sc available), density, mass,...), the data related to the simulation (Initial temperature, initial distribution, thermostat, integration method,...) and a final section where the names of the output data files are defined. Additionaly, this file contains the necessary parameters in order to run correctly the radial distribution function (g(r)) calculation.

To start using the program, the following command has to be used:

make all

This will compile and execute the program and all the statistic calculations will also be performed. It is important to point out that in order to perform the whole program, the user is asked a couple of questions related to the statistical study, so keep an eye on this, otherwise the program will not reach completion.

Once the process has been completed, the unnecessary files are cleaned and the output files are sent to their corresponding directories (Results -> Data and Figures).

Note: Due to the modular nature of the program, it can be executed in parts (or modules) by using the following commands:

# Compilation of the Main and Gofr programs (Fortran programming language)
make compile

# Execution of the Main and Gofr programs (Fortran programming language)
make run

# Computes the statistical analysis and generates the corresponding figures as outputs (Python programming language)
make statistic

# Move data files and figures (outputs) to  the Results folder (Please, don't do it before the statistical analysis, the files to be analyzed must be in the working folder) 
make move

# Removes objects, executables and unnecessary .mod files
make clean

# If the user wants to return the repository to its original state (remove unnecessary files and results), the following command can be used
make clean_all

The program generates an .xyz file containing the trajectory of the system. It is highly recommended the use of VMD in order to visualize the results.

Wiki 📖

...Work in progress...

Distribution of tasks ✒️

Project coordinator: Àlex Teruel

  • Main program (Fortran program): Joint work
  • Initial state (Fortran module): Oliver Loveday
  • Boundary conditions (Fortran module): Adrià Calzada
  • Forces (Fortran module): Daniel Conde
  • Integration (Fortran module): Àlex Teruel
  • Radial distribution function (Fortran program): Àlex Teruel
  • Statistics (Python program): Daniel Conde
  • Visualization of Results (Python program): Joint work
  • Makefile: Joint work

The joint work tasks will be carried out (to a greater extent) by those members who are more advanced in their corresponding tasks.

FAQs

What is that paralel file? Wasn't the program a serie algorithm?

Paralel directory is a program that uses mpi, so you have a paralelize version of the program in this file.

Contributing 🖇️

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors