\(\int x \csc ^{-1}(a+b x)^2 \, dx\) [29]

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

Optimal result

Integrand size = 10, antiderivative size = 145 \[ \int x \csc ^{-1}(a+b x)^2 \, dx=\frac {(a+b x) \sqrt {1-\frac {1}{(a+b x)^2}} \csc ^{-1}(a+b x)}{b^2}-\frac {a^2 \csc ^{-1}(a+b x)^2}{2 b^2}+\frac {1}{2} x^2 \csc ^{-1}(a+b x)^2-\frac {4 a \csc ^{-1}(a+b x) \text {arctanh}\left (e^{i \csc ^{-1}(a+b x)}\right )}{b^2}+\frac {\log (a+b x)}{b^2}+\frac {2 i a \operatorname {PolyLog}\left (2,-e^{i \csc ^{-1}(a+b x)}\right )}{b^2}-\frac {2 i a \operatorname {PolyLog}\left (2,e^{i \csc ^{-1}(a+b x)}\right )}{b^2} \] Output:

(b*x+a)*(1-1/(b*x+a)^2)^(1/2)*arccsc(b*x+a)/b^2-1/2*a^2*arccsc(b*x+a)^2/b^ 
2+1/2*x^2*arccsc(b*x+a)^2-4*a*arccsc(b*x+a)*arctanh(I/(b*x+a)+(1-1/(b*x+a) 
^2)^(1/2))/b^2+ln(b*x+a)/b^2+2*I*a*polylog(2,-I/(b*x+a)-(1-1/(b*x+a)^2)^(1 
/2))/b^2-2*I*a*polylog(2,I/(b*x+a)+(1-1/(b*x+a)^2)^(1/2))/b^2
 

Mathematica [A] (verified)

Time = 0.61 (sec) , antiderivative size = 213, normalized size of antiderivative = 1.47 \[ \int x \csc ^{-1}(a+b x)^2 \, dx=\frac {2 a \sqrt {\frac {-1+a^2+2 a b x+b^2 x^2}{(a+b x)^2}} \csc ^{-1}(a+b x)+2 b x \sqrt {\frac {-1+a^2+2 a b x+b^2 x^2}{(a+b x)^2}} \csc ^{-1}(a+b x)-a^2 \csc ^{-1}(a+b x)^2+b^2 x^2 \csc ^{-1}(a+b x)^2+4 a \csc ^{-1}(a+b x) \log \left (1-e^{i \csc ^{-1}(a+b x)}\right )-4 a \csc ^{-1}(a+b x) \log \left (1+e^{i \csc ^{-1}(a+b x)}\right )-2 \log \left (\frac {1}{a+b x}\right )+4 i a \operatorname {PolyLog}\left (2,-e^{i \csc ^{-1}(a+b x)}\right )-4 i a \operatorname {PolyLog}\left (2,e^{i \csc ^{-1}(a+b x)}\right )}{2 b^2} \] Input:

Integrate[x*ArcCsc[a + b*x]^2,x]
 

Output:

(2*a*Sqrt[(-1 + a^2 + 2*a*b*x + b^2*x^2)/(a + b*x)^2]*ArcCsc[a + b*x] + 2* 
b*x*Sqrt[(-1 + a^2 + 2*a*b*x + b^2*x^2)/(a + b*x)^2]*ArcCsc[a + b*x] - a^2 
*ArcCsc[a + b*x]^2 + b^2*x^2*ArcCsc[a + b*x]^2 + 4*a*ArcCsc[a + b*x]*Log[1 
 - E^(I*ArcCsc[a + b*x])] - 4*a*ArcCsc[a + b*x]*Log[1 + E^(I*ArcCsc[a + b* 
x])] - 2*Log[(a + b*x)^(-1)] + (4*I)*a*PolyLog[2, -E^(I*ArcCsc[a + b*x])] 
- (4*I)*a*PolyLog[2, E^(I*ArcCsc[a + b*x])])/(2*b^2)
 

Rubi [A] (verified)

Time = 0.47 (sec) , antiderivative size = 137, normalized size of antiderivative = 0.94, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.600, Rules used = {5782, 25, 4927, 3042, 4678, 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 x \csc ^{-1}(a+b x)^2 \, dx\)

\(\Big \downarrow \) 5782

\(\displaystyle -\frac {\int b x (a+b x)^2 \sqrt {1-\frac {1}{(a+b x)^2}} \csc ^{-1}(a+b x)^2d\csc ^{-1}(a+b x)}{b^2}\)

\(\Big \downarrow \) 25

\(\displaystyle \frac {\int -b x (a+b x)^2 \sqrt {1-\frac {1}{(a+b x)^2}} \csc ^{-1}(a+b x)^2d\csc ^{-1}(a+b x)}{b^2}\)

\(\Big \downarrow \) 4927

\(\displaystyle -\frac {\int b^2 x^2 \csc ^{-1}(a+b x)d\csc ^{-1}(a+b x)-\frac {1}{2} b^2 x^2 \csc ^{-1}(a+b x)^2}{b^2}\)

\(\Big \downarrow \) 3042

\(\displaystyle -\frac {\int \csc ^{-1}(a+b x) \left (a-\csc \left (\csc ^{-1}(a+b x)\right )\right )^2d\csc ^{-1}(a+b x)-\frac {1}{2} b^2 x^2 \csc ^{-1}(a+b x)^2}{b^2}\)

\(\Big \downarrow \) 4678

\(\displaystyle -\frac {\int \left (\csc ^{-1}(a+b x) a^2-2 (a+b x) \csc ^{-1}(a+b x) a+(a+b x)^2 \csc ^{-1}(a+b x)\right )d\csc ^{-1}(a+b x)-\frac {1}{2} b^2 x^2 \csc ^{-1}(a+b x)^2}{b^2}\)

\(\Big \downarrow \) 2009

\(\displaystyle -\frac {\frac {1}{2} a^2 \csc ^{-1}(a+b x)^2+4 a \csc ^{-1}(a+b x) \text {arctanh}\left (e^{i \csc ^{-1}(a+b x)}\right )-\frac {1}{2} b^2 x^2 \csc ^{-1}(a+b x)^2-2 i a \operatorname {PolyLog}\left (2,-e^{i \csc ^{-1}(a+b x)}\right )+2 i a \operatorname {PolyLog}\left (2,e^{i \csc ^{-1}(a+b x)}\right )+\log \left (\frac {1}{a+b x}\right )-(a+b x) \sqrt {1-\frac {1}{(a+b x)^2}} \csc ^{-1}(a+b x)}{b^2}\)

Input:

Int[x*ArcCsc[a + b*x]^2,x]
 

Output:

-((-((a + b*x)*Sqrt[1 - (a + b*x)^(-2)]*ArcCsc[a + b*x]) + (a^2*ArcCsc[a + 
 b*x]^2)/2 - (b^2*x^2*ArcCsc[a + b*x]^2)/2 + 4*a*ArcCsc[a + b*x]*ArcTanh[E 
^(I*ArcCsc[a + b*x])] + Log[(a + b*x)^(-1)] - (2*I)*a*PolyLog[2, -E^(I*Arc 
Csc[a + b*x])] + (2*I)*a*PolyLog[2, E^(I*ArcCsc[a + b*x])])/b^2)
 

Defintions of rubi rules used

rule 25
Int[-(Fx_), x_Symbol] :> Simp[Identity[-1]   Int[Fx, x], x]
 

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

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4678
Int[(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(n_.)*((c_.) + (d_.)*(x_))^(m_.) 
, x_Symbol] :> Int[ExpandIntegrand[(c + d*x)^m, (a + b*Csc[e + f*x])^n, x], 
 x] /; FreeQ[{a, b, c, d, e, f, m}, x] && IGtQ[m, 0] && IGtQ[n, 0]
 

rule 4927
Int[Cot[(c_.) + (d_.)*(x_)]*Csc[(c_.) + (d_.)*(x_)]*(Csc[(c_.) + (d_.)*(x_) 
]*(b_.) + (a_))^(n_.)*((e_.) + (f_.)*(x_))^(m_.), x_Symbol] :> Simp[(-(e + 
f*x)^m)*((a + b*Csc[c + d*x])^(n + 1)/(b*d*(n + 1))), x] + Simp[f*(m/(b*d*( 
n + 1)))   Int[(e + f*x)^(m - 1)*(a + b*Csc[c + d*x])^(n + 1), x], x] /; Fr 
eeQ[{a, b, c, d, e, f, n}, x] && IGtQ[m, 0] && NeQ[n, -1]
 

rule 5782
Int[((a_.) + ArcCsc[(c_) + (d_.)*(x_)]*(b_.))^(p_.)*((e_.) + (f_.)*(x_))^(m 
_.), x_Symbol] :> Simp[-(d^(m + 1))^(-1)   Subst[Int[(a + b*x)^p*Csc[x]*Cot 
[x]*(d*e - c*f + f*Csc[x])^m, x], x, ArcCsc[c + d*x]], x] /; FreeQ[{a, b, c 
, d, e, f}, x] && IGtQ[p, 0] && IntegerQ[m]
 
Maple [A] (verified)

Time = 0.68 (sec) , antiderivative size = 212, normalized size of antiderivative = 1.46

method result size
derivativedivides \(\frac {-a \left (\operatorname {arccsc}\left (b x +a \right )^{2} \left (b x +a \right )-2 \,\operatorname {arccsc}\left (b x +a \right ) \ln \left (1-\frac {i}{b x +a}-\sqrt {1-\frac {1}{\left (b x +a \right )^{2}}}\right )+2 \,\operatorname {arccsc}\left (b x +a \right ) \ln \left (1+\frac {i}{b x +a}+\sqrt {1-\frac {1}{\left (b x +a \right )^{2}}}\right )-2 i \operatorname {dilog}\left (1+\frac {i}{b x +a}+\sqrt {1-\frac {1}{\left (b x +a \right )^{2}}}\right )+2 i \operatorname {dilog}\left (1-\frac {i}{b x +a}-\sqrt {1-\frac {1}{\left (b x +a \right )^{2}}}\right )\right )+\frac {\operatorname {arccsc}\left (b x +a \right )^{2} \left (b x +a \right )^{2}}{2}+\operatorname {arccsc}\left (b x +a \right ) \sqrt {\frac {\left (b x +a \right )^{2}-1}{\left (b x +a \right )^{2}}}\, \left (b x +a \right )-\ln \left (\frac {1}{b x +a}\right )}{b^{2}}\) \(212\)
default \(\frac {-a \left (\operatorname {arccsc}\left (b x +a \right )^{2} \left (b x +a \right )-2 \,\operatorname {arccsc}\left (b x +a \right ) \ln \left (1-\frac {i}{b x +a}-\sqrt {1-\frac {1}{\left (b x +a \right )^{2}}}\right )+2 \,\operatorname {arccsc}\left (b x +a \right ) \ln \left (1+\frac {i}{b x +a}+\sqrt {1-\frac {1}{\left (b x +a \right )^{2}}}\right )-2 i \operatorname {dilog}\left (1+\frac {i}{b x +a}+\sqrt {1-\frac {1}{\left (b x +a \right )^{2}}}\right )+2 i \operatorname {dilog}\left (1-\frac {i}{b x +a}-\sqrt {1-\frac {1}{\left (b x +a \right )^{2}}}\right )\right )+\frac {\operatorname {arccsc}\left (b x +a \right )^{2} \left (b x +a \right )^{2}}{2}+\operatorname {arccsc}\left (b x +a \right ) \sqrt {\frac {\left (b x +a \right )^{2}-1}{\left (b x +a \right )^{2}}}\, \left (b x +a \right )-\ln \left (\frac {1}{b x +a}\right )}{b^{2}}\) \(212\)

Input:

int(x*arccsc(b*x+a)^2,x,method=_RETURNVERBOSE)
 

Output:

1/b^2*(-a*(arccsc(b*x+a)^2*(b*x+a)-2*arccsc(b*x+a)*ln(1-I/(b*x+a)-(1-1/(b* 
x+a)^2)^(1/2))+2*arccsc(b*x+a)*ln(1+I/(b*x+a)+(1-1/(b*x+a)^2)^(1/2))-2*I*d 
ilog(1+I/(b*x+a)+(1-1/(b*x+a)^2)^(1/2))+2*I*dilog(1-I/(b*x+a)-(1-1/(b*x+a) 
^2)^(1/2)))+1/2*arccsc(b*x+a)^2*(b*x+a)^2+arccsc(b*x+a)*(((b*x+a)^2-1)/(b* 
x+a)^2)^(1/2)*(b*x+a)-ln(1/(b*x+a)))
 

Fricas [F]

\[ \int x \csc ^{-1}(a+b x)^2 \, dx=\int { x \operatorname {arccsc}\left (b x + a\right )^{2} \,d x } \] Input:

integrate(x*arccsc(b*x+a)^2,x, algorithm="fricas")
                                                                                    
                                                                                    
 

Output:

integral(x*arccsc(b*x + a)^2, x)
 

Sympy [F]

\[ \int x \csc ^{-1}(a+b x)^2 \, dx=\int x \operatorname {acsc}^{2}{\left (a + b x \right )}\, dx \] Input:

integrate(x*acsc(b*x+a)**2,x)
 

Output:

Integral(x*acsc(a + b*x)**2, x)
 

Maxima [F]

\[ \int x \csc ^{-1}(a+b x)^2 \, dx=\int { x \operatorname {arccsc}\left (b x + a\right )^{2} \,d x } \] Input:

integrate(x*arccsc(b*x+a)^2,x, algorithm="maxima")
 

Output:

1/2*x^2*arctan2(1, sqrt(b*x + a + 1)*sqrt(b*x + a - 1))^2 - 1/8*x^2*log(b^ 
2*x^2 + 2*a*b*x + a^2)^2 + integrate(1/2*(2*sqrt(b*x + a + 1)*sqrt(b*x + a 
 - 1)*b*x^2*arctan2(1, sqrt(b*x + a + 1)*sqrt(b*x + a - 1)) - 2*(b^3*x^4 + 
 3*a*b^2*x^3 + (3*a^2 - 1)*b*x^2 + (a^3 - a)*x)*log(b*x + a)^2 + (b^3*x^4 
+ 2*a*b^2*x^3 + (a^2 - 1)*b*x^2 + 2*(b^3*x^4 + 3*a*b^2*x^3 + (3*a^2 - 1)*b 
*x^2 + (a^3 - a)*x)*log(b*x + a))*log(b^2*x^2 + 2*a*b*x + a^2))/(b^3*x^3 + 
 3*a*b^2*x^2 + a^3 + (3*a^2 - 1)*b*x - a), x)
 

Giac [F]

\[ \int x \csc ^{-1}(a+b x)^2 \, dx=\int { x \operatorname {arccsc}\left (b x + a\right )^{2} \,d x } \] Input:

integrate(x*arccsc(b*x+a)^2,x, algorithm="giac")
 

Output:

integrate(x*arccsc(b*x + a)^2, x)
 

Mupad [F(-1)]

Timed out. \[ \int x \csc ^{-1}(a+b x)^2 \, dx=\int x\,{\mathrm {asin}\left (\frac {1}{a+b\,x}\right )}^2 \,d x \] Input:

int(x*asin(1/(a + b*x))^2,x)
 

Output:

int(x*asin(1/(a + b*x))^2, x)
 

Reduce [F]

\[ \int x \csc ^{-1}(a+b x)^2 \, dx=\int \mathit {acsc} \left (b x +a \right )^{2} x d x \] Input:

int(x*acsc(b*x+a)^2,x)
 

Output:

int(acsc(a + b*x)**2*x,x)