       Re: Normal Disappear Problem

• To: mathgroup at smc.vnet.net
• Subject: [mg55325] Re: Normal Disappear Problem
• From: Roland Franzius <roland.franzius at uos.de>
• Date: Sat, 19 Mar 2005 04:45:35 -0500 (EST)
• Organization: Universitaet Hannover
• References: <d1ecv2\$evi\$1@smc.vnet.net>
• Sender: owner-wri-mathgroup at wolfram.com

```gouqizi.lvcha at gmail.com schrieb:
> Hi, All:
>
> I have the following parametric equation for an unit sphere:
>
> x = cos(u)sin(v)
> y = sin(u)sin(v)
> z = cos(v)
>
> 0<=u<2*Pi ; 0<=v<=Pi
>
> Then I use
>
> normal = (Dx/Du, Dy/Du, Dz/Du) CROSS (Dx/Dv, Dy/Dv, Dz/Dv) to get the
> normal vector.
>
> I get the follwoing after calculation (with normalization):
>
> normal =  [sin(v) ^2 cos(u), sin(v)^2  sin(u), cos(u)^2  cos(v) sin(v)
> +  sin(u)^2  cos(v) sin(v)]
>
> Now when u=0, v=0 , Normal = (0,0,0)! How can it be? We know the fact
> that a sphere should have normal everywhere.

Use normalized tangent vectors

X = {Cos[u]Sin[v],Sin[u]Sin[v],Cos[v]};

t1 = D[X, #] & /@ {u, v};

t2 = t1/Sqrt[Dot[#, #] & /@ t1] // TrigExpand // FullSimplify //
PowerExpand;

t3 = Cross @@ t2

{(-Cos[u])*Sin[v], (-Sin[u])*Sin[v], (-Cos[u]^2)*Cos[v] - Cos[v]*Sin[u]^2}

Dot[t3, t3] // FullSimplify
1

The u-direction tangent vector t1[] is 0 at the poles v=0,pi
corresponding to the fact of no east direction there. Normalizing t
makes the cross product normal unit vector constant even at the poles.

--

Roland Franzius

```

• Prev by Date: Re: Normal Disappear Problem
• Next by Date: Re: Normal Disappear Problem
• Previous by thread: Re: Normal Disappear Problem
• Next by thread: plotting weighted graphs