FEM Types

Below are the definitions of the types which specify problems. Some general notes are:

Poisson Equation Problem

Wraps the data that defines a 2D linear Poisson equation problem:

\[-Δu = f\]

with bounday conditions gD on the Dirichlet boundary and gN on the Neumann boundary. Linearity is determined by whether the forcing function f is a function of one variable (x) or two (u,x) (with x=[:,1] and y=[:,2]).

If the keyword σ is given, then this wraps the data that defines a 2D stochastic heat equation

\[-Δu = f + σdW\]

Constructors

PoissonProblem(f,analytic,Du,mesh): Defines the Dirichlet problem with analytical solution analytic, solution gradient Du = [u_x,u_y], and forcing function f

PoissonProblem(u0,f,mesh): Defines the problem with initial value u0 (as a function) and f. If your initial data is a vector, wrap it as u0(x) = vector.

Note: If all functions are of (x), then the program assumes it's linear. Write your functions using the math to program syntax translation: $x$= x[:,1] and $y$= x[:,2]. Use f=f(u,x) and σ=σ(u,x) (if specified) for nonlinear problems (with the boundary conditions still (x)). Systems of equations can be specified with u_i = u[:,i] as the ith variable. See the example problems for more help.

Keyword Arguments

Heat Equation Problem

Wraps the data that defines a 2D heat equation problem:

\[u_t = Δu + f\]

with bounday conditions gD on the Dirichlet boundary and gN on the Neumann boundary. Linearity is determined by whether the forcing function f is a function of two variables (t,x) or three (t,x,u) (with x=[:,1] and y=[:,2]).

If the keyword σ is given, then this wraps the data that defines a 2D stochastic heat equation.

\[u_t = Δu + f + σdW_t\]

Constructors

Note: If all functions are of (t,x), then the program assumes it's linear. Write your functions using the math to program syntax translation: $x$= x[:,1] and $y$= x[:,2]. Use f=f(t,x,u) and σ=σ(t,x,u) (if specified) for nonlinear problems (with the boundary conditions still (t,x)). Systems of equations can be specified with u_i = u[:,i] as the ith variable. See the example problems for more help.

Keyword Arguments

Example Problems

Examples problems can be found in DiffEqProblemLibrary.jl.

To use a sample problem, you need to do:

# Pkg.add("DiffEqProblemLibrary")
using DiffEqProblemLibrary

Poisson Equation

Nonlinear Poisson equation with $f(u)=1-u/2$ and $f(v)=.5u-v$ and initial condition homogenous 1/2. Corresponds to the steady state of a humogenous reaction-diffusion equation with the same $f$.

source

Problem with deterministic solution: $u(x,y)= \sin(2πx)\cos(2πy)/(8π^2)$ and additive noise $σ(x,y)=5$

source

Nonlinear Poisson equation with $f(u)=1-u/2$ and $f(v)=1-v$ and initial condition homogenous 1/2. Corresponds to the steady state of a humogenous reaction-diffusion equation with the same $f$.

source

Problem defined by the solution: $u(x,y)= \sin(2πx)\cos(2πy)/(8π^2)$

source

Nonlinear Poisson equation with $f(u)=1-u/2$. Corresponds to the steady state of a humogenous reaction-diffusion equation with the same $f$.

source

Heat Equation

DiffEqProblemLibrary.prob_femheat_birthdeathsystem
DiffEqProblemLibrary.prob_femheat_birthdeathinteractingsystem
DiffEqProblemLibrary.prob_femheat_diffuse
DiffEqProblemLibrary.prob_femheat_stochasticbirthdeath
DiffEqProblemLibrary.prob_femheat_moving
DiffEqProblemLibrary.heatProblemExample_gierermeinhardt
DiffEqProblemLibrary.heatProblemExample_grayscott
DiffEqProblemLibrary.prob_femheat_pure
DiffEqProblemLibrary.prob_femheat_diffusionconstants
DiffEqProblemLibrary.prob_femheat_birthdeath