pde - 如何在使用有限差分法求解 pde 集时修复 gPROMS 中的“系统结构奇异”错误?
问题描述
我是 gPROMS 的新手,并尝试使用 gPROMS 使用前向有限差分法求解给定的 pde 方程。
y"+z+y=0;
z'+y'=0;
y(0)=0, y'(0)=0, z(0)=1.
我已经为模型和流程编写了代码,如下所示:
变量类型
ANY (lower bound 0; upper bound 100)
型号(问题)
#Defining independent variable
DISTRIBUTION_DOMAIN
x_dom AS [ 0 : 10 ]
#Defining dependent variables
VARIABLE
y AS DISTRIBUTION(x_dom) OF ANY
z AS DISTRIBUTION(x_dom) OF ANY
#Bondary condition
Boundary
y(0)=0;
z(0)=1;
PARTIAL(y(0),x_dom)=0;
#Writing pdes
Equation
FOR x := 0|+ TO 10|- DO
PARTIAL(y(x),x_dom,x_dom)+z(x)+y(x)=0;
PARTIAL(z(x),x_dom)+PARTIAL(y(x),x_dom)=0;
END
流程
UNIT
P101 AS Problem
SET
#Discretization method
WITHIN P101 DO
x_dom:= [ FFDM, 1, 10 ] ;
END
结果
You need to ASSIGN 1 variable(s).
List of available variables:
P101.y(0.0) Algebraic (OUTPUT)
P101.y(1.0) Algebraic (OUTPUT)
P101.y(2.0) Algebraic (OUTPUT)
P101.y(3.0) Algebraic (OUTPUT)
P101.y(4.0) Algebraic (OUTPUT)
P101.y(5.0) Algebraic (OUTPUT)
P101.y(6.0) Algebraic (OUTPUT)
P101.y(7.0) Algebraic (OUTPUT)
P101.y(8.0) Algebraic (OUTPUT)
P101.y(9.0) Algebraic (OUTPUT)
P101.y(10.0) Algebraic (OUTPUT)
P101.z(0.0) Algebraic (OUTPUT)
P101.z(1.0) Algebraic (OUTPUT)
P101.z(2.0) Algebraic (OUTPUT)
P101.z(3.0) Algebraic (OUTPUT)
P101.z(4.0) Algebraic (OUTPUT)
P101.z(5.0) Algebraic (OUTPUT)
P101.z(6.0) Algebraic (OUTPUT)
P101.z(7.0) Algebraic (OUTPUT)
P101.z(8.0) Algebraic (OUTPUT)
P101.z(9.0) Algebraic (OUTPUT)
P101.z(10.0) Algebraic (OUTPUT)
WARNING: The system is structurally singular. gPROMS will try to weaken structural check and
resolve the singularity on solver's level.
Structural Analysis: performing wellposedness check...
Structural analysis has found an error in the system
我尝试添加一个变量,但它不起作用。我应该如何编写代码以免出错?
谢谢你。
解决方案
推荐阅读
- regex - 如何在欧芹数据欧芹模式中转义双引号?
- c# - 你如何在 C# 中转换我的列表?
- git - git rebase 反复要求我运行`git rebase --continue`
- vuejs2 - 使用点击事件条件渲染的组件渲染函数中可能存在无限更新循环
- jquery - 当通过 JQuery 发布数据时,nodejs API 中的 req.body 为空
- python - 如何在每次循环后重置列表?
- svg - 托管时不显示 SVG
- python-3.x - MongoEngine:运算符“__contains”不适用于非英文字母或单词
- react-native - 我想从另一个移动应用程序打开 Qliksense 移动应用程序
- ios - AdMob 刷新请求