Thursday 30 April 2015

Interesting proof of Heron's formula

Area of $\triangle ABC=\sqrt{s(s-a)(s-b)(s-c)}$, $s=\frac{1}{2}(a+b+c)$

$2s=2t+2(c-t)+2(b-t)$
$\begin{cases} s=b+c-t\:\:\:(1)\\2s=b+c+a\:\:\:(2)\end{cases}$
$(2)-(1), s=a+t \Rightarrow t=s-a$
$\text{From (1)}, s-b=c-t\:\text{and}\: s-c=b-t$

$\begin{cases}\tan \frac{A}{2}=\frac{R}{s-a} \\ \tan \frac{B}{2}=\frac{R}{s-b}\end{cases}\\
\Rightarrow \large \tan \frac{A}{2} \tan \frac{B}{2}=\frac{R^2}{(s-a)(s-b)}$

Similarly,
$\large{\tan \frac{A}{2} \tan \frac{C}{2}=\frac{R^2}{(s-a)(s-c)}\\
\tan \frac{B}{2} \tan \frac{C}{2}=\frac{R^2}{(s-b)(s-c)}}$

Adding all the three results,
$\large{\tan \frac{A}{2} \tan \frac{B}{2}+\tan \frac{A}{2} \tan \frac{C}{2}+\tan \frac{B}{2} \tan \frac{C}{2}\\
=R^2[\frac{1}{(s-a)(s-b)}+\frac{1}{(s-a)(s-c)}+\frac{1}{(s-b)(s-c)}]\\
=R^2[\frac{s-c+s-b+s-a}{(s-a)(s-b)(s-c)}]\\
=\frac{R^2s}{(s-a)(s-b)(s-c)}}$

Now, $A+B=\pi-C$.
$\frac{A}{2}+\frac{B}{2}=\frac{\pi}{2}-\frac{C}{2}\\
\large{\tan (\frac{A}{2}+\frac{B}{2})=\frac{1}{\tan \frac{C}{2}}\\
\frac{\tan \frac{A}{2}+\tan \frac{B}{2}}{1-\tan \frac{A}{2} \tan \frac{B}{2}}=\frac{1}{\tan \frac{C}{2}}\\
\tan \frac{A}{2} \tan \frac{C}{2}+\tan \frac{B}{2} \tan \frac{C}{2}=1-\tan \frac{A}{2} \tan \frac{B}{2}\\
\tan \frac{A}{2} \tan \frac{B}{2}+\tan \frac{A}{2} \tan \frac{C}{2}+\tan \frac{B}{2} \tan \frac{C}{2}=1}$
$\large{\therefore 1=\frac{R^2s}{(s-a)(s-b)(s-c)}\\
R=\sqrt{\frac{(s-a)(s-b)(s-c)}{s}}}$

Area of $\triangle ABC=\frac{1}{2}(aR+bR+cR)=sR=\sqrt{s(s-a)(s-b)(s-c)}\:\Box$

Wednesday 22 April 2015

Interesting probability problems

Birthday problem
"Find the probability that, in a group of n people, there is at least one pair of people who have the same birthday."
In a leap year, there are 366 days. By the pigeonhole principle, the probability that there is at least two people sharing the same birthday will be 1 when there are 367 people. [If we have more than one people having the same birthday among those 367 people, then of course the probability is one. If the 366 people each has a different birthday, the last person (367th person) will have a birthday coinciding one of those 366, hence the result.]
In fact, the probability reaches 0.99 in a group of 70 people, whereas in a group of 23, the probability becomes 0.5. The calculations are as follows:
Let's say there are 365 days in a year.
In a room of n people,
$\text{P(no two people share the same birthday)}$
$\large =365/365\cdot 364/365\cdot 363/365\cdot \ldots \cdot[365-(n-1)]/365\\
\Large =\frac{365\:\cdot\:364\:\cdot\:363\:\cdot\: \ldots \:\cdot\: [365-(n-1)]}{365^n}\\
\Large =\frac{P^{365}_n}{365^n}$

Monty Hall problem
"Suppose you're on a game show, and you're given the choice of three doors: Behind one door is a car; behind the others, goats. You pick a door, say No. 1, and the host, who knows what's behind the doors, opens another door, say No. 3, which has a goat. He then says to you, "Do you want to pick door No. 2?" Is it to your advantage to switch your choice?"
The answer is you should always swap because doing so doubles the probability of winning the car.
If you do not swap, you have 1/3 chance of winning the car and 2/3 chance of winning a goat.
What if you swap? If at first you pick a goat door (2/3 chance) and you swap, you have 1/2 chance of wining the car. And if at first you pick a car door and swap, you get a goat. So overall, the probability of winning the car if you swap is $2/3\cdot 1/2 + 2/3\cdot 1/2 = 2/3$, which is twice the probability of winning the car if you do not swap.

A similar counterintuitive probability problem

Sock Drawer
"A drawer contains red socks and black socks. When two socks are drawn at random, the probability that both are red is $\frac{1}{2}$. (a) How small can the number of socks in the drawer be? (b) How small if the number of black socks is even?"
Let there be r red and b black socks.
P(first sock is red) = $\Large \frac{r}{r+b}$
P(two socks are both red) = $\frac{1}{2}$, which means $\Large \frac{r}{r+b}\cdot \frac{r-1}{r+b-1}=\frac{1}{2}$.
We can plug in different values of r and b to get the answers, but that is not a wise way of approaching this problem.
It turns out we can reach the answers by using inequalities.
Notice that $\Large \frac{r}{r+b}>\frac{r-1}{r+b-1}$ for $b>0$.
So we can create the inequalities
$\Large (\frac{r-1}{r+b-1})^2 < \frac{1}{2} < (\frac{r}{r+b})^2$
$\Large \frac{r-1}{r+b-1} < \frac{1}{\sqrt{2}} < \frac{r}{r+b}$ --(*)
From the first inequality of (*), $(\sqrt{2}+1)b>r-1$.
From the second, $r>\frac{1}{\sqrt{2}}(r+b)$ or $r>\frac{1}{\sqrt{2}-1}b=(\sqrt{2}+1)b$
Finally, $(\sqrt{2}+1)b<r<(\sqrt{2}+1)b+1$
For $b=1$, $r>2.414$ and $r<3.414$, so the candidate is $r=3$. For $r=3$ and $b=1$, $\text{P(2 red socks)}=3/4\cdot 2/3=1/2$, thus the smallest number of socks is 4.
Now for even values of b,
$\begin{array}{c|c|c|c} b & \text{r is between} & \text{eligible r} & \text{P(2 red socks)} \\ \hline 2 & 4.8,\:\:5.8 & 5 & \frac{5\cdot 4}{7\cdot 6} \neq \frac{1}{2}\\ 4 & 9.7,\:\:10.7 & 10 & \frac{10\cdot 9}{14\cdot 13} \neq \frac{1}{2} \\ 6 & 14.5,\:\:15.5 & 15 & \frac{15\cdot 14}{21\cdot 20}=\frac{1}{2} \end{array}$
So 15+6=21 socks is the smallest number when b is even.
Related: Number Theory -- Diophantine Analysis

Geometric distribution
A brilliant proof of its expected value:
When the first outcome is a failure (with probability $1-p=q$), the mean number of trials required is $1+E(X)$, and when the first outcome is a success (with probability $p$), the mean number is $1$. $\therefore E(X)=p(1)+q[1+E(X)] \Rightarrow E(X)=1+qE(X) \Rightarrow E(X)=\frac{1}{1-q}=\frac{1}{p}$

More:
http://www.quora.com/What-are-the-most-interesting-or-popular-probability-puzzles-in-which-the-intuition-is-contrary-to-the-solution

Reference:
Fifty challenging problems in probability by F. Mosteller

Saturday 18 April 2015

Geometry of lines and planes II

Equation of a line through a line with position vector $\vec{a}$ parallel to $\vec{b}$



Vector form
$\vec{r}=\vec{a}+\lambda\vec{b},\lambda \in \mathbb{R}$

Cartesian form
$\vec{r}=(x,y,z), \vec{a}=(a_1,a_2,a_3), \vec{b}=(b_1,b_2,b_3)$
$(x,y,z)=(a_1+\lambda b_1,a_2+\lambda b_2,a_3+\lambda b_3)$
$\Rightarrow x=a_1+\lambda b_1, y=a_2+\lambda b_2, z=a_3+\lambda b_3$

If $b_1,b_2,b_3 \neq 0$, then eliminating $\lambda$ from these equations yields
$\frac{x-a_1}{b_1}=\frac{y-a_2}{b_2}=\frac{z-a_3}{b_3}(=\lambda)$

Example:
Equation of line through $(-2,0,5)$ parallel to $(1,2,-3)$
$\frac{x+2}{1}=\frac{y}{2}=\frac{z-5}{-3} \Rightarrow 3y=6x+12=10-2z$

Example:
Equation of line through $(1,2,3)$ parallel to $(-2,0,5)$
Note that $b_2=0$ in this case.
$x=1-2\lambda, y=2+0\lambda, z=3+5\lambda$
Eliminating $\lambda \Rightarrow y=2, \frac{1-x}{2}=\frac{z-3}{5}$
Thus, the equations are $y=2, 5x+2z=11$.

Remark: Both equations are needed to describe the line. Each equation on its own describes a plane. The required line is the intersection of these two planes.



Equation of a line through two points



$\vec{AB}=\vec{b}-\vec{a}$

Vector form
$\vec{r}=\vec{a}+\lambda(\vec{b}-\vec{a})=(1-\lambda)\vec{a}+\lambda\vec{b}, \lambda \in \mathbb{R}$

Cartesian form
$x=a_1+\lambda(b_1-a_1), y=a_2+\lambda(b_2-a_2), z=a_3+\lambda(b_3-a_3)$
or $\Large \frac{x-a_1}{b_1-a_1}=\frac{y-a_2}{b_2-a_2}=\frac{z-a_3}{b_3-a_3}$ if the denominators are non-zero.

Example:
Prove that medians of a triangle are concurrent.



Proof:
Let $\vec{a}$ be the position vector from the origin to A, $\vec{b}$ be the position vector from the origin to B, and so on.
Then $\vec{f}=\frac{1}{2}(\vec{a}+\vec{b}),\vec{e}=\frac{1}{2}(\vec{b}+\vec{c}),\vec{e}=\frac{1}{2}(\vec{a}+\vec{c})$
Any point on the line BE is given by $(1-\lambda)\vec{b}+\lambda\frac{1}{2}(\vec{a}+\vec{c})$.
Similarly, any point on AD is $(1-\mu)\vec{a}+\mu\frac{1}{2}(\vec{b}+\vec{c})$.
Since $G$ lies on both of these lines, we have $(1-\lambda)\vec{b}+\lambda\frac{1}{2}(\vec{a}+\vec{c})=(1-\mu)\vec{a}+\mu\frac{1}{2}(\vec{b}+\vec{c})$.
$\Rightarrow 1-\lambda=\frac{\mu}{2}$ and $\frac{\lambda}{2}=1-\mu$
$\Rightarrow \lambda=\mu=\frac{2}{3}$
Therefore $G=\frac{1}{3}(\vec{a}+\vec{b}+\vec{c})$.
Finally, check that G lies on CF.



Equation of plane through the origin and parallel to $\vec{a}$ and $\vec{b}$



$\vec{r}=\lambda\vec{a}+\mu\vec{b}, \lambda, \mu \in \mathbb{R}$



Equation of plane through C parallel to $\vec{a}$ and $\vec{b}$

A general plane can be specified by giving two vectors which lie on the plane and the position vector of a point lying on the plane.



$\vec{r}=\vec{OP}=\vec{OC}+\vec{CP}=\vec{c}+\lambda\vec{a}+\mu\vec{b}, \lambda, \mu \in \mathbb{R}$



Equation of plane through points $\vec{a},\vec{b},\vec{c}$

We can also specify a plane uniquely by giving 3 non-collinear points which lie on it.


$\vec{r}=\vec{a}+\lambda(\vec{b}-\vec{a})+\mu(\vec{c}-\vec{a})=(1-\lambda-\mu)\vec{a}+\lambda\vec{b}+\mu\vec{c}, \lambda, \mu \in \mathbb{R}$



Equation of plane in terms of normal to the plane


Projection of $OP$ onto $ON=\vec{r}\cdot\hat{n}=p$
Let $\hat{n}=(a,b,c), \vec{r}=(x,y,z)$
$ax+by+cz=p$

Key point:
One parameter is needed to write the equation of a line and two parameters are needed for that of a plane.

More

Friday 17 April 2015

Geometry of lines and planes I

Distance of two points in 3 dimensions
$|P_1P_2|=\sqrt{(x_2-x_1)^2+(y_2-y_1)^2+(z_2-z_1)^2}$
$\begin{align}|P_1P_2|^2 &=|P_1B|^2+|BP_2|^2\\&=|P_1A|^2+|AB|^2+|BP_2|^2\\&=(x_2-x_1)^2+(y_2-y_1)^2+(z_2-z_1)^2\end{align}$

Direction cosine
$\vec{a}=\langle a_1,a_2,a_3 \rangle$
The angles $\alpha,\beta,\gamma$ in $[0,\pi]$ that $\vec{a}$ makes with $x,y,z$ axes respectively are direction angles of $\vec{a}$.
$\Large\cos \alpha=\frac{\vec{a}\cdot \hat{i}}{|\vec{a}||\hat{i}|}=\frac{\langle a_1,a_2,a_3 \rangle \cdot \langle 1,0,0 \rangle}{|\langle a_1,a_2,a_3 \rangle||\langle 1,0,0 \rangle|}=\frac{a_1}{|\vec{a}|}$
Similarly, $\large \cos \beta=\frac{a_2}{|\vec{a}|}$ and $\large \cos \gamma=\frac{a_3}{|\vec{a}|}$.
Thus, $\vec{a}=|\vec{a}|\langle \cos\alpha,\cos\beta,\cos\gamma \rangle$
Note also that $\cos^2\alpha+\cos^2\beta+\cos^2\gamma=\frac{1}{|\vec{a}|^2}(a_1^2+a_2^2+a_3^2)=1$

Dot product in component form
Cosine Law: $\begin{align} |\vec{a}-\vec{b}|^2&=|\vec{a}|^2+|\vec{b}|^2-2|\vec{a}||\vec{b}|\cos \theta\\ &=|\vec{a}|^2+|\vec{b}|^2-2\vec{a}\cdot\vec{b}\end{align}$
$\begin{align} \vec{a}\cdot \vec{b}&=|\vec{a}||\vec{b}|\cos \theta\\
&=\frac{1}{2}(|\vec{a}|^2+|\vec{b}|^2-|\vec{a}-\vec{b}|^2)\\&=\frac{1}{2}[a_1^2+a_2^2+a_3^2+b_1^2+b_2^2+b_3^2-(a_1-b_1)^2-(a_2-b_2)^2-(a_3-b_3)^2]\\&=a_1b_1+a_2b_2+a_3b_3 \end{align}$

Projections
scalar projection of $\vec{b}$ onto $\vec{a}$:
$\large \text{comp}_\vec{a} \vec{b}=|\vec{b}|\cos \theta=\frac{\vec{a}\cdot \vec{b}}{|\vec{a}|}=\frac{\vec{a}}{|\vec{a}|}\cdot \vec{b}$
vector projection of $\vec{b}$ onto $\vec{a}$:
$\large \text{proj}_\vec{a} \vec{b}=\frac{\vec{a}\cdot \vec{b}}{|\vec{a}|} \cdot \frac{\vec{a}}{|\vec{a}|}=\frac{\vec{a}\cdot \vec{b}}{|\vec{a}|^2} \vec{a}$

Scalar triple product
volume of a parallelepiped $V=Ah=|\vec{b}\times\vec{c}||\vec{a}|\cos \theta=|\vec{a}\cdot (\vec{b} \times \vec{c})|$
The base parallelogram can be determined by [$\vec{b}$ and $\vec{c}$] or [$\vec{a}$ and $\vec{b}$].
Also, because of the commutative property of dot products, we have $\vec{a}\cdot (\vec{b} \times \vec{c})=(\vec{a} \times \vec{b}) \cdot \vec{c}$.

symmetric equation, vector equation, scalar equation of the plane through a point with normal vector, linear equation

skew lines

More to know [later]
Orthogonal projection
$\large \text{ortho}_\vec{a} \vec{b}=\vec{b}-\text{proj}_\vec{a} \vec{b}$

Parallelogram Law
$|\vec{a}+\vec{b}|^2+|\vec{a}-\vec{b}|^2=2|\vec{a}|^2+2|\vec{b}|^2$
geometric meaning

Vector and chemistry
Bond angle 109.5

Vector triple product
$\vec{a}\times\vec{b}\times\vec{c}=(\vec{a}\cdot\vec{c})\vec{b}-(\vec{a}\cdot\vec{b})\vec{c}$
$\Rightarrow \vec{a}\times(\vec{b}\times\vec{c})+\vec{b}\times(\vec{c}\times\vec{a})+\vec{c}\times(\vec{a}\times\vec{b})=\vec{0}$

$(\vec{a}\times\vec{b})\cdot(\vec{c}\times\vec{d})=\begin{vmatrix}\vec{a}\cdot\vec{c} & \vec{b}\cdot\vec{c}\\ \vec{a}\cdot\vec{d} & \vec{b}\cdot\vec{d} \end{vmatrix}$

crystallography

Useful:
http://www.math.jhu.edu/~hhaosu/Teaching/0607FCalcIII/
http://www.math.jhu.edu/~hhaosu/Teaching/0607FCalcIII/06FMA261AHW02Sol.pdf
http://www.leadinglesson.com/problem-on-orthogonal-matrices

Friday 10 April 2015

Parametrizations

Line segments
Given two points $a,b$ in $\Bbb C$,the line segment $ab$ has parametric equation $$\color{blue}{z(t)=(1-t)a+tb},\quad t\in [0,1].$$
Circles
We know the rectangular equation for a circle with center at the origin: $$x^2+y^2=r^2.$$ The equality also holds when we substitute $$\color{blue}{x=r\cos t,\quad y=r\sin t}.$$ What about parametrizing a circle with center $(a,b)$? We have $$(x-a)^2+(y-b)^2=r^2.$$ We can put $$\color{blue}{x=r\cos t+a,\quad y=r\sin t+b}.$$ In the complex plane, we have $$z(t)=re^{it},\quad t\in [0,2\pi]$$ for circles with center at the origin and $$\color{blue}{z(t)=z_0+re^{it}},\quad t\in [0,2\pi]$$ for circles with center $z_0$.

Ellipses
A ellipse is the set of points $P$ such that the sum of whose distances from two fixed points (the foci $F_1$ and $F_2$) separated by a distance $2c$ is a given positive constant $2a$. It is given by $$\{P:|d(P,F_1)+d(P,F_2)|=2a\}.$$ When $F_1=(-c,0)$ and $F_2=(c,0)$, we have $$\bigg\{(x,y) \;\bigg|\; \dfrac{x^2}{a^2}+\dfrac{y^2}{b^2}=1\bigg\}, \quad b=\sqrt{c^2-a^2}$$ with parametrization $$\color{blue}{x=a\cos t, \quad y=b\sin t},\quad t\in [0,2\pi]$$
Hyperbolas
A hyperbola is the set of points $P$ in a plane that the difference of whose distances from two fixed points (the foci $F_1$ and $F_2$) separated by a distance $2c$ is a given positive constant $2a$. It is given by $$\{P:|d(P,F_1)-d(P,F_2)|=2a\}.$$ When $F_1=(-c,0)$ and $F_2=(c,0)$, we have $$\bigg\{(x,y)\;\bigg| \;\dfrac{x^2}{a^2}-\dfrac{y^2}{b^2}=1\bigg\}, \quad b=\sqrt{c^2-a^2}.$$ Recall that $\cosh^2 t-\sinh^2 t=1$. The right branch is parametrized by $$\color{blue}{x=a\cosh t,\quad y=b\sinh t},\quad t\in (-\infty,\infty).$$ The left branch is parametrized by $$\color{blue}{x=-a\cosh t,\quad y=b\sinh t},\quad t\in (-\infty,\infty).$$
More to know
Lemniscates
A lemniscate is the set of points $P$ in a plane that the product of whose distances from two fixed points (the foci $F_1$ and $F_2$) a distance $2c$ away is the constant $c^2$.

Minimal surfaces of revolution
Let $\gamma:I\to \Bbb R^2$ be a parametrized curve of the form $\gamma(t)=(t,y(t))$ for some smooth function $y:I\to \Bbb R$ with $y(t)>0$ for all $t\in I$. The surface obtained by rotating $\gamma $ about the $x$-axis is given by $$\phi(t,\theta)=(t,y(t)\cos\theta,y(t)\sin\theta).$$ Reference
Parametric curves

Thursday 2 April 2015

Naming quadric surfaces

Non-degenerate real quadric surfaces
$\frac{x^2}{a^2}+\frac{y^2}{b^2}-z=0\\
z=\frac{x^2}{a^2}+\frac{y^2}{b^2}$
Consider the horizontal cross section (level curve) of z by setting $z=c$.
We have $\frac{x^2}{a^2}+\frac{y^2}{b^2}=c$, which is the equation for an ellipse.
Now consider the vertical cross section of z at $x=c$.
We get $z=\frac{c^2}{a^2}+\frac{y^2}{b^2}$ -- a constant plus $\frac{y^2}{b^2}$, which is the equation of a parabola. Similarly, the vertical cross section of z at $y=c$ is also a parabola.
We know that the figure is a elliptical paraboloid.

When we change b (denominator) to a, we have a circular paraboloid.

$\frac{x^2}{a^2}-\frac{y^2}{b^2}-z=0\\
z=\frac{x^2}{a^2}-\frac{y^2}{b^2}$
Horizontal cross section: $\frac{x^2}{a^2}-\frac{y^2}{b^2}=c\:\:[z=c]\Rightarrow$ hyperbola
Vertical cross section: $\frac{x^2}{a^2}- \text{constant}$ or $\text{constant} - \frac{y^2}{b^2} \Rightarrow$ parabola
Surface: Hyperbolic paraboloid

$\frac{x^2}{a^2}+\frac{y^2}{b^2}-\frac{z^2}{c^2}=1$
Horizontal cross section: $\frac{x^2}{a^2}+\frac{y^2}{b^2}=\frac{k^2}{c^2}+1\:\:[z=k] \Rightarrow$ ellipse
Vertical cross section: $\frac{x^2}{a^2}-\frac{z^2}{c^2}=1-\frac{m^2}{b^2}\:\:[y=m]$ or $\frac{y^2}{b^2}-\frac{z^2}{c^2}=1-\frac{n^2}{a^2}\:\:[x=n] \Rightarrow$ hyperbola
Surface: Elliptical hyperboloid of one sheet

$\frac{x^2}{a^2}+\frac{y^2}{b^2}-\frac{z^2}{c^2}=-1$
Horizontal cross section: $\frac{x^2}{a^2}+\frac{y^2}{b^2}=\frac{k^2}{c^2}-1\:\:[z=k] \Rightarrow$ generally ellipse
There are no horizontal cross sections when z is between -1 and 1. For simplicity, we can look at the equation $-x^2-y^2+z^2=1$. Suppose $z=0$. Then the left hand side is negative, but the right hand side is positive. There's no way to fix this, so the cross section simply doesn't exist!
Vertical cross section: $\frac{z^2}{c^2}-\frac{x^2}{a^2}=1+\frac{m^2}{b^2}\:\:[y=m]$ or $\frac{z^2}{c^2}-\frac{y^2}{b^2}=1+\frac{n^2}{a^2}\:\:[x=n] \Rightarrow$ hyperbola
Surface: Elliptical hyperboloid of two sheets

Here's a hint about telling the two kinds of hyperboloids apart: look at the cross sections x=0, y=0, and z=0 (respectively but not simultaneously). If they exist, then it's a hyperboloid of one sheet. If you end up with something negative equal to something positive, it's a hyperboloid of two sheets.

Degenerate quadric surfaces
$\frac{x^2}{a^2}+\frac{y^2}{b^2}-\frac{z^2}{c^2}=0$
Horizontal cross section: $\frac{x^2}{a^2}+\frac{y^2}{b^2}=\frac{k^2}{c^2}\:\:[z=k] \Rightarrow$ ellipse
Vertical cross section:
(1) $\frac{z^2}{c^2}-\frac{x^2}{a^2}=\frac{m^2}{b^2}\:\:[y=m]$ or $\frac{z^2}{c^2}-\frac{y^2}{b^2}=\frac{n^2}{a^2}\:\:[x=n] \Rightarrow$ hyperbola
(2) $\frac{x^2}{a^2}-\frac{z^2}{c^2}=0\:\:[y=0]$ or $\frac{y^2}{b^2}-\frac{z^2}{c^2}=0\:\:[x=0]$ $\iff (\frac{x}{a}-\frac{z}{c})(\frac{x}{a}+\frac{z}{c})=0$ or $(\frac{y}{b}-\frac{z}{c})(\frac{y}{b}+\frac{z}{c})=0 \Rightarrow$ pair of straight lines
Surface: Elliptic Cone

$\frac{x^2}{a^2}+\frac{y^2}{a^2}-\frac{z^2}{b^2}=0$ -- Special case of cone (Circular cone)
$\frac{x^2}{a^2}+\frac{y^2}{b^2}=1$ -- Elliptic cylinder
$\frac{x^2}{a^2}+\frac{y^2}{a^2}=1$ -- Circular cylinder
$\frac{x^2}{a^2}-\frac{y^2}{b^2}=1$ -- Hyperbolic cylinder

Useful website:
Quadric surfaces

Wednesday 1 April 2015

Directional derivatives

The partial derivatives $f_x(x_0,y_0)$ and $f_y(x_0,y_0)$ are the rate of changes of $z=f(x,y)$ at $(x_0,y_0)$ in the positive x- and y- directions. Rate of change in other directions are given by directional derivatives. In fact, the partial derivatives of f with respect to x and y are just special cases of the directional derivative.

To find the directional derivatives of $z=f(x,y)$ at $(x_0,y_0)$ in the direction of the unit vector $\vec{u}=\langle u_1, u_2 \rangle$ in the xy-plane, we introduce an s-axis with its origin at $(x_0,y_0)$, with its positive direction in the direction of $\vec{u}$. Then the point at s on the s-axis has xy-coordinates $x=x_0+su_1, y=y_0+su_2$, and the value of $z = f(x, y)$ at the point s on the s-axis is $F(s)=f(x_0+su_1,y_0+su_2)$. We call $z=F(s)$ the cross section through $(x_0,y_0)$ of $z=f(x,y)$ in the direction of $\vec{u}$.



If the origin is not $(0,0)$, we introduce a second vertical z-axis (in blue) with its origin at the point $(x_0, y_0,0)$ (the origin on the s-axis). Then the graph of $z=F(s)$ is the intersection of the surface $z=f(x,y)$ with the sz-plane. The directional derivative of $z=f(x,y)$ is the slope of the tangent line to this curve in the positive s-direction at s = 0, which is at the point $(x_0, y_0, f(x_0, y_0))$.



The directional derivative [denoted $D_{\vec{u}}f(x_0,y_0)$] of $z=f(x,y)$ at $(x_0,y_0)$ in the direction of the unit vector $\vec{u}=\langle u_1,u_2 \rangle$ is the derivative of the cross section function (1) at $s=0$:
$D_{\vec{u}}f(x_0,y_0)=\frac{d}{ds}f(x_0+su_1,y_0+su_2)|_{s=0}$

For any unit vector $u=\langle u_1,u_2 \rangle$, the (directional) derivative of $z=f(x, y)$ at $(x_0, y_0)$ in the direction of $\vec{u}$ is $D_{\vec{u}}f(x_0,y_0)=f_x(x_0,y_0)u_1+f_y(x_0,y_0)u_2$

Proof:
$F'(s)\\=\frac{d}{ds}[f(x_0+su_1,y_0+su_2)]\\=f_x(x_0+su_1,y_0+su_2)\frac{d}{ds}(x_0+su_1)+f_y(x_0+su_1,y_0+su_2)\frac{d}{ds}(y_0+su_2)\\=f_x(x_0+su_1,y_0+su_2)u_1+f_y(x_0+su_1,y_0+su_2)u_2\\=f_x(x_0,y_0)u_1+f_y(x_0,y_0)u_2 \:\:\text{[put s=0]}$