Mapping Functions |
xy2pol(x, y) or xy2pol(v) Converts the rectangular coordinates of a point (x, y) to polar coordinates (r, θ).
pol2xy(r, θ) or pol2xy(v) Converts the polar coordinates of a point (r, θ) to rectangular coordinates (x, y).
xyz2sph(x, y, z) or xyz2sph(v) Converts the rectangular coordinates of a point (x, y, z) to spherical coordinates (r, θ, φ).
sph2xyz(r, θ, φ) or sph2xyz(v) Converts the spherical coordinates of a point (r, θ, φ) to rectangular coordinates (x, y, z).
xyz2cyl(x, y, z) or xyz2cyl(v) Converts the rectangular coordinates of a point (x, y, z) to cylindrical coordinates (r, θ, z).
cyl2xyz(r, θ, z) or cyl2xyz(v) Converts the cylindrical coordinates of a point (r, θ, z) to rectangular coordinates (x, y, z).
Each function returns a three-element column vector with the new coordinates. Angles are given in radians.