1

This question may sound mathematical, but it's more of a programming question related to discretization, so I decided to ask it here.

The problem is to find a 2nd order finite difference approximation of the partial derivative uxy, where u is a function of x and y.

Page 5 of this pdf I found does a centered difference approximation it in two steps. It first does the 2nd order centered finite-difference approximation of one of the partials, and then inserts the approximation of the second partial into it (using the same formula):

enter image description here

Inserting lines 2 and 3 into 1 gives (according to the pdf) the following:

enter image description here

The last O[(Δx)2,(Δy)2] is what I have a problem with. Notice that when the O(Δy)2 terms of lines 2 and 3 go into the numerator of 1, they are being divided by the Δx in the denominator. So how come the residual terms in line 3 are of O(Δy)2 instead of O(Δy2/Δx)? Would this be a '2nd order' approximation any more? (If, say, grid-spacing along both axes are the same (Δx=Δy=h), the term is of order h2/h =h, not h2.)

My suggestion would be to use a higher order approximation (3rd or more) in lines 2 and 3 in order to survive the division by Δx and still have the final expression in 2nd order. But I may be missing something here.

4

2 回答 2

1

如果我没记错的话,如果你在泰勒展开式中写出更多的项,很快就会发现高阶项被抵消掉了。也就是说,在 (1) 的分子中替换 (2) 和 (3) 后得到的“O(dy)^2 - O(dy)^2”实际上确实变为零。

于 2014-04-07T00:44:14.400 回答
0

您有两个一阶斜率,它们结合起来给出一阶平面。通过组合两个斜率得到 (∂u/∂x)*(∂u/∂y),您不会在顺序方面获得任何收益。

这仍然是一阶近似值,如果需要,您将需要在有限差分中使用更多点以获得更高阶项。

我认为 (∂²u/∂x∂y) 的符号使事情变得混乱。使用两个一阶运算符的乘积可以更清楚地了解正在发生的事情。

于 2014-04-07T00:45:09.133 回答