An open API service indexing awesome lists of open source software.

https://github.com/victorvianna/particles-simulation

(Old college project) Multi-threaded simulation of n particles in space submitted to gravitational and electric forces.
https://github.com/victorvianna/particles-simulation

multithreading simulation

Last synced: 10 months ago
JSON representation

(Old college project) Multi-threaded simulation of n particles in space submitted to gravitational and electric forces.

Awesome Lists containing this project

README

          

# N-particles-simulation
Multithreaded simulation of n particles in space. Gravitational and electric forces are implemented, but application may be easily scaled to consider other forces.

![GUI](https://raw.githubusercontent.com/victorvianna/N-particles-simulation/master/screenshots/gui-screenshot.png)

## Authors

Cauim de Souza Lima
Victor Hugo Vianna

## Requirements

Java 1.8

## Instructions

Open a shell and run
```
$ ./RUN.sh
```
You can either enter the particle data through the shell or pre-record it in a file input.txt. (If such a file exists, input will be read there!) Neutral particles are displayed in red, positive ones in blue and negative ones in green.

## Main algorithmic ideas

Use of an Executor who consumes tasks of type PositionUpdate and VelocityUpdate from a task queue