jgabriel6157 / DG

1D DG code for advection
0 stars 0 forks source link

DG Code

Overview

DG code is the temporary name for this code which solves the 1D advection equation du/dt+adu/dx=0 for arbitrary order and grid size along with a python script to plot results.

Features

Requirements

Usage

  1. Compile the code using the provided Makefile:
    make
  2. Run the solver executable:
    ./dg1d

    The time it took the simulation to run and error (if test = true in input.txt) are output

  3. After running the solver, animate the results using the python script:
    python3 plot_results.py

    This will generate an animation of the solution.

Input File Format

The input file (input.txt) must contain the following parameters:

Code Structure

Author

-Jack Gabriel