Skip to content
Snippets Groups Projects

Add lecture notes for coordinates

Merged Michael Wimmer requested to merge coordinates into master
+ 138
64
@@ -2,21 +2,37 @@
title: Coordinates
---
# Coordinates
## Cartesian coordinates
# Cartesian coordinates
The most common coordinates are *Cartesian coordinates*, where we use a
number $n$ of perpendicular axes. The coordinates corresponding to these
axes are $x_j$ where $j=1, \ldots, n$. The distance $\Delta s$ between
two points $(x_1, x_2, \ldots, x_n)$ and $(x'_1, x'_2, \ldots, x'_n)$ is
given by
axes are $x_j$ where $j=1, \ldots, n$.
Cartesian coordinates are simple, as the coordinate axis are simply
straight lines and perpendicular to each other. Due to this, it is
very easy to do calculations in Cartesian coordinates. For example,
the distance $\Delta s$ between two points $(x_1, x_2, \ldots, x_n)$
and $(x'_1, x'_2, \ldots, x'_n)$ is easily computed as
$$\Delta s^2 = (x'_1 - x_1)^2 + (x'_2 - x_2)^2 + \ldots + (x'_n - x_n)^2.$$
The expression on the right hand side can be written using a summation
sign $\sum$: $$\Delta s^2 = \sum_{i=1}^n (x'_i - x_i)^2.$$ A space with
such a distance definition is called a *Euclidean space*.
(A space with such a distance definition is called a *Euclidean
space*.)
In mathematics, we are often dealing with so-called *infinitesimally* small
distances, for example in the definition of derivatives and integrals.
In Cartesion coordinates the expressions for infinitesimal distances $ds$ and
infinitesimal volumes $dV$ are given as
$$ds = \sqrt{dx_1^2 + dx_2^2 + \ldots + dx_n^2}$$
and
$$dV = dx_1 dx_2 \ldots dx_N.$$
The formula for $dV$ also indicates that in Cartesian coordinates, the integral
over a volume can be expressed as individual integrals over all coordinate directions:
$\int dV = \idotsint dx_1 dx_2 \ldots dx_N$.
Cartesian coordinates are used a lot. They are particularly suitable for
infinite spaces or for rectangular volumes.
@@ -24,8 +40,9 @@ infinite spaces or for rectangular volumes.
![image](figures/Coordinates_5_1.svg)
## Polar coordinates
# Polar coordinates
## Definition
It often turns out useful to change to a different type of coordinate
system. For example, if you want to describe the vibrations of a
@@ -48,13 +65,32 @@ from the angular one ($0^\circ$, $45^\circ$ etc.).
The plot below shows a point on a curve with the polar coordinates
$(r,\varphi)$ indicated. From this, we can see that the *Cartesian*
coordinates $(x,y)$ of the point are related to the polar ones as
follows: $$x = r \cos\varphi;$$ $$y = r \sin \varphi.$$
follows:
$$\begin{equation} x = r \cos\varphi; \end{equation}$$
$$\begin{equation} y = r \sin \varphi.\end{equation}$$
![image](figures/Coordinates_9_0.svg)
The inverse relation is given as
$$\begin{equation} r=\sqrt{x^2 + y^2}; \label{rxy}\end{equation}$$
$$\begin{equation} \varphi=\begin{cases}
\arctan(y/x) & \text{$x>0$,}\\
\pi + \arctan(y/x) & \text{$x<0$ and $y>0$,}\\
-\pi + \arctan(y/x) & \text{$x<0$ and $y<0$.}
\end{cases} \label{phixy}\end{equation}$$
The last formula for $\varphi$ warrants a closer explanation: It is easy
to see that $\tan(\varphi)=y/x$ - but this is not a unique relation, due to
the fact that the $\tan$ has different branches. Convince yourself that
the expression above is correct for all the four sectors!
## Distances and areas
Now suppose we want to calculate the distance between two points, one
with polar coordinates $(r_1, \varphi_1)$, and the other with
$(r_2, \varphi_2)$. This looks like a difficult exercise. A convenient
$(r_2, \varphi_2)$. This looks like a difficult exercise. One possible
way to perform this is by translating the polar coordinates into
Cartesian coordinates and using the expression given above for this
distance: $$\Delta s^2 = (x_1 - x_2)^2 + (y_1 - y_2)^2,$$ so
@@ -72,34 +108,73 @@ arc of radius $r_1$ and then we move a small distance radially outward
from $r_1$ to $r_2$. Provided the difference between the angles
$\varphi_1$ and $\varphi_2$ is (very) small, these paths are
approximately perpendicular and we can use Pythagoras’ theorem to find
the distance $\Delta s$. Note that the arc is approximately straight –
it has a length $r_1 \Delta \varphi$, where
$\Delta \varphi = \varphi_2-\varphi_1$. So we have:
$$\Delta s^2 = (\Delta r)^2 + (arc~length)^2 = (\Delta r)^2 + r_1^2 (\Delta \varphi)^2 .$$
For $r\equiv r_1 \approx r_2$, replacing the $\Delta$’s by $d$’s to
emphasise the infinitesimal character of the differences, we finally
have: $$ds^2 = dr^2+ r^2 d\varphi^2 .$$ You should recall this formula!
If we traverse a curved path in the plane, we must sum up all the $ds$,
which actually boils down to calculating an integral:
$$Path~length = \int_{start}^{end} ds = \int_{start}^{end} \sqrt{dr^2 + r^2 d\varphi^2}.$$
Here, the boundaries $start$ and $end$ stand for the starting and end
point of the path.
Note that the path can often be written in the form $r(\varphi)$,
i.e. we write $r$ as a function of $\varphi$. We can then write the
integral as:
$$Path~length = \int_{start}^{end} \sqrt{dr^2 + r^2 d\varphi^2} = \int_{\varphi_{start}}^{\varphi_{end}} \sqrt{\left(\frac{dr}{d\varphi}\right)^2 + r^2} \; d\varphi.$$
(Note: this parametrisation is strictly speaking only possible when $r$
is a uni-valued function of $\varphi$; a meandering path generally does
not have this property.)
**Exercise:** write the same expression as an integral over $dr$ instead
of $d\varphi$. Please sketch two paths, one which is more suitable for
the expression above (the integral over $\varphi$) and the other more
convenient for the expression you obtained in this problem.
## Cylindrical coordinates
the distance $d s$. Note that the arc is approximately straight –
it has a length $r_1 d \varphi$, where
$d \varphi = \varphi_2-\varphi_1$. So we have:
$$d s^2 = (d r)^2 + (arc~length)^2 = (d r)^2 + r_1^2 (d \varphi)^2 .$$
We can use the same arguments also for the area: since the different
segments are approximately perpendicular, we find the area by simply
multiplying them:
$$dA = r dr d\varphi.$$
This is an important formula to remember for integrating in polar
coordinates! The extra $r$ that appears here can be intuitively
understood: the area swept by an angle difference $d\varphi$
*increases* as we move further away from the origin.
!!! check "Example: Integrating over a circular area"
To check the area element we just derived, let us compute a simple
integral. We compute the integral over a circle with radius $r_0$
with a very simple function that equals to $1$. In this case,
we expect to get as a result the are of the region we integrate over.
We find:
$$
\int_0^{2\pi} d\varphi \int_0^r_0 r dr =
2\pi \int_0^r_0 r dr = 2 \pi \frac{1}{2} r_0^2 = \pi r_0^2,
$$
which is indeed the area of a circle with radius 0.
## Converting derivatives between coordinate systems
Often, in physics important equations involve derivatives given in terms
of Cartesian coordinates. One prominent example are equations of the form
$$\left(\frac{\partial^2}{\partial x^2} + \frac{\partial^2}{\partial y^2}\right)
f(x, y) = \ldots.$$
The derivative operator $\left(\frac{\partial^2}{\partial x^2} +
\frac{\partial^2}{\partial y^2}\right)$ is so common it has its own name:
the Laplacian (here for two-dimensional space).
Such an equation is universal, but for particular situations it might be
advantageous to use a different coordinate system, such as polar coordinates
for a system with rotational symmetry. The question then is: How does the
corresponding equation look like in a different coordinate system?
There are different ways to find the answer. Here, we will focus on
directly deriving the transformed equation through an explicit calculation
involving the chain rule for a function of several variables.
!!! info Chain rule for a multi-variable function
Let $f$ be a function of $n$ variables: $f(y_1, y_2, \ldots, y_n)$,
as well as $g_i(x_1, x_2, \ldots, x_n)$ for $i=1,2,\ldots, n$. Then
$$\frac{\partial}{\partial x_i} = \sum_{j=1}^n
\fac{partial f}{\partial y_j} \frac{\partial g_j}{\partial x_i}$$
We start by replacing the function $f(x, y)$ by a function in polar coordinates
$f(r, \varphi)$, and ask what is $\frac{\partial}{\partial x} f(r, \varphi)$. When
we look at this expression, we need to understand what it *means* to take the derivative
of a function of $r, \varphi$ in terms of $x$?
For this, we need to realize that there are relations between the coordinate systems.
In particular, $r = r(x,y)$ and $\varphi = \varphi(x, y)$ as defined in equations
\ref{rxy} and \ref{phixy}.
# Cylindrical coordinates
Three dimensional systems may have axial symmetry. An example is an
electrically charged wire of which we would like to calculate the
@@ -111,10 +186,10 @@ choose the coordinate system ourselves - this is not imposed by the
problem.
Cylindrical coordinates are defined straightforwardly: we use polar
coordinates $\rho$ and $\varphi$ in the $xy$ plane, and the distance $z$
coordinates $r$ and $\varphi$ in the $xy$ plane, and the distance $z$
along the symmetry-axis as the third coordinate. If the axis system is
chosen in physical space, we have two coordinates which have the
dimension of a distance: $\rho$ and $z$. The other coordinate,
dimension of a distance: $r$ and $z$. The other coordinate,
$\varphi$, is of course dimensionless.
What is the distance travelled along a path when we express this in
@@ -122,17 +197,17 @@ cylindrical coordinates? Let’s consider an example (Figure).
![image](figures/Coordinates_13_0.svg)
We want to find the length of the (small) red segment $\Delta s$. By
We want to find the length of the (small) red segment $d s$. By
inspecting the figure, we see that the horizontal (i.e. parallel to the
$xy$-plane) segment $\Delta l$ is perpendicular to the vertical segment
$dz$. Using for $\Delta l$ the length we obtained before for a line
$xy$-plane) segment $d l$ is perpendicular to the vertical segment
$dz$. Using for $d l$ the length we obtained before for a line
segment in the $xy$ plane, expressed in polar coordinates, we
immediately find:
$$\Delta s^2 = \Delta l^2 + \Delta z^2 = \Delta \rho^2 + \rho^2 \Delta \varphi^2 + \Delta z^2.$$
Using $d$ instead of $\Delta$ for infinitesimal changes, this reads:
$$ds^2 = dl^2 + dz^2 = d\rho^2 + \rho^2 d\varphi^2 + dz^2.$$
$$d s^2 = d l^2 + d z^2 = d r^2 + r^2 d \varphi^2 + d z^2.$$
The volume element is consequently given as
$$dV = r dr d\varphi dz.$$
## Spherical coordinates
# Spherical coordinates
For problems with spherical symmetry, we use *spherical coordinates*.
These work as follows. For a point $\bf r$ in 3D space, we can specify
@@ -147,12 +222,11 @@ The position of a point on the sphere is specified using the two angles
$\theta$ and $\phi$ indicated in the figure.
!!! warning
Note that in mathematics, usually the angles are labelled the other way
Note that in mathematics, often the angles are labelled the other way
round: there, $\phi$ is used for the angle between a line running from
the origin o the point of interest and the $z$-axis, and $\theta$ for
the angle of the projection of that line with the $x$-axis. The
convention used here is custom in physics. IT IS IMPORTANT TO BE AWARE
OF THIS!!
convention used here is custom in physics.
The relation between Cartesian and coordinates is defined by
$$x = r \cos \varphi \sin \vartheta$$
@@ -184,6 +258,10 @@ displacement.
![image](figures/Coordinates_19_0.svg)
From these arguments we can again also find the volume element, it is
here given as
$$dV = r^2 \sin\theta dr d\theta d\varphi.$$
### summary
We have discussed four different coordinate systems:
@@ -201,12 +279,14 @@ We have discussed four different coordinate systems:
given in terms of these coordinates.
Infinitesimal distance: $$ds^2 = dr^2 + r^2 d\phi^2.$$
Infinitesimal area: $$dA = r dr d\varphi.$$
3. *Cylindrical coordinates*: $${\bf r} = (\rho, \phi, z).$$ Can be
3. *Cylindrical coordinates*: $${\bf r} = (r, \phi, z).$$ Can be
used in three dimensions. Suitable for systems with axial symmetry
or functions given in terms of these coordinates.
Infinitesimal distance: $$ds^2 = d\rho^2 + \rho^2 d\phi^2 + dz^2.$$
Infinitesimal distance: $$ds^2 = dr^2 + r^2 d\phi^2 + dz^2.$$
Infinitesimal volume:: $$dV = r dr d\varphi dz.$$
4. *Spherical coordinates*: $${\bf r} = (r, \theta, \phi).$$ Can be
used in three dimensions. Suitable for systems with spherical
@@ -214,6 +294,8 @@ We have discussed four different coordinate systems:
Infinitesimal distance:
$$ds^2 =r^2 (\sin^2 \theta d\phi^2 + d\theta^2) + dr^2 .$$
Infinitesimal volume:
$$dV = r^2 \sin(\theta) dr d\theta d\varphi.$$
Problems
========
@@ -248,11 +330,3 @@ Problems
\frac{\partial}{\partial \vartheta}\left( \sin\vartheta \frac{\partial\psi(r,\vartheta, \varphi)}{\partial \vartheta}\right).$$
This is however even more tedious (you do not have to show this).
4. [:smirk:] A particle moves over a cone which is characterized
by the condition $rho = z$. Calculate the kinetic energy expressed
in terms of the cylindrical coordinates $z$ and $\varphi$ and their
first order time derivatives.
5. [:smirk:] The same question for a particle moving on a
spherical shell of radius $R$. (Use coordinates $\varphi$ and
$\vartheta$.)
Loading