MuPAD Pro Computing Essentials, 2nd Edition

Example 8.10 Class Spherical

In this example I show how to use class Spherical to produce a plot in spherical coordinates.

h := (x,y,z,phi, theta)->[abs(1-sin(10*phi)),abs(sin(10*phi)),0]:
 
a := 1.3: 
b := 3:
 
Shell := plot::Spherical(
   [(a^phi)*sin(b*theta),phi,theta],
   phi = -1..2*PI, theta = 0..PI,
   Mesh = [50,50],
   FillColorFunction = h
):
 
MyCam := plot::Camera(
   [100,70,50],[0,0,-0.5], PI/45
):
 
plot(
   Shell, MyCam,
   Scaling = Constrained,
   Axes = None
)
 
Loading sample geometry.

JavaView Display

Use the mouse pointer to rotate the graphics. Right click on the picture will open a menu where we can select rotations, scaling, moving and a few other options.

More features of this graphics can be examined using full JavaView applet >>


© Miroslaw Majewski, Abu Dhabi,  Update  26-10-2004