Physics Equations and Diagrams — Documenting Scientific Concepts

Complete guide to documenting physics concepts with KaTeX equations, Mermaid diagrams, and scientific notation

Introduction

Physics documentation requires precise mathematical notation, clear diagrams, and structured explanations. Whether you're documenting classical mechanics, electromagnetism, quantum physics, or any other physics domain, combining KaTeX for equations and Mermaid for diagrams creates professional, accessible scientific documentation.

This guide demonstrates how to document physics concepts effectively using AutEng's powerful features. You'll learn to write complex equations, create informative diagrams, and structure scientific content that's both rigorous and readable.

Why Use AutEng for Physics Documentation?

  • KaTeX Support: Write complex equations with LaTeX syntax
  • Mermaid Diagrams: Create flowcharts, state diagrams, and visual explanations
  • Real-time Preview: See equations and diagrams as you write
  • Version Control: Track changes to your scientific documentation
  • Collaboration: Share documentation with colleagues and students

What You'll Learn

  • • How to write physics equations using KaTeX
  • • Creating diagrams for physical systems and processes
  • • Documenting derivations and proofs
  • • Best practices for scientific notation
  • • Structuring physics documentation effectively

Classical Mechanics: Newton's Laws

Classical mechanics forms the foundation of physics. Let's document Newton's laws with proper equations and diagrams.

Newton's Second Law

The fundamental equation relating force, mass, and acceleration:

Newton's Second Law

The relationship between force, mass, and acceleration

Newton's Second Law states that the force acting on an object is equal to the mass of the object multiplied by its acceleration:

F=ma\vec{F} = m\vec{a}F=ma

Where:

  • F\vec{F}F is the net force vector (in Newtons, N)
  • mmm is the mass (in kilograms, kg)
  • a\vec{a}a is the acceleration vector (in m/s²)

In component form:

Fx=max,Fy=may,Fz=mazF_x = ma_x, \quad F_y = ma_y, \quad F_z = ma_zFx=max,Fy=may,Fz=maz

Kinetic Energy

The energy of motion depends on mass and velocity:

Kinetic Energy Formula

Energy of a moving object

The kinetic energy of an object with mass mmm moving at velocity vvv is:

KE=12mv2KE = \frac{1}{2}mv^2KE=21mv2

For a system of particles, the total kinetic energy is:

KEtotal=i=1n12mivi2KE_{total} = \sum_{i=1}^{n} \frac{1}{2}m_i v_i^2KEtotal=i=1n21mivi2

Derivation from Work-Energy Theorem:

Starting with W=FdxW = \int F \, dxW=Fdx and F=ma=mdvdtF = ma = m\frac{dv}{dt}F=ma=mdtdv:

W=mdvdtdx=mdxdtdv=mvdv=12mv2W = \int m\frac{dv}{dt} \, dx = \int m\frac{dx}{dt} \, dv = \int mv \, dv = \frac{1}{2}mv^2W=mdtdvdx=mdtdxdv=mvdv=21mv2

Force Diagram

Visualizing forces acting on an object using a flowchart-style diagram:

Free Body Diagram

Forces acting on an object on an inclined plane

Rendering diagram...

Equations of Motion:

Parallel to incline: ma=mgsinθfma = mg\sin\theta - fma=mgsinθf

Perpendicular to incline: N=mgcosθN = mg\cos\thetaN=mgcosθ

Electromagnetism: Maxwell's Equations

Maxwell's equations are the foundation of classical electromagnetism. Here's how to document them with proper notation and context.

The Four Maxwell Equations

Maxwell's Equations in Differential Form

The complete set of equations governing electromagnetic fields

Maxwell's equations describe how electric and magnetic fields are generated and altered by charges and currents:

1. Gauss's Law (Electric):

E=ρϵ0\nabla \cdot \vec{E} = \frac{\rho}{\epsilon_0}E=ϵ0ρ

Electric field divergence equals charge density divided by permittivity.

2. Gauss's Law (Magnetic):

B=0\nabla \cdot \vec{B} = 0B=0

No magnetic monopoles exist; magnetic field lines form closed loops.

3. Faraday's Law:

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

A changing magnetic field induces an electric field.

4. Ampère-Maxwell Law:

×B=μ0J+μ0ϵ0Et\nabla \times \vec{B} = \mu_0\vec{J} + \mu_0\epsilon_0\frac{\partial \vec{E}}{\partial t}×B=μ0J+μ0ϵ0tE

Magnetic fields are generated by currents and changing electric fields.

Where:

  • E\vec{E}E = electric field (V/m)
  • B\vec{B}B = magnetic field (T)
  • ρ\rhoρ = charge density (C/m³)
  • J\vec{J}J = current density (A/m²)
  • ϵ0\epsilon_0ϵ0 = permittivity of free space
  • μ0\mu_0μ0 = permeability of free space

Electromagnetic Wave Equation

Wave Equation Derivation

How electromagnetic waves propagate through space

Taking the curl of Faraday's law and substituting Ampère-Maxwell law (in vacuum, ρ=0\rho = 0ρ=0, J=0\vec{J} = 0J=0):

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

Using the vector identity ×(×E)=(E)2E\nabla \times (\nabla \times \vec{E}) = \nabla(\nabla \cdot \vec{E}) - \nabla^2\vec{E}×(×E)=(E)2E and E=0\nabla \cdot \vec{E} = 0E=0:

2E=μ0ϵ02Et2-\nabla^2\vec{E} = -\mu_0\epsilon_0\frac{\partial^2 \vec{E}}{\partial t^2}2E=μ0ϵ0t22E

This gives the wave equation:

2E=μ0ϵ02Et2\nabla^2\vec{E} = \mu_0\epsilon_0\frac{\partial^2 \vec{E}}{\partial t^2}2E=μ0ϵ0t22E

The wave speed is:

c=1μ0ϵ03×108 m/sc = \frac{1}{\sqrt{\mu_0\epsilon_0}} \approx 3 \times 10^8 \text{ m/s}c=μ0ϵ013×108 m/s

Electromagnetic Wave Propagation

EM Wave Diagram

Relationship between electric and magnetic field components

Rendering diagram...

Key Properties:

  • Electric and magnetic fields oscillate perpendicular to each other
  • Both fields are perpendicular to the direction of propagation
  • Energy flows in the direction of E×B\vec{E} \times \vec{B}E×B (Poynting vector)

Quantum Mechanics: Wave Functions and Operators

Quantum mechanics requires careful notation for wave functions, operators, and probability amplitudes.

Schrödinger Equation

Time-Dependent Schrödinger Equation

The fundamental equation of quantum mechanics

The time-dependent Schrödinger equation describes how quantum states evolve:

itΨ(r,t)=H^Ψ(r,t)i\hbar\frac{\partial}{\partial t}\Psi(\vec{r}, t) = \hat{H}\Psi(\vec{r}, t)itΨ(r,t)=H^Ψ(r,t)

Where:

  • Ψ(r,t)\Psi(\vec{r}, t)Ψ(r,t) is the wave function
  • =h/2π\hbar = h/2\pi=h/2π is the reduced Planck constant
  • H^\hat{H}H^ is the Hamiltonian operator

Time-Independent Form:

For stationary states with Ψ(r,t)=ψ(r)eiEt/\Psi(\vec{r}, t) = \psi(\vec{r})e^{-iEt/\hbar}Ψ(r,t)=ψ(r)eiEt/ℏ:

H^ψ(r)=Eψ(r)\hat{H}\psi(\vec{r}) = E\psi(\vec{r})H^ψ(r)=Eψ(r)

For a Particle in a Potential:

22m2ψ+V(r)ψ=Eψ-\frac{\hbar^2}{2m}\nabla^2\psi + V(\vec{r})\psi = E\psi2m22ψ+V(r)ψ=Eψ

Heisenberg Uncertainty Principle

Uncertainty Relations

Fundamental limits on simultaneous measurements

The uncertainty principle states that certain pairs of physical properties cannot be simultaneously known to arbitrary precision:

Position-Momentum Uncertainty:

ΔxΔp2\Delta x \cdot \Delta p \geq \frac{\hbar}{2}ΔxΔp2

Energy-Time Uncertainty:

ΔEΔt2\Delta E \cdot \Delta t \geq \frac{\hbar}{2}ΔEΔt2

General Form for Operators:

For any two observables A^\hat{A}A^ and B^\hat{B}B^:

ΔAΔB12[A^,B^]\Delta A \cdot \Delta B \geq \frac{1}{2}|\langle[\hat{A}, \hat{B}]\rangle|ΔAΔB21⟨[A^,B^]⟩

Where [A^,B^]=A^B^B^A^[\hat{A}, \hat{B}] = \hat{A}\hat{B} - \hat{B}\hat{A}[A^,B^]=A^B^B^A^ is the commutator.

Quantum State Evolution

State Diagram

Evolution of quantum states through measurement

Rendering diagram...

Key Concepts:

  • Before measurement: system exists in superposition of states
  • Measurement causes wave function collapse
  • Outcome is probabilistic, determined by ψiψ2|\langle\psi_i|\psi\rangle|^2ψiψ2
  • After measurement: system is in definite eigenstate

Thermodynamics: Laws and Processes

Thermodynamics deals with heat, work, and energy transfer. Let's document the fundamental laws and key processes.

The Four Laws

Laws of Thermodynamics

The fundamental principles governing energy and entropy

Zeroth Law (Thermal Equilibrium):

If systems A and B are each in thermal equilibrium with system C, then A and B are in thermal equilibrium with each other.

First Law (Energy Conservation):

ΔU=QW\Delta U = Q - WΔU=QW

Where:

  • ΔU\Delta UΔU = change in internal energy
  • QQQ = heat added to system
  • WWW = work done by system

Second Law (Entropy):

For any thermodynamic process:

ΔSuniverse0\Delta S_{universe} \geq 0ΔSuniverse0

The entropy of an isolated system never decreases. For a reversible process:

dS=dQrevTdS = \frac{dQ_{rev}}{T}dS=TdQrev

Third Law (Absolute Zero):

As temperature approaches absolute zero, the entropy of a perfect crystal approaches zero:

limT0S=0\lim_{T \to 0} S = 0limT0S=0

Carnot Cycle

Carnot Engine Efficiency

The theoretical maximum efficiency of a heat engine

The Carnot cycle represents the most efficient heat engine possible between two temperature reservoirs.

Efficiency:

η=1TCTH=WQH\eta = 1 - \frac{T_C}{T_H} = \frac{W}{Q_H}η=1THTC=QHW

Where:

  • THT_HTH = hot reservoir temperature (K)
  • TCT_CTC = cold reservoir temperature (K)
  • WWW = work output
  • QHQ_HQH = heat input from hot reservoir

Carnot Cycle Stages:

Rendering diagram...

Key Insight: No real engine can exceed Carnot efficiency.

Ideal Gas Law

Ideal Gas Relationships

Equations of state for ideal gases

Ideal Gas Law:

PV=nRTPV = nRTPV=nRT

Where:

  • PPP = pressure (Pa)
  • VVV = volume (m³)
  • nnn = number of moles
  • RRR = universal gas constant (8.314 J/(mol·K))
  • TTT = temperature (K)

Alternative Forms:

Using n=N/NAn = N/N_An=N/NA where NNN is number of molecules:

PV=NkTPV = NkTPV=NkT

Where k=R/NAk = R/N_Ak=R/NA is Boltzmann's constant.

Internal Energy of Ideal Gas:

For a monatomic ideal gas:

U=32nRTU = \frac{3}{2}nRTU=23nRT

For a diatomic ideal gas:

U=52nRTU = \frac{5}{2}nRTU=25nRT

Best Practices for Physics Documentation

Follow these guidelines to create clear, accurate, and professional physics documentation.

1. Use Standard Notation

Follow established conventions for symbols and notation:

✅ GOOD: Standard notation
- Vectors: $\vec{F}$, $\vec{v}$, $\vec{E}$
- Scalars: $m$, $T$, $E$
- Operators: $\hat{H}$, $\hat{p}$, $\nabla$
- Constants: $c$, $\hbar$, $k_B$

❌ AVOID: Non-standard notation
- Using F for both force and field
- Inconsistent vector notation
- Undefined symbols

2. Define All Variables

Always explain what each symbol represents and include units:

✅ GOOD: Complete definitions
$$F = ma$$

Where:
- $F$ = force (Newtons, N)
- $m$ = mass (kilograms, kg)
- $a$ = acceleration (m/s²)

❌ INCOMPLETE: Missing definitions
$$F = ma$$
(What are F, m, and a?)

3. Show Derivations Step-by-Step

Break complex derivations into clear, logical steps:

✅ GOOD: Clear steps
Starting with Newton's second law:
$$F = ma$$

Substituting $a = dv/dt$:
$$F = m\frac{dv}{dt}$$

Multiplying both sides by $dx$:
$$F\,dx = m\frac{dv}{dt}\,dx = mv\,dv$$

Integrating:
$$\int F\,dx = \int mv\,dv = \frac{1}{2}mv^2$$

❌ UNCLEAR: Skipping steps
$$F = ma \implies KE = \frac{1}{2}mv^2$$
(How did we get there?)

4. Use Diagrams Effectively

Complement equations with visual representations:

  • • Use flowcharts for processes and decision trees
  • • Use state diagrams for quantum states and transitions
  • • Label all components clearly
  • • Use consistent color coding
  • • Keep diagrams simple and focused

5. Provide Physical Interpretation

Don't just present equations—explain what they mean physically. Connect mathematical formalism to real-world phenomena and intuition.

6. Include Worked Examples

Demonstrate concepts with concrete numerical examples:

**Example:** Calculate the kinetic energy of a 1000 kg car traveling at 20 m/s.

Given:
- $m = 1000$ kg
- $v = 20$ m/s

Solution:
$$KE = \frac{1}{2}mv^2 = \frac{1}{2}(1000)(20)^2 = 200,000 \text{ J} = 200 \text{ kJ}$$

7. Cite Assumptions and Limits

Clearly state when equations apply and when they break down. For example, specify if an equation assumes non-relativistic speeds, ideal conditions, or classical (non-quantum) behavior.

Common Pitfalls & Solutions

Pitfall 1: Inconsistent Notation

Using the same symbol for different quantities or switching notation mid-document.

❌ WRONG: Inconsistent use of E
$$E = mc^2$$  (E for energy)
$$E = \frac{kq}{r^2}$$  (E for electric field)

✅ CORRECT: Distinct symbols
$$E = mc^2$$  (E for energy)
$$\vec{E} = \frac{kq}{r^2}\hat{r}$$  (𝐄⃗ for electric field)

Pitfall 2: Missing Units or Dimensions

Forgetting to specify units makes equations ambiguous and error-prone.

❌ WRONG: No units
The speed of light is $c = 3 \times 10^8$

✅ CORRECT: Include units
The speed of light is $c = 3 \times 10^8$ m/s

✅ BETTER: Dimensional analysis
$$[c] = \frac{[L]}{[T]} = \text{m/s}$$

Pitfall 3: Confusing Scalars and Vectors

Not distinguishing between scalar and vector quantities leads to confusion.

❌ WRONG: Unclear if vector or scalar
$$F = ma$$

✅ CORRECT: Clear vector notation
$$\vec{F} = m\vec{a}$$

Or in component form:
$$F_x = ma_x, \quad F_y = ma_y, \quad F_z = ma_z$$

Pitfall 4: Overly Complex Diagrams

Trying to show too much in one diagram makes it hard to understand.

❌ AVOID:

  • • Cramming multiple concepts into one diagram
  • • Using too many colors or styles
  • • Unlabeled or poorly labeled components
  • • Overly detailed technical drawings

✅ INSTEAD:

  • • Create separate diagrams for different concepts
  • • Use consistent, minimal color schemes
  • • Label everything clearly
  • • Focus on the key idea

Pitfall 5: Skipping Mathematical Steps

Jumping from one equation to another without showing the intermediate steps.

❌ WRONG: Missing steps
$$\nabla \times \vec{E} = -\frac{\partial \vec{B}}{\partial t}$$
Therefore:
$$\nabla^2\vec{E} = \mu_0\epsilon_0\frac{\partial^2 \vec{E}}{\partial t^2}$$

✅ CORRECT: Show the derivation
Starting with Faraday's law:
$$\nabla \times \vec{E} = -\frac{\partial \vec{B}}{\partial t}$$

Take the curl of both sides:
$$\nabla \times (\nabla \times \vec{E}) = -\frac{\partial}{\partial t}(\nabla \times \vec{B})$$

Apply Ampère-Maxwell law and vector identity...
[Continue with full derivation]

Advanced Documentation Techniques

Take your physics documentation to the next level with these advanced techniques.

Tensor Notation

For advanced topics like general relativity, use proper tensor notation:

Einstein field equations in tensor notation:

$$G_{\mu\nu} + \Lambda g_{\mu\nu} = \frac{8\pi G}{c^4}T_{\mu\nu}$$

Where:
- $G_{\mu\nu}$ = Einstein tensor
- $g_{\mu\nu}$ = metric tensor
- $\Lambda$ = cosmological constant
- $T_{\mu\nu}$ = stress-energy tensor
- Greek indices run from 0 to 3 (spacetime)

Bra-Ket Notation

For quantum mechanics, use Dirac notation consistently:

Quantum state: $|\psi\rangle$
Dual state: $\langle\psi|$
Inner product: $\langle\phi|\psi\rangle$
Outer product: $|\psi\rangle\langle\phi|$
Expectation value: $\langle\psi|\hat{A}|\psi\rangle$

Example - Spin states:
$$|\uparrow\rangle = \begin{pmatrix} 1 \\ 0 \end{pmatrix}, \quad |\downarrow\rangle = \begin{pmatrix} 0 \\ 0 \end{pmatrix}$$

Matrix Representations

Use matrices for operators and transformations:

Pauli matrices for spin-1/2:

$$\sigma_x = \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix}, \quad
\sigma_y = \begin{pmatrix} 0 & -i \\ i & 0 \end{pmatrix}, \quad
\sigma_z = \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix}$$

Rotation matrix in 2D:

$$R(\theta) = \begin{pmatrix} \cos\theta & -\sin\theta \\ \sin\theta & \cos\theta \end{pmatrix}$$

Combining Multiple Representations

Show the same concept in different forms for deeper understanding:

  • • Differential form and integral form
  • • Coordinate representation and abstract notation
  • • Time domain and frequency domain
  • • Position space and momentum space

Conclusion

Effective physics documentation combines precise mathematical notation, clear diagrams, and thoughtful explanations. By using KaTeX for equations and Mermaid for diagrams, you can create professional scientific documentation that's both rigorous and accessible.

Key Takeaways

  • • Use standard notation and define all variables
  • • Show derivations step-by-step with clear explanations
  • • Complement equations with diagrams and visual aids
  • • Provide physical interpretation alongside mathematical formalism
  • • Include worked examples and specify assumptions
  • • Keep diagrams focused and well-labeled
  • • Maintain consistency throughout your documentation

Next Steps

Ready to create your own physics documentation? Start with:

Related Content

Ready to Start?

Start creating beautiful technical documentation with AutEng.

Get Started with AutEng