HyPar
1.0
Finite-Difference Hyperbolic-Parabolic PDE Solver on Cartesian Grids
|
Initialize the Burgers module. More...
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <basic.h>
#include <arrayfunctions.h>
#include <bandedmatrix.h>
#include <physicalmodels/burgers.h>
#include <mpivars.h>
#include <hypar.h>
Go to the source code of this file.
Functions | |
double | BurgersComputeCFL (void *, void *, double, double) |
int | BurgersAdvection (double *, double *, int, void *, double) |
int | BurgersUpwind (double *, double *, double *, double *, double *, double *, int, void *, double) |
int | BurgersInitialize (void *s, void *m) |
Initialize the Burgers module.
Definition in file BurgersInitialize.c.
double BurgersComputeCFL | ( | void * | s, |
void * | m, | ||
double | dt, | ||
double | t | ||
) |
Computes the maximum CFL number over the domain. Note that the CFL is computed over the local domain on this processor only.
s | Solver object of type HyPar |
m | MPI object of type MPIVariables |
dt | Time step size for which to compute the CFL |
t | Time |
Definition at line 15 of file BurgersComputeCFL.c.
int BurgersAdvection | ( | double * | f, |
double * | u, | ||
int | dir, | ||
void * | s, | ||
double | t | ||
) |
Compute the hyperbolic flux over the local domain.
\begin{equation} {\bf F}\left({\bf u}\right) = 0.5 {\bf u}^2 \end{equation}
f | Array to hold the computed flux (same size and layout as u) |
u | Array containing the conserved solution |
dir | Spatial dimension |
s | Solver object of type HyPar |
t | Current time |
Definition at line 17 of file BurgersAdvection.c.
int BurgersUpwind | ( | double * | fI, |
double * | fL, | ||
double * | fR, | ||
double * | uL, | ||
double * | uR, | ||
double * | u, | ||
int | dir, | ||
void * | s, | ||
double | t | ||
) |
Upwinding scheme for the Burgers equations
fI | Computed upwind interface flux |
fL | Left-biased reconstructed interface flux |
fR | Right-biased reconstructed interface flux |
uL | Left-biased reconstructed interface solution |
uR | Right-biased reconstructed interface solution |
u | Cell-centered solution |
dir | Spatial dimension |
s | Solver object of type HyPar |
t | Current solution time |
Definition at line 15 of file BurgersUpwind.c.
int BurgersInitialize | ( | void * | s, |
void * | m | ||
) |
Initialize the nonlinear Burgers physics module - allocate and set physics-related parameters, read physics-related inputs from file, and set the physics-related function pointers in HyPar
s | Solver object of type HyPar |
m | Object of type MPIVariables containing MPI-related info |
Definition at line 25 of file BurgersInitialize.c.