2 Examples
These are example scripts using the py-pde package, which illustrates some of the most important features of the package.
2.1 Grids and fields
These examples show how to define and manipulate discretized fields.
Plotting a scalar field in cylindrical coordinates
2.2 Simple PDEs
These examples demonstrate basic usage of the package to solve PDEs.
Solving Laplace’s equation in 2d
Solving Poisson’s equation in 1d
Kuramoto-Sivashinsky - Using PDE class
Time-dependent boundary conditions
Brusselator - Using the PDE class
Diffusion equation with spatial dependence
2.3 Output and analysis
These examples demonstrate how to store and analyze output.
Writing and reading trajectory data
2.4 Advanced PDEs
These examples demonstrate more advanced usage of the package.
Heterogeneous boundary conditions
Kuramoto-Sivashinsky - Using custom class
1D problem - Using custom class
Kuramoto-Sivashinsky - Compiled methods
Post-step hook function in a custom class
Brusselator - Using custom class