Git Product home page Git Product logo

fibonaccisphere's Introduction

FibonacciSphere

My project for High Performance Computing at Northeastern University

In this project, I wrote an algorithm to calculate the nearest point on a Fibonacci Lattice Sphere. I then explored various methods of parallelizing it using OpenMP, MPI, and OpenACC. Using maps and some trigonometric calculations I wrote an elegant algorithm and achieved constant runtime regardless of the number of points on the lattice (excluding setup costs). I then explored divide and conquer techniques along with other structural algorithm modifications to parallelize batch processing of randomly generated points with the goal of minimum runtime.

Fibonacci Lattice Sphere

Sequential

Compiled with g++ on the Discovery Cluster

g++ fibonacciSphere.c -o bin/fibonacciSphere

If compiling with debug flag only hard coded parameters will be used (bins, points, seed)

Command line arguments:

arg[1]: number of bins to generate
arg[2]: number of points to generate
arg[3]: seed (optional)

OpenMP

Compiled with g++ on the Discovery Cluster

g++ -openmp fibonacciSphereOpenMP.c -o bin/fibonacciSphereOpenMP

Command line arguments:

arg[1]: number of bins to generate
arg[2]: number of points to generate
arg[3]: number of threads
arg[4]: seed (optional)

MPI

Compiled with mpiCC on the Discovery Cluster

mpiCC -o bin/fibonacciSphereMPI fibonacciSphereMPI.c

Command line arguments:

arg[1]: number of bins to generate
arg[2]: number of points to generate
arg[3]: seed (optional)

OpenNP and MPI

Compiled with mpiCC on the Discovery Cluster

mpiCC -openmp fibonacciSphereOpenMPandMPI.c -o bin/fibonacciSphereOpenMPandMPI

Command line arguments:

arg[1]: number of bins to generate
arg[2]: number of points to generate
arg[3]: number of threads
arg[4]: seed (optional)

OpenACC

Compiled with gcc on the Discovery Cluster

gcc -lm fibonacciSphereOpenACC.cpp -O3 -o bin/fibonacciSphereOpenACC

Command line arguments:

arg[1]: number of bins to generate
arg[2]: number of points to generate
arg[3]: seed (optional)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.