DMelt:Math/2 Parametric Functions

From HandWiki

Parametric functions

Parametric functions can be constructed using the Java class jhplot.FPR jhplot.FPR. The variables "u" and "v" are parametric variables used to build "x,y,z". To display such functions, use the canvas jhplot.HPlot3DP jhplot.HPlot3DP.

Lets us show an example of creating two parametric function:

from java.awt import Color
from jhplot import *

c1 = HPlot3DP("Canvas",600,600,2,1)
c1.setGTitle('3D surfaces')

f1=FPR('u=2 Pi u; z=1.5*(v-.5); x=z cos(u)*.8-0; y=z sin(u)*.8+0')
f2=FPR('u=2 Pi u; x=cos(u)*.5+.1; y=sin(u)*.5+.1; z=1.5*(v-.5)'),1)

The output of this script is shown here

DMelt example: Two parametric functions on 2 pads using HPlot3DP canavs

As you can see, one can overlay several functions on top of each other and set the transparency level.

Here are some examples: