BetaFree coursewareRewritten from MIT OpenCourseWareCC BY-NC-SA 4.0
Open CosmologyPhysics & cosmology, from high school to a graduate year

Spherical coordinates and gravitational attraction

Spherical coordinates locate a point by its distance ρ from the origin, the angle φ down from the positive z-axis, and the usual angle θ: z = ρ cos φ, r = ρ sin φ, like polar coordinates in the rz half-plane. ρ = a is a sphere, φ = π/4 a cone. A small piece of a sphere of radius a has area a² sin φ Δφ Δθ, so dV = ρ² sin φ dρ dφ dθ. The cap of the unit ball above z = 1/√2 has volume 2π/3 − 5π/(6√2). The gravitational pull of a solid on a mass at the origin is a triple integral; with the z-axis as axis of symmetry it simplifies, and it proves Newton's theorem: a uniform sphere attracts an outside mass like a point mass at its centre.

You need this first

Full reading path (24 pages)
  1. Vectors (8.01)
  2. Vectors and the dot product (18.02)
  3. Determinants and the cross product (18.02)
  4. Planes through three points, and matrices (18.02)
  5. Equations of planes and square systems (18.02)
  6. Parametric equations of lines and the cycloid (18.02)
  7. Velocity, acceleration and Kepler's second law (18.02)
  8. Functions of two variables and partial derivatives (18.02)
  9. Tangent planes, critical points and least squares (18.02)
  10. The second derivative test (18.02)
  11. Differentials and the chain rule (18.02)
  12. The gradient and directional derivatives (18.02)
  13. Lagrange multipliers (18.02)
  14. Non-independent variables (18.02)
  15. Double integrals (18.02)
  16. Double integrals in polar coordinates, and their uses (18.02)
  17. Change of variables in double integrals (18.02)
  18. Vector fields and line integrals (18.02)
  19. Gradient fields and path independence (18.02)
  20. Testing for gradient fields, potentials and curl (18.02)
  21. Green's theorem (18.02)
  22. Flux and the normal form of Green's theorem (18.02)
  23. Simply connected regions (18.02)
  24. Triple integrals and cylindrical coordinates (18.02)
On this page · 6 sections
  1. Spherical coordinates
  2. The volume element
  3. Example: a cap of the ball
  4. Gravitational attraction
  5. Newton's theorem
  6. Summary

After rectangular and cylindrical coordinates, the third system for triple integrals: spherical coordinates, a space version of polar coordinates (transcript, p. 1).

Spherical coordinates#

A point is located by its distance to the origin and two angles (transcript, pp. 1–2; notes, p. 1):

  • ρ\rho (rho, the Greek r), the distance from the origin, 0≤ρ<∞0 \le \rho < \infty;
  • φ\varphi (phi), the angle down from the positive zz-axis: 0 on the positive zz-axis, π/2\pi/2 on the xyxy-plane, π\pi on the negative zz-axis;
  • θ\theta, the same angle as in cylindrical coordinates, counterclockwise from the xx-axis.

On a sphere ρ=a\rho = a, φ\varphi is like latitude, except that it is 0 at the North Pole and π\pi at the South Pole, and θ\theta like longitude (p. 2; notes, p. 1). Another way to see them: in the vertical half-plane at angle θ\theta, with axes rr (distance from the zz-axis) and zz, ρ\rho and φ\varphi are polar coordinates, with the angle measured from the zz-axis (pp. 2–3). So (p. 3; notes, p. 1):

Spherical to cylindrical and rectangular
z=ρcos⁡φ,r=ρsin⁡φ,x=ρsin⁡φcos⁡θ,y=ρsin⁡φsin⁡θ,ρ=x2+y2+z2z = \rho\cos\varphi, \quad r = \rho\sin\varphi, \qquad x = \rho\sin\varphi\cos\theta, \quad y = \rho\sin\varphi\sin\theta, \qquad \rho = \sqrt{x^2 + y^2 + z^2}
In words

z equals rho cos phi, r equals rho sine phi, x equals rho sine phi cos theta, y equals rho sine phi sine theta, rho equals the square root of x squared plus y squared plus z squared, end of root

These coordinates, like cylindrical ones, favour the zz-axis, so a symmetric problem should be centred on it (p. 3).

Some surfaces (p. 4; notes, p. 1): ρ=a\rho = a is the sphere of radius aa about the origin. φ=π/4\varphi = \pi/4 is a cone: at 45° from the zz-axis, cos⁡φ=sin⁡φ\cos\varphi = \sin\varphi, so z=rz = r. In general φ=\varphi = constant is a cone about the zz-axis, and φ=π/2\varphi = \pi/2 is the flattest of cones, the xyxy-plane; φ<π/2\varphi < \pi/2 is the upper half-space (p. 4).

The volume element#

First the area of a small piece of the sphere of radius aa, between φ\varphi and φ+Δφ\varphi + \Delta\varphi and between θ\theta and θ+Δθ\theta + \Delta\theta: the grid of a globe (transcript, pp. 5–6; notes, p. 1). Its east–west side is an arc of a parallel, a circle of radius r=asin⁡φr = a\sin\varphi, so its length is asin⁡φ Δθa\sin\varphi\,\Delta\theta. Its north–south side is an arc of a meridian, a great circle of radius aa, of length a Δφa\,\Delta\varphi (p. 6). So (p. 7; notes, p. 1):

Surface element of a sphere
ΔS≈a2sin⁡φ Δφ Δθ,dS=a2sin⁡φ dφ dθ\Delta S \approx a^2\sin\varphi\,\Delta\varphi\,\Delta\theta, \qquad dS = a^2\sin\varphi\,d\varphi\,d\theta
In words

capital delta S is approximately a squared sine phi capital delta phi capital delta theta, d S equals a squared sine phi d phi d theta

Adding a thickness Δρ\Delta\rho between two spheres gives a small box of volume ΔS Δρ\Delta S\,\Delta\rho, with aa now ρ\rho (p. 7; notes, p. 1):

Volume element in spherical coordinates
dV=ρ2sin⁡φ dρ dφ dθdV = \rho^2\sin\varphi\,d\rho\,d\varphi\,d\theta
In words

d V equals rho squared sine phi d rho d phi d theta

Source: 18.02 lecture summaries, Week 11 (Prof. Auroux), Lecture 26, pp. 1–2, Lecture 26, p. 1

Integrating in this order, ρ\rho first, means shooting a ray from the origin in a fixed direction (φ,θ)(\varphi, \theta) and finding where it is in the solid; then how far north and south the solid extends; then around the zz-axis (p. 5).

Example: a cap of the ball#

Last lecture's slanted cap, rotated to sit on the zz-axis: the part of the unit ball above the plane z=1/2z = 1/\sqrt2 (transcript, p. 8; notes, p. 1). A ray in direction (φ,θ)(\varphi, \theta) enters the region through the plane, where ρcos⁡φ=1/2\rho\cos\varphi = 1/\sqrt2, that is ρ=12sec⁡φ\rho = \frac{1}{\sqrt2}\sec\varphi, and leaves through the sphere ρ=1\rho = 1 (pp. 8–9). The rays that meet the cap have 0≤φ≤π/40 \le \varphi \le \pi/4: at the edge, ρ=1\rho = 1 and cos⁡φ=1/2\cos\varphi = 1/\sqrt2; a slice by a vertical half-plane shows the 45° angle too (pp. 9–10; notes, p. 1). And θ\theta goes all the way around (p. 10):

Volume of the cap
V=∫02π∫0π/4∫12sec⁡φ1ρ2sin⁡φ dρ dφ dθ=2π3−5π62V = \int_0^{2\pi}\int_0^{\pi/4}\int_{\frac{1}{\sqrt2}\sec\varphi}^{1} \rho^2\sin\varphi\,d\rho\,d\varphi\,d\theta = \frac{2\pi}{3} - \frac{5\pi}{6\sqrt2}
In words

V equals the integral from 0 to 2 pi of the integral over 0 of to the power pi over 4, end of power, the integral from 1 over the square root of 2 secant phi to 1 of rho squared sine phi d rho d phi d theta equals 2 pi over 3 minus 5 pi over the quantity 6 the square root of 2

Source: 18.02 Lecture 26 transcript, pp. 10–11

(Evaluation left as an exercise; it involves sec⁡3φ\sec^3\varphi and a substitution, p. 11.) A horizontal plane has an odd-looking equation, like a line not through the origin in polar coordinates (p. 10). Spherical coordinates also suit averages of the distance ρ\rho from the origin, and moments of inertia about the zz-axis (p. 11).

Gravitational attraction#

Two masses attract each other with a force along the line between them, proportional to both masses and inversely proportional to the square of the distance (transcript, p. 12; notes, p. 1). A solid attracts as the sum of all its pieces (the ground below pulls an object down, the far side of the Earth pulls it too, and the total points down) (p. 12). Put the test mass mm at the origin; a small mass ΔM\Delta M at (x,y,z)(x, y, z), at distance ρ\rho, pulls it with magnitude G ΔM m/ρ2G\,\Delta M\,m/\rho^2 towards ⟨x,y,z⟩/ρ\langle x, y, z\rangle/\rho (pp. 12–13; notes, p. 1). With ΔM=δ ΔV\Delta M = \delta\,\Delta V (p. 13; notes, p. 1):

Gravitational force of a solid
F⃗=∫∫∫RG m ⟨x,y,z⟩ρ3 δ dV\vec F = \int\int\int_R \frac{G\,m\,\langle x, y, z\rangle}{\rho^3}\,\delta\,dV
In words

vector F equals the integral of the integral of the integral of _ capital R G m the average of x, y, z over rho cubed, times delta d V

(a vector integral, component by component). In rectangular coordinates ρ3=(x2+y2+z2)3/2\rho^3 = (x^2 + y^2 + z^2)^{3/2} is unpleasant (p. 13). Instead place the solid so that the zz-axis is an axis of symmetry: then by symmetry the force is along the zz-axis, and in spherical coordinates the powers of ρ\rho cancel (p. 14; notes, pp. 1–2):

The z component
Fz=G m∫∫∫Rzρ3 δ dV=G m∫∫∫Rδ cos⁡φ sin⁡φ dρ dφ dθF_z = G\,m\int\int\int_R \frac{z}{\rho^3}\,\delta\,dV = G\,m\int\int\int_R \delta\,\cos\varphi\,\sin\varphi\,d\rho\,d\varphi\,d\theta
In words

F sub z equals G m the integral of the integral of the integral of _ capital R z over rho cubed, times delta d V equals G m the integral of the integral of the integral of _ capital R delta cos phi sine phi d rho d phi d theta

Newton's theorem#

The gravitational attraction of a spherical planet of uniform density (or of density depending only on the distance to its centre), on a mass outside it or on its surface, is the same as that of a point mass with the same total mass at its centre (transcript, pp. 14–15; notes, p. 2). If the Earth collapsed to a black hole of the same mass, your weight would not change (p. 15). The notes do the computation, for uniform density δ\delta and a test mass on the surface: the sphere of radius aa sits on the positive zz-axis, touching the xyxy-plane at the origin, so its spherical equation is ρ=2acos⁡φ\rho = 2a\cos\varphi (a right triangle inscribed in a vertical slice, with the diameter 2a2a as hypotenuse) (notes, p. 2):

Newton's theorem
Fz=G m δ∫02π∫0π/2∫02acos⁡φcos⁡φ sin⁡φ dρ dφ dθ=43πG m δ a=G M ma2,M=43πa3δF_z = G\,m\,\delta\int_0^{2\pi}\int_0^{\pi/2}\int_0^{2a\cos\varphi} \cos\varphi\,\sin\varphi\,d\rho\,d\varphi\,d\theta = \tfrac43\pi G\,m\,\delta\,a = \frac{G\,M\,m}{a^2}, \qquad M = \tfrac43\pi a^3\delta
In words

F sub z equals G m delta the integral from 0 to 2 pi of the integral over 0 of to the power pi over 2, end of power, the integral from 0 to 2 a cos phi of cos phi sine phi d rho d phi d theta equals four thirds pi G m delta a equals G capital M m over a squared, capital M equals four thirds pi a cubed delta

Source: 18.02 lecture summaries, Week 11 (Prof. Auroux), Lecture 26, pp. 1–2, Lecture 26, p. 2
Worked example

Two spherical integrals

(a) Find the average distance from the centre of the points of the unit ball. (b) Find the volume of the "ice-cream cone" inside the unit sphere and inside the cone φ=π/4\varphi = \pi/4.

(a) Average of ρ

∫02π∫0π∫01ρ⋅ρ2sin⁡φ dρ dφ dθ=14⋅2⋅2π=π\int_0^{2\pi}\int_0^\pi\int_0^1 \rho \cdot \rho^2\sin\varphi\,d\rho\,d\varphi\,d\theta = \frac14 \cdot 2 \cdot 2\pi = \pi. Dividing by the volume 43π\frac43\pi: the average distance is 34\frac34. Most of the volume of a ball is near its surface.

(b) The cone

∫02π∫0π/4∫01ρ2sin⁡φ dρ dφ dθ=13⋅(1−12)⋅2π≈0.613\int_0^{2\pi}\int_0^{\pi/4}\int_0^1 \rho^2\sin\varphi\,d\rho\,d\varphi\,d\theta = \frac13 \cdot \left(1 - \frac{1}{\sqrt2}\right) \cdot 2\pi \approx 0.613. Subtracting the cap above, the part of the cone below the plane z=1/2z = 1/\sqrt2 is 0.613−0.243=0.3700.613 - 0.243 = 0.370, which is 13πr2h\frac13\pi r^2 h for a cone of radius and height 1/21/\sqrt2.

Summary#

  • Spherical coordinates: ρ\rho (distance to origin), φ\varphi (down from the zz-axis, 00 to π\pi), θ\theta; z=ρcos⁡φz = \rho\cos\varphi, r=ρsin⁡φr = \rho\sin\varphi, ρ=x2+y2+z2\rho = \sqrt{x^2 + y^2 + z^2}.
  • ρ=a\rho = a is a sphere, φ=\varphi = constant a cone, φ=π/2\varphi = \pi/2 the xyxy-plane.
  • dS=a2sin⁡φ dφ dθdS = a^2\sin\varphi\,d\varphi\,d\theta on a sphere; dV=ρ2sin⁡φ dρ dφ dθdV = \rho^2\sin\varphi\,d\rho\,d\varphi\,d\theta.
  • The cap of the unit ball above z=1/2z = 1/\sqrt2 has volume 2π3−5π62\frac{2\pi}{3} - \frac{5\pi}{6\sqrt2}.
  • Gravitational force of a solid: F⃗=∫∫∫Gm⟨x,y,z⟩δ/ρ3 dV\vec F = \int\int\int G m\langle x, y, z\rangle\delta/\rho^3\,dV; with axial symmetry Fz=Gm∫∫∫δcos⁡φsin⁡φ dρ dφ dθF_z = Gm\int\int\int \delta\cos\varphi\sin\varphi\,d\rho\,d\varphi\,d\theta, which proves Newton's theorem for a mass outside a uniform sphere or on its surface.

Symbols on this page

Show the 30 symbols used here
δ\delta delta.
The density of the solid: mass per unit volume. Unit: kg/m³. Say it: “delta”.
Δ\Delta capital delta.
A change or difference in a quantity, e.g. Δx = x₂ − x₁. Say it: “capital delta”.
θ\theta theta.
An angle. Say it: “theta” (sounds like “thay-ta or thee-ta”).
π\pi pi.
The ratio of a circle's circumference to its diameter, π ≈ 3.14159. Say it: “pi”.
ρ\rho rho.
Density: mass (or energy divided by c²) per unit volume. ρ_c is the critical density, ρ̄ the mean density. Unit: kg/m³ (on some pages an energy density in natural units: GeV⁴, eV/cm³). Say it: “rho”.
ϕ\phi phi.
The spherical coordinate φ: the angle down from the positive z-axis, from 0 to π. Say it: “phi” (sounds like “fye”).
∞\infty infinity.
Infinity: larger than any number. Say it: “infinity”.
≈\approx approximately equal.
Is approximately equal to. Say it: “is approximately”.
≤\le less than or equal.
Is less than or equal to. Say it: “is less than or equal to”.
⋅\cdot dot.
Times (multiplication). Between two vectors: the dot product. Say it: “times”.
⟨\langle angle brackets.
The average (mean value) of what is inside, ⟨…⟩. Say it: “the average of”.
∫\int integral.
Integral: the sum of infinitely many small pieces, such as the area under a curve. Say it: “the integral of”.
sin⁡\sin sine.
Sine of an angle. Say it: “sine”.
cos⁡\cos cosine.
Cosine of an angle. Say it: “cos”.
v⃗\vec v vector arrow.
A vector: a quantity with a size and a direction. Say it: “vector”.
aa a.
The radius of the sphere (or of the planet). Unit: m. Say it: “a”.
zz z.
The z coordinate, ρ cos φ. Say it: “z”.
GG G.
Newton's gravitational constant, G ≈ 6.674 × 10⁻¹¹ m³ kg⁻¹ s⁻². Unit: m³/(kg·s²). Say it: “G”.
xx x.
The x coordinate, ρ sin φ cos θ. Say it: “x”.
yy y.
The y coordinate, ρ sin φ sin θ. Say it: “y”.
dd d.
The d of dV, dS, dρ, dφ, dθ. Say it: “d”.
mm m.
The test mass at the origin. Unit: kg. Say it: “m”.
FF F.
The gravitational force on the test mass at the origin. Unit: N. Say it: “F”.
rr r.
The distance from the z-axis (cylindrical coordinate), ρ sin φ. Say it: “r”.
hh h.
The height of a cone (in the worked example). Unit: m. Say it: “h”.
MM M.
A mass: a small piece ΔM of the solid, or the planet's total mass. Unit: kg. Say it: “capital M”.
SS S.
Surface area on a sphere; dS is a small piece of it. Unit: m². Say it: “S”.
VV V.
Volume; dV is a small piece of volume. Unit: m³. Say it: “V”.
sec⁡\sec secant.
The secant, 1/cos. Say it: “secant”.
FzF_{z} F z.
The z component of the gravitational force. Unit: N. Say it: “F sub z”.

Tap or click a symbol in a formula to see the same explanation. All symbols: symbols and notation.

Words on this page

Show the 23 words used here

New here

spherical coordinates.
Giving a point in space by its distance from the origin and two angles: one measured down from the vertical axis, one around it.

Also used

cylindrical coordinates.
Polar coordinates in a plane plus a height z along the axis, suited to problems with an axis of symmetry. Explained in Vectors.
triple integral.
An integral over a region of space: cut the region into tiny boxes, multiply each by the function's value there, and add. Explained in Triple integrals and cylindrical coordinates.
polar coordinates.
Coordinates in a flat plane that give a point's distance r from the origin and its angle θ from a fixed direction. Explained in Vectors.
p..
Page, in a reference to a source; pp. means pages, as in pp. 3–5.
symmetric.
Unchanged by some swap, reflection or turn; for an expression in two quantities, unchanged when they are exchanged. Explained in Introduction to Fourier series.
integration.
Finding an integral: adding up very many small pieces, or finding an antiderivative. Explained in Differentials and antiderivatives.
moment of inertia.
How hard a body is to set spinning about an axis: each bit of mass times its squared distance from the axis, all added up. Explained in Rotation and angular momentum.
proportional.
Of two quantities: always in the same ratio, so that doubling one doubles the other. Explained in Graphs, straight lines and slope.
test body.
An idealised body so small and light that it does not disturb the gravity around it, with no charge, size or spin. Explained in Tensor densities, covariant divergences and the geodesic equation.
magnitude.
The size of a quantity without its direction or sign; for a vector, the length of its arrow. Explained in Vectors.
vector.
A quantity with both a size and a direction, such as a velocity or a force, drawn as an arrow. Explained in Vectors.
integral.
A sum of very many very small pieces, such as the area under a graph; it undoes taking a derivative. Explained in Rates of change and area under a graph.
symmetry.
A change, such as a reflection, a rotation or a shift, that leaves something looking exactly the same. Explained in The derivative: slope of the tangent line and rate of change.
uniform.
The same at every point, or unchanging in time: a uniform rod has the same density all along it. Explained in The electric field.
density.
How much of something (mass, charge, energy, particles or probability) there is in each unit of volume, area, length or other variable. Explained in Density and pressure.
black hole.
A region of spacetime from which nothing, not even light, can escape, formed when matter collapses beyond its own horizon. Explained in Black holes.
weight.
The pull of gravity on a body, a force equal to its mass times the gravitational acceleration, measured in newtons.
theorem.
A statement that has been proved true, step by step, from definitions and earlier results. Explained in Limits and continuity.
galaxy.
A huge system of stars, gas and dust, from thousands to over a trillion stars, held together by gravity inside a dark matter halo. Explained in Towards the universe: weighing the Sun and the Galaxy with orbits.
net force.
The sum of all the forces acting on a body, added as vectors; it alone decides the body's acceleration. Explained in What is a force?.

Academic

transcript.
A written record of exactly what was said in a recorded lecture, word for word.
model.
A simplified description of a real system, usually in equations, that keeps what matters and leaves out the rest.

Tap or click a word, here or in the text, for its meaning in this lesson. All words: the glossary. How many words are marked in the text: Reading options (the “Aa” button).

Where this leads

In cosmology

32 more cosmology pages that build on this

Pages that build on this

Practise

Check your understanding

  1. In spherical coordinates, the surface φ=π/2\varphi = \pi/2 is…
  2. dVdV in spherical coordinates is…
  3. The point with cylindrical coordinates r=3r = 3, z=4z = 4 has ρ=\rho =
0 of 3 answered

Flashcards

1 / 3