An open API service indexing awesome lists of open source software.

https://github.com/ahmadrafidev/learn-cuda

A place where I learn about CUDA
https://github.com/ahmadrafidev/learn-cuda

cuda cuda-programming gpu os parallel-programming

Last synced: about 1 year ago
JSON representation

A place where I learn about CUDA

Awesome Lists containing this project

README

          

# Parallel Programming Source Code

A place where I learn about CUDA 🐎

## Introduction

This repository contains implementations of Parallel Jacobi Iteration and Gauss-Seidel Iteration using CUDA. These methods are used to solve systems of linear equations and are optimized to run on NVIDIA GPUs.

## Prerequisites

To compile and run these programs, you need:

- An NVIDIA GPU with CUDA support
- CUDA Toolkit installed
- A C++ compiler (e.g., `g++` or `nvcc`)

## Compilation

### Jacobi Iteration

To compile the Jacobi Iteration program, use the following command:

```bash
nvcc -o jacobi jacobi.cu
```

### Gauss-Seidel Iteration

To compile the Gauss-Seidel Iteration program, use the following command:

```bash
nvcc -o gauss_seidel gauss_seidel.cu
```

## Running the Programs

### Jacobi Iteration

To run the Jacobi Iteration program, use the following command:

```bash
./jacobi
```

Replace with the size of the matrix you want to use. For example, to run with a 32x32 matrix:

```bash
./jacobi 32
```

### Gauss-Seidel Iteration

To run the Gauss-Seidel Iteration program, use the following command:

```bash
./gauss_seidel
```

Replace with the size of the matrix you want to use. For example, to run with a 64x64 matrix:

```bash
./gauss_seidel 64
```

## Example Output
![Gauss Seidel 16]()
![Gauss Seidel 32]()
![Gauss Seidel 64]()