\(\int (e+f x)^m (a+b \cot ^{-1}(c+d x)) \, dx\) [33]

Optimal result
Mathematica [A] (verified)
Rubi [A] (verified)
Maple [F]
Fricas [F]
Sympy [F(-1)]
Maxima [F]
Giac [F]
Mupad [F(-1)]
Reduce [F]

Optimal result

Integrand size = 18, antiderivative size = 177 \[ \int (e+f x)^m \left (a+b \cot ^{-1}(c+d x)\right ) \, dx=\frac {(e+f x)^{1+m} \left (a+b \cot ^{-1}(c+d x)\right )}{f (1+m)}+\frac {i b d (e+f x)^{2+m} \operatorname {Hypergeometric2F1}\left (1,2+m,3+m,\frac {d (e+f x)}{d e+(i-c) f}\right )}{2 f (d e+(i-c) f) (1+m) (2+m)}-\frac {i b d (e+f x)^{2+m} \operatorname {Hypergeometric2F1}\left (1,2+m,3+m,\frac {d (e+f x)}{d e-(i+c) f}\right )}{2 f (d e-(i+c) f) (1+m) (2+m)} \] Output:

(f*x+e)^(1+m)*(a+b*arccot(d*x+c))/f/(1+m)+1/2*I*b*d*(f*x+e)^(2+m)*hypergeo 
m([1, 2+m],[3+m],d*(f*x+e)/(d*e+(I-c)*f))/f/(d*e+(I-c)*f)/(1+m)/(2+m)-1/2* 
I*b*d*(f*x+e)^(2+m)*hypergeom([1, 2+m],[3+m],d*(f*x+e)/(d*e-(I+c)*f))/f/(d 
*e-(I+c)*f)/(1+m)/(2+m)
 

Mathematica [A] (verified)

Time = 0.28 (sec) , antiderivative size = 162, normalized size of antiderivative = 0.92 \[ \int (e+f x)^m \left (a+b \cot ^{-1}(c+d x)\right ) \, dx=\frac {(e+f x)^{1+m} \left (2 \left (a+b \cot ^{-1}(c+d x)\right )+\frac {b d (e+f x) \left ((d e-(i+c) f) \operatorname {Hypergeometric2F1}\left (1,2+m,3+m,\frac {d (e+f x)}{d e-(-i+c) f}\right )+(-d e+(-i+c) f) \operatorname {Hypergeometric2F1}\left (1,2+m,3+m,\frac {d (e+f x)}{d e-(i+c) f}\right )\right )}{(-i d e+f+i c f) (d e-(i+c) f) (2+m)}\right )}{2 f (1+m)} \] Input:

Integrate[(e + f*x)^m*(a + b*ArcCot[c + d*x]),x]
 

Output:

((e + f*x)^(1 + m)*(2*(a + b*ArcCot[c + d*x]) + (b*d*(e + f*x)*((d*e - (I 
+ c)*f)*Hypergeometric2F1[1, 2 + m, 3 + m, (d*(e + f*x))/(d*e - (-I + c)*f 
)] + (-(d*e) + (-I + c)*f)*Hypergeometric2F1[1, 2 + m, 3 + m, (d*(e + f*x) 
)/(d*e - (I + c)*f)]))/(((-I)*d*e + f + I*c*f)*(d*e - (I + c)*f)*(2 + m))) 
)/(2*f*(1 + m))
 

Rubi [A] (verified)

Time = 0.48 (sec) , antiderivative size = 236, normalized size of antiderivative = 1.33, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.222, Rules used = {5571, 5388, 485, 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 (e+f x)^m \left (a+b \cot ^{-1}(c+d x)\right ) \, dx\)

\(\Big \downarrow \) 5571

\(\displaystyle \frac {\int \left (e-\frac {c f}{d}+\frac {f (c+d x)}{d}\right )^m \left (a+b \cot ^{-1}(c+d x)\right )d(c+d x)}{d}\)

\(\Big \downarrow \) 5388

\(\displaystyle \frac {\frac {b d \int \frac {\left (e-\frac {c f}{d}+\frac {f (c+d x)}{d}\right )^{m+1}}{(c+d x)^2+1}d(c+d x)}{f (m+1)}+\frac {d \left (a+b \cot ^{-1}(c+d x)\right ) \left (\frac {f (c+d x)}{d}-\frac {c f}{d}+e\right )^{m+1}}{f (m+1)}}{d}\)

\(\Big \downarrow \) 485

\(\displaystyle \frac {\frac {d \left (a+b \cot ^{-1}(c+d x)\right ) \left (\frac {f (c+d x)}{d}-\frac {c f}{d}+e\right )^{m+1}}{f (m+1)}+\frac {b d \int \left (\frac {i \left (e-\frac {c f}{d}+\frac {f (c+d x)}{d}\right )^{m+1}}{2 (-c-d x+i)}+\frac {i \left (e-\frac {c f}{d}+\frac {f (c+d x)}{d}\right )^{m+1}}{2 (c+d x+i)}\right )d(c+d x)}{f (m+1)}}{d}\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {\frac {d \left (a+b \cot ^{-1}(c+d x)\right ) \left (\frac {f (c+d x)}{d}-\frac {c f}{d}+e\right )^{m+1}}{f (m+1)}+\frac {b d \left (\frac {i d \left (\frac {f (c+d x)}{d}-\frac {c f}{d}+e\right )^{m+2} \operatorname {Hypergeometric2F1}\left (1,m+2,m+3,\frac {d e-c f+f (c+d x)}{d e-c f+i f}\right )}{2 (m+2) (d e+(-c+i) f)}-\frac {i d \left (\frac {f (c+d x)}{d}-\frac {c f}{d}+e\right )^{m+2} \operatorname {Hypergeometric2F1}\left (1,m+2,m+3,\frac {d e-c f+f (c+d x)}{d e-(c+i) f}\right )}{2 (m+2) (d e-(c+i) f)}\right )}{f (m+1)}}{d}\)

Input:

Int[(e + f*x)^m*(a + b*ArcCot[c + d*x]),x]
 

Output:

((d*(e - (c*f)/d + (f*(c + d*x))/d)^(1 + m)*(a + b*ArcCot[c + d*x]))/(f*(1 
 + m)) + (b*d*(((I/2)*d*(e - (c*f)/d + (f*(c + d*x))/d)^(2 + m)*Hypergeome 
tric2F1[1, 2 + m, 3 + m, (d*e - c*f + f*(c + d*x))/(d*e + I*f - c*f)])/((d 
*e + (I - c)*f)*(2 + m)) - ((I/2)*d*(e - (c*f)/d + (f*(c + d*x))/d)^(2 + m 
)*Hypergeometric2F1[1, 2 + m, 3 + m, (d*e - c*f + f*(c + d*x))/(d*e - (I + 
 c)*f)])/((d*e - (I + c)*f)*(2 + m))))/(f*(1 + m)))/d
 

Defintions of rubi rules used

rule 485
Int[((c_) + (d_.)*(x_))^(n_)/((a_) + (b_.)*(x_)^2), x_Symbol] :> Int[Expand 
Integrand[(c + d*x)^n, 1/(a + b*x^2), x], x] /; FreeQ[{a, b, c, d, n}, x] & 
&  !IntegerQ[2*n]
 

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 5388
Int[((a_.) + ArcCot[(c_.)*(x_)]*(b_.))*((d_) + (e_.)*(x_))^(q_.), x_Symbol] 
 :> Simp[(d + e*x)^(q + 1)*((a + b*ArcCot[c*x])/(e*(q + 1))), x] + Simp[b*( 
c/(e*(q + 1)))   Int[(d + e*x)^(q + 1)/(1 + c^2*x^2), x], x] /; FreeQ[{a, b 
, c, d, e, q}, x] && NeQ[q, -1]
 

rule 5571
Int[((a_.) + ArcCot[(c_) + (d_.)*(x_)]*(b_.))^(p_.)*((e_.) + (f_.)*(x_))^(m 
_.), x_Symbol] :> Simp[1/d   Subst[Int[((d*e - c*f)/d + f*(x/d))^m*(a + b*A 
rcCot[x])^p, x], x, c + d*x], x] /; FreeQ[{a, b, c, d, e, f, m, p}, x] && I 
GtQ[p, 0]
 
Maple [F]

\[\int \left (f x +e \right )^{m} \left (a +b \,\operatorname {arccot}\left (d x +c \right )\right )d x\]

Input:

int((f*x+e)^m*(a+b*arccot(d*x+c)),x)
 

Output:

int((f*x+e)^m*(a+b*arccot(d*x+c)),x)
 

Fricas [F]

\[ \int (e+f x)^m \left (a+b \cot ^{-1}(c+d x)\right ) \, dx=\int { {\left (b \operatorname {arccot}\left (d x + c\right ) + a\right )} {\left (f x + e\right )}^{m} \,d x } \] Input:

integrate((f*x+e)^m*(a+b*arccot(d*x+c)),x, algorithm="fricas")
 

Output:

integral((b*arccot(d*x + c) + a)*(f*x + e)^m, x)
 

Sympy [F(-1)]

Timed out. \[ \int (e+f x)^m \left (a+b \cot ^{-1}(c+d x)\right ) \, dx=\text {Timed out} \] Input:

integrate((f*x+e)**m*(a+b*acot(d*x+c)),x)
 

Output:

Timed out
 

Maxima [F]

\[ \int (e+f x)^m \left (a+b \cot ^{-1}(c+d x)\right ) \, dx=\int { {\left (b \operatorname {arccot}\left (d x + c\right ) + a\right )} {\left (f x + e\right )}^{m} \,d x } \] Input:

integrate((f*x+e)^m*(a+b*arccot(d*x+c)),x, algorithm="maxima")
 

Output:

1/2*((f*x*arctan2(1, d*x + c) + e*arctan2(1, d*x + c))*(f*x + e)^m + 2*(f* 
m + f)*integrate(1/2*((c^2*arctan2(1, d*x + c) + arctan2(1, d*x + c))*f*m 
+ (d^2*f*m*arctan2(1, d*x + c) + d^2*f*arctan2(1, d*x + c))*x^2 + d*e + (c 
^2*arctan2(1, d*x + c) + arctan2(1, d*x + c))*f + (2*c*d*f*m*arctan2(1, d* 
x + c) + (2*c*arctan2(1, d*x + c) + 1)*d*f)*x)*(f*x + e)^m/((c^2 + 1)*f*m 
+ (d^2*f*m + d^2*f)*x^2 + (c^2 + 1)*f + 2*(c*d*f*m + c*d*f)*x), x))*b/(f*m 
 + f) + (f*x + e)^(m + 1)*a/(f*(m + 1))
 

Giac [F]

\[ \int (e+f x)^m \left (a+b \cot ^{-1}(c+d x)\right ) \, dx=\int { {\left (b \operatorname {arccot}\left (d x + c\right ) + a\right )} {\left (f x + e\right )}^{m} \,d x } \] Input:

integrate((f*x+e)^m*(a+b*arccot(d*x+c)),x, algorithm="giac")
 

Output:

integrate((b*arccot(d*x + c) + a)*(f*x + e)^m, x)
 

Mupad [F(-1)]

Timed out. \[ \int (e+f x)^m \left (a+b \cot ^{-1}(c+d x)\right ) \, dx=\int {\left (e+f\,x\right )}^m\,\left (a+b\,\mathrm {acot}\left (c+d\,x\right )\right ) \,d x \] Input:

int((e + f*x)^m*(a + b*acot(c + d*x)),x)
 

Output:

int((e + f*x)^m*(a + b*acot(c + d*x)), x)
 

Reduce [F]

\[ \int (e+f x)^m \left (a+b \cot ^{-1}(c+d x)\right ) \, dx =\text {Too large to display} \] Input:

int((f*x+e)^m*(a+b*acot(d*x+c)),x)
 

Output:

((e + f*x)**m*acot(c + d*x)*b*c*e*m + (e + f*x)**m*acot(c + d*x)*b*c*f*m*x 
 + (e + f*x)**m*a*c*e*m + (e + f*x)**m*a*c*f*m*x + (e + f*x)**m*b*e - int( 
(e + f*x)**m/(c**2*e*m + c**2*e + c**2*f*m*x + c**2*f*x + 2*c*d*e*m*x + 2* 
c*d*e*x + 2*c*d*f*m*x**2 + 2*c*d*f*x**2 + d**2*e*m*x**2 + d**2*e*x**2 + d* 
*2*f*m*x**3 + d**2*f*x**3 + e*m + e + f*m*x + f*x),x)*b*c**2*e*f*m**2 - in 
t((e + f*x)**m/(c**2*e*m + c**2*e + c**2*f*m*x + c**2*f*x + 2*c*d*e*m*x + 
2*c*d*e*x + 2*c*d*f*m*x**2 + 2*c*d*f*x**2 + d**2*e*m*x**2 + d**2*e*x**2 + 
d**2*f*m*x**3 + d**2*f*x**3 + e*m + e + f*m*x + f*x),x)*b*c**2*e*f*m + int 
((e + f*x)**m/(c**2*e*m + c**2*e + c**2*f*m*x + c**2*f*x + 2*c*d*e*m*x + 2 
*c*d*e*x + 2*c*d*f*m*x**2 + 2*c*d*f*x**2 + d**2*e*m*x**2 + d**2*e*x**2 + d 
**2*f*m*x**3 + d**2*f*x**3 + e*m + e + f*m*x + f*x),x)*b*c*d*e**2*m**2 + i 
nt((e + f*x)**m/(c**2*e*m + c**2*e + c**2*f*m*x + c**2*f*x + 2*c*d*e*m*x + 
 2*c*d*e*x + 2*c*d*f*m*x**2 + 2*c*d*f*x**2 + d**2*e*m*x**2 + d**2*e*x**2 + 
 d**2*f*m*x**3 + d**2*f*x**3 + e*m + e + f*m*x + f*x),x)*b*c*d*e**2*m - in 
t((e + f*x)**m/(c**2*e*m + c**2*e + c**2*f*m*x + c**2*f*x + 2*c*d*e*m*x + 
2*c*d*e*x + 2*c*d*f*m*x**2 + 2*c*d*f*x**2 + d**2*e*m*x**2 + d**2*e*x**2 + 
d**2*f*m*x**3 + d**2*f*x**3 + e*m + e + f*m*x + f*x),x)*b*e*f*m**2 - int(( 
e + f*x)**m/(c**2*e*m + c**2*e + c**2*f*m*x + c**2*f*x + 2*c*d*e*m*x + 2*c 
*d*e*x + 2*c*d*f*m*x**2 + 2*c*d*f*x**2 + d**2*e*m*x**2 + d**2*e*x**2 + d** 
2*f*m*x**3 + d**2*f*x**3 + e*m + e + f*m*x + f*x),x)*b*e*f*m + int(((e ...