Giter Club home page Giter Club logo

serial-to-parallel--monte-carlo-pi's Introduction

Serial-to-Parallel--Monte-Carlo-Pi

This tutorial covers how to write a parallel program to calculate π using the Monte Carlo method with MPI and OpenMP.

####Compiling and Running Before you start, you will need to edit the submit scripts (submit.pbs and mpisubmit.pbs) and replace AAA123 with the correct project ID. Once done, you need to load the PGI programming environment

module load PrgEnv-pgi

The code can be simultaneously compiled and submitted via a Make task depending on which version you'd like to run:

  • Serial version: make serial
  • MPI_Reduce verion: make mpi
  • MPI Send/Recv verion: make mpisr
  • OpenMP version: make omp
  • Hybrid OpenMP/MPI version: make mpiomp

The output should look something like:

Wed Sep 18 11:02:27 EDT 2013
Pi: 3.140800
Application 3587838 resources: utime ~0s, stime ~0s, Rss ~3444, inblocks ~4534, outblocks ~11970

The tutorial from which this code is from can be found on the OLCF website at: https://www.olcf.ornl.gov/tutorials/monte-carlo-pi/

serial-to-parallel--monte-carlo-pi's People

Watchers

James Cloos avatar Robert D. French avatar

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.