# 5.7: Gauss’ Law - Differential Form

- Page ID
- 6308

The integral form of Gauss’ Law is a calculation of enclosed charge \(Q_{encl}\) using the surrounding density of electric flux:

\[\oint_{\mathcal S} {\bf D}\cdot d{\bf s} = Q_{encl} \label{m0045_eGLIF}\]

where \({\bf D}\) is electric flux density and \({\mathcal S}\) is the enclosing surface. It is also sometimes necessary to do the inverse calculation (i.e., determine electric field associated with a charge distribution). This is sometimes possible using Equation \ref{m0045_eGLIF} if the symmetry of the problem permits; see examples in Section [m0014_Gauss_Law_Integral_Form] and [m0149_E_due_to_Inf_Line_Charge]. If the problem does not exhibit the necessary symmetry, then it seems that one must fall back to the family of techniques presented in Section [m0104_E_due_to_a_Continuous_Distribution_of_Charge] requiring direct integration over the charge, which is derived from Coulomb’s Law.

However, even the Coulomb’s Law / direct integration approach has a limitation that is very important to recognize: It does not account for the presence of structures that may influence the electric field. For example, the electric field due to a charge in free space is different from the electric field due to the same charge located near a perfectly-conducting surface. In fact, these approaches do not account for the possibility of *any* spatial variation in material composition, which rules out their use in many engineering applications.

To address this broader scope of problems, we require an alternative form of Gauss’ Law that applies at individual points in space. That is, we require Gauss’ Law expressed in the form of a differential equation, as opposed to an integral equation. This facilitates the use of Gauss’ Law even in problems that do not exhibit sufficient symmetry and that involve material boundaries and spatial variations in material constitutive parameters. Given this differential equation and the boundary conditions imposed by structure and materials, we may then solve for the electric field in these more complicated scenarios. In this section, we derive the desired differential form of Gauss’ Law. Elsewhere (in particular, in Section [m0067_Poissons_and_Laplaces_Equations]) we use this equation as a tool to find electric fields in problems involving material boundaries.

There are in fact two methods to develop the desired differential equation. One method is via the definition of divergence, whereas the other is via the divergence theorem. Both methods are presented below because each provides a different bit of insight. Let’s explore the first method:

**Derivation via the definition of divergence.** Let the geometrical volume enclosed by \({\mathcal S}\) be \({\mathcal V}\), which has volume \(V\) (units of m\(^3\)). Dividing both sides of Equation \ref{[m0045_eGLIF} by \(V\) and taking the limit as \(V \to 0\):

\[\lim_{V \to 0} \frac{ \oint_{\mathcal S}{ {\bf D} \cdot d{\bf s} } }{V} = \lim_{V \to 0} \frac{ Q_{encl} }{V}\]

The quantity on the right hand side is the volume charge density \(\rho_v\) (units of C/m\(^3\)) at the point at which we converge after letting the volume go to zero. The left hand side is, by definition, the *divergence* of \({\bf D}\), indicated in mathematical notation as “\(\nabla \cdot {\bf D}\)” (see Section [m0044_Divergence]). Thus, we have *Gauss’ Law in differential form*:

\[\boxed{ \nabla \cdot {\bf D} = \rho_v } \label{m0045_eGLDF}\]

To interpret this equation, recall that divergence is simply the flux (in this case, *electric* flux) per unit volume.

Gauss’ Law in differential form (Equation \ref{m0045_eGLDF}) says that the electric flux per unit volume originating from a point in space is equal to the volume charge density at that point.

**Derivation via the divergence theorem.** Equation \ref{m0045_eGLDF} may also be obtained from Equation \ref{m0045_eGLIF} using the Divergence Theorem, which in the present case may be written:

\[\int_{\mathcal V} \left( \nabla \cdot {\bf D} \right) dv = \oint_{\mathcal S} {\bf D}\cdot d{\bf s}\]

From Equation \ref{m0045_eGLIF}, we see that the right hand side of the equation may be replaced with the enclosed charge:

\[\int_{\mathcal V} \left( \nabla \cdot {\bf D} \right) dv = Q_{encl}\]

Furthermore, the enclosed charge can be expressed as an integration of the volume charge density \(\rho_v\) over \({\mathcal V}\): \[\int_{\mathcal V} \left( \nabla \cdot {\bf D} \right) dv = \int_{\mathcal V}\rho_v dv\] The above relationship must hold regardless of the specific location or shape of \({\mathcal V}\). The only way this is possible is if the integrands are equal. Thus, \(\nabla \cdot {\bf D}=\rho_v\), and we have obtained Equation \ref{m0045_eGLDF}.

Example \(\PageIndex{1}\): Determining the charge density at a point, given the associated electric field

The electric field intensity in free space is \[{\bf E}({\bf r}) = \hat{\bf x}A x^2 + \hat{\bf y}B z + \hat{\bf z}C x^2 z \nonumber\] where \(A=3~\mbox{V/m\)^3\(}\), \(B=2~\mbox{V/m\)^2\(}\), and \(C=1~\mbox{V/m\)^4\(}\). What is the charge density at \({\bf r} = \hat{\bf x}2 - \hat{\bf y}2\) m?

**Solution**

First, we use \({\bf D} = \epsilon {\bf E}\) to get \({\bf D}\). Since the problem is in free space, \(\epsilon = \epsilon_0\). Thus we have that the volume charge density is

Now calculating the charge density at the specified location \({\bf r}\):

To obtain the electric field from the charge distribution in the presence of boundary conditions imposed by materials and structure, we must enforce the relevant boundary conditions. These boundary conditions are presented in Sections [m0020_Boundary_Conditions_on_E] and [m0021_Boundary_Conditions_on_D]. Frequently, a simpler approach requiring only the boundary conditions on the electric potential (\(V(\bf{r})\)) is possible; this is presented in Section [m0067_Poissons_and_Laplaces_Equations].

Furthermore, the reader should note the following. Gauss’ Law does not always necessarily *fully* constrain possible solutions for the electric field. For that, we might also need Kirchoff’s Voltage Law; see Section [m0152_KVL_Electrostatics_Integral-to-Differential].

Before moving on, it is worth noting that Equation \ref{m0045_eGLDF} can be solved in the special case in which there are no boundary conditions to satisfy; i.e., for charge only, in a uniform and unbounded medium. In fact, no additional electromagnetic theory is required to do this. Here’s the solution:

\[{\bf D}({\bf r}) = \frac{1}{4\pi} \int_{\mathcal V} { \frac{{\bf r}-{\bf r}'}{\left|{\bf r}-{\bf r}'\right|^3}~\rho_v({\bf r}')~dv}\]

which we recognize as one of the results obtained in Section [m0104_E_due_to_a_Continuous_Distribution_of_Charge] (after dividing both sides by \(\epsilon\) to get \({\bf E}\)). It is reasonable to conclude that Gauss’ Law (in either integral or differential form) is fundamental, whereas Coulomb’s Law is merely a consequence of Gauss’ Law.