Skip to content

matteobarbera/heat_eq_solver

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Heat Equation Solver

This project was completed as part of a TU Delft course Object Oriented Scientific Programming with C++. The code approximates the solution to the heat equation $\dot{u} = \Delta u$ in 1D and 2D. The code made use of only Standard Library headers, and the Vector and Matrix classes necessary to find the solution to the partial differential equation were written from scratch as an exercise in C++.

Report.pdf describes in detail the choices taken for the different parts of the code, together with a descsription of the unit and verification tests performed to test individual code snippets as well the overall solution of the heat equation.

For the initial condition:

$$ u\left(\textbf{x},0\right) = \prod\limits_{k=0}^{n-1}\sin\left(\pi x_k\right)\qquad\forall \textbf{x}\in\Omega $$

The code produced the following results, which matched the known solution to this fundamental initial condition.

In 1D, for a mesh size $m = 100$:

In 2D, for a mesh size $m = 100$ (100x100):

About

Solver for the Heat Equation in 1D and 2D

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages