12.07.2015 Views

MATLAB Function Reference (Volume 2: Graphics)

MATLAB Function Reference (Volume 2: Graphics)

MATLAB Function Reference (Volume 2: Graphics)

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

cylinderPurpose2cylinderGenerate cylinderSyntaxDescription[X,Y,Z] = cylinder[X,Y,Z] = cylinder(r)[X,Y,Z] = cylinder(r,n)cylinder(...)cylinder generates x, y, and z coordinates of a unit cylinder. You can draw thecylindrical object using surf or mesh, or draw it immediately by not providingoutput arguments.[X,Y,Z] = cylinder returns the x, y, and z coordinates of a cylinder with aradius equal to 1. The cylinder has 20 equally spaced points around itscircumference.[X,Y,Z] = cylinder(r) returns the x, y, and z coordinates of a cylinder usingr to define a profile curve. cylinder treats each element in r as a radius atequally spaced heights along the unit height of the cylinder. The cylinder has20 equally spaced points around its circumference.[X,Y,Z] = cylinder(r,n) returns the x, y, and z coordinates of a cylinderbased on the profile curve defined by vector r. The cylinder has n equallyspaced points around its circumference.cylinder(...), with no output arguments, plots the cylinder using surf.Remarkscylinder treats its first argument as a profile curve. The resulting surfacegraphics object is generated by rotating the curve about the x-axis, and thenaligning it with the z-axis.2-116

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!