How to solve the problem?
1 回表示 (過去 30 日間)
古いコメントを表示
I got my solution(poisson's equation). and I wanted to draw 3D plot of this solution. but I want to keep (b -equation parameter)as a constant . i did it. is it wrong or right?. i got my curve but it seems,it didn"t start by following initial condition.. how can I do that? here,is my code and equation. ( i'm new here. if any mistake,plz consider it)
x=0:.01:2;
y=0:.01:2;
b=0.5;[X, Y]=meshgrid(x, y);
uxy=zeros(size(X));
for a=1:2
m=a^2;
pn=(16*m*sinh(pi*Y/2*a).*cos(pi*X/2*a))/(pi^3*sinh(pi*b/2));
uxy=(m- X.^2)/2-pn;
end
surf(X, Y,uxy)
0 件のコメント
採用された回答
Alan Stevens
2021 年 4 月 25 日
Like this?
x=0:.1:2;
y=0:.1:2;
b=0.5;[X, Y]=meshgrid(x, y);
uxy=zeros(size(X));
for a=1:2
m=a^2;
pn=(16*m*sinh(pi*Y/2*a).*cos(pi*X/2*a))/(pi^3*sinh(pi*b/2));
uxy=(m- X.^2)/2-pn;
figure
surf(X, Y,uxy)
end
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Animation についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!