Problem:
Find the divergence of the vector field $f(x,y,z)\uvec{i} + g(x,y,z)\uvec{j} + h(x,y,z)\uvec{k}$ where $f(x,y,z) = x$, $g(x,y,z) = z-x$, and $h(x,y,z) = \cos (z)$
from sympy import *
from sympy.vector import *

C = CoordSys3D('C')
x, y, z = C.x, C.y, C.z
f = x
g = z-x
h = cos(z)
field = f * C.i + g * C.j + h * C.k
print(divergence(field))
