Volume of a truncated ellipsoid My objective is to find the volume of the intersection of the ellipsoid
$$\frac{x^2}{a^2}+\frac{y^2}{b^2}+\frac{z^2}{c^2}\leq1$$
and $$Ax+By+Cz\leq D$$
where $a,b,c,A,B,C,D\in\mathbb{R}$. I have done several attempts but it seems like I have to consider a lot of different cases. My approach is to give a parametrization of the intersection and then finding the volume through solving an integral. However, I can't seem to find a good enough parametrization.
 A: Define the "step function" $\theta(x) = \{1 (x>0) ; 0 (x\le0)\}$.
So the volume you want is
$$
V = \int \int \int \theta(1-(\frac{x^2}{a^2}+\frac{y^2}{b^2}+\frac{z^2}{c^2})) \theta(D-(Ax+By+Cz)) dx dy dz 
$$
Change variables to $X = x/a$, $Y= y/b$, $Z = z/c$ (w.l.o.g. $a,b,c>0$). Then
$$
V = abc \int \int \int \theta(1-(X^2+Y^2+Z^2)) \theta(D-(AaX+BbY+CcZ)) dX dY dZ 
$$
Now this is the $abc$ times the volume of a unit sphere cut by a plane. The rest which is cut off the sphere is called a spherical cap. So you need the distance $d$ from the plane to the origin. This can be computed at the locus where the plane $D-(AaX+BbY+CcZ)$ meets the plane's normal vector $(X,Y,Z) = d(Aa,Bb,Cc)/\sqrt{(Aa)^2+(Bb)^2+(Cc)^2}$. So you get $d=D/\sqrt{(Aa)^2+(Bb)^2+(Cc)^2}$.
Now you have two cases:
1) $|d| \ge 1$. This means the plane does not cut the sphere, and your volume is $V=abc\frac43 \pi$.
2) $|d| < 1$. The plane cuts the sphere. You have to subtract from the sphere's volume the volume of the spherical cap with height $h = 1 -|d|$ which is given (see link) by $V_s=\frac13 \pi h^2 (3-h)$, hence $V_s=\frac13 \pi (1 -|d|)^2 (2+|d|)$. So the volume of your body is 
$V=abc \frac13 \pi (4 - (1 -|d|)^2 (2+|d|))$ or 
$$
V=abc \frac13 \pi \Big(4 - (1-\frac{D^2}{(Aa)^2+(Bb)^2+(Cc)^2} )(2 + \frac{|D|}{\sqrt{(Aa)^2+(Bb)^2+(Cc)^2}} )\Big) 
$$
