How to smooth a 3d surface

How to smooth my 3d plot,i tried smooth function but it only works for 2dimensional.
Y is a 201x201 matrix
Y= [201 201]
x = 10:0.1:30;
z = 1:0.01:3;
[X,Z] = ndgrid(x,z);
mesh(X,Z,smooth(Y))

回答 (1 件)

Benjamin Kraus
Benjamin Kraus 2017 年 11 月 9 日

0 投票

Have you tried conv2?

1 件のコメント

Joseph Lee
Joseph Lee 2017 年 11 月 9 日
Sorry, I'm not sure how to use it, i got an error following an example.
x = 10:0.1:30;
z = 1:0.01:3;
[X,Z] = ndgrid(x',z);
mesh(conv2(X,Z,(Y_3D)))
Error using conv2
The first and second arguments must be vectors when the third argument is a matrix.

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeInterpolation of 2-D Selections in 3-D Grids についてさらに検索

タグ

質問済み:

2017 年 11 月 9 日

コメント済み:

2017 年 11 月 9 日

Community Treasure Hunt

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

Start Hunting!

Translated by