function PtPlot(t,X)
%--------------------------
% This script generates a plot of the point set
%--------------------------
switch t
    case 1
        x1=linspace(0,1,70);
        [x2,x3]=meshgrid(x1);
        x3=(2*pi).*x3;
        U=x2.*cos(x3);
        V=x2.*sin(x3);
        T=x2;
    case 2
        x1=linspace(0,1,70);
        [x2,x3]=meshgrid(x1);
        x2=(2*pi).*x2;
        x3=1-2.*x3;
        U=cos(x2);
        V=sin(x2);
        T=x3;
    case 3
        x1=linspace(0,1,70);
        [x2,x3]=meshgrid(x1);
        x2=(2*pi).*x2;
        x3=(2*pi).*x3;
        U=(2+cos(x2)).*cos(x3);
        V=(2+cos(x2)).*sin(x3);
        T=sin(x2);
    case 4
        x1=linspace(0,1,70);
        [x2,x3]=meshgrid(x1);
        x2=pi.*x2;
        x3=(2*pi).*x3;
        U=sin(x2).*cos(x3);
        V=sin(x2).*sin(x3);
        T=cos(x2);
end

figure;
surf(U,V,T);
colormap gray
alpha(0.8)
shading flat
axis tight
hold on;
plot3(X(:,1),X(:,2),X(:,3),'b.','MarkerSize',18);
hold off;
end