如何在有限差分法中施加边界条件


14

我想使用高阶中心差近似值时遇到问题:

(ui+2,j+16ui+1,j30ui,j+16ui1,jui2,j12)

泊松方程

(uxx+uyy=0)
在边界条件为的平方域中:

Δ X = Δ ÿ = 0.1

u(0,y)=u(x,0)=u(x,1)=0,u(1,y)=sinπy
Δx=Δy=0.1

当我想获取域内部点的值时,考虑此近似值,某些点取决于边界的外部点。例如,需要具有的值ü - 2 Ĵ = Ü - 1 0点是的边界之外。在这种情况下,有人可以帮我吗? u1,1ui2,j=u1,0


1
我想您正在使用狄利克雷边界条件,对吗?
保罗

请说明您要施加的边界条件。
David Ketcheson '02

也许关键在于使用边界条件来获得涉及这些值的约束。我无法扩展,因为我从未尝试用数值方法求解PDE,但是这种想法适用于ODE。有人可以确认吗?
astrojuanlu 2012年

对于高阶方法,可能很难通过以这种方式填充幻像细胞来确保方法的稳定性。也就是说,根据我的经验,椭圆形问题通常会更宽容,因此您也许可以摆脱它。
杰里米·科兹登

1
liona,您可以编辑问题并在此处添加边界条件,这比在评论中添加边界条件要好得多。
David Ketcheson

Answers:


9

您可能需要研究按部分求和(SBP)的有限差分方法。Ken Mattsson在这些方法上做了很多工作。这里是一个好的起点(常数),并且此处(可变系数)。

基本上,这些方法的工作方式是它们是内部的标准中心方法,并且过渡到边界附近的一侧。SBP技术的一个重要部分是过渡到单面,这样即使在包含边界条件之后,也可以证明针对时间相关问题的方法的稳定性。(这是可能的,因为操作员自己“定义”了一个规范,该规范模仿了零件的离散集成。)

您说的是在看泊松方程,我不确定SBP算子和椭圆方程如何稳定地包含边界条件。我有一个同事在处理椭圆问题时玩过这些游戏,似乎表明您所做的事情并不重要。


8

您还可以使用其他模具在边界点附近获得高阶精度。您当前的模具的形式为:

Aui+2,j+Bui+1,j+Cui,j+Dui1,j+Eui2,j

但是,您也可以在边界附近使用不同的模具,如下所示:

Aui+3,j+Bui+2,j+Cui+1,j+Dui,j+Eui1,j

to compute the value at u1,1. Note that the coefficients in the second stencil will be different from the ones in the first formula.

Similarly, you can approximate the value at the opposite boundary by a similar formula.


Thank you for your answer, however how I can compute the value at u1,1 when I use only one type of difference approximation method? (i.e. Can it be correct that it is used different approximation types in different places?)
liona

How can I obtain the coefficients?
liona

2
To understand how to derive finite difference formulas, a good reference is Chapter 1 of Leveque's book: faculty.washington.edu/rjl/fdmbook. It amounts to Taylor series and a bit of algebra.
David Ketcheson

@liona: Yes, you can use different approximation formulas at different locations... Generally, it is more important to ensure that all of your formulas adhere to the order of truncation that you desire. That is, if you want your numerical solution to be of order O(h2), then all of your finite difference approximations must also have a truncation error of O(h2)
Paul

@liona: The book that David Ketcheson is referring to is one of the best books on the subject of finite difference method (in my honest opinion). As he states, we simply need to sum the taylor expansions for the expressions AU(x+h), BU(x), CU(xh), DU(x2h), and EU(x3h). Then, ensure that all the coefficients of the second derivative terms Uxx sum to 1, and as many other terms as possible sum to zero.
Paul

-4

please see my fdm paper which you can locate in researchgate under my name david Edwards jr. if you have questions I would be glad to help.

david


2
Simply giving instructions for people to search elsewhere is not a useful answer. At a minimum, you should provide a summary of the answer here and provide a link to more details. Furthermore, many of us disagree with the way ResearchGate is run and therefore avoid all interactions with that site, making it impossible to see your paper with your suggested method.
Doug Lipinski

Please revise your answer to include a summary of whatever background you think is needed to answer the question. Answers are meant to be relatively self-contained; referring a reader to search for one's paper is not self-contained, and is far less helpful than providing a summary of its contents.
Geoff Oxberry
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.