Navigation

Operators and Keywords

Function List:

C++ API

Function File: div = divergence (x, y, z, fx, fy, fz)
Function File: div = divergence (fx, fy, fz)
Function File: div = divergence (x, y, fx, fy)
Function File: div = divergence (fx, fy)

Calculate divergence of a vector field given by the arrays fx, fy, and fz or fx, fy respectively.

                  d               d               d
div F(x,y,z)  =   -- F(x,y,z)  +  -- F(x,y,z)  +  -- F(x,y,z)
                  dx              dy              dz

The coordinates of the vector field can be given by the arguments x, y, z or x, y respectively.

See also: curl, gradient, del2, dot.

Package: octave