Flow Along a Curve
By the way, if the curve f(x,y) is already parametrized as r(t)={x(t),y(t)},
then r'(t)={x'(t),y'(t)} is the tangent vector, so the unit tangent vector must
be
T(t)={x'(t),y(t)}/||{x'(t),y(t)}||
(Remember the vectorcalc1 notebook?)
Combining this with ds=||r'(t)|| dt yields
v.T ds = v.r'(t) dt
![]()
In[32]:=
Clear[v,f,r,flow]
v[x_,y_]:={x^2,-y^2}
f[x_,y_]:=x^2+y^2-9
In[33]:=
r[t_]:={3 Cos[t],3 Sin[t]}
In[34]:=
T=r'[t]/norm[r'[t]]
Out[34]=
-3 Sin[t] 3 Cos[t]
{---------------------------, ---------------------------}
2 2 2 2
Sqrt[9 Cos[t] + 9 Sin[t] ] Sqrt[9 Cos[t] + 9 Sin[t] ]
In[35]:=
Simplify[T]
Out[35]=
{-Sin[t], Cos[t]}
In[36]:=
integrand=(v[r[t][[1]],r[t][[2]]].T) norm[r'[t]]
Out[36]=
2 2
Sqrt[9 Cos[t] + 9 Sin[t] ]
2
-27 Cos[t] Sin[t]
(--------------------------- -
2 2
Sqrt[9 Cos[t] + 9 Sin[t] ]
2
27 Cos[t] Sin[t]
---------------------------)
2 2
Sqrt[9 Cos[t] + 9 Sin[t] ]
In[37]:=
Simplify[%]
Out[37]=
2 2
3 (-9 Cos[t] Sin[t] - 9 Cos[t] Sin[t] )
In[38]:=
flow=Integrate[integrand,{t,0,2 Pi}]
Out[38]=
0
Up to 2D Flows