How to Calculate Divergence
- 1). Write out the vector-valued function whose divergence you wish to calculate. In this case, you will simply write the given function as a sum of unit vector components: F = x^2(x-dot) + 2z(y-dot) - y(z-dot).
- 2). Take the partial derivative of F with respect to x (d/dx) and dot the resulting function with the x-dot unit vector. Note all that is meant by "partial" derivative is the derivative is only taken with respect to the "x" variable. So, d/dx(F) = 2x(x-dot) + 0(y-dot) + 0(z-dot) and d/dx(F) (dot) x-dot = 2x(x-dot) (dot) x-dot + 0(y-dot) (dot) x-dot + 0(z-dot) (dot) x-dot = 2x + 0 + 0 = 0.
- 3). Take the partial derivative of F with respect to y (d/dy) and dot the resulting function with the y-dot unit vector: d/dy(F) = 0(x-dot) + 0(y-dot) - 1(z-dot) and d/dz(F) (dot) y-dot = 0(x-dot) (dot) y-dot + 0(y-dot) (dot) y-dot -1(z-dot) (dot) y-dot = 0 + 0 + 0 = 0.
- 4). Take the partial derivative of F with respect to z (d/dz) and dot the resulting function with the z-dot unit vector: d/dz(F) = 0(x-dot) + 2(y-dot) + 0(z-dot) and d/dy(F) (dot) z-dot = 0(x-dot) (dot) z-dot + 2(y-dot) (dot) z-dot + 0(z-dot) (dot) z-dot = 0 + 0 + 0 = 0.
- 5). Take the sum of all partial derivative and dot product combinations that were generated in the previous steps to get the divergence. For this example, div F = 2x + 0 + 0 = 2x.
div F = G (dot) [x^2, 2z, -y]'
Source...