Skip to content

This project aims to apply matrix multiplication in-parallel using OpenMP API with C language

Notifications You must be signed in to change notification settings

Faisal-AlDhuwayhi/Parallel-Matrix-Multiplication

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Parallel Matrix Multiplication

The project discusses the ability to utilize parallel processing to solve the problem of matrix multiplication, especially multiplying two matrices of the squared size of MxM of randomly generated numbers. With the employment of OpenMP API of C language.

Project Experiment

In this project, you need to write a parallel program using OpenMP that calculates the multiplication of 2 matrices A and B of size MxM.

Run the code using p= 1,2,3,4 processors (threads) and with M=100, 200, 500, 1000, 2000 sizes. Print the results in a table. You need to run each case multiple times to take a representative average. When measuring the time make sure that the machine has only the parallel program running to reduce variations in run time measurement. Also, find the speedup and efficiency for each run and list it down in a table.

Before starting, test your program on a small matrix (M=3) to make sure the multiplication is correct before running for a large size matrix to measure the time.

Finally, write a report that summarizes your experiment, also observations, and conclusions.

You can find The Team Report and The Individual Report -contains other observations besides the team report- of the project in the repository.

Requirements

Run

In a terminal or command window, navigate to the top-level project directory Parallel-Matrix-Multiplication/ (that contains this README) and run the following command:

gcc -o Matrix_multi -fopenmp Matrix_multi.c

Then run the following command:

Matrix_multi

OpenMP Resources