Integrand size = 22, antiderivative size = 86 \[ \int \frac {(A+B x) (d+e x)}{\left (b x+c x^2\right )^2} \, dx=-\frac {A d}{b^2 x}+\frac {(b B-A c) (c d-b e)}{b^2 c (b+c x)}+\frac {(b B d-2 A c d+A b e) \log (x)}{b^3}-\frac {(b B d-2 A c d+A b e) \log (b+c x)}{b^3} \] Output:
-A*d/b^2/x+(-A*c+B*b)*(-b*e+c*d)/b^2/c/(c*x+b)+(A*b*e-2*A*c*d+B*b*d)*ln(x) /b^3-(A*b*e-2*A*c*d+B*b*d)*ln(c*x+b)/b^3
Time = 0.12 (sec) , antiderivative size = 80, normalized size of antiderivative = 0.93 \[ \int \frac {(A+B x) (d+e x)}{\left (b x+c x^2\right )^2} \, dx=-\frac {\frac {A b d}{x}+\frac {b (b B-A c) (-c d+b e)}{c (b+c x)}-(b B d-2 A c d+A b e) \log (x)+(b B d-2 A c d+A b e) \log (b+c x)}{b^3} \] Input:
Integrate[((A + B*x)*(d + e*x))/(b*x + c*x^2)^2,x]
Output:
-(((A*b*d)/x + (b*(b*B - A*c)*(-(c*d) + b*e))/(c*(b + c*x)) - (b*B*d - 2*A *c*d + A*b*e)*Log[x] + (b*B*d - 2*A*c*d + A*b*e)*Log[b + c*x])/b^3)
Time = 0.47 (sec) , antiderivative size = 86, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.091, Rules used = {1206, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {(A+B x) (d+e x)}{\left (b x+c x^2\right )^2} \, dx\) |
\(\Big \downarrow \) 1206 |
\(\displaystyle \int \left (\frac {A b e-2 A c d+b B d}{b^3 x}-\frac {c (A b e-2 A c d+b B d)}{b^3 (b+c x)}+\frac {(b B-A c) (b e-c d)}{b^2 (b+c x)^2}+\frac {A d}{b^2 x^2}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {\log (x) (A b e-2 A c d+b B d)}{b^3}-\frac {\log (b+c x) (A b e-2 A c d+b B d)}{b^3}+\frac {(b B-A c) (c d-b e)}{b^2 c (b+c x)}-\frac {A d}{b^2 x}\) |
Input:
Int[((A + B*x)*(d + e*x))/(b*x + c*x^2)^2,x]
Output:
-((A*d)/(b^2*x)) + ((b*B - A*c)*(c*d - b*e))/(b^2*c*(b + c*x)) + ((b*B*d - 2*A*c*d + A*b*e)*Log[x])/b^3 - ((b*B*d - 2*A*c*d + A*b*e)*Log[b + c*x])/b ^3
Int[((d_) + (e_.)*(x_))^(m_.)*((f_) + (g_.)*(x_))^(n_.)*((b_.)*(x_) + (c_.) *(x_)^2)^(p_), x_Symbol] :> Int[ExpandIntegrand[x^p*(d + e*x)^m*(f + g*x)^n *(b + c*x)^p, x], x] /; FreeQ[{b, c, d, e, f, g}, x] && ILtQ[p, -1] && Inte gersQ[m, n]
Time = 0.71 (sec) , antiderivative size = 97, normalized size of antiderivative = 1.13
method | result | size |
default | \(-\frac {-A b c e +A \,c^{2} d +b^{2} B e -B b c d}{b^{2} c \left (c x +b \right )}-\frac {\left (A b e -2 A c d +B b d \right ) \ln \left (c x +b \right )}{b^{3}}+\frac {\left (A b e -2 A c d +B b d \right ) \ln \left (x \right )}{b^{3}}-\frac {A d}{b^{2} x}\) | \(97\) |
norman | \(\frac {-\frac {A d}{b}-\frac {\left (A b c e -2 A \,c^{2} d -b^{2} B e +B b c d \right ) x^{2}}{b^{3}}}{x \left (c x +b \right )}+\frac {\left (A b e -2 A c d +B b d \right ) \ln \left (x \right )}{b^{3}}-\frac {\left (A b e -2 A c d +B b d \right ) \ln \left (c x +b \right )}{b^{3}}\) | \(99\) |
risch | \(\frac {\frac {\left (A b c e -2 A \,c^{2} d -b^{2} B e +B b c d \right ) x}{b^{2} c}-\frac {A d}{b}}{x \left (c x +b \right )}+\frac {\ln \left (-x \right ) A e}{b^{2}}-\frac {2 \ln \left (-x \right ) A c d}{b^{3}}+\frac {\ln \left (-x \right ) B d}{b^{2}}-\frac {\ln \left (c x +b \right ) A e}{b^{2}}+\frac {2 \ln \left (c x +b \right ) A c d}{b^{3}}-\frac {\ln \left (c x +b \right ) B d}{b^{2}}\) | \(126\) |
parallelrisch | \(\frac {A \ln \left (x \right ) x^{2} b \,c^{2} e -2 A \ln \left (x \right ) x^{2} c^{3} d -A \ln \left (c x +b \right ) x^{2} b \,c^{2} e +2 A \ln \left (c x +b \right ) x^{2} c^{3} d +B \ln \left (x \right ) x^{2} b \,c^{2} d -B \ln \left (c x +b \right ) x^{2} b \,c^{2} d +A \ln \left (x \right ) x \,b^{2} c e -2 A \ln \left (x \right ) x b \,c^{2} d -A \ln \left (c x +b \right ) x \,b^{2} c e +2 A \ln \left (c x +b \right ) x b \,c^{2} d +B \ln \left (x \right ) x \,b^{2} c d -B \ln \left (c x +b \right ) x \,b^{2} c d +A x \,b^{2} c e -2 A x b \,c^{2} d -B x \,b^{3} e +B \,b^{2} c d x -A \,b^{2} c d}{b^{3} c x \left (c x +b \right )}\) | \(222\) |
Input:
int((B*x+A)*(e*x+d)/(c*x^2+b*x)^2,x,method=_RETURNVERBOSE)
Output:
-(-A*b*c*e+A*c^2*d+B*b^2*e-B*b*c*d)/b^2/c/(c*x+b)-(A*b*e-2*A*c*d+B*b*d)*ln (c*x+b)/b^3+(A*b*e-2*A*c*d+B*b*d)*ln(x)/b^3-A*d/b^2/x
Leaf count of result is larger than twice the leaf count of optimal. 184 vs. \(2 (86) = 172\).
Time = 0.07 (sec) , antiderivative size = 184, normalized size of antiderivative = 2.14 \[ \int \frac {(A+B x) (d+e x)}{\left (b x+c x^2\right )^2} \, dx=-\frac {A b^{2} c d - {\left ({\left (B b^{2} c - 2 \, A b c^{2}\right )} d - {\left (B b^{3} - A b^{2} c\right )} e\right )} x + {\left ({\left (A b c^{2} e + {\left (B b c^{2} - 2 \, A c^{3}\right )} d\right )} x^{2} + {\left (A b^{2} c e + {\left (B b^{2} c - 2 \, A b c^{2}\right )} d\right )} x\right )} \log \left (c x + b\right ) - {\left ({\left (A b c^{2} e + {\left (B b c^{2} - 2 \, A c^{3}\right )} d\right )} x^{2} + {\left (A b^{2} c e + {\left (B b^{2} c - 2 \, A b c^{2}\right )} d\right )} x\right )} \log \left (x\right )}{b^{3} c^{2} x^{2} + b^{4} c x} \] Input:
integrate((B*x+A)*(e*x+d)/(c*x^2+b*x)^2,x, algorithm="fricas")
Output:
-(A*b^2*c*d - ((B*b^2*c - 2*A*b*c^2)*d - (B*b^3 - A*b^2*c)*e)*x + ((A*b*c^ 2*e + (B*b*c^2 - 2*A*c^3)*d)*x^2 + (A*b^2*c*e + (B*b^2*c - 2*A*b*c^2)*d)*x )*log(c*x + b) - ((A*b*c^2*e + (B*b*c^2 - 2*A*c^3)*d)*x^2 + (A*b^2*c*e + ( B*b^2*c - 2*A*b*c^2)*d)*x)*log(x))/(b^3*c^2*x^2 + b^4*c*x)
Leaf count of result is larger than twice the leaf count of optimal. 233 vs. \(2 (82) = 164\).
Time = 0.76 (sec) , antiderivative size = 233, normalized size of antiderivative = 2.71 \[ \int \frac {(A+B x) (d+e x)}{\left (b x+c x^2\right )^2} \, dx=\frac {- A b c d + x \left (A b c e - 2 A c^{2} d - B b^{2} e + B b c d\right )}{b^{3} c x + b^{2} c^{2} x^{2}} + \frac {\left (A b e - 2 A c d + B b d\right ) \log {\left (x + \frac {A b^{2} e - 2 A b c d + B b^{2} d - b \left (A b e - 2 A c d + B b d\right )}{2 A b c e - 4 A c^{2} d + 2 B b c d} \right )}}{b^{3}} - \frac {\left (A b e - 2 A c d + B b d\right ) \log {\left (x + \frac {A b^{2} e - 2 A b c d + B b^{2} d + b \left (A b e - 2 A c d + B b d\right )}{2 A b c e - 4 A c^{2} d + 2 B b c d} \right )}}{b^{3}} \] Input:
integrate((B*x+A)*(e*x+d)/(c*x**2+b*x)**2,x)
Output:
(-A*b*c*d + x*(A*b*c*e - 2*A*c**2*d - B*b**2*e + B*b*c*d))/(b**3*c*x + b** 2*c**2*x**2) + (A*b*e - 2*A*c*d + B*b*d)*log(x + (A*b**2*e - 2*A*b*c*d + B *b**2*d - b*(A*b*e - 2*A*c*d + B*b*d))/(2*A*b*c*e - 4*A*c**2*d + 2*B*b*c*d ))/b**3 - (A*b*e - 2*A*c*d + B*b*d)*log(x + (A*b**2*e - 2*A*b*c*d + B*b**2 *d + b*(A*b*e - 2*A*c*d + B*b*d))/(2*A*b*c*e - 4*A*c**2*d + 2*B*b*c*d))/b* *3
Time = 0.03 (sec) , antiderivative size = 106, normalized size of antiderivative = 1.23 \[ \int \frac {(A+B x) (d+e x)}{\left (b x+c x^2\right )^2} \, dx=-\frac {A b c d - {\left ({\left (B b c - 2 \, A c^{2}\right )} d - {\left (B b^{2} - A b c\right )} e\right )} x}{b^{2} c^{2} x^{2} + b^{3} c x} - \frac {{\left (A b e + {\left (B b - 2 \, A c\right )} d\right )} \log \left (c x + b\right )}{b^{3}} + \frac {{\left (A b e + {\left (B b - 2 \, A c\right )} d\right )} \log \left (x\right )}{b^{3}} \] Input:
integrate((B*x+A)*(e*x+d)/(c*x^2+b*x)^2,x, algorithm="maxima")
Output:
-(A*b*c*d - ((B*b*c - 2*A*c^2)*d - (B*b^2 - A*b*c)*e)*x)/(b^2*c^2*x^2 + b^ 3*c*x) - (A*b*e + (B*b - 2*A*c)*d)*log(c*x + b)/b^3 + (A*b*e + (B*b - 2*A* c)*d)*log(x)/b^3
Time = 0.24 (sec) , antiderivative size = 108, normalized size of antiderivative = 1.26 \[ \int \frac {(A+B x) (d+e x)}{\left (b x+c x^2\right )^2} \, dx=\frac {{\left (B b d - 2 \, A c d + A b e\right )} \log \left ({\left | x \right |}\right )}{b^{3}} - \frac {{\left (B b c d - 2 \, A c^{2} d + A b c e\right )} \log \left ({\left | c x + b \right |}\right )}{b^{3} c} + \frac {B b c d x - 2 \, A c^{2} d x - B b^{2} e x + A b c e x - A b c d}{{\left (c x^{2} + b x\right )} b^{2} c} \] Input:
integrate((B*x+A)*(e*x+d)/(c*x^2+b*x)^2,x, algorithm="giac")
Output:
(B*b*d - 2*A*c*d + A*b*e)*log(abs(x))/b^3 - (B*b*c*d - 2*A*c^2*d + A*b*c*e )*log(abs(c*x + b))/(b^3*c) + (B*b*c*d*x - 2*A*c^2*d*x - B*b^2*e*x + A*b*c *e*x - A*b*c*d)/((c*x^2 + b*x)*b^2*c)
Time = 0.12 (sec) , antiderivative size = 117, normalized size of antiderivative = 1.36 \[ \int \frac {(A+B x) (d+e x)}{\left (b x+c x^2\right )^2} \, dx=-\frac {\frac {A\,d}{b}+\frac {x\,\left (2\,A\,c^2\,d+B\,b^2\,e-A\,b\,c\,e-B\,b\,c\,d\right )}{b^2\,c}}{c\,x^2+b\,x}-\frac {2\,\mathrm {atanh}\left (\frac {\left (b\,\left (A\,e+B\,d\right )-2\,A\,c\,d\right )\,\left (b+2\,c\,x\right )}{b\,\left (A\,b\,e-2\,A\,c\,d+B\,b\,d\right )}\right )\,\left (b\,\left (A\,e+B\,d\right )-2\,A\,c\,d\right )}{b^3} \] Input:
int(((A + B*x)*(d + e*x))/(b*x + c*x^2)^2,x)
Output:
- ((A*d)/b + (x*(2*A*c^2*d + B*b^2*e - A*b*c*e - B*b*c*d))/(b^2*c))/(b*x + c*x^2) - (2*atanh(((b*(A*e + B*d) - 2*A*c*d)*(b + 2*c*x))/(b*(A*b*e - 2*A *c*d + B*b*d)))*(b*(A*e + B*d) - 2*A*c*d))/b^3
Time = 0.26 (sec) , antiderivative size = 205, normalized size of antiderivative = 2.38 \[ \int \frac {(A+B x) (d+e x)}{\left (b x+c x^2\right )^2} \, dx=\frac {-\mathrm {log}\left (c x +b \right ) a \,b^{2} e x +2 \,\mathrm {log}\left (c x +b \right ) a b c d x -\mathrm {log}\left (c x +b \right ) a b c e \,x^{2}+2 \,\mathrm {log}\left (c x +b \right ) a \,c^{2} d \,x^{2}-\mathrm {log}\left (c x +b \right ) b^{3} d x -\mathrm {log}\left (c x +b \right ) b^{2} c d \,x^{2}+\mathrm {log}\left (x \right ) a \,b^{2} e x -2 \,\mathrm {log}\left (x \right ) a b c d x +\mathrm {log}\left (x \right ) a b c e \,x^{2}-2 \,\mathrm {log}\left (x \right ) a \,c^{2} d \,x^{2}+\mathrm {log}\left (x \right ) b^{3} d x +\mathrm {log}\left (x \right ) b^{2} c d \,x^{2}-a \,b^{2} d -a b c e \,x^{2}+2 a \,c^{2} d \,x^{2}+b^{3} e \,x^{2}-b^{2} c d \,x^{2}}{b^{3} x \left (c x +b \right )} \] Input:
int((B*x+A)*(e*x+d)/(c*x^2+b*x)^2,x)
Output:
( - log(b + c*x)*a*b**2*e*x + 2*log(b + c*x)*a*b*c*d*x - log(b + c*x)*a*b* c*e*x**2 + 2*log(b + c*x)*a*c**2*d*x**2 - log(b + c*x)*b**3*d*x - log(b + c*x)*b**2*c*d*x**2 + log(x)*a*b**2*e*x - 2*log(x)*a*b*c*d*x + log(x)*a*b*c *e*x**2 - 2*log(x)*a*c**2*d*x**2 + log(x)*b**3*d*x + log(x)*b**2*c*d*x**2 - a*b**2*d - a*b*c*e*x**2 + 2*a*c**2*d*x**2 + b**3*e*x**2 - b**2*c*d*x**2) /(b**3*x*(b + c*x))