Skip to content

An implementation of a one-dimensional stabilized DG method that can time step explicity, even when there are arbitrarily small cells on the grid.

License

Notifications You must be signed in to change notification settings

andrewgiuliani/PyDGSRD1D

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

build-and-test-status

PyDGSRD-1D

This is a Python code that solves 1D hyperbolic conservation laws on nonuniform grids using the state redistribution method. State redistribution is an algorithm that solves the small cell problem on cut cell grids. That is, arbitrarily small cells on embedded boundary grids result in overly restrictive maximum stable time steps when using explicit time stepping algorithms. Similar in spirit to flux redistribution by Collela [1], state redistribution relaxes this time step restriction using a simple postprocessing operation. Of course, this algorithm is most interesting in two and three dimensions, but this one-dimensional code illustrates the important aspects of the algorithm.

SRD

High order approximation (p = 5) of an advecting pulse on a highly nonunform grid. The DG solution on each element is plotted with a different colour.

Installation

This simple code can be installed quickly by cloning the repository, navigating into the PyDGSRD1D directory and running pip install -e .

Goal

The goal of this work is to use explicit Runge Kutta time steppers on highly nonuniform grids using the time step restriction

where is the cell size, and is the maximum wavespeed in the numerical solution. In the following grid, the majority of cells on the grid have size and only three have size with . That is, could potentially be quite small.

example

State redistribution will allow the use of a time step that is proportional not . The main idea of state redistribution is to temporarily merge, or coarsen, the numerical solution into neighborhoods located on the small cells. Then, the solution on these neighborhoods is refined back onto the base, nonuniform, grid. In the next section, we describe the different ways of determining these merging neighborhoods in one dimension (the preprocessing stage).

🧪   Examples

A number of examples are available in the examples directory to illustrate how to use the code.

Contact

For help running the code, or any other questions, send me an email at giuliani AT cims DOT nyu DOT edu

📓  License

License: MIT

References

[1] Colella, Phillip, et al. "A Cartesian grid embedded boundary method for hyperbolic conservation laws." Journal of Computational Physics 211.1 (2006): 347-366.

[2] Giuliani, Andrew. "A two-dimensional stabilized discontinuous Galerkin method on curvilinear embedded boundary grids". https://arxiv.org/abs/2102.01857

About

An implementation of a one-dimensional stabilized DG method that can time step explicity, even when there are arbitrarily small cells on the grid.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages