Integrand size = 12, antiderivative size = 59 \[ \int \frac {\cos ^4(a+b x)}{x} \, dx=\frac {1}{2} \cos (2 a) \operatorname {CosIntegral}(2 b x)+\frac {1}{8} \cos (4 a) \operatorname {CosIntegral}(4 b x)+\frac {3 \log (x)}{8}-\frac {1}{2} \sin (2 a) \text {Si}(2 b x)-\frac {1}{8} \sin (4 a) \text {Si}(4 b x) \] Output:
1/2*cos(2*a)*Ci(2*b*x)+1/8*cos(4*a)*Ci(4*b*x)+3/8*ln(x)-1/2*sin(2*a)*Si(2* b*x)-1/8*sin(4*a)*Si(4*b*x)
Time = 0.17 (sec) , antiderivative size = 52, normalized size of antiderivative = 0.88 \[ \int \frac {\cos ^4(a+b x)}{x} \, dx=\frac {1}{8} (4 \cos (2 a) \operatorname {CosIntegral}(2 b x)+\cos (4 a) \operatorname {CosIntegral}(4 b x)+3 \log (x)-4 \sin (2 a) \text {Si}(2 b x)-\sin (4 a) \text {Si}(4 b x)) \] Input:
Integrate[Cos[a + b*x]^4/x,x]
Output:
(4*Cos[2*a]*CosIntegral[2*b*x] + Cos[4*a]*CosIntegral[4*b*x] + 3*Log[x] - 4*Sin[2*a]*SinIntegral[2*b*x] - Sin[4*a]*SinIntegral[4*b*x])/8
Time = 0.32 (sec) , antiderivative size = 59, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {3042, 3793, 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 {\cos ^4(a+b x)}{x} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\sin \left (a+b x+\frac {\pi }{2}\right )^4}{x}dx\) |
\(\Big \downarrow \) 3793 |
\(\displaystyle \int \left (\frac {\cos (2 a+2 b x)}{2 x}+\frac {\cos (4 a+4 b x)}{8 x}+\frac {3}{8 x}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {1}{2} \cos (2 a) \operatorname {CosIntegral}(2 b x)+\frac {1}{8} \cos (4 a) \operatorname {CosIntegral}(4 b x)-\frac {1}{2} \sin (2 a) \text {Si}(2 b x)-\frac {1}{8} \sin (4 a) \text {Si}(4 b x)+\frac {3 \log (x)}{8}\) |
Input:
Int[Cos[a + b*x]^4/x,x]
Output:
(Cos[2*a]*CosIntegral[2*b*x])/2 + (Cos[4*a]*CosIntegral[4*b*x])/8 + (3*Log [x])/8 - (Sin[2*a]*SinIntegral[2*b*x])/2 - (Sin[4*a]*SinIntegral[4*b*x])/8
Int[((c_.) + (d_.)*(x_))^(m_)*sin[(e_.) + (f_.)*(x_)]^(n_), x_Symbol] :> In t[ExpandTrigReduce[(c + d*x)^m, Sin[e + f*x]^n, x], x] /; FreeQ[{c, d, e, f , m}, x] && IGtQ[n, 1] && ( !RationalQ[m] || (GeQ[m, -1] && LtQ[m, 1]))
Time = 1.52 (sec) , antiderivative size = 52, normalized size of antiderivative = 0.88
method | result | size |
derivativedivides | \(-\frac {\sin \left (4 a \right ) \operatorname {Si}\left (4 b x \right )}{8}+\frac {\cos \left (4 a \right ) \operatorname {Ci}\left (4 b x \right )}{8}-\frac {\sin \left (2 a \right ) \operatorname {Si}\left (2 b x \right )}{2}+\frac {\cos \left (2 a \right ) \operatorname {Ci}\left (2 b x \right )}{2}+\frac {3 \ln \left (b x \right )}{8}\) | \(52\) |
default | \(-\frac {\sin \left (4 a \right ) \operatorname {Si}\left (4 b x \right )}{8}+\frac {\cos \left (4 a \right ) \operatorname {Ci}\left (4 b x \right )}{8}-\frac {\sin \left (2 a \right ) \operatorname {Si}\left (2 b x \right )}{2}+\frac {\cos \left (2 a \right ) \operatorname {Ci}\left (2 b x \right )}{2}+\frac {3 \ln \left (b x \right )}{8}\) | \(52\) |
risch | \(\frac {3 \ln \left (x \right )}{8}+\frac {i {\mathrm e}^{-4 i a} \pi \,\operatorname {csgn}\left (b x \right )}{16}-\frac {i {\mathrm e}^{-4 i a} \operatorname {Si}\left (4 b x \right )}{8}-\frac {\operatorname {expIntegral}_{1}\left (-4 i b x \right ) {\mathrm e}^{-4 i a}}{16}+\frac {i {\mathrm e}^{-2 i a} \pi \,\operatorname {csgn}\left (b x \right )}{4}-\frac {i {\mathrm e}^{-2 i a} \operatorname {Si}\left (2 b x \right )}{2}-\frac {{\mathrm e}^{-2 i a} \operatorname {expIntegral}_{1}\left (-2 i b x \right )}{4}-\frac {{\mathrm e}^{2 i a} \operatorname {expIntegral}_{1}\left (-2 i b x \right )}{4}-\frac {{\mathrm e}^{4 i a} \operatorname {expIntegral}_{1}\left (-4 i b x \right )}{16}\) | \(114\) |
Input:
int(cos(b*x+a)^4/x,x,method=_RETURNVERBOSE)
Output:
-1/8*sin(4*a)*Si(4*b*x)+1/8*cos(4*a)*Ci(4*b*x)-1/2*sin(2*a)*Si(2*b*x)+1/2* cos(2*a)*Ci(2*b*x)+3/8*ln(b*x)
Time = 0.08 (sec) , antiderivative size = 49, normalized size of antiderivative = 0.83 \[ \int \frac {\cos ^4(a+b x)}{x} \, dx=\frac {1}{8} \, \cos \left (4 \, a\right ) \operatorname {Ci}\left (4 \, b x\right ) + \frac {1}{2} \, \cos \left (2 \, a\right ) \operatorname {Ci}\left (2 \, b x\right ) - \frac {1}{8} \, \sin \left (4 \, a\right ) \operatorname {Si}\left (4 \, b x\right ) - \frac {1}{2} \, \sin \left (2 \, a\right ) \operatorname {Si}\left (2 \, b x\right ) + \frac {3}{8} \, \log \left (x\right ) \] Input:
integrate(cos(b*x+a)^4/x,x, algorithm="fricas")
Output:
1/8*cos(4*a)*cos_integral(4*b*x) + 1/2*cos(2*a)*cos_integral(2*b*x) - 1/8* sin(4*a)*sin_integral(4*b*x) - 1/2*sin(2*a)*sin_integral(2*b*x) + 3/8*log( x)
Time = 0.99 (sec) , antiderivative size = 60, normalized size of antiderivative = 1.02 \[ \int \frac {\cos ^4(a+b x)}{x} \, dx=\frac {3 \log {\left (x \right )}}{8} - \frac {\sin {\left (2 a \right )} \operatorname {Si}{\left (2 b x \right )}}{2} - \frac {\sin {\left (4 a \right )} \operatorname {Si}{\left (4 b x \right )}}{8} + \frac {\cos {\left (2 a \right )} \operatorname {Ci}{\left (2 b x \right )}}{2} + \frac {\cos {\left (4 a \right )} \operatorname {Ci}{\left (4 b x \right )}}{8} \] Input:
integrate(cos(b*x+a)**4/x,x)
Output:
3*log(x)/8 - sin(2*a)*Si(2*b*x)/2 - sin(4*a)*Si(4*b*x)/8 + cos(2*a)*Ci(2*b *x)/2 + cos(4*a)*Ci(4*b*x)/8
Result contains complex when optimal does not.
Time = 0.08 (sec) , antiderivative size = 91, normalized size of antiderivative = 1.54 \[ \int \frac {\cos ^4(a+b x)}{x} \, dx=-\frac {1}{16} \, {\left (E_{1}\left (4 i \, b x\right ) + E_{1}\left (-4 i \, b x\right )\right )} \cos \left (4 \, a\right ) - \frac {1}{4} \, {\left (E_{1}\left (2 i \, b x\right ) + E_{1}\left (-2 i \, b x\right )\right )} \cos \left (2 \, a\right ) + \frac {1}{16} \, {\left (i \, E_{1}\left (4 i \, b x\right ) - i \, E_{1}\left (-4 i \, b x\right )\right )} \sin \left (4 \, a\right ) - \frac {1}{4} \, {\left (-i \, E_{1}\left (2 i \, b x\right ) + i \, E_{1}\left (-2 i \, b x\right )\right )} \sin \left (2 \, a\right ) + \frac {3}{8} \, \log \left (b x\right ) \] Input:
integrate(cos(b*x+a)^4/x,x, algorithm="maxima")
Output:
-1/16*(exp_integral_e(1, 4*I*b*x) + exp_integral_e(1, -4*I*b*x))*cos(4*a) - 1/4*(exp_integral_e(1, 2*I*b*x) + exp_integral_e(1, -2*I*b*x))*cos(2*a) + 1/16*(I*exp_integral_e(1, 4*I*b*x) - I*exp_integral_e(1, -4*I*b*x))*sin( 4*a) - 1/4*(-I*exp_integral_e(1, 2*I*b*x) + I*exp_integral_e(1, -2*I*b*x)) *sin(2*a) + 3/8*log(b*x)
Result contains higher order function than in optimal. Order 9 vs. order 4.
Time = 0.43 (sec) , antiderivative size = 428, normalized size of antiderivative = 7.25 \[ \int \frac {\cos ^4(a+b x)}{x} \, dx =\text {Too large to display} \] Input:
integrate(cos(b*x+a)^4/x,x, algorithm="giac")
Output:
1/16*(6*log(abs(x))*tan(2*a)^2*tan(a)^2 - real_part(cos_integral(4*b*x))*t an(2*a)^2*tan(a)^2 - 4*real_part(cos_integral(2*b*x))*tan(2*a)^2*tan(a)^2 - 4*real_part(cos_integral(-2*b*x))*tan(2*a)^2*tan(a)^2 - real_part(cos_in tegral(-4*b*x))*tan(2*a)^2*tan(a)^2 - 8*imag_part(cos_integral(2*b*x))*tan (2*a)^2*tan(a) + 8*imag_part(cos_integral(-2*b*x))*tan(2*a)^2*tan(a) - 16* sin_integral(2*b*x)*tan(2*a)^2*tan(a) - 2*imag_part(cos_integral(4*b*x))*t an(2*a)*tan(a)^2 + 2*imag_part(cos_integral(-4*b*x))*tan(2*a)*tan(a)^2 - 4 *sin_integral(4*b*x)*tan(2*a)*tan(a)^2 + 6*log(abs(x))*tan(2*a)^2 - real_p art(cos_integral(4*b*x))*tan(2*a)^2 + 4*real_part(cos_integral(2*b*x))*tan (2*a)^2 + 4*real_part(cos_integral(-2*b*x))*tan(2*a)^2 - real_part(cos_int egral(-4*b*x))*tan(2*a)^2 + 6*log(abs(x))*tan(a)^2 + real_part(cos_integra l(4*b*x))*tan(a)^2 - 4*real_part(cos_integral(2*b*x))*tan(a)^2 - 4*real_pa rt(cos_integral(-2*b*x))*tan(a)^2 + real_part(cos_integral(-4*b*x))*tan(a) ^2 - 2*imag_part(cos_integral(4*b*x))*tan(2*a) + 2*imag_part(cos_integral( -4*b*x))*tan(2*a) - 4*sin_integral(4*b*x)*tan(2*a) - 8*imag_part(cos_integ ral(2*b*x))*tan(a) + 8*imag_part(cos_integral(-2*b*x))*tan(a) - 16*sin_int egral(2*b*x)*tan(a) + 6*log(abs(x)) + real_part(cos_integral(4*b*x)) + 4*r eal_part(cos_integral(2*b*x)) + 4*real_part(cos_integral(-2*b*x)) + real_p art(cos_integral(-4*b*x)))/(tan(2*a)^2*tan(a)^2 + tan(2*a)^2 + tan(a)^2 + 1)
Timed out. \[ \int \frac {\cos ^4(a+b x)}{x} \, dx=\int \frac {{\cos \left (a+b\,x\right )}^4}{x} \,d x \] Input:
int(cos(a + b*x)^4/x,x)
Output:
int(cos(a + b*x)^4/x, x)
\[ \int \frac {\cos ^4(a+b x)}{x} \, dx=\int \frac {\cos \left (b x +a \right )^{4}}{x}d x \] Input:
int(cos(b*x+a)^4/x,x)
Output:
int(cos(a + b*x)**4/x,x)