11.07.2015 Views

Advanced Programming Guide

Advanced Programming Guide

Advanced Programming Guide

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

254 • Chapter 6: <strong>Programming</strong> with Maple GraphicsPOLYGONS([[ 1 3 , 1 3 , 1 ], [1, 0, 0], [0, 1, 0]],3[[ 1 3 , 1 3 , 1 3 ], [0, 1, 0], [0, 0, 1]], [[1 3 , 1 3 , 1 ], [0, 0, 1], [1, 0, 0]])3Since these POLYGONS belong in three-dimensional space, you mustput them inside a PLOT3D structure to display them.> PLOT3D( % );Again, you can extend the stellateFace procedure to work for arbitrarypolyhedra having more than one face.> stellate := proc( polyhedron, aspectRatio)> local v;> seq( stellateFace( v, evalf(aspectRatio) ),> v=polyhedron );> end proc:This constructs stellated polyhedra.> stellated := display( stellate( dodecahedron(), 3),> scaling= constrained ):> display( array( [dodecahedron(), stellated] ) );

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

Saved successfully!

Ooh no, something went wrong!