CPS 303 High Performance Computing. Wensheng Shen Department of Computational Science SUNY Brockport

Size: px
Start display at page:

Download "CPS 303 High Performance Computing. Wensheng Shen Department of Computational Science SUNY Brockport"

Transcription

1 CPS 303 High Perormance Computing Wensheng Shen Department o Computational Science SUNY Brockport

2 Chapter 4 An application: numerical integration Use MPI to solve a problem o numerical integration with the trapezoidal rule.

3 4. The trapezoidal rule Deinite integral o a nonnegative unction

4 Trapezoids approimating deinite integral

5 The ith trapezoid [ ] i i h [ ] [ ] [ ] [ ] [ ]h h h h h n n n n n... / / = =

6 #include <stdio.h> main { loat integral; /* store result in integral */ loat a, b; /* let and right endpoints */ int n; /* Number o trapezoids */ loat h; /* trapezoid base width */ loat ; int i; loat loat ; /* unction we re integrating */ print Enter a, b, and n\n ; scan % % %d, &a, &b, &n; h = b-a/n; integral = a b/.0; = a; ori=; i<=n-; i { = h; integral = integral ; } integral = integral*h; print with n=%d trapezoids, our estimate\n, n; print o the integral rom % to % = %\n, a, b, integral; }

7 loat loat { loat return_val; /* calculate. Store calculation in return_val. */ return return_val; }

8 4. Parallelizing the trapezoidal rule In this case, data is just the interval [a, b] and the number o trapezoid. We can parallelize the trapezoidal rule program by assigning a subinterval o [a, b] to each process, and having that process estimate the integral o over the subinterval.

9 Suppose there are p processes and n trapezoids, and, in order to simpliy the discussion, we also suppose that n is divisible by p. Then it is natural or the irst process to calculate the area o the irst n/p trapezoids, the second process to calculate the area o the net n/p, etc. MPI identiies each process by a nonnegative integer. So i there are p processes, the irst is process 0, the second process,, and the last process p-.

10 Process 0 i P- Interval [a, anh/p] [anh/p, anh/p] [ainh/p, ainh/p] [ap-nh/p, b] Assignments o subintervals to processes

11 Each process needs the ollowing inormation: The number o processes, p Its rank The entire interval o integration, [a,b] The number o subintervals, n Each process sends its result to process 0, and process 0 will do the inal addition.

12 Algorithm Each process calculates its interval o integration. Each process estimates the integral o over its interval using the trapezoidal rule. Each process!= 0 sends its integral to 0. Process 0 sums the calculations received rom the individual processes and prints the result.

13 Global and local variables Global variables: variables whose contents are signiicant on all processes, such as a, b, and n in the previous code; Local variables: variables whose contents are signiicant only on individual processes, such as local_a, local_b, and local_n in the previous code Use dierent names or global and local variables.

14 4.3 I/O on parallel systems In the previous code, the input data, a, b, and n, are hardwired. I we want o change any o these, we must edit and recompile the program. We assume that process 0 can do both input and output. Let us urther assume all processes can do input and output. We add the ollowing piece o code and run it with two processes: scan % % %d, &a, &b, &n; 0 04 user types in Who gets the data? Process 0, process, or both, or process 0 gets the 0 and, but process gets 04? I several processes attempt to simultaneously write data to the terminal screen, are the data printed in order? It is out o control

15 Solution: let process 0 be the master process to do I/O Only process 0 can do I/O, and we need process 0 to send the user input to the other processes. We need to write another unction, Get_data, dealing with input and output. Other ways: modiy eisting code, collective communication, net chapter.

16 Void get_dataloat* a_ptr, loat* b_ptr, int* n_ptr, int my_rank, int p { int source=0; int dest; int tag; MPI_Status status; imy_rank == 0 { print enter a, b, and n\n ; scan % % %d, a_ptr, b_ptr, n_ptr; ordest=; dest<p; dest { tag = 0; MPI_Senda_ptr,, MPI_FLOAT, dest, tag, MPI_COMM_WORLD; tag = ; MPI_Sendb_ptr,, MPI_FLOAT, dest, tag, MPI_COMM_WORLD; tag = ; MPI_Sendn_ptr,, MPI_INT, dest, tag, MPI_COMM_WORLD; } } else { tag=0; MPI_Recva_ptr,, MPI_FLOAT, source, tag, MPI_COMM_WORLD, &status; tag = ; MPI_Recvb_ptr,, MPI_FLOAT, source, tag, MPI_COMM_WORLD, &status; tag = ; MPI_Recva_ptr,, MPI_FLOAT, source, tag, MPI_COMM_WORLD, &status; } }

17 P does not evenly divide n We have 8 trapezoids and 3 processes, how can we distribute the eight trapezoids to 3 processes? We take the loor o n/p. n/p=8/3=.6, loorn/p=. processes 0 and have trapezoids each, process 3 has 4 trapezoids. We let the irst p- processes to have loorn/p, and the pth process to have n-loorn/p*p- trapezoids. The loor o n/p n p

18 The Simpson s rule Three points integration, the number o intervals must be an even number. I the number o total panels is n, then the number o Simpson panels is n/

19 ith interval h h [ai-h, aih] i i ith interval [aih, aih] h = b a n Area=h/3 i- 4 i i

20 [ ] h d b a = [ ] n n n b a h d = In general,

21 The derivation o Simpson s rule: undetermined coeicients Using 3-point integration b a a b d α a β γ b Quadratic polynomial = c c c3

22 The relationship between Simpson s rule and the trapezoid rule A b a a b b a = B b a a b b a = 3 B A b a Midpoint rule Trapezoid rule Simpson s rule

Collective Communications I

Collective Communications I Collective Communications I Ned Nedialkov McMaster University Canada CS/SE 4F03 January 2016 Outline Introduction Broadcast Reduce c 2013 16 Ned Nedialkov 2/14 Introduction A collective communication involves

More information

Assignment 3 Key CSCI 351 PARALLEL PROGRAMMING FALL, Q1. Calculate log n, log n and log n for the following: Answer: Q2. mpi_trap_tree.

Assignment 3 Key CSCI 351 PARALLEL PROGRAMMING FALL, Q1. Calculate log n, log n and log n for the following: Answer: Q2. mpi_trap_tree. CSCI 351 PARALLEL PROGRAMMING FALL, 2015 Assignment 3 Key Q1. Calculate log n, log n and log n for the following: a. n=3 b. n=13 c. n=32 d. n=123 e. n=321 Answer: Q2. mpi_trap_tree.c The mpi_trap_time.c

More information

Outline. Introduction to HPC computing. OpenMP MPI. Introduction. Understanding communications. Collective communications. Communicators.

Outline. Introduction to HPC computing. OpenMP MPI. Introduction. Understanding communications. Collective communications. Communicators. Lecture 8 MPI Outline Introduction to HPC computing OpenMP MPI Introduction Understanding communications Collective communications Communicators Topologies Grouping Data for Communication Input / output

More information

Introduction to MPI: Part II

Introduction to MPI: Part II Introduction to MPI: Part II Pawel Pomorski, University of Waterloo, SHARCNET ppomorsk@sharcnetca November 25, 2015 Summary of Part I: To write working MPI (Message Passing Interface) parallel programs

More information

Lecture 13. Writing parallel programs with MPI Matrix Multiplication Basic Collectives Managing communicators

Lecture 13. Writing parallel programs with MPI Matrix Multiplication Basic Collectives Managing communicators Lecture 13 Writing parallel programs with MPI Matrix Multiplication Basic Collectives Managing communicators Announcements Extra lecture Friday 4p to 5.20p, room 2154 A4 posted u Cannon s matrix multiplication

More information

A User's Guide to MPI. Peter S. Pacheco. Department of Mathematics. University of San Francisco. San Francisco, CA

A User's Guide to MPI. Peter S. Pacheco. Department of Mathematics. University of San Francisco. San Francisco, CA A User's Guide to MPI Peter S. Pacheco Department of Mathematics University of San Francisco San Francisco, CA 94117 peter@usfca.edu March 26, 1995 Contents 1 Introduction 3 2 Greetings! 4 2.1 General

More information

CPS 303 High Performance Computing

CPS 303 High Performance Computing CPS 303 High Performance Computing Wensheng Shen Department of Computational Science SUNY Brockport Chapter 5: Collective communication The numerical integration problem in Chapter 4 is not very efficient.

More information

CSE 160 Lecture 15. Message Passing

CSE 160 Lecture 15. Message Passing CSE 160 Lecture 15 Message Passing Announcements 2013 Scott B. Baden / CSE 160 / Fall 2013 2 Message passing Today s lecture The Message Passing Interface - MPI A first MPI Application The Trapezoidal

More information

9.8 Graphing Rational Functions

9.8 Graphing Rational Functions 9. Graphing Rational Functions Lets begin with a deinition. Deinition: Rational Function A rational unction is a unction o the orm P where P and Q are polynomials. Q An eample o a simple rational unction

More information

Introduction to MPI: Lecture 1

Introduction to MPI: Lecture 1 Introduction to MPI: Lecture 1 Jun Ni, Ph.D. M.E. Associate Professor Department of Radiology Carver College of Medicine Information Technology Services The University of Iowa Learning MPI by Examples:

More information

CS 179: GPU Programming. Lecture 14: Inter-process Communication

CS 179: GPU Programming. Lecture 14: Inter-process Communication CS 179: GPU Programming Lecture 14: Inter-process Communication The Problem What if we want to use GPUs across a distributed system? GPU cluster, CSIRO Distributed System A collection of computers Each

More information

int MPI_Cart_shift ( MPI_Comm comm, int direction, int displ, int *source, int *dest )

int MPI_Cart_shift ( MPI_Comm comm, int direction, int displ, int *source, int *dest ) Lecture 10 int MPI_Cart_shift ( MPI_Comm comm, int direction, int displ, int *source, int *dest ) comm - communicator with Cartesian structure direction - coordinate dimension of shift, in range [0,n-1]

More information

ES 240: Scientific and Engineering Computation. a function f(x) that can be written as a finite series of power functions like

ES 240: Scientific and Engineering Computation. a function f(x) that can be written as a finite series of power functions like Polynomial Deinition a unction () that can be written as a inite series o power unctions like n is a polynomial o order n n ( ) = A polynomial is represented by coeicient vector rom highest power. p=[3-5

More information

Introduction to Parallel Programming Message Passing Interface Practical Session Part I

Introduction to Parallel Programming Message Passing Interface Practical Session Part I Introduction to Parallel Programming Message Passing Interface Practical Session Part I T. Streit, H.-J. Pflug streit@rz.rwth-aachen.de October 28, 2008 1 1. Examples We provide codes of the theoretical

More information

The Rational Zero Theorem

The Rational Zero Theorem The Rational Zero Theorem Our goal in this section is to learn how we can ind the rational zeros o the polynomials. For example: x = x 4 + x x x + ( ) We could randomly try some actors and use synthetic

More information

Distributed Memory Programming with MPI

Distributed Memory Programming with MPI Distributed Memory Programming with MPI Part 1 Bryan Mills, PhD Spring 2017 A distributed memory system A shared memory system Identifying MPI processes n Common pracace to idenafy processes by nonnegaave

More information

Rational Functions. Definition A rational function can be written in the form. where N(x) and D(x) are

Rational Functions. Definition A rational function can be written in the form. where N(x) and D(x) are Rational Functions Deinition A rational unction can be written in the orm () N() where N() and D() are D() polynomials and D() is not the zero polynomial. *To ind the domain o a rational unction we must

More information

Numerical Integration

Numerical Integration Numerical Integration Numerical Integration is the process of computing the value of a definite integral, when the values of the integrand function, are given at some tabular points. As in the case of

More information

Collective Communication

Collective Communication Lab 14 Collective Communication Lab Objective: Learn how to use collective communication to increase the efficiency of parallel programs In the lab on the Trapezoidal Rule [Lab??], we worked to increase

More information

CPS 303 High Performance Computing

CPS 303 High Performance Computing CPS 303 High Performance Computing Wensheng Shen Department of Computational Science SUNY Brockport Chapter 7: Communicators and topologies Communicators: a communicator is a collection of processes that

More information

Introduction to MPI. HY555 Parallel Systems and Grids Fall 2003

Introduction to MPI. HY555 Parallel Systems and Grids Fall 2003 Introduction to MPI HY555 Parallel Systems and Grids Fall 2003 Outline MPI layout Sending and receiving messages Collective communication Datatypes An example Compiling and running Typical layout of an

More information

CSE 590: Special Topics Course ( Supercomputing ) Lecture 6 ( Analyzing Distributed Memory Algorithms )

CSE 590: Special Topics Course ( Supercomputing ) Lecture 6 ( Analyzing Distributed Memory Algorithms ) CSE 590: Special Topics Course ( Supercomputing ) Lecture 6 ( Analyzing Distributed Memory Algorithms ) Rezaul A. Chowdhury Department of Computer Science SUNY Stony Brook Spring 2012 2D Heat Diffusion

More information

Introduction to the Message Passing Interface (MPI)

Introduction to the Message Passing Interface (MPI) Introduction to the Message Passing Interface (MPI) CPS343 Parallel and High Performance Computing Spring 2018 CPS343 (Parallel and HPC) Introduction to the Message Passing Interface (MPI) Spring 2018

More information

Chapter 3 Image Enhancement in the Spatial Domain

Chapter 3 Image Enhancement in the Spatial Domain Chapter 3 Image Enhancement in the Spatial Domain Yinghua He School o Computer Science and Technology Tianjin University Image enhancement approaches Spatial domain image plane itsel Spatial domain methods

More information

Concavity. Notice the location of the tangents to each type of curve.

Concavity. Notice the location of the tangents to each type of curve. Concavity We ve seen how knowing where a unction is increasing and decreasing gives a us a good sense o the shape o its graph We can reine that sense o shape by determining which way the unction bends

More information

MPI 3. CSCI 4850/5850 High-Performance Computing Spring 2018

MPI 3. CSCI 4850/5850 High-Performance Computing Spring 2018 MPI 3 CSCI 4850/5850 High-Performance Computing Spring 2018 Tae-Hyuk (Ted) Ahn Department of Computer Science Program of Bioinformatics and Computational Biology Saint Louis University Learning Objectives

More information

[4] 1 cycle takes 1/(3x10 9 ) seconds. One access to memory takes 50/(3x10 9 ) seconds. =16ns. Performance = 4 FLOPS / (2x50/(3x10 9 )) = 120 MFLOPS.

[4] 1 cycle takes 1/(3x10 9 ) seconds. One access to memory takes 50/(3x10 9 ) seconds. =16ns. Performance = 4 FLOPS / (2x50/(3x10 9 )) = 120 MFLOPS. Give your answers in the space provided with each question. Answers written elsewhere will not be graded. Q1). [4 points] Consider a memory system with level 1 cache of 64 KB and DRAM of 1GB with processor

More information

MPI MESSAGE PASSING INTERFACE

MPI MESSAGE PASSING INTERFACE MPI MESSAGE PASSING INTERFACE David COLIGNON, ULiège CÉCI - Consortium des Équipements de Calcul Intensif http://www.ceci-hpc.be Outline Introduction From serial source code to parallel execution MPI functions

More information

An Introduction to Parallel Programming using MPI

An Introduction to Parallel Programming using MPI Lab 13 An Introduction to Parallel Programming using MPI Lab Objective: Learn the basics of parallel computing on distributed memory machines using MPI for Python Why Parallel Computing? Over the past

More information

NUMERICAL DIFFERENTIATION

NUMERICAL DIFFERENTIATION EP08 Computational Metods in Psics Notes on Lecture Numerical Dierentiation 1 NUMERICAL DIFFERENTIATION For a unction irst and second derivatives are given as ollows: Metod First Derivative Truncation

More information

Binary recursion. Unate functions. If a cover C(f) is unate in xj, x, then f is unate in xj. x

Binary recursion. Unate functions. If a cover C(f) is unate in xj, x, then f is unate in xj. x Binary recursion Unate unctions! Theorem I a cover C() is unate in,, then is unate in.! Theorem I is unate in,, then every prime implicant o is unate in. Why are unate unctions so special?! Special Boolean

More information

Holland Computing Center Kickstart MPI Intro

Holland Computing Center Kickstart MPI Intro Holland Computing Center Kickstart 2016 MPI Intro Message Passing Interface (MPI) MPI is a specification for message passing library that is standardized by MPI Forum Multiple vendor-specific implementations:

More information

A fast and area-efficient FPGA-based architecture for high accuracy logarithm approximation

A fast and area-efficient FPGA-based architecture for high accuracy logarithm approximation A ast and area-eicient FPGA-based architecture or high accuracy logarithm approximation Dimitris Bariamis, Dimitris Maroulis, Dimitris K. Iakovidis Department o Inormatics and Telecommunications University

More information

1-2. Composition of Functions. OBJECTIVES Perform operations with functions. Find composite functions. Iterate functions using real numbers.

1-2. Composition of Functions. OBJECTIVES Perform operations with functions. Find composite functions. Iterate functions using real numbers. - OBJECTIVES Perorm operations with unctions. Find composite unctions. Iterate unctions using real numbers. Composition o Functions BUSINESS Each year, thousands o people visit Yellowstone National Park

More information

Larger K-maps. So far we have only discussed 2 and 3-variable K-maps. We can now create a 4-variable map in the

Larger K-maps. So far we have only discussed 2 and 3-variable K-maps. We can now create a 4-variable map in the EET 3 Chapter 3 7/3/2 PAGE - 23 Larger K-maps The -variable K-map So ar we have only discussed 2 and 3-variable K-maps. We can now create a -variable map in the same way that we created the 3-variable

More information

MPI MPI. Linux. Linux. Message Passing Interface. Message Passing Interface. August 14, August 14, 2007 MPICH. MPI MPI Send Recv MPI

MPI MPI. Linux. Linux. Message Passing Interface. Message Passing Interface. August 14, August 14, 2007 MPICH. MPI MPI Send Recv MPI Linux MPI Linux MPI Message Passing Interface Linux MPI Linux MPI Message Passing Interface MPI MPICH MPI Department of Science and Engineering Computing School of Mathematics School Peking University

More information

MPI. (message passing, MIMD)

MPI. (message passing, MIMD) MPI (message passing, MIMD) What is MPI? a message-passing library specification extension of C/C++ (and Fortran) message passing for distributed memory parallel programming Features of MPI Point-to-point

More information

A Proposed Approach for Solving Rough Bi-Level. Programming Problems by Genetic Algorithm

A Proposed Approach for Solving Rough Bi-Level. Programming Problems by Genetic Algorithm Int J Contemp Math Sciences, Vol 6, 0, no 0, 45 465 A Proposed Approach or Solving Rough Bi-Level Programming Problems by Genetic Algorithm M S Osman Department o Basic Science, Higher Technological Institute

More information

Non-Blocking Communications

Non-Blocking Communications Non-Blocking Communications Deadlock 1 5 2 3 4 Communicator 0 2 Completion The mode of a communication determines when its constituent operations complete. - i.e. synchronous / asynchronous The form of

More information

Lecture 16. Parallel Sorting MPI Datatypes

Lecture 16. Parallel Sorting MPI Datatypes Lecture 16 Parallel Sorting MPI Datatypes Today s lecture MPI Derived Datatypes Parallel Sorting 2 MPI Datatypes Data types MPI messages sources need not be contiguous 1-dimensional arrays The element

More information

Intermediate MPI (Message-Passing Interface) 1/11

Intermediate MPI (Message-Passing Interface) 1/11 Intermediate MPI (Message-Passing Interface) 1/11 What happens when a process sends a message? Suppose process 0 wants to send a message to process 1. Three possibilities: Process 0 can stop and wait until

More information

CSE 613: Parallel Programming. Lecture 21 ( The Message Passing Interface )

CSE 613: Parallel Programming. Lecture 21 ( The Message Passing Interface ) CSE 613: Parallel Programming Lecture 21 ( The Message Passing Interface ) Jesmin Jahan Tithi Department of Computer Science SUNY Stony Brook Fall 2013 ( Slides from Rezaul A. Chowdhury ) Principles of

More information

Intermediate MPI (Message-Passing Interface) 1/11

Intermediate MPI (Message-Passing Interface) 1/11 Intermediate MPI (Message-Passing Interface) 1/11 What happens when a process sends a message? Suppose process 0 wants to send a message to process 1. Three possibilities: Process 0 can stop and wait until

More information

Understanding Signal to Noise Ratio and Noise Spectral Density in high speed data converters

Understanding Signal to Noise Ratio and Noise Spectral Density in high speed data converters Understanding Signal to Noise Ratio and Noise Spectral Density in high speed data converters TIPL 4703 Presented by Ken Chan Prepared by Ken Chan 1 Table o Contents What is SNR Deinition o SNR Components

More information

MPI Message Passing Interface

MPI Message Passing Interface MPI Message Passing Interface Portable Parallel Programs Parallel Computing A problem is broken down into tasks, performed by separate workers or processes Processes interact by exchanging information

More information

Peter Pacheco. Chapter 3. Distributed Memory Programming with MPI. Copyright 2010, Elsevier Inc. All rights Reserved

Peter Pacheco. Chapter 3. Distributed Memory Programming with MPI. Copyright 2010, Elsevier Inc. All rights Reserved An Introduction to Parallel Programming Peter Pacheco Chapter 3 Distributed Memory Programming with MPI 1 Roadmap Writing your first MPI program. Using the common MPI functions. The Trapezoidal Rule in

More information

Message Passing Interface

Message Passing Interface MPSoC Architectures MPI Alberto Bosio, Associate Professor UM Microelectronic Departement bosio@lirmm.fr Message Passing Interface API for distributed-memory programming parallel code that runs across

More information

Piecewise polynomial interpolation

Piecewise polynomial interpolation Chapter 2 Piecewise polynomial interpolation In ection.6., and in Lab, we learned that it is not a good idea to interpolate unctions by a highorder polynomials at equally spaced points. However, it transpires

More information

Distributed Memory Programming with MPI. Copyright 2010, Elsevier Inc. All rights Reserved

Distributed Memory Programming with MPI. Copyright 2010, Elsevier Inc. All rights Reserved An Introduction to Parallel Programming Peter Pacheco Chapter 3 Distributed Memory Programming with MPI 1 Roadmap Writing your first MPI program. Using the common MPI functions. The Trapezoidal Rule in

More information

Chapter 3. Distributed Memory Programming with MPI

Chapter 3. Distributed Memory Programming with MPI An Introduction to Parallel Programming Peter Pacheco Chapter 3 Distributed Memory Programming with MPI 1 Roadmap n Writing your first MPI program. n Using the common MPI functions. n The Trapezoidal Rule

More information

Non-Blocking Communications

Non-Blocking Communications Non-Blocking Communications Reusing this material This work is licensed under a Creative Commons Attribution- NonCommercial-ShareAlike 4.0 International License. http://creativecommons.org/licenses/by-nc-sa/4.0/deed.en_us

More information

Automated Modelization of Dynamic Systems

Automated Modelization of Dynamic Systems Automated Modelization o Dynamic Systems Ivan Perl, Aleksandr Penskoi ITMO University Saint-Petersburg, Russia ivan.perl, aleksandr.penskoi@corp.imo.ru Abstract Nowadays, dierent kinds o modelling settled

More information

Rectangle Sums

Rectangle Sums Rectangle Sums --208 You can approximate the area under a curve using rectangles. To do this, divide the base interval into pieces subintervals). Then on each subinterval, build a rectangle that goes up

More information

HPC Parallel Programing Multi-node Computation with MPI - I

HPC Parallel Programing Multi-node Computation with MPI - I HPC Parallel Programing Multi-node Computation with MPI - I Parallelization and Optimization Group TATA Consultancy Services, Sahyadri Park Pune, India TCS all rights reserved April 29, 2013 Copyright

More information

15-440: Recitation 8

15-440: Recitation 8 15-440: Recitation 8 School of Computer Science Carnegie Mellon University, Qatar Fall 2013 Date: Oct 31, 2013 I- Intended Learning Outcome (ILO): The ILO of this recitation is: Apply parallel programs

More information

CS 426. Building and Running a Parallel Application

CS 426. Building and Running a Parallel Application CS 426 Building and Running a Parallel Application 1 Task/Channel Model Design Efficient Parallel Programs (or Algorithms) Mainly for distributed memory systems (e.g. Clusters) Break Parallel Computations

More information

CPS 303 High Performance Computing. Wensheng Shen Department of Computational Science SUNY Brockport

CPS 303 High Performance Computing. Wensheng Shen Department of Computational Science SUNY Brockport CPS 303 High Performance Computing Wensheng Shen Department of Computational Science SUNY Brockport Chapter 2: Architecture of Parallel Computers Hardware Software 2.1.1 Flynn s taxonomy Single-instruction

More information

Introduction to MPI. Martin Čuma Center for High Performance Computing University of Utah

Introduction to MPI. Martin Čuma Center for High Performance Computing University of Utah Introduction to MPI Martin Čuma Center for High Performance Computing University of Utah mcuma@chpc.utah.edu Overview Quick introduction (in case you slept/missed last time). MPI concepts, initialization.

More information

Background Functions (1C) Young Won Lim 12/6/17

Background Functions (1C) Young Won Lim 12/6/17 Background Functions (1C) Copright (c) 2016-2017 Young W. Lim. Permission is granted to cop, distribute and/or modi this document under the terms o the GNU Free Documentation License, Version 1.2 or an

More information

ECE 6560 Multirate Signal Processing Chapter 8

ECE 6560 Multirate Signal Processing Chapter 8 Multirate Signal Processing Chapter 8 Dr. Bradley J. Bazuin Western Michigan University College o Engineering and Applied Sciences Department o Electrical and Computer Engineering 903 W. Michigan Ave.

More information

The Message Passing Interface (MPI): Parallelism on Multiple (Possibly Heterogeneous) CPUs

The Message Passing Interface (MPI): Parallelism on Multiple (Possibly Heterogeneous) CPUs 1 The Message Passing Interface (MPI): Parallelism on Multiple (Possibly Heterogeneous) CPUs http://mpi-forum.org https://www.open-mpi.org/ Mike Bailey mjb@cs.oregonstate.edu Oregon State University mpi.pptx

More information

10. SOPC Builder Component Development Walkthrough

10. SOPC Builder Component Development Walkthrough 10. SOPC Builder Component Development Walkthrough QII54007-9.0.0 Introduction This chapter describes the parts o a custom SOPC Builder component and guides you through the process o creating an example

More information

ECE 563 Second Exam, Spring 2014

ECE 563 Second Exam, Spring 2014 ECE 563 Second Exam, Spring 2014 Don t start working on this until I say so Your exam should have 8 pages total (including this cover sheet) and 11 questions. Each questions is worth 9 points. Please let

More information

The Graph of an Equation Graph the following by using a table of values and plotting points.

The Graph of an Equation Graph the following by using a table of values and plotting points. Calculus Preparation - Section 1 Graphs and Models Success in math as well as Calculus is to use a multiple perspective -- graphical, analytical, and numerical. Thanks to Rene Descartes we can represent

More information

Lesson 1. MPI runs on distributed memory systems, shared memory systems, or hybrid systems.

Lesson 1. MPI runs on distributed memory systems, shared memory systems, or hybrid systems. The goals of this lesson are: understanding the MPI programming model managing the MPI environment handling errors point-to-point communication 1. The MPI Environment Lesson 1 MPI (Message Passing Interface)

More information

Multiple-Choice Test Spline Method Interpolation COMPLETE SOLUTION SET

Multiple-Choice Test Spline Method Interpolation COMPLETE SOLUTION SET Multiple-Choice Test Spline Method Interpolation COMPLETE SOLUTION SET 1. The ollowing n data points, ( x ), ( x ),.. ( x, ) 1, y 1, y n y n quadratic spline interpolation the x-data needs to be (A) equally

More information

CSE 160 Lecture 18. Message Passing

CSE 160 Lecture 18. Message Passing CSE 160 Lecture 18 Message Passing Question 4c % Serial Loop: for i = 1:n/3-1 x(2*i) = x(3*i); % Restructured for Parallelism (CORRECT) for i = 1:3:n/3-1 y(2*i) = y(3*i); for i = 2:3:n/3-1 y(2*i) = y(3*i);

More information

MPI (Message Passing Interface)

MPI (Message Passing Interface) MPI (Message Passing Interface) Message passing library standard developed by group of academics and industrial partners to foster more widespread use and portability. Defines routines, not implementation.

More information

Collective Communications II

Collective Communications II Collective Communications II Ned Nedialkov McMaster University Canada SE/CS 4F03 January 2014 Outline Scatter Example: parallel A b Distributing a matrix Gather Serial A b Parallel A b Allocating memory

More information

AP Calculus AB. a.) Midpoint rule with 4 subintervals b.) Trapezoid rule with 4 subintervals

AP Calculus AB. a.) Midpoint rule with 4 subintervals b.) Trapezoid rule with 4 subintervals AP Calculus AB Unit 6 Review Name: Date: Block: Section : RAM and TRAP.) Evaluate using Riemann Sums L 4, R 4 for the following on the interval 8 with four subintervals. 4.) Approimate ( )d using a.) Midpoint

More information

What is Hadoop? Hadoop is an ecosystem of tools for processing Big Data. Hadoop is an open source project.

What is Hadoop? Hadoop is an ecosystem of tools for processing Big Data. Hadoop is an open source project. Back to Hadoop 1 What is Hadoop? Hadoop is an ecosystem of tools for processing Big Data. Hadoop is an open source project. 2 A family of tools MapReduce HDFS HBase Hive Pig ZooKeeper Avro Sqoop Oozie

More information

Parallel hardware. Distributed Memory. Parallel software. COMP528 MPI Programming, I. Flynn s taxonomy:

Parallel hardware. Distributed Memory. Parallel software. COMP528 MPI Programming, I. Flynn s taxonomy: COMP528 MPI Programming, I www.csc.liv.ac.uk/~alexei/comp528 Alexei Lisitsa Dept of computer science University of Liverpool a.lisitsa@.liverpool.ac.uk Flynn s taxonomy: Parallel hardware SISD (Single

More information

Global Constraints. Combinatorial Problem Solving (CPS) Enric Rodríguez-Carbonell (based on materials by Javier Larrosa) February 22, 2019

Global Constraints. Combinatorial Problem Solving (CPS) Enric Rodríguez-Carbonell (based on materials by Javier Larrosa) February 22, 2019 Global Constraints Combinatorial Problem Solving (CPS) Enric Rodríguez-Carbonell (based on materials by Javier Larrosa) February 22, 2019 Global Constraints Global constraints are classes o constraints

More information

MPI: The Message-Passing Interface. Most of this discussion is from [1] and [2].

MPI: The Message-Passing Interface. Most of this discussion is from [1] and [2]. MPI: The Message-Passing Interface Most of this discussion is from [1] and [2]. What Is MPI? The Message-Passing Interface (MPI) is a standard for expressing distributed parallelism via message passing.

More information

Introduction in Parallel Programming - MPI Part I

Introduction in Parallel Programming - MPI Part I Introduction in Parallel Programming - MPI Part I Instructor: Michela Taufer WS2004/2005 Source of these Slides Books: Parallel Programming with MPI by Peter Pacheco (Paperback) Parallel Programming in

More information

SINGAPORE-MIT ALLIANCE GETTING STARTED ON PARALLEL PROGRAMMING USING MPI AND ESTIMATING PARALLEL PERFORMANCE METRICS

SINGAPORE-MIT ALLIANCE GETTING STARTED ON PARALLEL PROGRAMMING USING MPI AND ESTIMATING PARALLEL PERFORMANCE METRICS SINGAPORE-MIT ALLIANCE Computational Engineering CME5232: Cluster and Grid Computing Technologies for Science and Computing COMPUTATIONAL LAB NO.2 10 th July 2009 GETTING STARTED ON PARALLEL PROGRAMMING

More information

Lagrangian relaxations for multiple network alignment

Lagrangian relaxations for multiple network alignment Noname manuscript No. (will be inserted by the editor) Lagrangian relaxations or multiple network alignment Eric Malmi Sanjay Chawla Aristides Gionis Received: date / Accepted: date Abstract We propose

More information

Programming Scalable Systems with MPI. Clemens Grelck, University of Amsterdam

Programming Scalable Systems with MPI. Clemens Grelck, University of Amsterdam Clemens Grelck University of Amsterdam UvA / SurfSARA High Performance Computing and Big Data Course June 2014 Parallel Programming with Compiler Directives: OpenMP Message Passing Gentle Introduction

More information

4.2 and 4.6 filled in notes.notebook. December 08, Integration. Copyright Cengage Learning. All rights reserved.

4.2 and 4.6 filled in notes.notebook. December 08, Integration. Copyright Cengage Learning. All rights reserved. 4 Integration Copyright Cengage Learning. All rights reserved. 1 4.2 Area Copyright Cengage Learning. All rights reserved. 2 Objectives Use sigma notation to write and evaluate a sum. Understand the concept

More information

Topics. Lecture 6. Point-to-point Communication. Point-to-point Communication. Broadcast. Basic Point-to-point communication. MPI Programming (III)

Topics. Lecture 6. Point-to-point Communication. Point-to-point Communication. Broadcast. Basic Point-to-point communication. MPI Programming (III) Topics Lecture 6 MPI Programming (III) Point-to-point communication Basic point-to-point communication Non-blocking point-to-point communication Four modes of blocking communication Manager-Worker Programming

More information

Message-Passing Computing

Message-Passing Computing Chapter 2 Slide 41þþ Message-Passing Computing Slide 42þþ Basics of Message-Passing Programming using userlevel message passing libraries Two primary mechanisms needed: 1. A method of creating separate

More information

and F is an antiderivative of f

and F is an antiderivative of f THE EVALUATION OF DEFINITE INTEGRALS Prepared by Ingrid Stewart, Ph.D., College of Southern Nevada Please Send Questions Comments to ingrid.stewart@csn.edu. Thank you! We have finally reached a point,

More information

Prof. Thomas Sterling Department of Computer Science Louisiana State University February 10, 2011

Prof. Thomas Sterling Department of Computer Science Louisiana State University February 10, 2011 Prof. Thomas Sterling Department of Computer Science Louisiana State University February 10, 2011 HIGH PERFORMANCE COMPUTING: MODELS, METHODS, & MEANS MESSAGE PASSING INTERFACE MPI (PART B) Topics MPI

More information

Cluster Computing MPI. Industrial Standard Message Passing

Cluster Computing MPI. Industrial Standard Message Passing MPI Industrial Standard Message Passing MPI Features Industrial Standard Highly portable Widely available SPMD programming model Synchronous execution MPI Outer scope int MPI_Init( int *argc, char ** argv)

More information

PCAP Assignment I. 1. A. Why is there a large performance gap between many-core GPUs and generalpurpose multicore CPUs. Discuss in detail.

PCAP Assignment I. 1. A. Why is there a large performance gap between many-core GPUs and generalpurpose multicore CPUs. Discuss in detail. PCAP Assignment I 1. A. Why is there a large performance gap between many-core GPUs and generalpurpose multicore CPUs. Discuss in detail. The multicore CPUs are designed to maximize the execution speed

More information

SUPER RESOLUTION IMAGE BY EDGE-CONSTRAINED CURVE FITTING IN THE THRESHOLD DECOMPOSITION DOMAIN

SUPER RESOLUTION IMAGE BY EDGE-CONSTRAINED CURVE FITTING IN THE THRESHOLD DECOMPOSITION DOMAIN SUPER RESOLUTION IMAGE BY EDGE-CONSTRAINED CURVE FITTING IN THE THRESHOLD DECOMPOSITION DOMAIN Tsz Chun Ho and Bing Zeng Department o Electronic and Computer Engineering The Hong Kong University o Science

More information

Neighbourhood Operations

Neighbourhood Operations Neighbourhood Operations Neighbourhood operations simply operate on a larger neighbourhood o piels than point operations Origin Neighbourhoods are mostly a rectangle around a central piel Any size rectangle

More information

Section 6.1 Estimating With Finite Sums

Section 6.1 Estimating With Finite Sums Suppose that a jet takes off, becomes airborne at a velocity of 180 mph and climbs to its cruising altitude. The following table gives the velocity every hour for the first 5 hours, a time during which

More information

Parallel Programming. Using MPI (Message Passing Interface)

Parallel Programming. Using MPI (Message Passing Interface) Parallel Programming Using MPI (Message Passing Interface) Message Passing Model Simple implementation of the task/channel model Task Process Channel Message Suitable for a multicomputer Number of processes

More information

Parallel Programming in C with MPI and OpenMP

Parallel Programming in C with MPI and OpenMP Parallel Programming in C with MPI and OpenMP Michael J. Quinn Chapter 4 Message-Passing Programming Learning Objectives n Understanding how MPI programs execute n Familiarity with fundamental MPI functions

More information

Introduction to MPI. Ricardo Fonseca. https://sites.google.com/view/rafonseca2017/

Introduction to MPI. Ricardo Fonseca. https://sites.google.com/view/rafonseca2017/ Introduction to MPI Ricardo Fonseca https://sites.google.com/view/rafonseca2017/ Outline Distributed Memory Programming (MPI) Message Passing Model Initializing and terminating programs Point to point

More information

Supercomputing in Plain English

Supercomputing in Plain English Supercomputing in Plain English An Introduction to High Performance Computing Part VI: Distributed Multiprocessing Henry Neeman, Director The Desert Islands Analogy Distributed Parallelism MPI Outline

More information

Anomalies. The following issues might make the performance of a parallel program look different than it its:

Anomalies. The following issues might make the performance of a parallel program look different than it its: Anomalies The following issues might make the performance of a parallel program look different than it its: When running a program in parallel on many processors, each processor has its own cache, so the

More information

4.7 Approximate Integration

4.7 Approximate Integration 4.7 Approximate Integration Some anti-derivatives are difficult to impossible to find. For example, 1 0 e x2 dx or 1 1 1 + x3 dx We came across this situation back in calculus I when we introduced the

More information

Computationally Light Multi-Speed Atomic Memory

Computationally Light Multi-Speed Atomic Memory Computationally Light Multi-Speed Atomic Memory Antonio Fernández Anta 1, Theophanis Hadjistasi 2, and Nicolas Nicolaou 1 1 IMDEA Networks Institute Madrid, Spain antonio.ernandez@imdea.org, nicolas.nicolaou@imdea.org

More information

Parallel Programming in C with MPI and OpenMP

Parallel Programming in C with MPI and OpenMP Parallel Programming in C with MPI and OpenMP Michael J. Quinn Chapter 4 Message-Passing Programming Learning Objectives Understanding how MPI programs execute Familiarity with fundamental MPI functions

More information

A Classification System and Analysis for Aspect-Oriented Programs

A Classification System and Analysis for Aspect-Oriented Programs A Classiication System and Analysis or Aspect-Oriented Programs Martin Rinard, Alexandru Sălcianu, and Suhabe Bugrara Massachusetts Institute o Technology Cambridge, MA 02139 ABSTRACT We present a new

More information

7.8. Approximate Integration

7.8. Approximate Integration 7.8. Approimate Integration Recall that when we originally defined the definite integral of a function interval, that we did so with the limit of a Riemann sum: on an where is the number of intervals that

More information

Graphs of quadratics functions are parabolas opening up if a > 0, and down if a < 0. Examples:

Graphs of quadratics functions are parabolas opening up if a > 0, and down if a < 0. Examples: Quadratic Functions ( ) = a + b + c Graphs o quadratics unctions are parabolas opening up i a > 0, and down i a < 0. Eamples: = = + = = 0 MATH 80 Lecture B o 5 Ronald Brent 07 All rights reserved. Notes:

More information

CS4961 Parallel Programming. Lecture 18: Introduction to Message Passing 11/3/10. Final Project Purpose: Mary Hall November 2, 2010.

CS4961 Parallel Programming. Lecture 18: Introduction to Message Passing 11/3/10. Final Project Purpose: Mary Hall November 2, 2010. Parallel Programming Lecture 18: Introduction to Message Passing Mary Hall November 2, 2010 Final Project Purpose: - A chance to dig in deeper into a parallel programming model and explore concepts. -

More information