Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Hello Chegg! I hope you're having a nice day. I am struggling to successfully complete an project. I am suppose to write a parallel program

Hello Chegg! I hope you're having a nice day.

I am struggling to successfully complete an project.

I am suppose to write a parallel program using openMP. The array has 100000 elements, and should produce the same sum for N threads, where N is 1, 4, and 8.

PLEASE HELP, if you can, itll be appreciated with a like!

heres the psuedo code given

sum[Pn] = 0;

for (i = 1000*Pn; i < 1000*(Pn+1); i++)

sum[Pn] = sum[Pn] + A[i];

total = 0;

for (i = 0; i < 100; i = i + 1)

total += sum[i];

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Securing SQL Server Protecting Your Database From Attackers

Authors: Denny Cherry

3rd Edition

0128012757, 978-0128012758

More Books

Students also viewed these Databases questions