> | restart; with( plots ): with( plottools ): with( Student[Calculus1] ): |
> |
Auxiliary Procedures (do not modify)
> | SpherePyramid := proc( N::posint ) local COLORS, layer; layer := proc( n, N, C ) local CTR, G; G := seq( -(n-1)+2*i, i=0..n-1 ); CTR := [seq( seq( [i,j,N+1-n], j=G ), i=G )]; return seq( sphere( c, 1, color=C ), c=CTR ); end proc: COLORS := [ red, blue, green, cyan, pink, magenta, navy, orange, violet, wheat ]: display( seq( layer( i, N, COLORS[i] ), i=1..N ), view=[-(N+2)..N+2,-(N+2)..N+2,-2..N+2], style=patchnogrid, axes=boxed ); end proc: |
> |
> | #SpherePyramid( 10 ); |
> |