New User Special Price Expires in

Let's log you in.

Sign in with Facebook


Don't have a StudySoup account? Create one here!


Create a StudySoup account

Be part of our community, it's free to join!

Sign up with Facebook


Create your account
By creating an account you agree to StudySoup's terms and conditions and privacy policy

Already have a StudySoup account? Login here

Parallel Programming

by: Betty Kertzmann

Parallel Programming CS 475

Betty Kertzmann
GPA 3.51


Almost Ready


These notes were just uploaded, and will be ready to view shortly.

Purchase these notes here, or revisit this page.

Either way, we'll remind you when they're ready :)

Preview These Notes for FREE

Get a free preview of these Notes, just enter your email below.

Unlock Preview
Unlock Preview

Preview these materials now for free

Why put in your email? Get access to more of this material and other relevant free materials for your school

View Preview

About this Document

Class Notes
25 ?




Popular in Course

Popular in ComputerScienence

This 21 page Class Notes was uploaded by Betty Kertzmann on Tuesday September 22, 2015. The Class Notes belongs to CS 475 at Colorado State University taught by Staff in Fall. Since its upload, it has received 4 views. For similar materials see /class/210189/cs-475-colorado-state-university in ComputerScienence at Colorado State University.


Reviews for Parallel Programming


Report this Material


What is Karma?


Karma is the currency of StudySoup.

You can buy or earn more Karma at anytime and redeem it for class notes, study guides, flashcards, and more!

Date Created: 09/22/15
The First pleasantly Parallel Program Kaustubh Gadkari CS 475 FA08 The Problem For what combination of inputs is the output 1 a Dikj i it w it i Li 2 it L The Solution Circuit satisfiability is NPcomplete No known polynomial time algorithm to solve general instances of the problem Try every input combination 16 inputs gt 216 65536 input combinations Partitioning Where is the parallelism In this problem the parallelism is natural One task gt one set of inputs All tasks are independent Therefore all tasks can be performed in parallel Partitioning contd Pleasantly parallel No channels between tasks I 35 E t Output ti J39 J Agglomeration and Mapping Properties of algorithm Fixed number of tasks No communication between tasks Time needed to complete each task is variable Consult decision tree fig 37 of text Map tasks to processors in a cyclic manner Cyclic Mapping Assume p processes Each process gets every pihpiece of work For n pieces of work 01 n 1 to be assigned to p processes Op p 1 the k piece of work is assigned to process k modulo p Cyclic Mapping contd For example n 20 and p 6 POO61218 P1171319 P228 14 P3 3 9 15 P44 1016 P55 11 17 Summary of Program Design Program will consider all 65536 input combinations Allocate combinations in a cyclic fashion to processes Each process individually checks its combinations If the circuit is satisfied the process prints the combination Tasks Login to bassinerscgov Try running the first pleasantly parallel program CS 475 Lab Introduction GNUPIot Doug Hains August 26 2009 CS 475 Lab General Information gt Instructor Doug Hains gt Office Room 435 lst cubicle on left gt Office Hours In CS Lab TBA gt Email dhains cscolostateedu gt Lab Times gt Wed 10001140 COMSC 225 CS 475 Lab Topics gt Useful tools gt Gnuplot LATEX etc gt NERSC machines gt Logging in running jobs etc gt Homework assignments E39nri 39stafit el39quotquotg QpenMP CS 475 Lab Grading Attending lab is required and will be part of your grade gt Most labs will end in an in Iab exercise gt You will get a passfail for completing each exercise gt Exercises do no have to be perfect but you must attend lab and put in an effort GNUPIot gt GNUPlot is a commanddriven interactive function plotting program gt Documentation gt http wwwgnuplotinfo gt man gnuplot gt help from within gnuplot s interactive shell Running GNUPlot gt To run GNUPlot on the lab machines 4 A 39 Q w 3 quot Am 4linr us lt r gt gnuplot gt You will be presented the GNUPlot shell prompt gt gnuplotgt 392 1 At this point you are ready to 1 22 issue commands to plot interactively Plotting a function Once you are at the shell prompt the plot function creates a 2D plot gt to plot the sine function with values in the range 757 5 gt plot 525 sinx gt To plot more than one function on the same graph using the same X values separate functions by a comma or use replot gt plot 55 sinx cosx gt or gt plot 525 sinx gt replot cosx gt All the built in functions can be found at httpwwwgnuplotinfodocsnode53html Reading data from a file plot datafile using xzy b b b V Enclose filename in single quotes Data should be separated by whitespace For example to plot the data from a file called knapsack18nodes dat gt plot knapsack18nodesdat If your data file has multiple columns and for example you want to use column 1 as the X value and 4 as the y value gt plot knapsack18nodesdat using 14 If you prefer to connect your data points with lines gt plot knapsack18nodesdat using 14 with lines To apply functions to the data use 1 to reference column 1 2 to reference column 2 etc gt plot knapsack18nodesdat using 11og2 Saving your plots to a file gt We will save our results to postscript for use with IATEX gt The commands to do must be issued before the plot commands for example gt set terminal postscript gt set output quotsinepsquot gt plot 55 sinx gt Will save the output of plot 5z5 sinx to the postscript file sineps Scripting with GNUPlot gt Once you have your plot commands working in the interactive shell you can save time by writing a script gt This automates graph generation gt For example to plot the knapsack data create a file knapsackgp with the following lines gt set terminal postscript gt set output quotknapsacktimingspsquot gt plot knapsack18nodesdat using 11og2 gt You can now execute these commands by entering gnuplot knapsackgp at the Linux shell assuming your data file is in the same directory ln Lab Exercise gt Copy the tile quotcs475providedlabsexercisedat gt Plot and examine the data gt Manipulate the data to get as close to a straight line as possible gt Interpret the results gt When you think you have the correct answer call me over and show me what you have


Buy Material

Are you sure you want to buy this material for

25 Karma

Buy Material

BOOM! Enjoy Your Free Notes!

We've added these Notes to your profile, click here to view them now.


You're already Subscribed!

Looks like you've already subscribed to StudySoup, you won't need to purchase another subscription to get this material. To access this material simply click 'View Full Document'

Why people love StudySoup

Steve Martinelli UC Los Angeles

"There's no way I would have passed my Organic Chemistry class this semester without the notes and study guides I got from StudySoup."

Kyle Maynard Purdue

"When you're taking detailed notes and trying to help everyone else out in the class, it really helps you learn and understand the I made $280 on my first study guide!"

Jim McGreen Ohio University

"Knowing I can count on the Elite Notetaker in my class allows me to focus on what the professor is saying instead of just scribbling notes the whole time and falling behind."

Parker Thompson 500 Startups

"It's a great way for students to improve their educational experience and it seemed like a product that everybody wants, so all the people participating are winning."

Become an Elite Notetaker and start selling your notes online!

Refund Policy


All subscriptions to StudySoup are paid in full at the time of subscribing. To change your credit card information or to cancel your subscription, go to "Edit Settings". All credit card information will be available there. If you should decide to cancel your subscription, it will continue to be valid until the next payment period, as all payments for the current period were made in advance. For special circumstances, please email


StudySoup has more than 1 million course-specific study resources to help students study smarter. If you’re having trouble finding what you’re looking for, our customer support team can help you find what you need! Feel free to contact them here:

Recurring Subscriptions: If you have canceled your recurring subscription on the day of renewal and have not downloaded any documents, you may request a refund by submitting an email to

Satisfaction Guarantee: If you’re not satisfied with your subscription, you can contact us for further help. Contact must be made within 3 business days of your subscription purchase and your refund request will be subject for review.

Please Note: Refunds can never be provided more than 30 days after the initial purchase date regardless of your activity on the site.