Skip to content

Calculus and Linear Algebra for Relativity

Scrollable formula. Use Left and Right arrow keys to reveal hidden content.

Scrollable table. Use Left and Right arrow keys to reveal additional columns.

Scrollable figure. Use Left and Right arrow keys to inspect hidden content.

Relativity uses elementary calculus and linear algebra in a less forgiving way than many introductory physics courses: the objects must survive a change of coordinates or basis. This module checks the small set of skills needed to differentiate fields, manipulate linear maps and bilinear forms, and keep components distinct from the geometric object they represent. It offers focused preparation for relativity.

By the end, you should be able to use these tools in coordinate, tensor, and variational calculations, then carry them into a changed relativity problem while checking dimensions and simple limits.

Work without a timer. Record the reasoning that fixes each sign, index, or matrix order; a bare numerical answer is not enough.

  1. Let f(x,y)=x2y+eyf(x,y)=x^2y+e^y. Find dfdf and the directional derivative at (1,0)(1,0) along v=(2,−1)v=(2,-1).
  2. A linear map has matrix A=(2103)A=\begin{pmatrix}2&1\\0&3\end{pmatrix} in a basis (e1,e2)(e_1,e_2). For the new basis e1′=e1e'_1=e_1 and e2′=e1+e2e'_2=e_1+e_2, find the matrix A′A' and verify that its eigenvalues did not change.
  3. For the bilinear form g=diag⁡(−1,1,1,1)g=\operatorname{diag}(-1,1,1,1) and vector u=(γ,γv,0,0)u=(\gamma,\gamma v,0,0), compute g(u,u)g(u,u) when γ=(1−v2)−1/2\gamma=(1-v^2)^{-1/2}. Then lower the index on uu.
  4. For fixed endpoint variations of S[q]=∫t1t2(m2q˙2−V(q))dt,S[q]=\int_{t_1}^{t_2}\left(\frac m2\dot q^2-V(q)\right)dt, integrate the term ∫mq˙ δq˙ dt\int m\dot q\,\delta\dot q\,dt by parts and identify the equation selected by δS=0\delta S=0.
Hints for 1

First compute the partial derivatives. A differential is a covector: apply it to vv rather than taking an extra dot product with an undefined metric.

Solution to 1

The chain rule gives

df=(2xy) dx+(x2+ey) dy.df=(2xy)\,dx+(x^2+e^y)\,dy.

At (1,0)(1,0) this is df=0 dx+2 dydf=0\,dx+2\,dy. Therefore

Dvf=df(v)=0(2)+2(−1)=−2.D_vf=df(v)=0(2)+2(-1)=-2.

The result is linear in vv, as a directional derivative must be.

Hints for 2

Put the new basis vectors into the columns of PP. Components obey [w]old=P[w]new[w]_{\mathrm{old}}=P[w]_{\mathrm{new}}, so A′=P−1APA'=P^{-1}AP.

Solution to 2

Here

P=(1101),P−1=(1−101).P=\begin{pmatrix}1&1\\0&1\end{pmatrix}, \qquad P^{-1}=\begin{pmatrix}1&-1\\0&1\end{pmatrix}.

Thus

A′=P−1AP=(2003).A'=P^{-1}AP =\begin{pmatrix}2&0\\0&3\end{pmatrix}.

Both matrices have characteristic polynomial (2−λ)(3−λ)(2-\lambda)(3-\lambda). Components changed; the linear map and its eigenvalues did not.

Hints for 3

Use the bilinear form once for the norm and once to compute uμ=gμνuνu_\mu=g_{\mu\nu}u^\nu. Do not change the spatial sign when lowering the time component.

Solution to 3

With the displayed signature,

g(u,u)=−γ2+γ2v2=−γ2(1−v2)=−1.g(u,u)=-\gamma^2+\gamma^2v^2 =-\gamma^2(1-v^2)=-1.

Lowering the index gives

uμ=(−γ,γv,0,0).u_\mu=(-\gamma,\gamma v,0,0).

The norm is independent of the chosen inertial components. The calculation also catches the common mistake u0=+u0u_0=+u^0.

Hints for 4

Use δq˙=d(δq)/dt\delta\dot q=d(\delta q)/dt. Keep the endpoint term until the fixed-endpoint condition removes it.

Solution to 4

Integration by parts yields

∫t1t2mq˙ δq˙ dt=[mq˙ δq]t1t2−∫t1t2mq¨ δq dt.\int_{t_1}^{t_2}m\dot q\,\delta\dot q\,dt =\left[m\dot q\,\delta q\right]_{t_1}^{t_2} -\int_{t_1}^{t_2}m\ddot q\,\delta q\,dt.

The boundary term vanishes because δq(t1)=δq(t2)=0\delta q(t_1)=\delta q(t_2)=0. Since δV=V′(q)δq\delta V=V'(q)\delta q,

δS=−∫t1t2(mq¨+V′(q))δq dt.\delta S=-\int_{t_1}^{t_2}\bigl(m\ddot q+V'(q)\bigr)\delta q\,dt.

Arbitrary interior variations therefore imply mq¨=−V′(q)m\ddot q=-V'(q). The full variational interpretation belongs to Variational Mechanics and Symmetries.

  • Secure: all four setups are correct, matrix order and index lowering are explained, and each result has a check.
  • Uncertain: the method is recognizable but one topic—usually basis changes, bilinear forms, or integration by parts—requires prompts. Review that subsection below and repeat the corresponding problem with new numbers.
  • Not yet: coordinate changes are treated as changes of the underlying object, derivatives cannot be organized as linear maps, or endpoint terms are discarded without justification. Work through the focused review before returning to a relativity route.

Use your answers to choose what to study next. A single algebra slip with a sound setup calls for a quick review; an unfamiliar construction calls for studying the corresponding section.

At a point, dfdf is the linear rule taking a direction vv to the first-order change df(v)df(v). For a map F:Rn→RmF:\mathbb R^n\to\mathbb R^m, the Jacobian Jai=∂Fa/∂xiJ^a{}_i=\partial F^a/\partial x^i is the component matrix of its derivative. Under composition, matrix order follows the chain rule. This viewpoint is the bridge to tangent maps and tensor transformation laws.

A vector is not its component column. If the columns of PP are the new basis vectors expressed in the old basis, then component columns obey [v]old=P[v]new[v]_{\mathrm{old}}=P[v]_{\mathrm{new}} and hence [v]new=P−1[v]old[v]_{\mathrm{new}}=P^{-1}[v]_{\mathrm{old}}; the geometric vector itself has not changed. A linear map has matrix Anew=P−1AoldPA_{\mathrm{new}}=P^{-1}A_{\mathrm{old}}P, while a covariant bilinear form has gnew=PTgoldPg_{\mathrm{new}}=P^{\mathsf T}g_{\mathrm{old}}P. In index notation, repeated upper–lower pairs are summed, and free indices must agree on both sides of an equation.

Positive-definite inner products are not the only useful bilinear forms. The Lorentzian form has one negative and three positive directions. Lowering an index applies the metric; it is not decorative typography. Eigenvalues of a linear map are basis-independent, while the entries of its matrix and its eigenvectors’ component columns are not.

Variational and field calculations repeatedly move derivatives between factors. Always record the boundary term, the data held fixed, and the regularity needed. Dropping a boundary term before stating why it vanishes is not a harmless shortcut in gravitational action problems.

For the coordinate-independent continuation, use Tensor Fields and Natural Operations. It develops the full geometric interpretation from the tools introduced here.

Transfer task: flat spacetime in polar coordinates

Section titled “Transfer task: flat spacetime in polar coordinates”

In 2+12+1-dimensional flat spacetime,

ds2=−dt2+dx2+dy2.ds^2=-dt^2+dx^2+dy^2.

Change variables to x=rcos⁡ϕx=r\cos\phi, y=rsin⁡ϕy=r\sin\phi. Derive the metric components in (t,r,ϕ)(t,r,\phi), compute the squared norm of V=∂t+Ω∂ϕV=\partial_t+\Omega\partial_\phi, and state where VV is timelike.

Hint 1

Differentiate xx and yy, then expand dx2+dy2dx^2+dy^2. The mixed dr dϕdr\,d\phi terms must cancel.

Hint 2

Once the metric is diagonal, use the component column Vμ=(1,0,Ω)V^\mu=(1,0,\Omega) and compute gμνVμVνg_{\mu\nu}V^\mu V^\nu.

Solution

The differentials are

dx=cos⁡ϕ dr−rsin⁡ϕ dϕ,dy=sin⁡ϕ dr+rcos⁡ϕ dϕ.dx=\cos\phi\,dr-r\sin\phi\,d\phi, \qquad dy=\sin\phi\,dr+r\cos\phi\,d\phi.

Squaring and adding gives dx2+dy2=dr2+r2dϕ2dx^2+dy^2=dr^2+r^2d\phi^2, so

gμν=diag⁡(−1,1,r2).g_{\mu\nu}=\operatorname{diag}(-1,1,r^2).

Therefore

g(V,V)=−1+r2Ω2.g(V,V)=-1+r^2\Omega^2.

VV is timelike when r∣Ω∣<1r|\Omega|\lt1, null at r∣Ω∣=1r|\Omega|=1, and spacelike beyond it. Restoring cc changes the condition to r∣Ω∣<cr|\Omega|\lt c, which is dimensionally correct. The changed coordinate representation did not create curvature; it only made the metric components position-dependent.

  • Multiplying basis-change matrices in the wrong order because the direction of component conversion was not stated.
  • Treating dfdf and ∇f\nabla f as identical without specifying a metric that converts the covector into a vector.
  • Changing a tensor’s components and calling that a change in the tensor itself.
  • Omitting endpoint or boundary terms before declaring the variation or boundary conditions.

If this module interrupted the Graduate General Relativity Self-Study Path or the First Graduate Course in General Relativity, return there after completing the transfer task. If differential equations remain the weak point, continue first to Differential Equations for Relativity.