Re: Derivatives in Other Coord Systems
- To: mathgroup at smc.vnet.net
- Subject: [mg40249] Re: Derivatives in Other Coord Systems
- From: sodastereo at eudoramail.com (Julius Carver)
- Date: Fri, 28 Mar 2003 04:28:43 -0500 (EST)
- References: <b5rm2k$etq$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
It's very easy Ken. First you have to define the position vector in a coordinate system. For example in cylindrical coordinates In[1]:= << Calculus`VectorAnalysis` In[2]:= Rc[t] = CoordinatesToCartesian[{r[t], q[t], z}, Cylindrical] Out[2]= {Cos[q[t]] r[t], r[t] Sin[q[t]], z} or in spherical ones In[3]:= Rs[t] = CoordinatesToCartesian[{r[t], q[t], f[t]}, Spherical] Out[3]= {Cos[f[t]] r[t] Sin[q[t]], r[t] Sin[f[t]] Sin[q[t]], Cos[q[t]] r[t]} Then you have to derive these expressions one or two times to obtain the velocity or the acceleration respectively In[4]:= D[Rc[t], {t, 1}] Out[4]= {-(r[t] Sin[q[t]] q'[t]) + Cos[q[t]] r'[t], Cos[q[t]] r[t] q'[t] + Sin[q[t]] r'[t], 0} In[5]:= D[Rs[t], {t, 2}] Out[5]= {2 Cos[q[t]] q'[t] (-(r[t] Sin[f[t]] f'[t]) + Cos[f[t]] r'[t]) + 2 Cos[f[t]] r[t] (-(Sin[q[t]] q'[t] ) + Cos[q[t]] q''[t]) + 2 Sin[q[t]] (-2 Sin[f[t]] f'[t] r'[t] + r[t] (-(Cos[f[t]] f'[t] ) - Sin[f[t]] f''[t]) + Cos[f[t]] r''[t]), 2 Cos[q[t]] q'[t] (Cos[f[t]] r[t] f'[t] + Sin[f[t]] r'[t]) + 2 r[t] Sin[f[t]] (-(Sin[q[t]] q'[t] ) + Cos[q[t]] q''[t]) + 2 Sin[q[t]] (2 Cos[f[t]] f'[t] r'[t] + r[t] (-(Sin[f[t]] f'[t] ) + Cos[f[t]] f''[t]) + Sin[f[t]] r''[t]), -2 Sin[q[t]] q'[t] r'[t] + 2 r[t] (-(Cos[q[t]] q'[t] ) - Sin[q[t]] q''[t]) + Cos[q[t]] r''[t]}