Integrand size = 11, antiderivative size = 150 \[ \int \log (a+b \tan (c+d x)) \, dx=-\frac {i \log \left (\frac {b (i-\tan (c+d x))}{a+i b}\right ) \log (a+b \tan (c+d x))}{2 d}+\frac {i \log \left (-\frac {b (i+\tan (c+d x))}{a-i b}\right ) \log (a+b \tan (c+d x))}{2 d}+\frac {i \operatorname {PolyLog}\left (2,\frac {a+b \tan (c+d x)}{a-i b}\right )}{2 d}-\frac {i \operatorname {PolyLog}\left (2,\frac {a+b \tan (c+d x)}{a+i b}\right )}{2 d} \] Output:
-1/2*I*ln(b*(I-tan(d*x+c))/(a+I*b))*ln(a+b*tan(d*x+c))/d+1/2*I*ln(-b*(I+ta n(d*x+c))/(a-I*b))*ln(a+b*tan(d*x+c))/d+1/2*I*polylog(2,(a+b*tan(d*x+c))/( a-I*b))/d-1/2*I*polylog(2,(a+b*tan(d*x+c))/(a+I*b))/d
Time = 0.05 (sec) , antiderivative size = 150, normalized size of antiderivative = 1.00 \[ \int \log (a+b \tan (c+d x)) \, dx=-\frac {i \log \left (\frac {b (i-\tan (c+d x))}{a+i b}\right ) \log (a+b \tan (c+d x))}{2 d}+\frac {i \log \left (-\frac {b (i+\tan (c+d x))}{a-i b}\right ) \log (a+b \tan (c+d x))}{2 d}+\frac {i \operatorname {PolyLog}\left (2,\frac {a+b \tan (c+d x)}{a-i b}\right )}{2 d}-\frac {i \operatorname {PolyLog}\left (2,\frac {a+b \tan (c+d x)}{a+i b}\right )}{2 d} \] Input:
Integrate[Log[a + b*Tan[c + d*x]],x]
Output:
((-1/2*I)*Log[(b*(I - Tan[c + d*x]))/(a + I*b)]*Log[a + b*Tan[c + d*x]])/d + ((I/2)*Log[-((b*(I + Tan[c + d*x]))/(a - I*b))]*Log[a + b*Tan[c + d*x]] )/d + ((I/2)*PolyLog[2, (a + b*Tan[c + d*x])/(a - I*b)])/d - ((I/2)*PolyLo g[2, (a + b*Tan[c + d*x])/(a + I*b)])/d
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 \log (a+b \tan (c+d x)) \, dx\) |
\(\Big \downarrow \) 3028 |
\(\displaystyle x \log (a+b \tan (c+d x))-\int \frac {b d x \sec ^2(c+d x)}{a+b \tan (c+d x)}dx\) |
\(\Big \downarrow \) 27 |
\(\displaystyle x \log (a+b \tan (c+d x))-b d \int \frac {x \sec ^2(c+d x)}{a+b \tan (c+d x)}dx\) |
\(\Big \downarrow \) 7299 |
\(\displaystyle x \log (a+b \tan (c+d x))-b d \int \frac {x \sec ^2(c+d x)}{a+b \tan (c+d x)}dx\) |
Input:
Int[Log[a + b*Tan[c + d*x]],x]
Output:
$Aborted
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[Log[u_], x_Symbol] :> Simp[x*Log[u], x] - Int[SimplifyIntegrand[x*(D[u, x]/u), x], x] /; InverseFunctionFreeQ[u, x]
Time = 11.50 (sec) , antiderivative size = 134, normalized size of antiderivative = 0.89
method | result | size |
derivativedivides | \(\frac {b \left (-\frac {i \ln \left (a +b \tan \left (d x +c \right )\right ) \left (\ln \left (\frac {i b -b \tan \left (d x +c \right )}{i b +a}\right )-\ln \left (\frac {i b +b \tan \left (d x +c \right )}{i b -a}\right )\right )}{2 b}-\frac {i \left (\operatorname {dilog}\left (\frac {i b -b \tan \left (d x +c \right )}{i b +a}\right )-\operatorname {dilog}\left (\frac {i b +b \tan \left (d x +c \right )}{i b -a}\right )\right )}{2 b}\right )}{d}\) | \(134\) |
default | \(\frac {b \left (-\frac {i \ln \left (a +b \tan \left (d x +c \right )\right ) \left (\ln \left (\frac {i b -b \tan \left (d x +c \right )}{i b +a}\right )-\ln \left (\frac {i b +b \tan \left (d x +c \right )}{i b -a}\right )\right )}{2 b}-\frac {i \left (\operatorname {dilog}\left (\frac {i b -b \tan \left (d x +c \right )}{i b +a}\right )-\operatorname {dilog}\left (\frac {i b +b \tan \left (d x +c \right )}{i b -a}\right )\right )}{2 b}\right )}{d}\) | \(134\) |
risch | \(\text {Expression too large to display}\) | \(1538\) |
Input:
int(ln(a+b*tan(d*x+c)),x,method=_RETURNVERBOSE)
Output:
1/d*b*(-1/2*I*ln(a+b*tan(d*x+c))*(ln((I*b-b*tan(d*x+c))/(a+I*b))-ln((I*b+b *tan(d*x+c))/(I*b-a)))/b-1/2*I*(dilog((I*b-b*tan(d*x+c))/(a+I*b))-dilog((I *b+b*tan(d*x+c))/(I*b-a)))/b)
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 599 vs. \(2 (119) = 238\).
Time = 0.12 (sec) , antiderivative size = 599, normalized size of antiderivative = 3.99 \[ \int \log (a+b \tan (c+d x)) \, dx =\text {Too large to display} \] Input:
integrate(log(a+b*tan(d*x+c)),x, algorithm="fricas")
Output:
1/4*(4*d*x*log(b*tan(d*x + c) + a) + 2*d*x*log(-2*(I*tan(d*x + c) - 1)/(ta n(d*x + c)^2 + 1)) + 2*d*x*log(-2*(-I*tan(d*x + c) - 1)/(tan(d*x + c)^2 + 1)) - 2*(d*x + c)*log(-2*((I*a*b - b^2)*tan(d*x + c)^2 - a^2 - I*a*b + (I* a^2 - 2*a*b - I*b^2)*tan(d*x + c))/((a^2 + b^2)*tan(d*x + c)^2 + a^2 + b^2 )) - 2*(d*x + c)*log(-2*((-I*a*b - b^2)*tan(d*x + c)^2 - a^2 + I*a*b + (-I *a^2 - 2*a*b + I*b^2)*tan(d*x + c))/((a^2 + b^2)*tan(d*x + c)^2 + a^2 + b^ 2)) + 2*c*log(((I*a*b + b^2)*tan(d*x + c)^2 - a^2 + I*a*b + (I*a^2 + I*b^2 )*tan(d*x + c))/(tan(d*x + c)^2 + 1)) + 2*c*log(((I*a*b - b^2)*tan(d*x + c )^2 + a^2 + I*a*b + (I*a^2 + I*b^2)*tan(d*x + c))/(tan(d*x + c)^2 + 1)) - I*dilog(2*((I*a*b - b^2)*tan(d*x + c)^2 - a^2 - I*a*b + (I*a^2 - 2*a*b - I *b^2)*tan(d*x + c))/((a^2 + b^2)*tan(d*x + c)^2 + a^2 + b^2) + 1) + I*dilo g(2*((-I*a*b - b^2)*tan(d*x + c)^2 - a^2 + I*a*b + (-I*a^2 - 2*a*b + I*b^2 )*tan(d*x + c))/((a^2 + b^2)*tan(d*x + c)^2 + a^2 + b^2) + 1) + I*dilog(2* (I*tan(d*x + c) - 1)/(tan(d*x + c)^2 + 1) + 1) - I*dilog(2*(-I*tan(d*x + c ) - 1)/(tan(d*x + c)^2 + 1) + 1))/d
\[ \int \log (a+b \tan (c+d x)) \, dx=\int \log {\left (a + b \tan {\left (c + d x \right )} \right )}\, dx \] Input:
integrate(ln(a+b*tan(d*x+c)),x)
Output:
Integral(log(a + b*tan(c + d*x)), x)
Time = 0.17 (sec) , antiderivative size = 175, normalized size of antiderivative = 1.17 \[ \int \log (a+b \tan (c+d x)) \, dx=\frac {2 \, {\left (d x + c\right )} \log \left (b \tan \left (d x + c\right ) + a\right ) + \arctan \left (\frac {b^{2} \tan \left (d x + c\right ) + a b}{a^{2} + b^{2}}, \frac {a b \tan \left (d x + c\right ) + a^{2}}{a^{2} + b^{2}}\right ) \log \left (\tan \left (d x + c\right )^{2} + 1\right ) - {\left (d x + c\right )} \log \left (\frac {b^{2} \tan \left (d x + c\right )^{2} + 2 \, a b \tan \left (d x + c\right ) + a^{2}}{a^{2} + b^{2}}\right ) - i \, {\rm Li}_2\left (-\frac {i \, b \tan \left (d x + c\right ) - b}{i \, a + b}\right ) + i \, {\rm Li}_2\left (\frac {i \, b \tan \left (d x + c\right ) + b}{-i \, a + b}\right )}{2 \, d} \] Input:
integrate(log(a+b*tan(d*x+c)),x, algorithm="maxima")
Output:
1/2*(2*(d*x + c)*log(b*tan(d*x + c) + a) + arctan2((b^2*tan(d*x + c) + a*b )/(a^2 + b^2), (a*b*tan(d*x + c) + a^2)/(a^2 + b^2))*log(tan(d*x + c)^2 + 1) - (d*x + c)*log((b^2*tan(d*x + c)^2 + 2*a*b*tan(d*x + c) + a^2)/(a^2 + b^2)) - I*dilog(-(I*b*tan(d*x + c) - b)/(I*a + b)) + I*dilog((I*b*tan(d*x + c) + b)/(-I*a + b)))/d
\[ \int \log (a+b \tan (c+d x)) \, dx=\int { \log \left (b \tan \left (d x + c\right ) + a\right ) \,d x } \] Input:
integrate(log(a+b*tan(d*x+c)),x, algorithm="giac")
Output:
integrate(log(b*tan(d*x + c) + a), x)
Timed out. \[ \int \log (a+b \tan (c+d x)) \, dx=\int \ln \left (a+b\,\mathrm {tan}\left (c+d\,x\right )\right ) \,d x \] Input:
int(log(a + b*tan(c + d*x)),x)
Output:
int(log(a + b*tan(c + d*x)), x)
\[ \int \log (a+b \tan (c+d x)) \, dx=\int \mathrm {log}\left (\tan \left (d x +c \right ) b +a \right )d x \] Input:
int(log(a+b*tan(d*x+c)),x)
Output:
int(log(tan(c + d*x)*b + a),x)