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

96 questions
Filter by
Sorted by
Tagged with
55 views

30 views

### Semi-analytical/empirical modelling of wall boundary conditions in advection-diffusion-reaction equation with distributed source

Let's suppose I need to numerically solve a 3D steady-state transport equation of the form $$\nabla \cdot (\mathbf{u} c) = \nabla \cdot (D \nabla c) - \lambda c + S$$ where $c$ is the transported ...
70 views

184 views

41 views

629 views

I've spent the whole day trying to figure out what is the correct way to impose (and implement) periodic boundary conditions $u(0,t)=u(1,t)$ for all $t>0$ for the simple advection equation $u_t + v ... 1answer 333 views ### Robin Boundary Condition with Implicit Upwind - Finite Difference Method for 2D Convection-Diffusion Equation I am trying to solve a problem with 2D Convection-Diffusion equation with U = Concentration ($mg/m^{2}$) using Implicit Upwind Finite Difference Method like this $$\frac{\partial U}{\partial t} + ... 1answer 166 views ### 1-D boundary value problem: How implement mixed boundary conditions using a FD method? I have been given a convection-diffusion ODE modeling the steady state temperature of a pipe (through which flows a fluid) as$$-\frac{d}{dz}\left(\kappa \frac{dT}{dz} \right)+v\rho C\frac{dT}{dz}=Q(... 0answers 32 views ### Finite difference/element method : time step and spatial resolution close to a finite singularity I'm using the finite element method (FEM), but my question is quite a global question. It's related to this question but it is not the same. Let's assume we have this equation : $$\partial_t c - u\... 0answers 111 views ### FDM discretization of equation on the boundary In order to simulate the following equation using FDM$$u_t(t,x)-u_{xx}(t,x)=0, \quad (t,x) \in (0,1)\times (0,1)(u_t(t,x)-u_{x}(t,x))\rvert_{x=0}=0, \quad t \in (0,1)(u_t(t,x)+u_{x}(t,x))\... 1answer 95 views ### Error for the finite differences scheme -- Advection equation Consider the advection equation (1D in space) $$\frac{\partial u}{\partial t} + V\, \frac{\partial u}{\partial x}=0$$ and we solve it numerically on$[0,1]\times [0,1]\ni (t,x)$using a forward ... 1answer 661 views ### How to make a less diffusive code to solve 2D advection equation? I would like to solve the following differential equation numerically in 2D, $$\frac{\partial z^-}{\partial t}+(\vec{B}\cdot\vec{\nabla})z^-=0,$$ see Wikipedia if you are curious about what the ... 1answer 470 views ### Analytical Solution of Transport Equation I'm looking at the analytical solution of the convection-diffusion equation $$\frac{\partial C}{\partial t} = D\frac{\partial ^2 C}{\partial x^2}-v\frac{\partial C}{\partial x}$$ with initial ... 1answer 110 views ### Simulating Brownian motion in 3-D for first hitting time? I want to simulate Brownian motion in 3-D for the following conditions: $$p(x=0,y=0,z=0,t=0)=1$$ $$p(x,y,z=c,t)=0$$ where$p$is the probability of finding molecules in the 3-D environment. I want to ... 1answer 1k views ### Analytical solution of 1D advection -diffusion equation I am looking for the analytical solution of 1-dimensional advection-diffusion equation with Neumann boundary condition at both the inlet and outlet of a cylinder through which the fluid flow occurs. $$... 1answer 844 views ### Impose Neumann Boundary Condition in advection-diffusion equation 1D when solving the advection equation in 1D that is:$$ \frac{\partial u}{\partial t} + c\frac{\partial u}{\partial x} = 0 $$with u'(t,0) = 0 and u(t,L) = 0 , u(0,x) = u_{0} one numerical ... 0answers 367 views ### Inflow and outflow boundary conditions for advection-diffusion equation I'm trying to solve this advection-diffusion equation (ADE):$$\frac{\partial \phi}{\partial t} + \nabla \cdot (-D \nabla \phi + \mathbf{u} \phi) = 0$$In fact, this ADE framework is coupled to a ... 1answer 464 views ### How write a integration loop in fortran, leapfrog scheme to solvind PDE (advection)? I want to resolve numerically this equation using of difference finite method with Leapfrog Scheme$$\frac{\partial{u}}{\partial t}+ v \frac{\partial{u}}{\partial x}= 0 $$I'm trying to write a code ... 1answer 457 views ### Finite Differencing schemes for Convection-Diffusion equation I'm using the Convection(/advection)-Diffusion(-Reaction) equation to calculate the temperature over time in different hydraulic parts like a pipe or a heat exchanger. The flow/convection is always 1D,... 0answers 55 views ### Finite difference Neumann boundary conditions: uneven weighting of edge nodes? Originally asked this on math.stackexchange, but I figure it's also appropriate here. I'm reading through some finite difference code for a diffusion equation and came across something odd for the ... 0answers 56 views ### Jacobian Elements for Coupled Drift-Diffusion System using Vertex-Centered Finite Volume I'm trying to solve the fully coupled drift-diffusion system using Newton's Method. Although I eventually plan to potentially use a Jacobian-Free Newton-Krylov approach, this is still something that I ... 1answer 271 views ### Closed boundary conditions in finite difference method for diffusive-advective equation I am implementing a finite difference method in solving the diffusive-advective equation:$$ u_t + v \cdot u_x = D\cdot u_{xx} $$(v, D are constants). Planning to use the operator splitting method (... 0answers 220 views ### Finite Element Stabilization for Drift-Diffusion/Advection-Diffusion Equations I've tried my best to look through the relevant suggested similar questions when posting this, and hopefully this contains enough new material to not be considered a duplicate. I'm currently trying ... 1answer 107 views ### finite differences on a slanted grid --- advection diffusion equation I used pretty much all my expertise with finite differences to solve an advection-diffusion equation with space-dependent coefficient with a grid in the x,z domain with regular spacings. Something ... 5answers 943 views ### Don't we care about the numerical diffusion in the diffusion term? In the context of the solution of advection-diffusion equations by finite volume method, many numerical schemes, papers and book chapters are dedicated to address the numerical diffusion and/or ... 1answer 1k views ### CFL condition in Stokes equation Does the CFL condition play any role in a pure Stokes flow, i.e. convective term is neglibile, or vanishing? If not, what is the "equivalent" condition for stability? I have read something about the ... 1answer 6k views ### How to simulate 3D diffusion in python? I want to simulate a simple 3D diffusion (e.g., an ink released from one side of a vessel) using SciPy. There are some tutorials for one-dimensional diffusion. ... 0answers 160 views ### Jacobian of the electron and hole drift diffusion equations with respect to potential in semiconductors These are the discretized drift diffusion equations as taken from the book "Analysis and Simulation of Semiconductor Devices". The electron continuity equation is:$$((\Delta_{j-1}^y+\Delta_j^y)/2\... 0answers 111 views ### How to formulate Poisson's equation into flux eqution I have a small 2D system I'm trying to model using a non-linear extension of Darcy's law for fluid flow in porous media. I'm primarily interested in the local flow velocity, not necessarily the ... 0answers 57 views ### Solve ODE with two unknown functions I want to solve a diffusion-convection problem numerically. I start from a PDE of the form $$\partial_t f(x,t) = \partial_x(K(x)\;f(x,t))+\partial_{xx}\;f(x,t)^{m}\;.$$ It is possible to calculate a ... 1answer 3k views ### BDF vs implicit Runge Kutta time stepping Are there any reasons for why one should choose high order implicit Runge Kutta (IMRK) over BDF time stepping? BDF seems much easier to me as$q$stage IMRK needs$q$linear solves per time step. ... 1answer 163 views ### Can this nonlinear advection-diffusion equation be discretized as to only have to solve SPD systems? Consider a nonlinear advection-diffusion equation of the form $$\frac{\partial u}{\partial t} = \nabla \cdot (a(u) \nabla b(u) - \vec{c}(u)u) \tag{1}$$ on a rectangular domain with Dirichlet ... 3answers 309 views ### When is it safe to ignore the diffusion term in an advection-diffusion equation? Given the one dimensional equation:$\epsilon\frac{\partial^2u}{\partial x^2} +\frac{\partial u}{\partial x} = 0 $with$0\le\epsilon \ll1$with boundary conditions$u(0) = 0$and$u(1) = 2$, we ... 1answer 285 views ### How can I numericaly solve a convection-diffusion equation with a large diffusion term? I want to numerically solve the advection-diffusion equation: \begin{equation} u_t(x,t) + cu_x(x,t) = v u_{xx}(x,t) \end{equation} for$x \in [0,1]$and$t \geq 0$subject to the boundary conditions ... 0answers 84 views ### Implementing initial conditions into the solution domain of a 1-D advection-diffusion equation I have the following PDE.$\frac{\partial c}{\partial t} + v\frac{\partial c}{\partial x} - D\frac{\partial^2 c}{\partial x^2} = 0 \\$. I have discretized it such that i now have$\frac{dC}{dt} = ...
The partial differential equation is a combination of the diffusion plus convective trans­port equations and an adsorption sink. The equation for one-dimensional solute transport model is: \frac{\...