Skip to content
/ nocs Public
forked from matteomonti/nocs

NOCS (Not Only Colliding Spheres) exact 2D gas dynamics framework

License

Notifications You must be signed in to change notification settings

carlidel/nocs

 
 

Repository files navigation

NOCS

(Not Only Colliding Spheres)

docs GitHub pull-requests GitHub issues

GitHub stars GitHub watchers

Exact 2D gas dynamics framework.

List of authors
Author M. Monti
Contributor C.E. Montanari
Contributor N. Curti
Build Status
Linux : travis
Windows : in development

Table of Contents

What is NOCS

NOCS is a C++ 2D event-based engine for simulating molecules composed of hard spheres of arbitrary mass and dimension.

It's meant to be used for simulating statistical mechanics scenarios in the fastest and most precise way possible, by computing analytically every collision between molecules and by integrating the motion of the molecules only when strictly necessary.

Works about NOCS

  1. C. E., Montanari (2017) Development of an event-based simulator for analysing excluded volume effects in a Brownian gas. [Bachelor thesis], Università di Bologna, Corso di Studio in Fisica (L-DM270) http://amslaurea.unibo.it/view/cds/CDS8007/
  2. A., Cerfogli (2018) Entropic forces and dynamical properties of a rigid body Boltzmann gas. [Master thesis], Università di Bologna, Corso di Studio in Fisica (LM-DM270) http://amslaurea.unibo.it/view/cds/CDS8025/
  3. A. Bazzani, S. Vitali, C. E. Montanari, M. Monti e G. Castellani. (2019) Stochastic properties of colliding particles in a non-equilibrium thermal bath. (Abstract) https://sites.google.com/view/lfo12-13aprile2019/

Compiling the project

Dependencies

In order to properly compile the project, it's necessary to have cmake and a compiler that supports adequately the C++14 standard.

If you wish to have also the graphical support within your simulation executable, you will need a valid implementation of freeglut3 and a proper OpenGL development environment. On Linux it's sufficient to have installed the freeglut3-dev package:

sudo apt install freeglut3-dev

Compiling commands

Compile everything from source

After you have written your code in src/main.cpp, you can execute the compilation and obtain the executable. To do so, follow these steps:

  1. Create a bin folder;

  2. Open a terminal in the bin folder;

  3. Execute the following command if you wish to NOT have graphical support (i.e. every graphical method called in src/main.cpp will NOT be included in the compilation):

    cmake ..

    If instead you wish to have graphical support:

    cmake .. -DGRAPHICS=on

    Also you can of course set the build type with -DCMAKE_BUILD_TYPE and either work with Debug or Release.

  4. Execute the compilation with the make command.

  5. You will now have your executable main in the bin folder.

  6. You will also find an executable for every source file available in the examples folder

Documentation

You can explore the general source code documentation by using the index page.

A general tutorial on the tools and the features of NOCS is provided here.

About

NOCS (Not Only Colliding Spheres) exact 2D gas dynamics framework

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 97.6%
  • CMake 2.4%