figure 8 Klien bottle
eharetea

The Klein bottle is a closed nonorientable surface that has no inside or outside.

Houdini Math Geometry.

Date Created:Tuesday January 16th, 2007 12:18 AM
Date Modified:Saturday August 02nd, 2008 12:30 AM

Figure 8 Klein bottle

The "figure-8" form of the Klein bottle is obtained by rotating a figure eight about an axis while placing a twist in it, and is given by parametric equations
x(u,v) = [a+cos(1/2u)sin(v)-sin(1/2u)sin(2v)]cos(u)
y(u,v) = [a+cos(1/2u)sin(v)-sin(1/2u)sin(2v)]sin(u)
z(u,.v) = sin(1/2u)sin(v)+cos(1/2u)sin(2v)
for u in [0,2pi), v in [0,2pi), and a>2

In Houdini we can visualize with a \$ROWS*\$COLS grid
Create the variables u and v then enter the following the equations into the x,y,z pos parameters of a point SOP.
x pos = (2+cos(\$U/2)*sin(\$V)-sin(\$U/2)*sin(2*\$V))*cos(\$U)
y pos = (2+cos(\$U/2)*sin(\$V)-sin(\$U/2)*sin(2*\$V))*sin(\$U)
z pos = sin(\$U/2)*sin(\$V)+cos(\$U/2)*sin(2*\$V)
\$U = frac(\$PT/\$ROWS)*360 *\$COLS/(\$COLS-1)
\$V = floor(\$PT/\$ROWS)/(\$COLS-1)*360