2
$\begingroup$

Consider the diffusion-advection equation given by $$ - \mu \Delta u + \mathbf{v} \cdot \nabla u = f \ \text{in} \ \Omega $$ with some appropiate boundary conditions. Here the velocity field $\mathbf{v} : \Omega \rightarrow \mathbb{R}^2$ and the source function $ f: \Omega \rightarrow \mathbb{R} $ may depend on the position. Here $\Delta$ is the Laplace operator, and $\nabla$ is the gradient.

Solve the problem on a unit square with Dirichlet boundary conditions. Set up a finite difference scheme using central differences for both the first and second derivatives of $u$.

So for my scheme I obtained $$4\frac{\mu}{h^2} U_{p}+(\frac{v_{1}}{2 h}-\frac{\mu}{h^2})U_{E}+(\frac{v_{2}}{2 h} - \frac{\mu}{h^2})U_{N} - (\frac{v_{1}}{2 h}+\frac{\mu}{h^2})U_{W} - (\frac{v_{2}}{2 h} + \frac{\mu}{h^2})U_{S} + \tau = f$$ where $\tau$ is an error term. However Im really not sure this is correct. Im also not sure how to go about setting up the A matrix and progressing to solve the rest of the problem. Any help would be greatly appreciated.

$\endgroup$

0

You must log in to answer this question.