Primitive of Reciprocal of Root of a x + b by Root of p x + q/Lemma 2

Lemma for Primitive of $\frac 1 {\sqrt {\paren {a x + b} \paren {p x + q} } }$

 * $\ds \int \frac {\d x} {\sqrt {\paren {a x + b} \paren {p x + q} } } = \begin {cases}

\ds \frac 2 {\sqrt {a p} } \int \frac {\d u} {\sqrt {u^2 - \paren {\frac {b p - a q} p} } } & : a p > 0 \\ \ds \frac 2 {\sqrt {-a p} } \int \frac {\d u} {\sqrt {\paren {\frac {b p - a q} p} - u^2} } & : a p < 0 \end {cases}$

where:
 * $u := \sqrt {a x + b}$

Proof
Let us make the substitution:


 * Case $1: \quad a p > 0$


 * Case $2: \quad a p < 0$

We have:

Then:

Then: