Graphing III: 
Graphics3D Primitives

\(Needs["Graphics`Master`"]; 
Needs["Calculus`Master`"]; \)

Primitives

Graphics3D[{PointSize[.25], Point[{0, 0, 0}]}]

Show[%];

You can also use "Line", "Polygon", and "Text" in Graphics3D.

\(\(pieces = 24; 

    Show[Graphics3D[
	
        Table[
		
          Polygon[{{Cos[t], Sin[t], 0}, {Cos[t + \((2  π)\)/pieces], 
                Sin[t + \((2  π)\)/pieces], 0}, {0, 0, 2}}], {t, 
            \((2  π)\)/pieces, 2  π, \((2  π)\)/pieces}]
	]
]; 
    
							\)\)

\(\(pieces = 30; 

    Show[Graphics3D[
	
        Prepend[
			
          Table[
		
            Polygon[{{Cos[t], Sin[t], 0}, 

                	{Cos[t + \((2  π)\)/pieces], 
                  Sin[t + \((2  π)\)/pieces], 0}, 
	{0, 0, 2}}], 

            	{t, \((2  π)\)/pieces, 2  π, \((2  π)\)/pieces}], 

          			Polygon[{{\(-1\), \(-1\), 0}, {1, \(-1\), .5}, {1, 1, 1}, {
                \(-1\), 1, .5}}]]
	]
]; 
							\)\)

A new primitive is the "Cuboid"

Show[Graphics3D[Cuboid[{0, 0, 0}, {1, 1, 1}]], Axes -> True];

\(\(Show[
      Graphics3D[
		
        Table[Cuboid[{a = Random[Real, {\(-10\), 9}], 
              b = Random[Real, {\(-10\), 9}], 
              c = Random[Real, {\(-10\), 9}]}, {a + 1, b + 1, c + 1}], 

          			{50}]
	], Axes -> True]; \)\)

You can color the surface of a polygon, but this only works, if you set "Lighting->False":

\(\(pieces = 5; 

    Show[Graphics3D[
	
        Table[
		{Red, 
            Polygon[{{Cos[t], Sin[t], 0}, {Cos[t + \((2  π)\)/pieces], 
                  Sin[t + \((2  π)\)/pieces], 0}, {0, 0, 2}}]}, {t, 
            \((2  π)\)/pieces, 2  π, \((2  π)\)/pieces}]
	], 
      Lighting -> False
]; 
							\)\)

"EdgeForm[...]" determines the style for the edges of the polygon.

\(\(pieces = 5; 

    Show[Graphics3D[
	
        Table[
		{Red, EdgeForm[AbsoluteThickness[4], Blue], 
            Polygon[{{Cos[t], Sin[t], 0}, {Cos[t + \((2  π)\)/pieces], 
                  Sin[t + \((2  π)\)/pieces], 0}, {0, 0, 2}}]}, {t, 
            \((2  π)\)/pieces, 2  π, \((2  π)\)/pieces}]
	], 
      Lighting -> False
]; 
							\)\)

Polygons with more than three vertices will be triangulated:

\(\(Show[
      Graphics3D[
        Polygon[

          		{	{\(-1\), \(-1\), 0}, {\(-1\), 1, 1}, {1, 1, 0}, {1, \(-1\), 
              1}\ }
		]], Axes -> True, 
      ViewPoint -> {0.996, \ 3.225, \ 0.245}, AxesLabel -> {x, y, z}]; \)\)

An Example

ParametricPlot3D[{Cos[2  π t], Sin[2 π t], t}, {t, 0, 
        5.5}];

\(\(Show[
      Graphics3D[
		
        Table[{AbsoluteThickness[4], RGBColor[t/5.5, 0, 1 - t/5.5], 
            Line[{{Cos[2  π\ t], Sin[2  π\ t], t}, {
                  Cos[2  π \((t + .01)\)], Sin[2  π\ \((t + .01)\)], 
                  t + .01}}]}, {t, 0, 5.5 - .01, .01}]
	], Axes -> True, 
      ViewPoint -> {3.219, \ 0.069, \ 1.040}]; \)\)

\(\(Show[
      Graphics3D[
		
        Table[{AbsoluteThickness[3], GrayLevel[1 - \((t/5.5)\)^2], 
            Line[{{Cos[2  π\ t], Sin[2  π\ t], t}, {
                  Cos[2  π \((t + .01)\)], Sin[2  π\ \((t + .01)\)], 
                  t + .01}}]}, {t, 0, 5.5 - .01, .01}]
	], Axes -> True, 
      ViewPoint -> {3.219, \ 0.069, \ 1.040}, BoxRatios -> {1, 1, 1}]; \)\)

Etc

Helmut Knaust, email: helmut@math.utep.edu. Created 3-11-1999.