tell me the code for how to place scatterrers in a cylindrical volume?

1 次查看(过去 30 天)
place different scatterrers in a cylindrical volume
  7 个评论
Walter Roberson
Walter Roberson 2016-10-18
Then my code below is a solution. You do not need to plot the X Y Z points if you do not want to. Adjust the radius and height parameters according to your needs. N is the number of points to generate. The K'th scatterrer is located at (X(K), Y(K), Z(K))
vinod kumar govindu
vinod kumar govindu 2016-10-18
编辑:Walter Roberson 2016-10-18
is this the way to create cylindrical volume?
X=[-1,1];
Y=[-1,1];
Z=[30,34];
cylinder=[X,Y,Z];
r=input('enter tha value of range gate=');
deltar=[r-2,r+2];
N=input('enter the value of number of scatterrers=');
s=rand(N,1);
if it is wrong help me how to create that ?

请先登录,再进行评论。

采纳的回答

Walter Roberson
Walter Roberson 2016-10-18
radius = 5;
height = 18;
N = 1000;
r = sqrt(rand(1,N)) * radius;
th = rand(1,N) * 2 * pi;
h = rand(1,N) * height;
[X, Y, Z] = pol2cart(th, r, h);
scatter3(X, Y, Z)
  3 个评论
vinod kumar govindu
vinod kumar govindu 2016-10-19
thanks roberson.
i am trying on one coding since last week i am not getting time series response properly. I will explain my project crearly will you please provide code for that if possible?

请先登录,再进行评论。

更多回答(0 个)

Community Treasure Hunt

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

Start Hunting!

Translated by