It is convenient to use spherical coordinate systems for truncating along an angle. Assuming the definition taken from Arkansas TU for radius (r) , theta (t) and phi (p) as: 
Then you can truncate the limit setting: r1 r2 t1 t2 p1 p2 :
import scipy from scipy.integrate import quad, dblquad, tplquad from numpy import *
To truncate along the plane, it is convenient to use the Cartesian coordinate system (x,y,z) , where x**2+y**2+z**2=R**2 ( see mathworld ). Here I truncate half the scope to demonstrate:
from `x1=-R` to `x2=R`<br> from `y1=0` to `y2=(R**2-x**2)**0.5`<br> from `z1=-(R**2-x**2-y**2)**0.5` to `z2=(R**2-x**2-y**2)**0.5`<br> (an useful example using lambdas): R= 2. # limits for x x1 = -R x2 = R def diff_volume(z,y,x): return 1. volume = tplquad(diff_volume, x1, x2, lambda x: 0., lambda x: (R**2-x**2)**0.5, lambda x,y: -(R**2-x**2-y**2)**0.5, lambda x,y: (R**2-x**2-y**2)**0.5 )[0]
source share