Finite differencing on non-uniform grids

  • Context: Graduate 
  • Thread starter Thread starter hunt_mat
  • Start date Start date
  • Tags Tags
    Finite
Click For Summary
SUMMARY

The discussion centers on the challenges of applying finite differencing techniques on non-uniform grids, specifically using a five-point stencil for derivative calculations. The initial approach involved constructing a system of linear equations based on Taylor's theorem, leading to the inversion of a Vandermonde matrix. While the method yielded satisfactory results for first derivatives, it exhibited instability for higher derivatives. The participant also noted that a seven-point stencil performed even worse, prompting a request for insights into potential issues with the approach.

PREREQUISITES
  • Understanding of finite difference methods
  • Familiarity with Taylor's theorem
  • Knowledge of Vandermonde matrices
  • Experience with numerical stability in derivative calculations
NEXT STEPS
  • Investigate the stability of finite difference methods on non-uniform grids
  • Learn about the properties of Vandermonde matrices and their inversion
  • Explore alternative stencils for higher-order derivatives
  • Examine numerical methods for improving derivative accuracy
USEFUL FOR

Numerical analysts, computational scientists, and engineers working with finite difference methods and derivative calculations on non-uniform grids will benefit from this discussion.

hunt_mat
Homework Helper
Messages
1,816
Reaction score
33
Hi,

Recently I had to find a derivative on a uniform grid. Being naive I tried the following scheme:
[tex]f'(x_{n})=Af(x_{n+2})+Bf(x_{n+1})+Cf(x_{n})+Df(x_{n-1})+Ef(x_{n-2})[/tex]

Then write the [itex]f(x_{n\pm i})[/itex] in terms of [itex]f^{(n)}(x_{n})[/itex] by use of Taylor's theorem. This lead to a system of linear equations for the A,B,C,D,E which required inverting a Vandermonde matrix.

I tried it out a couple of times and it worked okay for the first derivative but when I applied it to higher derivatives it became unstable. Does anyone know what is going wrong?

I also tried a seven point stencil in the same way and that bizarrely was even worse.

Mat
 
Physics news on Phys.org
It might be helpful to look at the actual matrix you get for a case that causes trouble. It's probably also a good idea to do this for the smallest system possible. If you can see the problem play out on a system you could compute by hand, it might well give you an idea about what's going wrong.
 
Possibly, but I have tested the 7 point stencil on simple examples and have not got the answers which I should have. The five point stencil however works relative well for first order derivatives but not on higher derivatives (I think)
 

Similar threads

  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 36 ·
2
Replies
36
Views
8K
  • · Replies 7 ·
Replies
7
Views
5K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
Replies
2
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 2 ·
Replies
2
Views
4K
  • · Replies 71 ·
3
Replies
71
Views
14K