⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 form_boundary.m

📁 快速泊松方程求解--MATLAB Fast Poisson Solver in a Square
💻 M
字号:
% Boundary conditions for poisson.m
% 
% Form the boundaries of the Dirichlet problem in a box.
% Here gb = bottom condition, gl = left cond., gr = right, gt = top.
% Used in poisson.m.  BOUNDARY CONDITIONS MUST BE CONTINUOUS
% make sure that if any of them are zero, that they are the length of x.
function [gb,gt,gl,gr] = Form_Boundary(x,y)
% gb is for u(x,0)
% gt is for u(x,endpoint)
% gl is for u(0,y)
% gr is for u(endpoint,y)

gb = (1/2).*sin(6*pi.*x);
gt = sin(pi*2.*x);
gl = 5.*y.*(y-1);
gr = -y.*((y-1).^4);
%
% Written by M. Harper Langston - 5/10/00
% harper@cims.nyu.edu
%

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -