PCE_BURGERS, a C++ library which defines and solves a version of the time-dependent viscous Burgers equation, with uncertain viscosity, using a polynomial chaos expansion, in terms of Hermite polynomials, by Gianluca Iaccarino.
The time-dependent viscous Burgers equation to be solved is:
du/dt = - d ( u*(1/2-u)) /dx + nu d2u/dx2 for -3.0 <= x <= 3.0with boundary conditions
u(-3.0) = 0.0, u(+3.0) = 1.0.
The viscosity nu is assumed to be an uncertain quantity with normal distribution of known mean and variance.
A polynomial chaos expansion is to be used, with Hermite polynomial basis functions h(i,x), 0 <= i <= n.
Because the first two Hermite polynomials are simply 1 and x, we have that
nu = nu_mean * h(0,x) + nu_variance * h(1,x).We replace the time derivative by an explicit Euler approximation, so that the equation now describes the value of U(x,t+dt) in terms of known data at time t.
Now assume that the solution U(x,t) can be approximated by the truncated expansion:
U(x,t) = sum ( 0 <= i <= n ) c(i,t) * h(i,x)In the equation, we replace U by its expansion, and then multiply successively by each of the basis functions h(*,x) to get a set of n+1 equations that can be used to determine the values of c(i,t+dt).
This process is repeated until the desired final time is reached.
At any time, the coefficients c(0,t) contain information definining the expected value of u(x,t) at that time, while the higher order coefficients can be used to determine higher moments.
The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.
PCE_BURGERS is available in a C version and a C++ version and a FORTRAN90 version and a MATLAB version.
HERMITE_POLYNOMIAL, a C++ library which evaluates the physicist's Hermite polynomial, the probabilist's Hermite polynomial, the Hermite function, and related functions.
PCE_ODE_HERMITE, a C++ program which sets up a simple scalar ODE for exponential decay with an uncertain decay rate, using a polynomial chaos expansion in terms of Hermite polynomials.
SDE, a C++ library which illustrates the properties of stochastic differential equations (SDE's), and common algorithms for their analysis, by Desmond Higham;
Original FORTRAN90 version by Gianluca Iaccarino. C++ version by John Burkardt.