Referring to the discretization of derivatives by Finite differences, and its applications to numerical solutions of partial differential equations.

learn more… | top users | synonyms

2
votes
2answers
57 views

9-point stencil finite difference Laplacian with variable diffusion coefficients

So I'm trying to implement a 9-point stencil discretization to the 2D difussion equation. The stencil is here. However, most of the literature deals with a Laplacian that has a constant diffusion ...
2
votes
0answers
37 views

Calculating theoretical order of accuracy of least squares fit advection scheme

I'm familiar with finding the order of accuracy using von Neumann analysis for finite difference schemes formulated using Taylor series expansions. But is there a similar technique for finding the ...
4
votes
1answer
54 views

transverse component for multidimensional advection in method of lines

So I inherited from some people a code that solves the advection-diffusion-reaction equation for a particular system. The original code was first implemented in 1D which worked fine in cartesian ...
2
votes
0answers
177 views

Finite difference scheme for solving nonlinear least-squares problem

I am dealing with following problem: $$ \min_{u,\gamma}\Bigg\{ \frac{1}{1000} \iint_{S_2} {\gamma (x,y)^2 dxdy} + \iint_{S_2} {[u(x,y) - u_0 (x,y)]^2 dxdy} + \iint_{S_2} {[\Delta u(x,y) - \gamma ...
2
votes
1answer
118 views

How can I solve wave equation for circular membrabe in polar coordinates?

The original equation is $$\frac{1}{c^2} \frac{\partial^2 u}{\partial t^2} = \frac{\partial^2 u}{\partial r^2} + \frac{1}{r}\frac{\partial u}{\partial r} + \frac{1}{r^2}\frac{\partial^2 u}{\partial ...
2
votes
1answer
81 views

Finite difference for nonlinear system of equation

\begin{equation} \frac{\partial C_i}{\partial t} = D_i \nabla^2 C_i - \frac{I \cdot \nabla t_i}{z_i F} - \sum_{i'} \frac{z_{i'}}{z_i} D_{i'}\nabla \cdot (t_i\nabla C_{i'}) \end{equation} ...
0
votes
0answers
31 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
81 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 ...
3
votes
2answers
98 views

Error in result of finite-difference approximation when refining

I have calculated the first derivative of following equation using Euler method (first order), Three point Finite Difference method (second order) and Four point Finite Difference method (third ...
1
vote
1answer
150 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
75 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 ...
2
votes
2answers
130 views

How to solve a Poisson equation using the finite difference method when there is an object inside a domain?

I'm interested in solving an electrostatics problem in 2d case in some domain with a conductor placed inside the domain. From a mathematical point of view, I have to solve a Poisson equation with ...
2
votes
0answers
34 views

matplotlib contourplot for $\log z$ in the Complex Plane $\mathbb{C}$

I tried using Python's matplotlib on the logarithm and here is what I got, a kind of starburst pattern. Since the angle jumps between $\theta = 0$ and $\theta = 2\pi$, contour assumes there is a ...
-1
votes
1answer
205 views

How to initiate spirals in this model?

I am trying to reproduce Tang & Othmer paper which is related to excitations and oscillations in G-protein model in Dictyostelium discoideum, an amoeba species. The mathematical model in the paper ...
1
vote
0answers
38 views

Nonlinear 2D modeling of Neural Electromagnetic field in Matlab

I am trying to replicate the MATLAB simulation presented in this paper. More specifically, I have to code the solution to this equation $$\frac{a}{2R_i}\frac{\partial^2 V_m}{\partial x^2} - ...
0
votes
0answers
53 views

How one can explain to have non-unique numerical solution at the interface boundary?

If the existed computational domain is divided into two pieces and developed numerical scheme is applied to these lets say right and left side domains of the interface individually to obtain two ...
1
vote
1answer
63 views

A doubt in Multigrid V-cycle

Assume I have 3 levels of grids. Finest Grid = level 2, Coarser Grid = level 1, Coarsest Grid = level 0. Relax $u$ on $Au = b$ at level 2 for 3 times. Find residual $r2$ at level 2, then restrict to ...
1
vote
2answers
116 views

How can I prove that two eigenvectors are orthogonal?

I obtained 6 eigenpairs of a matrix using eigs of Matlab. How can I demonstrate that these eigenvectors are orthogonal to each other? I am almost sure that I ...
-2
votes
1answer
54 views

Finite Difference for Fourth-Order PDE

How to discretize the following 4th order PDE using finite difference method? $$\frac{\partial^{2} y}{\partial t^{2}}+\frac{\partial^{4} y}{\partial x^{4}}=0$$ thanks
0
votes
1answer
81 views

Finite Difference method

I'm following the article at http://www.paykin.info/irina/project_2.jsp Finite Difference method. How to interpret this one? How to convert this to pseudo code? $$u(i,j+1) = 2u(i,j) + ...
7
votes
1answer
72 views

Stability analysis of Heun's method

I am using Heun's method with a third order upwind spatial scheme, which is suggested by Shao (2008) to be used for solving the horizontal advection part of the advection-diffusion equation. This is ...
2
votes
0answers
36 views

Rank deficient Jacobian in discretized periodic solutions to autonomous ODE

I'm trying to numerically find periodic solutions to different systems of autonomous nonlinear ordinary differential equations. I decided to use a finite difference scheme and solve the resulting ...
1
vote
1answer
85 views

openfoam - Programming customized PDEs

I am looking for a method to automatically solve custom PDEs on a custom control volume. Specifically I would like to solve equations similar (but not exactly alike) to: $$\frac{\partial y}{\partial ...
1
vote
1answer
86 views

Correct way of computing norm $L_2$ for a finite difference scheme

I am computing the rate of convergence of my finite difference scheme in norm $L_2$. Which is the correct way to compute it? This: \begin{align} L_2 &= ...
2
votes
1answer
115 views

Why a finite difference scheme would give second order of accuracy in norm L2 but 1.5 with L1 (while 1 with Linf)?

My finite difference scheme for the 2D Euler equations is second order accurate in theory, since all the terms are second order accurate, with the advective terms being third order. So I expect a rate ...
0
votes
0answers
53 views

The centered difference operator for fractional function

Recently, I come to a question about the 2nd order centered finite difference approximation of a fractional function, more precisely, we set $\delta^{2}_x u(x,t) = u(x_{i-1},t)-2u(x_i,t) + ...
2
votes
2answers
64 views

Integro-differential PDE and method of lines

Let us consider the following equation : $$\partial_t u = \Delta_x u + K*u$$ where $K$ is a smooth kernel, $u(x,t)$ is the unknown and $x$ is in $\Omega$ a domain in 1d or 2d. I want to numerically ...
0
votes
0answers
44 views

Quick scheme for separable first-order ODE

I'm trying to integrate an incredibly simple ODE: $$ y'(x) = -f(y),\quad y(0) = y_0 \ , $$ from $x=0$ to $x=1$. This is a decay type of equation, $f$ is the (variable) decay rate and $y$ is the ...
1
vote
0answers
93 views

Tips on improving stability in numerical scheme for non-linear PDE

I am solving a non-linear second order system of PDEs in two variables. The equations are too complicated to write out here, but an essential feature is that there is a propagating wave which then ...
6
votes
3answers
105 views

Stability criterion for waves in anisotropic solids

The equations of motion for an elastic solid are given by $$\begin{align} &\nabla \cdot \boldsymbol{\sigma} + \mathbf{f} = \rho \ddot{\mathbf{u}}\\ &\boldsymbol{\sigma} = ...
0
votes
1answer
80 views

Spectral Coefficients of Implicit Finite Difference Solution

This is something I've been trying to figure out for a long time, and all I have is vague numerical results. I'm trying to answer the following question analytically: Suppose I have a time dependent ...
2
votes
2answers
180 views

The meaning of conservative discretization in Galerkin FEM and Discontinuous Galerkin

I do understand the meanning of "conservative discretization" within the FVM/FDM framework, indeed it is well explained in this post. Now, according to the table in this slide (pp.4), it concludes: ...
4
votes
1answer
86 views

Need a good reference for numerical transport phenomena

I'm a chemical engineering undergraduate and I'm currently starting to work in a theoretical transport phenomena/colloid science group. While my group has a nice code base for larger scale ...
3
votes
0answers
69 views

2D wave equation with Mur boundary condition - setting up the RHS and solving (time-steps)

I am trying to solve a 2D wave equation implicitly using FD with central approximations with the following boundary conditions $$\begin{align} &u=2\sin\left(\frac{2\pi}{5}t\right)\quad \text{at ...
0
votes
1answer
134 views

Solving PDE with state and time dependent boundary conditions

I am interested in solving the following PDE (heat equation): $$\frac{\partial u}{\partial t} = \kappa \frac{\partial ^2 u}{\partial x^2}$$ In order to solve it, I discretize space uniformly into $N$ ...
0
votes
2answers
42 views

How to obtain streamslines from velocity field data points

I managed to solved a lid-driven cavity flow using LB code. It gave me the velocity field data points. Now I have to obtain streamlines too, of course from the obtained velocity field. Besides, I ...
2
votes
0answers
109 views

Boundary equations for constant right hand side in Poisson equation (FD)

I am setting up to solve a 2D Poisson equation $\nabla^2u = T$ by the finite difference method. I am using the multigrid method. On the coarsest mesh, where the grid size is 2x2, I want to set up ...
2
votes
1answer
177 views

Can Gauss-Seidel/SOR (preconditioned?) be applied to a non-diagonally dominant matrix?

After applying finite difference method to a Laplace/Poisson problem always arises a diagonal dominant system of equations that can be solved with Gauss-Seidel or SOR methods. If the original PDE does ...
3
votes
0answers
80 views

Computing accuracy of my finite difference scheme for uniform grid on a non-uniform grid

I have a ADI finite difference scheme for the 2D Navier-Stokes equations that uses a second order accurate (central) approximation for the advective terms. I am ignoring the diffusive terms for now. I ...
1
vote
3answers
299 views

2D Stokes equation Code

Does anyone know where could I find a code (in Matlab or Mathematica, for example) for he Stokes equation in 2D? It has been solved numerically by so many people and referenced in so many paper that I ...
0
votes
0answers
28 views

Book recommendation on simulation of linear and nonlinear electronic circuits

I am looking for a book on electronic circuit simulation explaining the numerical modeling using transient and frequency based methods from a computational point of view. It should also have an ...
2
votes
0answers
105 views

1 D Diffusion equation FDM with different layers

I'm trying to solve this particular equation $\frac{\partial u}{\partial t} = \frac{\partial}{\partial x} \big[D_{i}(x)\frac{\partial u}{\partial x} \big] + S(x,t)$ where the $i$ index denotes ...
4
votes
2answers
151 views

Usability of upwind finite difference schemes

NOTE: I asked this on Mathematics Stack Exchange and there were no answers. So, I thought I might try here. Upwind schemes like the classic "upstream" scheme, can be used to solve, for example, the ...
0
votes
0answers
12 views

Is there a commonly accepted measure for SNR degradation from a derivative operator?

Is there a commonly accepted measure for the impact of a derivative operator (compact FD or otherwise) on signal or image SNR? I am about to do this empirically, taking SNR measurements on a large ...
4
votes
0answers
94 views

numerical analysis of a partial integro-differential equation

I have to numerically solve a nonlinear partial integro-differential equation. This is my equation, $$\frac{\partial y(x,t)}{\partial t}=\int_{-\infty}^\infty K_0(|x-u|) \frac{\partial^2 ...
0
votes
0answers
47 views

Help about Fluid-Fluid coupling techniques

I need a little help and advice with a project I want to do: the idea is to "couple" (I don't know whether I can call it like this) a conservative Navier-Stokes Solver (Fractional-step, 2nd order FDM) ...
1
vote
0answers
76 views

Visualization of solution for a MAC grid

So I implemented the projection method as in Chorin (1969) for the solution of the Navier-Stokes Equations with the Boussinesq Approximation, using a 2nd Order accurate FD scheme. The primitive ...
1
vote
0answers
137 views

What is the difference between SSPRK3 and RK3 time discretization methods?

Here, SSPRK3 refers to third order strong stability preserving Runge-Kutta and RK3 refres to regular third order Runge-Kutta method. The meaning of the method is obvious from the name. However there ...
4
votes
1answer
89 views

How to evaluate a series of derivatives?

Consider the function $$f(\mathbf{x}) = \sum_{n=0}^{N} a_n \left( (\mathbf{b}-\mathbf{x})\cdot \nabla \right)^n \frac{1}{r}$$ where $r = |\mathbf{x}| = \sqrt{(x-x_0)^2 + (y-y_0)^2}$ and $a_n$ and ...
0
votes
0answers
36 views

multivariable ode

I have a system of pde which I dicretized along the spatial derivative to yield a time-dependent ode. The resulting ode is multivariable,highly non-linear and stiff.Also they have largely different ...