%% Cylindrical to Cartesian Coordinates
% Convert the cylindrical coordinates defined by corresponding entries in the matrices theta, rho, and z to three-dimensional Cartesian coordinates x, y, and z.

theta = [0 pi/4 pi/2 pi]'

%

rho = [1 3 4 5]'

%

z = [7 8 9 10]'

%

[x,y,z] = pol2cart(theta,rho,z)

% Copyright 2012 The MathWorks, Inc.