- /
-
3D spiral
on 26 Oct 2021
- 10
- 84
- 2
- 0
- 209
nr = 3; % number of revolutions
ex = 1/2; % shaping exponent, e.g. 1/2, 1, 2
t = 0:0.01:nr;
k = (0:0.01:1)';
x = k.*t.*cos(2*pi*t);
y = k.*t.*sin(2*pi*t);
z = (k.^ex).*ones(size(t));
figure('Color','k')
surf(x,y,z)
colormap cool
shading interp
lighting gouraud
camlight headlight
axis off