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

learn more… | top users | synonyms

0
votes
0answers
33 views

PDE discretization (via finite difference sheme) question

So after posting this question and reading all your comments I would like to make this new question (update). If you consider the three equations presented here: $$\frac{\partial \rho}{\partial t} ...
1
vote
1answer
31 views

Non-uniform finite difference Adaptive Mesh Refinement

Assuming that the crosses in the figure below are unknowns in a vertex-centered finite difference scheme in an Adaptive Mesh, how can I calculate the double derivate (Laplacian) at the Red x ? The Red ...
4
votes
0answers
63 views

discrete definitions of curl $\nabla \times F$?

I have some data defined in an array (an image) and I need to find the curl of a certain function. Wikipedia has an integral definition of curl that I like, maybe it can be discrete. $$ \nabla ...
1
vote
0answers
73 views

3D Diffusion Equation in Fourier space

I'm solving the 3D Diffusion equation $$u_t=k(u_{xx}+u_{yy}+u_{zz})$$ in MATLAB using Fourier techniques. I assume a 3D Fourier expansion $(e^{-ipx},e^{-imy},e^{-imz})$of the solution. Physical ...
3
votes
1answer
96 views

Implementing Finite Difference Adaptive Mesh Refinement code

For a start I need to implement a 2-D, vertex centered, finite difference scheme, Adaptive mesh refinement serial code. I have the following doubts before starting: Is the input to AMR (say 2-D) ...
3
votes
1answer
68 views

Generating a non-uniform grid

I am interested in generating a 1D non-uniform grid on the interval [0, L] with N points, where a region of width $\sigma$ and ...
2
votes
2answers
110 views

Are the Finite Difference and Finite Volume Methods different after the application of the Gauss Divergence theorem on the FVM?

I have a rudimentary question about the differences between finite difference (FDM) and finite volume methods (FVM). In FDM we concentrate on the nodes (points) in space while in FVM we concentrate ...
0
votes
1answer
48 views

1D uniform flow test case for compressible flow

Are there any one dimensional hyperbolic test cases for a 1D uniform flow? (I need the test case for the purpose of showing the satisfaction of geometric conservation law on a moving mesh).
1
vote
1answer
48 views

Implementation of Neumann boundary condition with method of lines - 1D diffusion/reaction equation

I am solving the monodimensional diffusion/reaction equation by discretization using the well-known method of lines ${\partial c\over\partial t}=D{\partial^2 c\over\partial x^2}+ r\text{ for ...
0
votes
0answers
44 views

Solving a nonlinear problem with CDF

I'm trying to solve this problem: $\begin{cases} \partial_t E=-k\left([f(\rho)-i.\left[\delta+\frac{1}{2}a\left[\dfrac{\nabla^2_{\bot}}{4}+1-\rho^2\right]\right]]E - 2CP\right)\\ \partial_t ...
6
votes
1answer
77 views

Poisson equation finite-difference with pure Neumann boundary conditions

I'm trying to solve a 1D Poisson equation with pure Neumann boundary conditions. I've found many discussions of this problem, e.g. 1) Poisson equation with Neumann boundary conditions 2) Writing the ...
4
votes
1answer
85 views

How to calculate dispersion relation from a Finite Difference (FD) wave simulation

I have a python code that calculates the solution of the inhomogeneous acoustic wave equation for a 2D medium with any velocity and source configuration. It was implemented using Finite Differences ...
0
votes
1answer
120 views

Finite-difference approximation of the 2nd derivative operator matrix for a staggered grid

I'm working on a computational physics assignment and I was looking for some help as I've got stuck! The question is: Write a function to create the finite-difference approximation of the 2nd ...
0
votes
0answers
57 views

Solving the transient heat convection diffusion equation (2D) using BTCS in Matlab with derivative BCs

I'm really stacking guys on how to solve the Solving the transient heat convection diffusion equation (2D) using the full implicit BTCS in Matlab with derivative Boundary condition and variable ...
0
votes
0answers
15 views

Converting events with irregular arrival times into a continous signal (1st, 2nd and 3rd order)

I got events coming in at irregular intervals. From these I need to emit the number of events arrived and the expected first and second derivative over some specified measurement period P. So ...
1
vote
1answer
106 views

How efficient (compared to “normal” methods) is using a sparse finite difference matrix to solve differential equations?

Any differential operator can be written as a finite difference matrix acting on a vector of values. I recently used it to solve $\Delta A = j$ by writing the Laplacian as a finite difference ...
0
votes
1answer
105 views

Heat Equation - PDE

I'm trying to model the Black-Scholes Equation (transformed into a heat equation) using method of lines in Python. The transformed formula is basically \begin{equation*} \frac{\partial u}{\partial ...
3
votes
0answers
74 views

CFL Condition and Convection Diffusion Equation in 2D

I am solving the convection-diffusion equation in 2D using Finite Differences with the $\theta$ scheme. The velocity of the fluid and the diffusion coefficient is low in my case (in the range of ...
4
votes
0answers
65 views

Numerically calculating the divergence of a set of oriented points

Say I have a set of oriented points at locations $\vec{v_i}$ with each some direction $\vec{n_i}$, in practice they represent the normals of some surface that has been non uniformly sampled. How would ...
1
vote
1answer
94 views

Are FEM or DGFEM methods based on integrals or PDEs?

I know that FVM is based on the integral form of conservation laws, and FDS is based on PDEs. What I'm confused by, is whether FEM and DGFEM formulations are based on integral or pde form of ...
1
vote
2answers
78 views

Analytical Solution to the acoustic / scalar (Inhomogeneous) wave equation with source term

The acoustic wave equation in 2D is $$\frac{\partial^2}{\partial t^2}p(x,z,t) = c(x,z)^2\left[\frac{\partial^2}{\partial x^2}p(x,z,t) + \frac{\partial^2}{\partial z^2}p(x,z,t)\right] + s(x,z,t) ...
0
votes
1answer
107 views

Calculation of error

I have written a code in which I find the approximation of the solution of this elliptic problem. I calculated the error using the following part of code: http://pastebin.com/7b5mmuRW but I get the ...
2
votes
0answers
154 views

Unrealistic solution for advection-diffusion-reaction PDE with heterogeneous media

About the code: I have a code which simulates concentration from advection-diffusion-reaction PDE in 2D space (X,Y) with time. The solution is obtained using fully implicit finite-difference method ...
0
votes
0answers
17 views

How to model charge density waves in anisotropic arrays of metallic nanoparticles

The system I am investigating (theoretically) is an anisotropic array of metallic nanoparticles (arranged in such a way as to mimic strain). Each nanoparticle can host a charge density oscillation ...
3
votes
1answer
179 views

Points on the interface

We consider the problem $\left\{\begin{matrix} k(x)\Delta u(x)=f(x) & \text{ in } \Omega\\ u=0 & \text{ in } \Gamma \end{matrix}\right.$ where $\Omega \subset \mathbb{R}^2$ open and ...
0
votes
2answers
115 views

Wave Equation PDE [closed]

I'm trying to solve the following PDE wave equation using method of lines: Wave Equation: u_tt = u_xx with initial condition: u(0,x) = sin*pi,u_t(0,x)=0, 0 < x < 1 boundary ...
3
votes
2answers
176 views

Hyperbolic Equation PDE (Python)

I'm trying to solve the following first order hyperbolic PDE problem using method of lines: Hyperbolic Equation: $u_t = -u_x$ with initial condition: $u(0,x) = 0, 0 < x < 1$ ...
1
vote
0answers
48 views

Need suggestions on how to implement this time stepping for wave equation

I have the following system of equations obtained by implementing Sympletic Euler time scheme to wave equation. I want to model this in Fenics. Here 'u' is the displacement and 'p' is corresponding ...
2
votes
1answer
45 views

How can I analyze the stability of a PDE discretization at a boundary?

I have a numerical discretization of a partial differential equation that seems to be unstable or stable at a boundary point, depending on what finite difference scheme I am using. Are there standard ...
2
votes
0answers
73 views

Finite difference aproximation - Darcy law

I am solving following problem: Filtration of water can be described in bi-dimensional case by $$- \partial_x(K(x,y) \partial_x u ) - \partial_y (K(x,y) \partial_y u ) = 0, $$ where $u$ - water ...
0
votes
0answers
52 views

Finite-difference technique to solve a stiff ODE

I've written code using finite difference techniques from Mathematica to solve the following ODE: $$-\Phi''-\frac{3}{r}\Phi'+\Phi-1.5\Phi^{2}+\frac{\alpha}{2}\Phi^{3}=0$$ I've already asked an ...
0
votes
0answers
31 views

diffusion approximation time inhomogeneous Poisson process

I'm trying to approximate a time inhomogeneous Poisson process by means of a diffusion process. the process is defined as: $X(t)=X(t-1)+Y(N_{t-1,t}); X(0)=X_0$ where $N_{t-1,t} = \int_{t-1}^t ...
1
vote
2answers
59 views

Propagation of error using Euler's first order method [duplicate]

I was estimating a falling object's position versus time by using a simple first order step function, where ...
2
votes
1answer
64 views

FDM - Solving acoustical wave equation via first order PDE's

Solving acoustical wave equation: $$ c_0^2\partial_{xx}p-\partial_{tt}=0 $$ using forward-time centered-space FDM is not very convenient cause of numerical dispersion etc. What about using a little ...
3
votes
1answer
186 views

Finite difference scheme for 2D sound propagation

I am simulating the sound wave propagation in non-rectangular and asymetric spaces using finite-difference method. I presume linear acoustics equations to be enough (i.e. $\Box p = 0$, $\Box \vec{v} = ...
1
vote
1answer
41 views

Finite difference for Lighthill source term

I have experimental data containing horizontal and vertical components of speed and I need to evaluate this: $$ \frac{\partial^2}{\partial x_i \partial x_j}\left(v_iv_j\right) $$ Denoting $U$ as ...
0
votes
0answers
68 views

1-D finite differences with piecewise linear solution

I was having some lectures and I didn't quite understand the following: let's say you have a grid like $$G=\{ x \in \mathbb{R} : x = x_j = hj, \ j = 0,1,...,n,\ h=1/n\}.$$ And you write in ...
1
vote
1answer
77 views

Diffusion with space dependent drift in Fipy

I need to solve a diffusion equation in periodic boundary conditions using fipy but I would like to have a drift term that depends on the position so like this: $$ \partial_t u(x,t) = \partial_x^2 ...
2
votes
1answer
119 views

MAC Projection in Projection method?

My question concerns the following paper: A Conservative Adaptive Projection Method for the Variable Density Incompressible Navier–Stokes Equations ...
3
votes
0answers
181 views

How could we solve coupled PDE with finite difference method and Newton-Raphson method?

I'm trying to solve coupled PDE by Crank-Nicolson (CN) and Newton-Raphson method with MATLAB. I have used CN method but not for coupled problem. Please if someone could help let me know to add more ...
1
vote
2answers
190 views

Dirichlet BCs - alternative implementation methods

I am having problems with solving a hyperbolic wave problem with Dirichlet BCs. I have tried reducing the time step sizes, which does not affect the results, and notices increasing the number of nodes ...
0
votes
1answer
80 views

How to define fluxes for two dimensional convection-diffusion equation?

I want to solve the following differential equation using control volume approach on a Cartesian mesh: $$\frac{\partial T}{\partial t} + \frac{\partial T}{\partial x} + \frac{\partial T}{\partial y}= ...
0
votes
0answers
37 views

Is this mesh refinement procedure correct?

Hello, I am using the following coarse mesh of size 7. I am integrating using the control-volume approach in which I use difference between the fluxes at the edges of CV. As you can see that in the ...
-2
votes
2answers
503 views

Use of machine learning in computational fluid dynamics

Background: I have only built one working numeric solution to 2d Navier-Stokes, for a course. It was solution for lid-driven cavity flow. The course, however, discussed a number of schema for ...
1
vote
0answers
75 views

Discontinuity at Interface

The equation at the left of the interface is \begin{equation} \displaystyle\frac{\partial C_i}{\partial t} = D_i \nabla^2 C_i - z_i \frac{D_i}{RT}F \nabla \cdot (C_i \nabla \phi_2) \end{equation} ...
1
vote
0answers
48 views

Jacobi method converging then diverging

I am working to solve Poisson's equation in 2D axisymmetric cylindrical coordinates using the Jacobi method. The $L^2$ norm decreases from $\sim 10^3$ on the first iteration (I have a really bad ...
0
votes
0answers
178 views

Finite Difference Method Neumann Boundary Condition with Variable Coefficients by Ghost Points

I have found an alternative solution to the problem stated here. Here's the alternative solution link. It says that "A common technique in implementations of $\partial u/\partial x=0$ boundary ...
3
votes
1answer
110 views

CFL condition for variable coefficients

I understand that the constant in the Courant-Friedrichs-Lewy condition is defined as $\mathrm{CFL} = \frac{u \Delta t}{\Delta x}$, where $u$ is the principal coefficient. I came across this post: ...
2
votes
2answers
137 views

Ill-conditioned Jacobian matrix from Nernst-Planck equation with Butler-Volmer reactions

The governing equations are listed here of my notes on page 4. It's a reproduction of other's paper which solves the equations with COMSOL. The problems arise when I want to solve for the consistent ...
4
votes
1answer
96 views

Flux at coarse-fine mesh grid interface?

I am trying to solve one dimensional inviscid Burger's equation using adaptive mesh refinement. This is the PDE: $$\frac{\delta U}{\delta t} + \frac{\delta F}{\delta x} = 0$$ where the flux F of the ...