SlideShare une entreprise Scribd logo
1  sur  1
Télécharger pour lire hors ligne
Part 1: Matrix Multiplication with OpenMP (30 points) Write a program that calculates the product
of two matrices, using a parallel for loop. Note that this requires writing a triply-nested for loop, and
making one of the for loops parallel. Part 2a: Finding Pythagorean Triples with OpenMP (15
points) Write a program that calculates Pythagorean triples using nested for loops. The
Pythagorean Theorem states the following: a2+b2=c2 Where a,b, and c are whole numbers. Part
2b: Modifying the Pythagorean Theorem (5 points) Modify the Pythagorean Theorem by either
adding or subtracting a times b on the left-hand-side, and run the program again. Are there integer
solutions for this? a2+b2+ab=c2

Contenu connexe

Plus de agarshail

Pequired information The kolowing information applies ro th.pdf
Pequired information The kolowing information applies ro th.pdfPequired information The kolowing information applies ro th.pdf
Pequired information The kolowing information applies ro th.pdfagarshail
 
Perca Rana y Cerdo 1 Por qu estos organismos requieren.pdf
Perca Rana y Cerdo  1 Por qu estos organismos requieren.pdfPerca Rana y Cerdo  1 Por qu estos organismos requieren.pdf
Perca Rana y Cerdo 1 Por qu estos organismos requieren.pdfagarshail
 
Perceptions of gender are affected by all of these attribute.pdf
Perceptions of gender are affected by all of these attribute.pdfPerceptions of gender are affected by all of these attribute.pdf
Perceptions of gender are affected by all of these attribute.pdfagarshail
 
Pedro Gonzales un hispano de 37 aos llega en ambulancia d.pdf
Pedro Gonzales un hispano de 37 aos llega en ambulancia d.pdfPedro Gonzales un hispano de 37 aos llega en ambulancia d.pdf
Pedro Gonzales un hispano de 37 aos llega en ambulancia d.pdfagarshail
 
Penny Inc uses process costing All direct materials are ad.pdf
Penny Inc uses process costing All direct materials are ad.pdfPenny Inc uses process costing All direct materials are ad.pdf
Penny Inc uses process costing All direct materials are ad.pdfagarshail
 
Part C Short Essay Questions 13 points Answer in the spa.pdf
Part C Short Essay Questions  13 points Answer in the spa.pdfPart C Short Essay Questions  13 points Answer in the spa.pdf
Part C Short Essay Questions 13 points Answer in the spa.pdfagarshail
 
Pazarlama yntemleri asndan tketicilere pazarlamay B2C .pdf
Pazarlama yntemleri asndan tketicilere pazarlamay B2C  .pdfPazarlama yntemleri asndan tketicilere pazarlamay B2C  .pdf
Pazarlama yntemleri asndan tketicilere pazarlamay B2C .pdfagarshail
 
Paula tiene 25 aos es soltera y gana 40000 al ao Paula.pdf
Paula tiene 25 aos es soltera y gana 40000 al ao Paula.pdfPaula tiene 25 aos es soltera y gana 40000 al ao Paula.pdf
Paula tiene 25 aos es soltera y gana 40000 al ao Paula.pdfagarshail
 
Paydirt Limestone Incorporated was organized several years .pdf
Paydirt Limestone Incorporated was organized several years .pdfPaydirt Limestone Incorporated was organized several years .pdf
Paydirt Limestone Incorporated was organized several years .pdfagarshail
 
Pauline won a Financial Analyst competition and had the foll.pdf
Pauline won a Financial Analyst competition and had the foll.pdfPauline won a Financial Analyst competition and had the foll.pdf
Pauline won a Financial Analyst competition and had the foll.pdfagarshail
 
Paula is a shareholder and director of Aloha Pty Ltd a pr.pdf
Paula is a shareholder and director of Aloha Pty Ltd a pr.pdfPaula is a shareholder and director of Aloha Pty Ltd a pr.pdf
Paula is a shareholder and director of Aloha Pty Ltd a pr.pdfagarshail
 
Paula and Prudence both have a BMI Body Mass Index of 24 .pdf
Paula and Prudence both have a BMI Body Mass Index of 24 .pdfPaula and Prudence both have a BMI Body Mass Index of 24 .pdf
Paula and Prudence both have a BMI Body Mass Index of 24 .pdfagarshail
 
Patient is a 25yearold male without medical history brough.pdf
Patient is a 25yearold male without medical history brough.pdfPatient is a 25yearold male without medical history brough.pdf
Patient is a 25yearold male without medical history brough.pdfagarshail
 
Patient Age Gender Date of Report History Copy and past.pdf
Patient Age  Gender Date of Report History Copy and past.pdfPatient Age  Gender Date of Report History Copy and past.pdf
Patient Age Gender Date of Report History Copy and past.pdfagarshail
 
paso 1 lee el texto a continuacin Nubes y niebla como fue.pdf
paso 1 lee el texto a continuacin  Nubes y niebla como fue.pdfpaso 1 lee el texto a continuacin  Nubes y niebla como fue.pdf
paso 1 lee el texto a continuacin Nubes y niebla como fue.pdfagarshail
 
Part Five Remember where commas are used as discussed in c.pdf
Part Five Remember where commas are used as discussed in c.pdfPart Five Remember where commas are used as discussed in c.pdf
Part Five Remember where commas are used as discussed in c.pdfagarshail
 
Participants are asked to respond to a single item assessing.pdf
Participants are asked to respond to a single item assessing.pdfParticipants are asked to respond to a single item assessing.pdf
Participants are asked to respond to a single item assessing.pdfagarshail
 
Passive vs Active Portfolio Management Susans current port.pdf
Passive vs Active Portfolio Management Susans current port.pdfPassive vs Active Portfolio Management Susans current port.pdf
Passive vs Active Portfolio Management Susans current port.pdfagarshail
 
pathogens are organisms that are not normally pathogenic but.pdf
pathogens are organisms that are not normally pathogenic but.pdfpathogens are organisms that are not normally pathogenic but.pdf
pathogens are organisms that are not normally pathogenic but.pdfagarshail
 
Parte I el problema Matt y Flora son estudiantes universita.pdf
Parte I el problema Matt y Flora son estudiantes universita.pdfParte I el problema Matt y Flora son estudiantes universita.pdf
Parte I el problema Matt y Flora son estudiantes universita.pdfagarshail
 

Plus de agarshail (20)

Pequired information The kolowing information applies ro th.pdf
Pequired information The kolowing information applies ro th.pdfPequired information The kolowing information applies ro th.pdf
Pequired information The kolowing information applies ro th.pdf
 
Perca Rana y Cerdo 1 Por qu estos organismos requieren.pdf
Perca Rana y Cerdo  1 Por qu estos organismos requieren.pdfPerca Rana y Cerdo  1 Por qu estos organismos requieren.pdf
Perca Rana y Cerdo 1 Por qu estos organismos requieren.pdf
 
Perceptions of gender are affected by all of these attribute.pdf
Perceptions of gender are affected by all of these attribute.pdfPerceptions of gender are affected by all of these attribute.pdf
Perceptions of gender are affected by all of these attribute.pdf
 
Pedro Gonzales un hispano de 37 aos llega en ambulancia d.pdf
Pedro Gonzales un hispano de 37 aos llega en ambulancia d.pdfPedro Gonzales un hispano de 37 aos llega en ambulancia d.pdf
Pedro Gonzales un hispano de 37 aos llega en ambulancia d.pdf
 
Penny Inc uses process costing All direct materials are ad.pdf
Penny Inc uses process costing All direct materials are ad.pdfPenny Inc uses process costing All direct materials are ad.pdf
Penny Inc uses process costing All direct materials are ad.pdf
 
Part C Short Essay Questions 13 points Answer in the spa.pdf
Part C Short Essay Questions  13 points Answer in the spa.pdfPart C Short Essay Questions  13 points Answer in the spa.pdf
Part C Short Essay Questions 13 points Answer in the spa.pdf
 
Pazarlama yntemleri asndan tketicilere pazarlamay B2C .pdf
Pazarlama yntemleri asndan tketicilere pazarlamay B2C  .pdfPazarlama yntemleri asndan tketicilere pazarlamay B2C  .pdf
Pazarlama yntemleri asndan tketicilere pazarlamay B2C .pdf
 
Paula tiene 25 aos es soltera y gana 40000 al ao Paula.pdf
Paula tiene 25 aos es soltera y gana 40000 al ao Paula.pdfPaula tiene 25 aos es soltera y gana 40000 al ao Paula.pdf
Paula tiene 25 aos es soltera y gana 40000 al ao Paula.pdf
 
Paydirt Limestone Incorporated was organized several years .pdf
Paydirt Limestone Incorporated was organized several years .pdfPaydirt Limestone Incorporated was organized several years .pdf
Paydirt Limestone Incorporated was organized several years .pdf
 
Pauline won a Financial Analyst competition and had the foll.pdf
Pauline won a Financial Analyst competition and had the foll.pdfPauline won a Financial Analyst competition and had the foll.pdf
Pauline won a Financial Analyst competition and had the foll.pdf
 
Paula is a shareholder and director of Aloha Pty Ltd a pr.pdf
Paula is a shareholder and director of Aloha Pty Ltd a pr.pdfPaula is a shareholder and director of Aloha Pty Ltd a pr.pdf
Paula is a shareholder and director of Aloha Pty Ltd a pr.pdf
 
Paula and Prudence both have a BMI Body Mass Index of 24 .pdf
Paula and Prudence both have a BMI Body Mass Index of 24 .pdfPaula and Prudence both have a BMI Body Mass Index of 24 .pdf
Paula and Prudence both have a BMI Body Mass Index of 24 .pdf
 
Patient is a 25yearold male without medical history brough.pdf
Patient is a 25yearold male without medical history brough.pdfPatient is a 25yearold male without medical history brough.pdf
Patient is a 25yearold male without medical history brough.pdf
 
Patient Age Gender Date of Report History Copy and past.pdf
Patient Age  Gender Date of Report History Copy and past.pdfPatient Age  Gender Date of Report History Copy and past.pdf
Patient Age Gender Date of Report History Copy and past.pdf
 
paso 1 lee el texto a continuacin Nubes y niebla como fue.pdf
paso 1 lee el texto a continuacin  Nubes y niebla como fue.pdfpaso 1 lee el texto a continuacin  Nubes y niebla como fue.pdf
paso 1 lee el texto a continuacin Nubes y niebla como fue.pdf
 
Part Five Remember where commas are used as discussed in c.pdf
Part Five Remember where commas are used as discussed in c.pdfPart Five Remember where commas are used as discussed in c.pdf
Part Five Remember where commas are used as discussed in c.pdf
 
Participants are asked to respond to a single item assessing.pdf
Participants are asked to respond to a single item assessing.pdfParticipants are asked to respond to a single item assessing.pdf
Participants are asked to respond to a single item assessing.pdf
 
Passive vs Active Portfolio Management Susans current port.pdf
Passive vs Active Portfolio Management Susans current port.pdfPassive vs Active Portfolio Management Susans current port.pdf
Passive vs Active Portfolio Management Susans current port.pdf
 
pathogens are organisms that are not normally pathogenic but.pdf
pathogens are organisms that are not normally pathogenic but.pdfpathogens are organisms that are not normally pathogenic but.pdf
pathogens are organisms that are not normally pathogenic but.pdf
 
Parte I el problema Matt y Flora son estudiantes universita.pdf
Parte I el problema Matt y Flora son estudiantes universita.pdfParte I el problema Matt y Flora son estudiantes universita.pdf
Parte I el problema Matt y Flora son estudiantes universita.pdf
 

Dernier

Integumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptIntegumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptshraddhaparab530
 
Dust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSEDust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSEaurabinda banchhor
 
Activity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translationActivity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translationRosabel UA
 
Measures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataMeasures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataBabyAnnMotar
 
Transaction Management in Database Management System
Transaction Management in Database Management SystemTransaction Management in Database Management System
Transaction Management in Database Management SystemChristalin Nelson
 
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfVirtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfErwinPantujan2
 
Choosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for ParentsChoosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for Parentsnavabharathschool99
 
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptxINTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptxHumphrey A Beña
 
ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4MiaBumagat1
 
ClimART Action | eTwinning Project
ClimART Action    |    eTwinning ProjectClimART Action    |    eTwinning Project
ClimART Action | eTwinning Projectjordimapav
 
Concurrency Control in Database Management system
Concurrency Control in Database Management systemConcurrency Control in Database Management system
Concurrency Control in Database Management systemChristalin Nelson
 
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptxQ4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptxlancelewisportillo
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptxmary850239
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxAnupkumar Sharma
 
TEACHER REFLECTION FORM (NEW SET........).docx
TEACHER REFLECTION FORM (NEW SET........).docxTEACHER REFLECTION FORM (NEW SET........).docx
TEACHER REFLECTION FORM (NEW SET........).docxruthvilladarez
 
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...JojoEDelaCruz
 
ROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxVanesaIglesias10
 
Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4JOYLYNSAMANIEGO
 
4.16.24 Poverty and Precarity--Desmond.pptx
4.16.24 Poverty and Precarity--Desmond.pptx4.16.24 Poverty and Precarity--Desmond.pptx
4.16.24 Poverty and Precarity--Desmond.pptxmary850239
 

Dernier (20)

Integumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptIntegumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.ppt
 
Dust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSEDust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSE
 
Activity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translationActivity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translation
 
Measures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataMeasures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped data
 
Transaction Management in Database Management System
Transaction Management in Database Management SystemTransaction Management in Database Management System
Transaction Management in Database Management System
 
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfVirtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
 
Choosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for ParentsChoosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for Parents
 
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptxINTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
 
ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4
 
ClimART Action | eTwinning Project
ClimART Action    |    eTwinning ProjectClimART Action    |    eTwinning Project
ClimART Action | eTwinning Project
 
Concurrency Control in Database Management system
Concurrency Control in Database Management systemConcurrency Control in Database Management system
Concurrency Control in Database Management system
 
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptxQ4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
 
TEACHER REFLECTION FORM (NEW SET........).docx
TEACHER REFLECTION FORM (NEW SET........).docxTEACHER REFLECTION FORM (NEW SET........).docx
TEACHER REFLECTION FORM (NEW SET........).docx
 
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
 
ROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptx
 
Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4
 
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptxFINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
 
4.16.24 Poverty and Precarity--Desmond.pptx
4.16.24 Poverty and Precarity--Desmond.pptx4.16.24 Poverty and Precarity--Desmond.pptx
4.16.24 Poverty and Precarity--Desmond.pptx
 

Part 1 Matrix Multiplication with OpenMP 30 points Write .pdf

  • 1. Part 1: Matrix Multiplication with OpenMP (30 points) Write a program that calculates the product of two matrices, using a parallel for loop. Note that this requires writing a triply-nested for loop, and making one of the for loops parallel. Part 2a: Finding Pythagorean Triples with OpenMP (15 points) Write a program that calculates Pythagorean triples using nested for loops. The Pythagorean Theorem states the following: a2+b2=c2 Where a,b, and c are whole numbers. Part 2b: Modifying the Pythagorean Theorem (5 points) Modify the Pythagorean Theorem by either adding or subtracting a times b on the left-hand-side, and run the program again. Are there integer solutions for this? a2+b2+ab=c2