Contact
CoCalc Logo Icon
StoreFeaturesDocsShareSupport News AboutSign UpSign In
| Download

Parametric surfaces homework for Calc 3

Views: 67

Parametric surfaces homework

In this homework, you will design a parametric surface, pick a point on the surface, and calculate and plot the normal vector to the surface at that point.

To design a parametric surface, you need a vector function of two variables r(u,v)\mathbf{r}(u,v), and a region RR in the uvuv-plane:

%var u v r = vector(((1-u)*(3 + cos(v))*cos(4*pi*u), (1-u)*(3+cos(v))*sin(4*pi*u), 3*u + (1-u)*sin(v)))
show(r)
((u1)(cos(v)+3)cos(4πu),(u1)(cos(v)+3)sin(4πu),(u1)sin(v)+3u)\displaystyle \left(-{\left(u - 1\right)} {\left(\cos\left(v\right) + 3\right)} \cos\left(4 \, \pi u\right),\,-{\left(u - 1\right)} {\left(\cos\left(v\right) + 3\right)} \sin\left(4 \, \pi u\right),\,-{\left(u - 1\right)} \sin\left(v\right) + 3 \, u\right)

As an example, we will use the above vector function to map the rectangle 0u10 \le u \le 1 and πvπ-\pi \le v \le \pi:

region_plot([0 <= u, u <= 1, -pi <= v, v <= pi],(u,-1,2),(v,-4,4))

to the following surface:

surface = parametric_plot3d(r,(u,0,1),(v,-pi,pi)) surface
3D rendering not yet implemented

Next we will find a point on the surface, for example one corresponding to u=1/2u = 1/2 and v=π/3v = \pi/3:

pt = r(u=1/2,v=pi/3) pt
(7/4, 0, 1/4*sqrt(3) + 3/2)

We can plot the surface together with the point:

surface + point(pt,color="black")
3D rendering not yet implemented

The next task will be to find normal vector at the point. We will start by finding ru\mathbf{r}_u and rv\mathbf{r}_v:

ru = r.diff(u) rv = r.diff(v)
show(ru)
(4π(u1)(cos(v)+3)sin(4πu)(cos(v)+3)cos(4πu),4π(u1)(cos(v)+3)cos(4πu)(cos(v)+3)sin(4πu),sin(v)+3)\displaystyle \left(4 \, \pi {\left(u - 1\right)} {\left(\cos\left(v\right) + 3\right)} \sin\left(4 \, \pi u\right) - {\left(\cos\left(v\right) + 3\right)} \cos\left(4 \, \pi u\right),\,-4 \, \pi {\left(u - 1\right)} {\left(\cos\left(v\right) + 3\right)} \cos\left(4 \, \pi u\right) - {\left(\cos\left(v\right) + 3\right)} \sin\left(4 \, \pi u\right),\,-\sin\left(v\right) + 3\right)
show(rv)
((u1)cos(4πu)sin(v),(u1)sin(4πu)sin(v),(u1)cos(v))\displaystyle \left({\left(u - 1\right)} \cos\left(4 \, \pi u\right) \sin\left(v\right),\,{\left(u - 1\right)} \sin\left(4 \, \pi u\right) \sin\left(v\right),\,-{\left(u - 1\right)} \cos\left(v\right)\right)

Evaluate them at u=1/2u = 1/2 and v=π/3v = \pi/3:

ru_at_point = ru(u=1/2, v=pi/3) rv_at_point = rv(u=1/2, v=pi/3)

and find their cross product, which will be a normal vector to the surface at the given point:

n = ru_at_point.cross_product(rv_at_point)
%md Finally, we plot the surface together with the normal vector: 27bb3999-06c6-443f-9c8b-536a3c056bfcs︠ surface + arrow(pt,pt+n,color="red")
3D rendering not yet implemented

To make the plot nicer, we can rescale the normal vector, for example we can normalize it to get a unit normal vector:

n = n.normalized()
surface + arrow(pt,pt+n,color="red")
3D rendering not yet implemented

Your turn:

Your task is to create your own parametric surface. You will get extra points for a cool looking or interesting surface. Pick a point on your surface, calculate the normal vector at the point, and plot the surface together with the normal vector, just like it is done above.

Turn the homework in the same way as you did with the past homework. The due date is December 10, the last day of classes.

︠3aa59845-4e33-48c8-a0d0-ac648ea39f94︠