https://github.com/devansh1106/parallel-gauss-elimination
This repository contains code for performing Gaussian elimination using two types of algorithms. For more details see README.md
https://github.com/devansh1106/parallel-gauss-elimination
gauss-elimination linear linear-algebra linear-system-solver mathematical-programming mpi parallel-computing
Last synced: about 1 year ago
JSON representation
This repository contains code for performing Gaussian elimination using two types of algorithms. For more details see README.md
- Host: GitHub
- URL: https://github.com/devansh1106/parallel-gauss-elimination
- Owner: Devansh1106
- Created: 2023-09-02T16:39:13.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2024-09-25T14:13:20.000Z (over 1 year ago)
- Last Synced: 2025-02-10T05:18:11.754Z (over 1 year ago)
- Topics: gauss-elimination, linear, linear-algebra, linear-system-solver, mathematical-programming, mpi, parallel-computing
- Language: C++
- Homepage:
- Size: 1.24 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Parallel-Gauss-Elimination #
This is code for performing Gauss elimination in two ways:
1- Using parallel algorithm such as Messsage Passing Interface (MPI).
2- Using serial algorithm.
## Structure of the input and output files ##
This code takes only square matrix as input. All files will be in .txt format.
Structure of the input files will:
- Input matrix file will contain a square matrix of size NxN where N is the order of the matrix.
- Input right hand side (rhs) file will contain a vector of size Nx1 where N is the order of the matrix.
Struture of the output file will be:
- Output file will contain a solution in form of vector of size Nx1 where N is the order of the matrix.
## Configuration of code for your own input ##
Four changes are required for changing the input and congiure the code according to your own input:
1- First change the order of the matrix to the new order that you are going to input (N).
2- Change the name of the input file to the name of the file that you are going input.
3- Change the name of the right hand side file (rhs) to the new file that you are going to input.
4- Change the name of the output file in the code to the name that you preferred.
## Command for compiling code ##
First you need to install g++ and MPICH for compiling `main_serial.cpp` and `main_block_divison.cpp` respectively. Instructions are for using from terminal.
- For compiling main_serial.cpp file
- Use `g++ main_serial.cpp`
- For running `.exe`, use `./`
- For compiling main_block_division.cpp file
- Use `mpic++ main_block_division.cpp`
- For running `.exe`, use `mpirun -np `