Gauss's Law & Applications
Electric flux, Gauss's law in integral and differential form, and symmetric applications.
2.1 Electric Flux
The electric flux through a surface element $d\mathbf{a} = da\,\hat{n}$ is:
For a closed surface the total flux is $\Phi_E = \oint_S \mathbf{E} \cdot d\mathbf{a}$. The key insight: for a point charge $q$ enclosed by any closed surface, the flux depends only on $q$, not on the size or shape of the surface. This is Gauss's law.
2.2 Gauss's Law
Integral Form
The total electric flux through any closed surface equals the total charge enclosed divided by $\epsilon_0$.
2.2.1 Derivation from Coulomb's Law
Start with the field of a single point charge at the origin. For a spherical Gaussian surface of radius $r$:
For a non-spherical surface: the solid angle argument shows that $\mathbf{E} \cdot d\mathbf{a} = (q/4\pi\epsilon_0)(d\Omega)$where $d\Omega$ is the solid angle subtended. Integrating over the closed surface gives$4\pi$ steradians if $q$ is inside, and zero if outside. By superposition, Gauss's law holds for any charge distribution.
2.2.2 Differential Form โ Divergence Theorem
Applying the divergence theorem $\oint_S \mathbf{E} \cdot d\mathbf{a} = \int_\mathcal{V} \nabla \cdot \mathbf{E}\,d\tau$and writing $Q_{\rm enc} = \int_\mathcal{V} \rho\,d\tau$, since the volume is arbitrary:
This is the first of Maxwell's four equations. It states that the divergence of $\mathbf{E}$is proportional to the local charge density $\rho$.
2.3 Symmetric Applications
Gauss's law is most powerful when the charge distribution has spherical, cylindrical, or planar symmetry, reducing the surface integral to simple algebra.
Spherical symmetry: uniformly charged sphere (radius $R$)
Inside, the enclosed charge grows as $r^3$; outside, the sphere looks like a point charge.
Cylindrical symmetry: infinite line charge density $\lambda$
Gaussian surface: cylinder of radius $s$ and length $L$; end caps contribute zero flux.
Planar symmetry: infinite sheet with surface charge $\sigma$
Gaussian surface: pillbox straddling the sheet; the field is uniform and perpendicular to the sheet. Between two parallel plates of opposite charge: $E = \sigma/\epsilon_0$.
Numerical Verification of Gauss's Law
The simulation numerically integrates $\oint \mathbf{E} \cdot d\mathbf{a}$ over a spherical Gaussian surface and compares with $Q_{\rm enc}/\epsilon_0$, confirming Gauss's law to sub-percent accuracy.
Gauss's Law: Numerical Verification
Numerically integrates EยทdA over a Gaussian sphere and verifies it equals Q_enc/ฮตโ to high precision.
Click Run to execute the Python code
First run will download Python environment (~15MB)