Skip to main content
โšก Calmops

LaTeX for Physics: Equations, Units, and Scientific Notation

Introduction

Physics documents require precise mathematical notation, SI units, and specialized symbols. LaTeX provides the tools needed for professional physics typesetting. Whether you’re writing a research paper, thesis, or textbook, LaTeX offers comprehensive support for physics notation.

This guide covers physics document creation in LaTeX, including SI units, vectors, tensors, and common physics equations.

SI Units with siunitx

The siunitx package provides comprehensive unit typesetting:

\usepackage{siunitx}

\si{\meter}
\si{\kilogram}
\si{\second}
\si{\ampere}
\si{\kelvin}
\si{\mole}
\si{\candela}

% Physical constants
\si{5.97e24}
\si{6.626e-34}
\si{1.602e-19}
\si{8.854e-12}
\si{1.38e-23}

Unit Combinations

% Density
\si{\kilogram\per\cubic\meter}

% Force
\si{\newton}

% Torque
\si{\newton\meter}

% Heat capacity
\si{\joule\per\mole\per\kelvin}

% Acceleration
\si{\meter\per\square\second}

% Electric field
\si{\volt\per\meter}

Unit Formatting Options

\si[per-mode=symbol]{\joule\per\mole\per\kelvin}
\si[per-mode=fraction]{\joule\per\mole\per\kelvin}

% Number formatting
\si[exponent-base=10]{1.602e-19}
\si[exponent-base=10,exponent-to-prefix]{1.602e-19}

Vectors and Tensors

Vector Notation

% Arrow notation
\vec{v}
\dot{\vec{r}}
\ddot{\vec{x}}

% Hat notation (unit vectors)
\hat{k}
\hat{i}
\hat{j}

% Bold vectors
\mathbf{v}
\boldsymbol{\omega}

% Bar notation
\bar{v}

Tensor Notation

% Levi-Civita symbol
\epsilon_{ijk}

% Kronecker delta
\delta_{ij}

% Metric tensor
g_{\mu\nu}

% Riemann tensor
R^{\rho}_{\sigma\mu\nu}

% Stress-energy tensor
T^{\mu\nu}

% Electromagnetic tensor
F^{\mu\nu}

Position and Momentum

% Position vectors
\vec{r} = x\hat{i} + y\hat{j} + z\hat{k}

% Momentum
\vec{p} = m\vec{v}

% Angular momentum
\vec{L} = \vec{r} \times \vec{p}

Common Physics Equations

Classical Mechanics

% Newton's second law
\vec{F} = m\vec{a}

% Kinetic energy
E_k = \frac{1}{2}mv^2

% Gravitational force
F = G\frac{m_1 m_2}{r^2}

% Simple harmonic motion
x(t) = A\cos(\omega t + \phi)

% Harmonic oscillator
\frac{d^2x}{dt^2} + \omega^2 x = 0

Electromagnetism

% Maxwell's equations (differential form)
\nabla \cdot \vec{E} = \frac{\rho}{\varepsilon_0}

\nabla \cdot \vec{B} = 0

\nabla \times \vec{E} = -\frac{\partial \vec{B}}{\partial t}

\nabla \times \vec{B} = \mu_0\vec{J} + \mu_0\varepsilon_0\frac{\partial \vec{E}}{\partial t}

% Lorentz force
\vec{F} = q(\vec{E} + \vec{v} \times \vec{B})

% Electric potential
\vec{E} = -\nabla \phi - \frac{\partial \vec{A}}{\partial t}

Thermodynamics

% Ideal gas law
PV = nRT

% First law
\Delta U = Q - W

% Entropy
dS = \frac{\delta Q}{T}

% Heat equation
\frac{\partial T}{\partial t} = \alpha \nabla^2 T

Quantum Mechanics

% Time-dependent Schrรถdinger equation
i\hbar\frac{\partial}{\partial t}\Psi(\vec{r},t) = \hat{H}\Psi(\vec{r},t)

% Heisenberg uncertainty principle
\Delta x \Delta p \geq \frac{\hbar}{2}

% Commutation relation
[\hat{x},\hat{p}] = i\hbar

% Dirac notation
\langle\psi|\phi\rangle
\langle\psi|\hat{A}|\phi\rangle

% Hydrogen atom wavefunction
\Psi_{n\ell m}(\vec{r}) = R_{n\ell}(r)Y_{\ell}^{m}(\theta,\phi)

Relativity

% Lorentz factor
\gamma = \frac{1}{\sqrt{1-\frac{v^2}{c^2}}}

% Time dilation
\Delta t' = \gamma\Delta t

% Length contraction
L' = \frac{L}{\gamma}

% Mass-energy equivalence
E = mc^2

% Metric line element
ds^2 = -c^2dt^2 + dx^2 + dy^2 + dz^2

Physics Packages

Essential Packages

\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{siunitx}
\usepackage{physics}
\usepackage{braket}

Braket Package for Quantum Mechanics

\usepackage{braket}

% Dirac notation
\Ket{\psi}
\Bra{\psi}
\Braket{\psi|\phi}
\Braket{\psi|A|\phi}

% States
\Ket{n,\ell,m}
\Ket{0}; \Ket{1}
\Ket{\uparrow}; \Ket{\downarrow}

Physics Package

\usepackage{physics}

% Automaticๅพฎๅˆ†
\dd{x}
\dd[n]{x}

% Derivatives
\dv{x}
\dv[n]{x}{t}
\pdv{F}{x}
\pdv[n]{F}{x}{y}

% Vector operations
\grad{f}
\div{\vec{A}}
\curl{\vec{A}}
\laplacian{f}

Experimental Physics

Error Analysis

\usepackage[separate-uncertainty=true]{siunitx}

% Value with uncertainty
\SI{9.81 +- 0.01}{\meter\per\square\second}

% Compact notation
\SI{9.81(1)}{\meter\per\square\second}

Data Tables

\begin{table}
\centering
\begin{tabular}{
  S[table-format=2.1]
  S[table-format=3.2]
  S[table-format=1.3e-1]
}
\hline
{$t$ (s)} & {$x$ (m)} & {$v$ (m/s)}\\
\hline
0.0 & 0.00 & 0.000\\
0.5 & 1.25 & 2.450\\
1.0 & 4.90 & 4.905\\
1.5 & 11.0 & 7.350\\
\hline
\end{tabular}
\end{table}

Conclusion

LaTeX handles physics notation with siunitx and amsmath. Create precise physics documents using these packages for professional-quality typesetting.

Resources

Comments