Constant Pressure Boundary Conditions for PDEPE solver

3 ビュー (過去 30 日間)
Jacob 2014 年 6 月 10 日
コメント済み: Bill Greene 2014 年 6 月 11 日
Thanks for sharing your knowledge and experience!
Could you please shed some light on defining boundary conditions using the PDEPE solver?
I want the left side to have constant pressure, but still allow pressure flux (open boundary). The right side needs to be a no flow boundary.
I'm having trouble conceptualizing the math & code of these conditions. The pdepe solver requires boundary conditions in the form p(x,t,u) + q(x,t)f(x,t,u,DuDx)=0
Here's my (incorrect) code:
function [pl,ql,pr,qr] = pdex4bc(xl,ul,xr,ur,t) pl = [ul(1)-1; ul(2)-(0.011237)]; ql = [0; 0]; pr = [0; 0]; qr = [1; 1];
The results of this code successly set the constant pressure at the left boundary, but they do not seem to allow any pressure flux through the left side.
Any comments/suggestions are greatly appreciated! Thanks for your time.
  5 件のコメント
Bill Greene
Bill Greene 2014 年 6 月 11 日
>The right side is atmospheric pressure( u1(1) + ul(2) - Patm = 0 )
I believe you mean left side.
The problem with this:
pl = [ul(1)+ul(2)-1; ul(1)+ul(2)-1];
is that you have only one independent BC on the left but you need two.
I assume you are just experimenting with this:
pl = [ul(1)+ul(2)-1;ul(2)-1];
since that is the same as this:
pl = [ul(1); ul(2)-1];
which is not what you want.
I'm unclear on the physics you are trying to represent so can't be of much help on that. But if you get the physics sorted out and are still having trouble expressing this for pdepe, let us know.


回答 (0 件)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by