\documentclass[12pt]{article}
\usepackage{graphicx}
\usepackage{enumerate}
\usepackage{ifthen}
\usepackage{amsmath}
\usepackage{amssymb}

\usepackage{tikz,pgfplots}
\pgfplotsset{compat=1.12}

%\pagestyle{empty}
\topmargin -1in
%\topmargin -0.25in
\oddsidemargin -0.5in
\evensidemargin -0.5in
\textheight 9.25in
\textwidth 7.25in 

\newcommand{\comp}{ \,{\scriptstyle \stackrel{\circ}{}}\, } 
\newcommand{\nullset}{\mathrm{O}\!\!\!\!\big/\,}

\newcommand{\la}{\langle}
\newcommand{\ra}{\rangle}

\newcommand{\force}{{$\mbox{\,}$}}
\newcommand{\B}[1]{{\bf #1}}
\newcommand{\bdot}{{\,\bullet\,}}


%\pagestyle{empty}

\newcounter{mycounter}
\setcounter{mycounter}{0}

\begin{document}

\begin{center}
\Large \sc Differential Geometry \& Line Integrals:\\Notation \& Formulas Review \end{center}

%\vspace{0.1in}


\begin{itemize} \setlength{\itemsep}{1pt}
\item Let $C$ be an oriented curve parameterized by ${\bf r}(t) = \la x(t),y(t),z(t) \ra$ where $a \leq t \leq b$.
\item $-C$ denotes the curve $C$ with its orientation (i.e., direction) reversed. We let $C_1+C_2$ denote curve $C_1$ and curve $C_2$ joined together. Such curves don't have to be connected. More generally, $-3C_1+5C_2$ is the curves where we travel along $C_1$ backwards 3 times and then run along $C_2$ a total of 5 times.
\item Define $\displaystyle{s(t) = \int_a^t |{\bf r}'(u)|\,du}$. This is the {\it arc length} function. 

{\it Note:} $s(a)=0$, \fbox{$\displaystyle s(b) = \int_a^b |\B r '(t)|\,dt$} is the total arc length of $C$, and by the second part of the fundamental theorem of calculus $\dfrac{ds}{dt}=|\B r '(t)|$ so that we define \fbox{$ds = |\B r '(t)|\,dt$} to be the arc length element used in the definition of line integrals with respect to arc length.

\item \fbox{$\B T(t) = \dfrac{\B r '(t)}{|\B r '(t)|}$} is the {\it unit Tangent}, \fbox{$\B N(t) = \dfrac{\B T '(t)}{|\B T '(t)|}$} is the {\it unit Normal}, and \fbox{$\B B(t) = \B T(t) \times \B N(t)$} is the {\it Binormal}. For every $t$ (where these are defined), they are mutually perpendicular (i.e., $\B T \bdot \B N=0$, $\B N \bdot \B B=0$, and $\B B \bdot \B T =0$) unit vectors (i.e., $|\B T|=|\B N|=|\B B|=1$). This TNB-frame forms a right handed system -- much like a variable $\B i \B j \B k$ triple. In particular, $\B T \times \B N = \B B$, $\B N \times \B B = \B T$, and $\B B \times \B T = \B N$. We can think of $\B T$ as pointing forward, $\B N$ pointing left, and $\B B$ pointing up. Just like decomposing a vector into $\B i$, $\B j$, and $\B k$-components, every vector can be decomposed into $\B T$, $\B N$, and $\B B$-components.

\item Curvature is given by $\kappa = \left|\dfrac{d\B T}{ds}\right| = \dfrac{|\B T '(t)|}{|\B r '(t)|} = \dfrac{|\B r '(t) \times \B r ''(t)|}{|\B r '(t)|^3}$. The first formula shows that $\kappa$ depends only on the shape of the curve (not the particular parameterization). The second formula is easy to use when the TNB-frame has already been computed. Generally, the third formula is easiest to apply if we are computing curvature from scratch. 

Curvature measures how bent a curve is. If $C$ is a circle of radius $R$, we have \fbox{$\kappa = \dfrac{1}{R}$} (larger circles are less bent). We also have \fbox{$\kappa(t) = 0$ for all $t$ $\Longleftrightarrow$ $C$ is a line or a line segment}. 

{\it Note:} Even when $\B r(t)$ is many times differentiable, its TNB-frame may not exist (at least at certain points). Specifically, if $\B T'(t_0)=\B 0$, we cannot normalize $\B T'(t_0)=\B 0$ and so the unit normal and binormal will not exist for such a $t=t_0$. In fact, keeping in mind $\kappa = |\B T'|/|\B r'|$, we have that a sufficiently differential curve will have a well-defined TNB-frame at $t=t_0$ if and only if $\kappa(t_0) \not=0$. 

\item For a particular $t=t_0$, the plane which is parallel to $\B T(t_0)$ and $\B N(t_0)$ (and thus perpendicular to $\B B(t_0)$) and through the point $\B r(t_0)$ is called the {\it osculating plane} at $\B r(t_0)$. Such a plane has vector formula, $\B B(t_0) \bdot (\la x,y,z \ra - \B r(t_0))=0$. [osculating plane = kissing plane]

We can paramterize the line tangent to $C$ at $\B r(t_0)$ by $\vec \ell(t) = \B r(t_0) + \B r'(t_0)t$ or $\vec \ell(t) = \B r(t_0) + \B T(t_0)t$. The circular version of the tangent line is called a osculating circle or circle of curvature. The {\it  osculating circle} at $\B r(t_0)$ is the circle lying in the osculating plane at $\B r(t_0)$ whose curvature matches the curvature of $C$ at that point and whose center lies in the unit normal direction from $\B r(t_0)$. Specifically, this circle can be parameterized by\dots \[\B c(t) = \underbrace{\B r(t_0)+\dfrac{1}{\kappa(t_0)}\B N(t_0)}_{\mbox{the circle's center}} + \dfrac{1}{\kappa(t_0)}\cos(t)\B T(t_0) + \dfrac{1}{\kappa(t_0)}\sin(t)\B N(t_0)\]

\item If we think of $\B r(t)$ as the position of a particle, then $\B v(t) = \B r'(t)$ is its velocity, $|\B r'(t)|$ is its speed, and $\B a(t) = \B r''(t)$ is its acceleration. Decomposing acceleration into its TNB-frames components we have \fbox{$\B r''(t) = a_T(t)\B T(t) + a_N(t)\B N(t) + 0\B B(t)$} where $a_T(t)$ and $a_N(t)$ are the {\it tangential and normal components of acceleration}. Notice that the binormal component of acceleration is always identically $0$ (this has important physical consequences). 

{\it Note:} We have direct formula for these components. $a_T(t) = \dfrac{\B r'(t) \bdot \B r''(t)}{|\B r'(t)|}$ and $a_N(t) = \dfrac{|\B r'(t) \times \B r''(t)|}{|\B r'(t)|}$. If you have already computed curvature using the cross product formula, you've nearly computed these components as well.

\item Using $\kappa = |\B T'|/|\B r'|$ and $\B N = \B T'/|\B T'|$, is immediately follows that $\B T'(t) = \kappa(t)|\B r'(t)|\B N(t)$. It turns out that $\B B'(t)$ is also parallel to $\B N(t)$. We can define a function $\tau(t)$, called the {\it torsion} of $C$, by requiring \fbox{$\B B'(t) = -\tau(t)|\B r'(t)|\B N(t)$}. It can also be shown that $\B N'(t) = -\kappa(t)|\B r'(t)|\B T(t)+\tau(t)|\B r'(t)|\B B(t)$. These formulas for the derivatives of the $\B T$, $\B N$, and $\B B$ are called the Frenet-Serret formulas.

Torsion is a measurement of how the binormal changes. Since the binormal determines how the osculating plane is tilted, if $\B B'(t)=\B 0$, then $\B B(t)$ is constant and thus the osculating plane is constant as well. Since points on our curve near $\B r(t_0)$ nearly lie in the osculating plane at $\B r(t_0)$, we can only have a constant osculating plane when our curve is planar. Therefore, \fbox{$\tau(t)=0$ for all $t$ $\Longleftrightarrow$ $\B B'(t)=\B 0$ $\Longleftrightarrow$ $\B B(t)$ is constant $\Longleftrightarrow$ $C$ is a planar curve}.

Much like curvature, there is a relatively simple formula for torsion: $\tau(t) = \dfrac{(\B r'(t) \times \B r''(t)) \bdot \B r'''(t)}{|\B r'(t) \times \B r''(t)|^2}$.

\item Line integrals with respect to arc length (i.e., of scalar valued functions) compute net area of a sheet under a surface (or hyper-surface): \fbox{$\displaystyle \int_C f(x,y,z)\,ds = \int_a^b f(\B r(t))|\B r'(t)|\,dt$}.  Specifically, we let $ds = |{\bf r}'(t)|\,dt = \sqrt{(x'(t))^2+(y'(t))^2+(z'(t))^2}\,dt$, $x = x(t)$, $y = y(t)$, and $z = z(t)$.

{\it Note:} The value of $\int_C f(x,y,z)\,ds$ is independent of the choice of paramterization for $C$. In fact, it does not even depend on the orientation of $C$: $\int_{-C} f(x,y,z)\,ds = \int_C f(x,y,z)\,ds$.

Just as $\int_a^b 1\,dx = b-a$ is the length of the interval $I=[a,b]$, we have \fbox{$\displaystyle{\int_C 1\,ds = \mbox{Arc Length of } C}$}.
\end{itemize}

\newpage

\noindent
{\large\bf Center of mass}\\
Suppose we have a wire bent in the shape of the curve $C$ and suppose this wire has density $\delta(x,y,z)$ at each point $(x,y,z)$ along
the curve. Then if we focus on a little segment of the wire where the density is roughly constant, the mass of the segment of wire will
be approximately $\delta(x_0,y_0,z_0) \Delta s$ where $\Delta s$ is the length of this piece of the wire. So if we add up $\Sigma \delta \Delta s$ we should
get the total mass of the wire (approximately anyway). Translating to the world of integrals we have\dots
\begin{itemize} \setlength{\itemsep}{1pt}
   \item The total {\it mass} of the wire is $\displaystyle{m = \int_C \delta(x,y,z)\,ds}$
   \item Let $\displaystyle M_{yz}=M_{x=0} = \int_C x\,\delta(x,y,z)\,ds$. We call $M_{yz}$ the {\it moment about the $yz$-plane}. This is a weighted sum of $x$-coordinates.
            Likewise, $\displaystyle M_{xz}=M_{y=0} = \int_C y\,\delta(x,y,z)\,ds$ and $\displaystyle M_{xy}=M_{x=0} = \int_C z\,\delta(x,y,z)\,ds$ are {\it moments about the $xz$- and $xy$-planes} respectively. These compute weighted sums of $y$ and $z$ coordinates.
   \item Finally, $\displaystyle (\bar{x},\bar{y},\bar{z}) = \left(\dfrac{M_{yz}}{m},\dfrac{M_{xz}}{m},\dfrac{M_{xy}}{m}\right)$ is the {\it center of mass} of $C$ with density function $\delta$. The coordinates of the center of mass are weighted averages of $x$, $y$, and $z$ coordinates on the curve. 
\item If $\delta(x,y,z)=c= \mbox{ constant } \not= 0$, then $\delta$ will cancel out of the computation of the center of mass (in such a case we can just take $\delta=1$ in the formulas).
         In the case of a constant density function, we call the center of mass $(\bar{x},\bar{y},\bar{z})$ the {\it centroid} of $C$. This is a geometric center of our curve.
\end{itemize}

\vspace{0.1in}

\noindent
{\bf Example:} Let $C$ be the helix parameterized by ${\bf r}(t) = \la \cos(t),\sin(t),\sqrt{3}t \ra$ for $0 \leq t \leq 2\pi$. We will find the centroid of $C$ (i.e., let $\delta=1$).

First, ${\bf r}'(t) = \la -\sin(t),\cos(t),\sqrt{3} \ra$ so $|{\bf r}'(t)| = \sqrt{(-\sin(t))^2+(\cos(t))^2+(\sqrt{3})^2} = \sqrt{4}=2$. Thus $ds = 2\,dt$.
The mass (= arc length) of $C$ is $\displaystyle m = \int_C 1\,ds = \int_0^{2\pi} 2\,dt = 4\pi$
\[ \bar{x} = \frac{1}{m}\int_C x\,ds = \frac{1}{4\pi} \int_0^{2\pi} \cos(t) 2\,dt = 0 \qquad \qquad
    \bar{y} = \frac{1}{m}\int_C y\,ds = \frac{1}{4\pi} \int_0^{2\pi} \sin(t) 2\,dt = 0 \]
\[ \bar{z} = \frac{1}{m}\int_C z\,ds = \frac{1}{4\pi} \int_0^{2\pi} \sqrt{3}t 2\,dt = \frac{\sqrt{3}}{4\pi} \int_0^{2\pi} 2t\,dt = 
   \frac{\sqrt{3}}{4\pi} t^2 \Big|_0^{2\pi} =  \frac{\sqrt{3}}{4\pi} (2\pi)^2 - 0 = \pi\sqrt{3} \approx 5.4414 \]
Notice the helix's $z$-coordinates range from $z=0$ to $z=\sqrt{3} \cdot 2 \pi$ so $\bar{z}$ is exactly half way between
$0$ and $\sqrt{3} \cdot 2\pi$ (looking at a picture of this helix should convince you that this is the right answer).

\noindent {\bf Answer:} $(\bar{x},\bar{y},\bar{z}) = (0,0,\pi\sqrt{3})$

\vspace{-0.1in}

\force \hfill
\begin{tikzpicture}[scale=0.7]
\begin{axis}
[   view={50}{5},
    enlargelimits=false,
    %title={Test Axis},
      z label style={rotate=-90},
      xlabel={$x$},
      ylabel={$y$},
      zlabel={$z$},
      xticklabels={,,},
      yticklabels={,,},
      zticklabels={,,}
]
  
\addplot3[domain=0:2*pi+0.01,samples=100,samples y=0,color=blue,ultra thick] 
		({cos(deg(x))},
		 {sin(deg(x))},
		 {sqrt(3)*x)});

% add in markers along the curve.		 
\addplot3[
    only marks,
    mark=ball,
    visualization depends on=\thisrow{alignment} \as \alignment,
    nodes near coords, 
    point meta=explicit symbolic, % The meta data used in the nodes is not explicitly provided and not numeric
    every node near coord/.style={anchor=\alignment} % Align each coordinate at the anchor XX degrees clockwise from the right edge
    ] table[x expr=cos(deg(\thisrowno{0}*(2*pi))), 
                y expr=sin(deg(\thisrowno{0}*(2*pi))), 
                z expr=sqrt(3)*\thisrowno{0}*(2*pi),    % Provide data as a table
     meta index=1 % the meta data is found in the second column
    ] {
t   label  alignment
0  ${\bf r}(0)$  -15
0.25  ${\bf r}(\pi/2)$ 30 
0.5  ${\bf r}(\pi)$ 70 
0.75  ${\bf r}(3\pi/2)$ -15 
1  ${\bf r}(2\pi)$ -10 
};

\node[label={0:{$\;\;(0,0,\pi\sqrt{3})$}},circle,fill,inner sep=2pt,color=red] at (axis cs:0,0,5.44) {};

\end{axis}
\end{tikzpicture}
\hfill \force


\newpage

\begin{center}
{\Large \sc Supplemental Problems:} 
\end{center}

\vspace{0.2in}

\begin{enumerate}
\item $\displaystyle{\int_C 3x^2yz\,ds}$ where $C$ is the curve parameterized by $\displaystyle{{\bf r}(t)=\left\la t,t^2,\frac{2}{3}t^3\right\ra}$ and $0 \leq t \leq 1$.

\item $\displaystyle{\int_C xy^4\,ds}$ where $C$ is the right half of the circle centered at the origin of radius 2.

\item $\displaystyle{\int_C x^2z\,ds}$ where $C$ is the line segment from $(0,6,-1)$ to $(4,1,5)$.

\item $\displaystyle{\int_C \frac{x}{1+y^2}\,ds}$ where $C$ is the line segment $x=1+2t$, $y=t$ where $0 \leq t \leq 1$.

\item $\displaystyle{\int_C \frac{e^{-z}}{x^2+y^2}\,ds}$ where $C$ is the helix $\displaystyle{{\bf r}(t) = \left\la 2\cos(t),2\sin(t),t\right\ra}$ and $0 \leq t \leq 2\pi$.

\item Find the centroid of the helix $C$ param. by $\B r(t) = \la 4\sin(t), 3t, 4\cos(t) \ra$ where $-2\pi \leq t \leq 4\pi$.

\item Find the centroid of the helix $C$ param. by $\displaystyle{{\bf r}(t) = \left\la 2\sin(t),2\cos(t),3t\right\ra}$ where $0 \leq t \leq \pi$.

\item Find the centroid of the right half of the circle $x^2+y^2=9$.

\item Find the centroid of the part of the circle $x^2+y^2=25$ in the first quadrant.

\item Find the centroid of the curve $C$: the upper-half of the unit circle plus the $x$-axis from $-1$ to $1$.\\
          {\it Hint:} Use geometry and symmetry to compute 2 of the 3 line integrals.

\end{enumerate}

\noindent {\bf Answers:}

\vspace{-0.1in}

\begin{enumerate}
\item $ds = 2t^2+1\,dt$ \qquad $\displaystyle \int_0^1 (4t^9+2t^7)\,dt =$ \fbox{$\dfrac{13}{20}$}

\vspace{-0.2in}

\item $\B r(t) = \la 2\cos(t), 2\sin(t) \ra$, $-\pi/2 \leq t \leq \pi/2$, $ds=2\,dt$ \qquad $\displaystyle \int_{-\pi/2}^{\pi/2} 64\sin^4(t)\cos(t)\,dt =$ \fbox{$\dfrac{128}{5}$}

\vspace{-0.1in}

\item $\B r(t) = \la 0,6,-1 \ra+\la 4,-5,6 \ra t$, $0 \leq t \leq 1$, $ds = \sqrt{77}\,dt$ \qquad $\displaystyle \int_0^1 16t^2(6t-1)\sqrt{77}\,dt =$ \fbox{$\dfrac{56\sqrt{77}}{3}$}

\vspace{-0.2in}

\item $ds = \sqrt{5}\,dt$ \qquad $\displaystyle \int_0^1 \dfrac{2t+1}{t^2+1}\sqrt{5}\,dt =$ \fbox{$\sqrt{5}\ln(2)+\dfrac{\sqrt{5}}{4}\pi$}

\vspace{-0.1in}

\item $ds = \sqrt{5}\,dt$ \qquad $\displaystyle \int_0^{2\pi} \dfrac{\sqrt{5}}{4}e^{-t}\,dt =$ \fbox{$\dfrac{\sqrt{5}}{4}(1-e^{-2\pi})$}

\vspace{-0.1in}

\item $ds = 5\,dt$, $m=30\pi$ \qquad \fbox{$(\bar{x},\bar{y},\bar{z}) = (0, 3\pi ,0)$}

\vspace{-0.1in}

\item $ds = \sqrt{13}\,dt$, $m=\sqrt{13}\pi$ \qquad \fbox{$(\bar{x},\bar{y},\bar{z}) = (4/\pi, 0, 3\pi/2)$}

\vspace{-0.1in}

\item $ds = 3\,dt$, $m=3\pi$ \qquad \fbox{$(\bar{x},\bar{y}) = (6/\pi, 0)$}

\vspace{-0.1in}

\item $ds = 5\,dt$, $m=5\pi/2$ \qquad \fbox{$(\bar{x},\bar{y}) = (10/\pi, 10/\pi)$}

\vspace{-0.1in}

\item $m = \pi+2$ (half-circle plus line segment), symmetry: $\bar{x}=0$, $M_x = \int_0^\pi \sin(t)\,dt+\int_{-1}^1 0\,dt =2$ \qquad \fbox{$(\bar{x},\bar{y}) = (0,2/(2+\pi))$} 

\end{enumerate}


\end{document}
