Skip to content

daudich/RBOpenMP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 

Repository files navigation

OpenMP RedBlue Simulation


Parallel version requires a compiler with OpenMP support.

What is the RedBlue simulation?

A host of red and blue cells inhabit a board. Every turn, the red cells move one cell to the right if that cell is not occupied. On the next turn, the blue cells move a cell down, if they can. Once they reach the edge of the board they wrap around to the beginning of the board. This continues until one block(user-defined) contains a certain density of red cells or until all the iterations(user-defined) are exhausted.

Furethermore, cells of the same colour move simultaneously, so for example if a row looked like:

RR__R

Then after one move will appear:

R_R_R

Only the middle cell has moved.

The board is initialised randomly.

How to Run

  • To build: make

  • To clean: make clean

Timing relies on OpenMP timing libraries. If compiled without OpenMP, time will always display -1 second.

About

A Red Blue Game of Life porblem, solved using OpenMP

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published