MATLAB: How can i ploting 3 function with 2 variables

3dplotingfunctionsvariables

Hi i have 3 function like this
x1=(5+sin(w1*t))*cos(w2*t), x2=(5+sin(w1*t))*sin(w2*t), x3=cos(w1*t)
the t variable is not important for me but w1 and w2 is change like this
w1/w2=4, w1/w2=0.25, w1/w2=5 ….
i want to plot this 3 function in 3D but i cant!!!!!!

Best Answer

Ok this seems to give some chaotic pattern.
t = 0:0.01:2*pi;
w2=linspace(0,20,length(t));
w1=4*w2;
m=w1.*t;
n=w2.*t;
x1=(5+sin(m)).*cos(n);
x2=(5+sin(m)).*sin(n);
x3=cos(m);
plot3(x1,x2,x3);
Related Question