gradient3D function

3D Volume Gradient