hi
this script must plot a square, but i got the attached plot, how to connect all lines?
thanks
vhat1=[x,repmat(2,length(y),1),repmat(2,length(z),1)];
vhat2=[(x),repmat(-2,length(y),1),repmat(2,length(z),1)];
vhat3=[repmat(2,length(x),1),y,repmat(2,length(z),1)];
vhat4=[repmat(-2,length(x),1),y,repmat(2,length(z),1)];
vhatt=[vhat1;vhat2;vhat3;vhat4];

4 件のコメント

darova
darova 2020 年 6 月 24 日
what about thi simple way?
[x,y] = pol2cart(deg2rad(0:90:360),1);
line(x,y,x*0)
Oday Shahadh
Oday Shahadh 2020 年 6 月 24 日
its great, can put it in 3d space?
darova
darova 2020 年 6 月 24 日
Its in 3d already. What do you mean?
Oday Shahadh
Oday Shahadh 2020 年 6 月 24 日
x,y,z

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

回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange2-D and 3-D Plots についてさらに検索

タグ

質問済み:

2020 年 6 月 23 日

コメント済み:

2020 年 6 月 24 日

Community Treasure Hunt

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

Start Hunting!

Translated by