We’re rewarding the question askers & reputations are being recalculated! Read more.

Questions tagged [advection-diffusion]

Questions related to solving the advection-diffusion equation using numerical methods, including derivation and implementation of boundary conditions.

Filter by
Sorted by
Tagged with
1
vote
0answers
360 views

1D k-epsilon turbulence model in a turbidity current

I am trying to implement a 1D k-$\varepsilon$ turbulent model for a turbidity current, hence the conservation equation for $c$. I'm solving for the variables $u,c,k$ and $\varepsilon$. The remaining ...
2
votes
1answer
174 views

Not getting correct numerical solution for Advection-Diffusion-Reaction eqn

Objective: I am trying to numerically solve $C(x,y,t)$ from the following advection-diffusion-reaction equation in 2D space (x,y) and time. I will be testing my numerical solution with an approximate ...
1
vote
1answer
212 views

$AX=B$: How to solve for $X$ if elements of matrix A are matrices

Objective: I am trying to solve for $C$ in 2D space (x,y) and time from following PDE. $$ \text{PDE: }\frac{\partial C}{\partial t} + \nabla\left(v.C - D\nabla{C} \right)= \alpha.C $$ Method: I ...
1
vote
1answer
426 views

ADR equation implicit solution: Penta-diagonal matrix for a 2D $N\times N$ system

Objective: I am trying to simulate the following advection-diffusion-reaction equation in 2D space (x,y) and time. $$\begin{align} \text{ADR Equation: }\frac{\partial C}{\partial t} + \nabla\left(v.C ...
7
votes
1answer
808 views

How to avoid negative values of numerical solution of transport equation using FEM scheme?

The transport equation is actually an advection-diffussion-reaction equation, which has the form as $$\frac{\partial C}{\partial t} + v_1 \frac{\partial C}{\partial x} + v_2 \frac{\partial C}{\...
1
vote
1answer
307 views

Solve steady state reaction-diffusion/Helmholtz equation numerically

I am solving a problem of the form: $\dfrac{\partial u(x,y,t)}{\partial t} = \nabla^2 u(x,y,t) - f(x,y,t)u(x,y,t) - \kappa(x,y,t)$ At the moment, I am solving this at each time step by assuming a ...
1
vote
3answers
557 views

Solve diffusion equation with linear source term

I would like to solve numerically the diffusion equation, where the sink term depends linearly on the field, and there is field-independent sink: $\frac{\partial^2 u(x)}{\partial x^2} =f(x)u(x) - \...
6
votes
1answer
434 views

Inverse advection-diffusion problem, solving for a drift coefficient with experimental data?

I am investigating a physical process where I believe the 1-D advection-diffusion equation: \begin{equation} \frac{\partial u}{\partial t} = -\frac{\partial}{\partial x}[\mu(x,t) u(x,t)] + \frac{\...
2
votes
1answer
120 views

Trignometric/Fourier spectral collocation with zero Dirichlet BC in 2D

I am concerned with numerical solution to the following problem on $[0,1]\times[0,1]$. $\dfrac{\partial\theta}{\partial t}+u(x,t).\nabla \theta(x,t)=\kappa \nabla^2\theta(t,x)$ with Dirichlet ...
1
vote
1answer
265 views

How to solve coupled steady laminar diffusion flame jet problem? [closed]

I am trying to solve governing equations of laminar diffusion flame jet for steady state case. In the next step, I will solve for unsteady case. I have non-dimensional continuity, axial momentum, ...
0
votes
0answers
203 views

advection diffusion equation

Would you know what is the condition for stability for the advection-diffusion equation where we treat the diffusion part using Crank-Nicholson and the advection part using FCTS (forward in time ...
2
votes
0answers
377 views

finite volume for diffusion equation with anisotropic (tensor) coefficient

Consider the scalar PDE for $u$ with Dirichlet boundary conditions: $\mathrm{div}(\mathcal{K}\nabla u) = f\; \forall x\; \in \Omega \subset R^2$, $u = 0 \; \forall \; x\;\in \partial\Omega$ ...
4
votes
1answer
214 views

The most efficient way to solve diffusion equation with concentrated initial condition

I want to solve the diffusion equation, i.e. $$ \dot{f} - f'' = 0 $$ with a boundary condition $f(0) = f(1) = 0$ and with an initial condition that $f$ is a boxcar function concentrated over some ...
1
vote
1answer
709 views

Solving the convection-diffusion equation using finite differences at high Peclet numbers

I am trying to solve the 2D convection-diffusion equation, which in non-dimensional variables can be expressed for my problem as: $\frac{\partial c}{\partial t} = \lambda^2\frac{\partial^2c}{\partial ...
3
votes
2answers
531 views

In what regime do the continuous and discontinuous Galerkin method become unstable for advection-diffusion systems?

I know that the finite volume method (based around a central different stencil) is unstable for advection dominated advection-diffusion problems. This leads to different adaptive schemes to can be ...
4
votes
3answers
3k views

Conservation of Mass in 1D Advection-Diffusion Equation

My long-term goal is to numerically solve the 1D advection-diffusion equation of the form: $$\frac{\partial u}{\partial t}=\frac{\partial }{\partial x}\left( v(x,t) u+D\frac{\partial u}{\partial x}\...
4
votes
1answer
520 views

My algorithm for the heat equation is unstable

I have implemented the 2D heat equation with what I thought was the Crank-Nicolson algorithm in the following way: ...
3
votes
2answers
877 views

Slow convergence of Newton's method for finite elements

The application is a simple non-linear advection diffusion problem (steady state) using DGFEM. My error at each iteration is given by $$ e_{n+1} = ||\mathbf{J}^{-1}(\mathbf{u}_{n})\mathbf{F}(\mathbf{u}...
3
votes
1answer
309 views

Convergence of interior penalty DG methods

I’m currently having some issues with my routine for the linear advection-diffusion problem. The model problem is as follows: $$ \nabla\cdot(\mathbf{s} u) - \nabla\cdot(\kappa\nabla u) = f, \;\;\;\...
6
votes
2answers
819 views

What are some of the differences between using a Lagrangian and Eulerian framework to quantify passive scalar dynamics?

On one hand, one may seed the domain with particles and track their trajectories in the Lagrangian sense by implementing a Lagrangian particle tracking model. On the other hand, one may use the ...
3
votes
1answer
257 views

Should particles in Smoothed Particle Hydrodynamics (SPH) always move during a simulation?

Or can they just be used as an interpolation points and use some other "transported property" which are just evolved and propagated from boundary conditions like for eg. heat conduction through a ...
4
votes
1answer
156 views

What is the origin of the preasymptotic convergence behaviour in FEM?

When you have fine-scale features (e.g. boundary layers) in the solution, its FEM approximation on coarse meshes converge at strange apparent rates. Looking at Cea's lemma, is this behaviour because ...
4
votes
1answer
203 views

How can exponential fitting be used with the finite element method?

Restricted to one dimensional problem, is it possible to dynamically adapt the finite element method (FEM) discretisation based on the local value of the Péclet number ($P_e$) for advection-diffusion ...
5
votes
2answers
2k views

Does the finite element method impose any restrictions on the Peclet number for numerical stability?

Background on finite volume method When discretising the flux with a central difference stencil of the the advection-diffusion equation restriction $\frac{ah}{d} < 2$ must be observed for the ...
5
votes
2answers
492 views

Solving PDE with spatial and temporal derivatives on left hand side

I wish to solve an equation of the form, $$ \frac{\partial}{\partial t} \left( \frac{\partial \phi}{\partial x} \right) = -\frac{\partial}{\partial x}(\mathcal{F}) $$ for the variable $\phi$ (e.g. ...
2
votes
2answers
975 views

How to solve an advection-diffusion equation

I need to solve an advection-diffusion equation of the form: $\frac{∂u}{∂t}=\frac{1}{x}\frac{∂u}{∂x}+\frac{∂^2 u}{∂x^2 } $ with MATLAB. Could you guide me, please? Is the Crank-Nicolson method ...
2
votes
1answer
342 views

How to write this non-linear PDE with the finite volume method?

I wish to solve a coupled system of non-linear equation of this form, $$ u_t = -(\mathcal{F})_x + f(x,u,w) \\ w_t = \mathcal{F} + g(x,u,w) $$ by stepping the equations forward in time. The first ...
3
votes
2answers
1k views

Does the time-dependent advection-diffusion equation have an analytical solution?

The advection-diffusion problem, where $0<x<1$, $$u_t = (-au + du_x)_x$$ with Dirichlet boundary conditions, $ u(0)=1,~u(1)=0 $ , has the steady-state solution, $$ u(x) = \frac{e^{\lambda} - ...
6
votes
2answers
1k views

Finite-volume method: can Dirichlet boundary conditions be applied to the integral form?

I would like to apply Dirichlet conditions to the advection-diffusion equation using the finite-volume method. This answer, "How should boundary conditions be applied when using finite-volume method?" ...
16
votes
1answer
867 views

How do you debug numerical code, what could be source of this oscillatory error?

Quiet a lot of insight can be gained form experience, I was just wondering if anybody has seen something similar to this before. The plot shows the initial condition (green) for the advection-...
7
votes
1answer
705 views

Are we free to choose the position of ghost cells on a non-uniform finite-volume mesh?

Following Hundsdorfer approach the finite volume discretisation of the advection-diffusion equation (conservative form) on non-uniform cell centered grid can be written as, $$ w_j^{\prime} = \frac{w_{...
5
votes
1answer
378 views

Implementing an adaptive discretisation (upwind/central hybrid) for the advection-diffusion equation on a non-uniform mesh

I am following the approach of Hundsdorfer from Numerical solution of time-dependent advection-diffusion-reaction equations in which they introduce adaptive upwinding. The method can adapt from pure ...
13
votes
3answers
775 views

What are the basic principles behind generating a moving mesh?

I am interested in implementing an moving mesh for an advection-diffusion problem. Adaptive Moving Mesh Methods gives a good example of how to do this for Burger's equation in 1D using finite-...