Integrand size = 15, antiderivative size = 63 \[ \int \cos ^3(a+b x) \csc (c+b x) \, dx=\frac {\cos (3 a-c+2 b x)}{4 b}+\frac {\cos ^3(a-c) \log (\sin (c+b x))}{b}-\frac {3}{4} x \sin (a-c)-\frac {1}{4} x \sin (3 (a-c)) \] Output:
1/4*cos(2*b*x+3*a-c)/b+cos(a-c)^3*ln(sin(b*x+c))/b-3/4*x*sin(a-c)-1/4*x*si n(3*a-3*c)
Result contains complex when optimal does not.
Time = 0.30 (sec) , antiderivative size = 117, normalized size of antiderivative = 1.86 \[ \int \cos ^3(a+b x) \csc (c+b x) \, dx=\frac {6 i b x \cos (a-c)-8 i \arctan (\tan (c+b x)) \cos ^3(a-c)+2 \cos (3 a-c+2 b x)+3 \cos (a-c) \log \left (\sin ^2(c+b x)\right )+\cos (3 (a-c)) \left (2 i b x+\log \left (\sin ^2(c+b x)\right )\right )-6 b x \sin (a-c)-2 b x \sin (3 (a-c))}{8 b} \] Input:
Integrate[Cos[a + b*x]^3*Csc[c + b*x],x]
Output:
((6*I)*b*x*Cos[a - c] - (8*I)*ArcTan[Tan[c + b*x]]*Cos[a - c]^3 + 2*Cos[3* a - c + 2*b*x] + 3*Cos[a - c]*Log[Sin[c + b*x]^2] + Cos[3*(a - c)]*((2*I)* b*x + Log[Sin[c + b*x]^2]) - 6*b*x*Sin[a - c] - 2*b*x*Sin[3*(a - c)])/(8*b )
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 \cos ^3(a+b x) \csc (b x+c) \, dx\) |
\(\Big \downarrow \) 7299 |
\(\displaystyle \int \cos ^3(a+b x) \csc (b x+c)dx\) |
Input:
Int[Cos[a + b*x]^3*Csc[c + b*x],x]
Output:
$Aborted
Result contains complex when optimal does not.
Time = 1.45 (sec) , antiderivative size = 163, normalized size of antiderivative = 2.59
method | result | size |
risch | \(\frac {i x \,{\mathrm e}^{3 i \left (a -c \right )}}{4}+\frac {3 i x \,{\mathrm e}^{i \left (a -c \right )}}{4}-\frac {3 i \cos \left (a -c \right ) x}{2}-\frac {i \cos \left (3 a -3 c \right ) x}{2}-\frac {3 i \cos \left (a -c \right ) a}{2 b}-\frac {i \cos \left (3 a -3 c \right ) a}{2 b}+\frac {3 \ln \left ({\mathrm e}^{2 i \left (b x +a \right )}-{\mathrm e}^{2 i \left (a -c \right )}\right ) \cos \left (a -c \right )}{4 b}+\frac {\ln \left ({\mathrm e}^{2 i \left (b x +a \right )}-{\mathrm e}^{2 i \left (a -c \right )}\right ) \cos \left (3 a -3 c \right )}{4 b}+\frac {\cos \left (2 b x +3 a -c \right )}{4 b}\) | \(163\) |
default | \(\text {Expression too large to display}\) | \(500\) |
Input:
int(cos(b*x+a)^3*csc(b*x+c),x,method=_RETURNVERBOSE)
Output:
1/4*I*x*exp(3*I*(a-c))+3/4*I*x*exp(I*(a-c))-3/2*I*cos(a-c)*x-1/2*I*cos(3*a -3*c)*x-3/2*I/b*cos(a-c)*a-1/2*I/b*cos(3*a-3*c)*a+3/4/b*ln(exp(2*I*(b*x+a) )-exp(2*I*(a-c)))*cos(a-c)+1/4/b*ln(exp(2*I*(b*x+a))-exp(2*I*(a-c)))*cos(3 *a-3*c)+1/4*cos(2*b*x+3*a-c)/b
Time = 0.09 (sec) , antiderivative size = 107, normalized size of antiderivative = 1.70 \[ \int \cos ^3(a+b x) \csc (c+b x) \, dx=\frac {2 \, \cos \left (-a + c\right )^{3} \log \left (\frac {1}{2} \, \sin \left (b x + c\right )\right ) + {\left (4 \, \cos \left (-a + c\right )^{2} - 1\right )} \cos \left (b x + c\right ) \sin \left (b x + c\right ) \sin \left (-a + c\right ) + {\left (4 \, \cos \left (-a + c\right )^{3} - 3 \, \cos \left (-a + c\right )\right )} \cos \left (b x + c\right )^{2} + {\left (2 \, b x \cos \left (-a + c\right )^{2} + b x\right )} \sin \left (-a + c\right )}{2 \, b} \] Input:
integrate(cos(b*x+a)^3*csc(b*x+c),x, algorithm="fricas")
Output:
1/2*(2*cos(-a + c)^3*log(1/2*sin(b*x + c)) + (4*cos(-a + c)^2 - 1)*cos(b*x + c)*sin(b*x + c)*sin(-a + c) + (4*cos(-a + c)^3 - 3*cos(-a + c))*cos(b*x + c)^2 + (2*b*x*cos(-a + c)^2 + b*x)*sin(-a + c))/b
Leaf count of result is larger than twice the leaf count of optimal. 10487 vs. \(2 (0) = 0\).
Time = 27.79 (sec) , antiderivative size = 33056, normalized size of antiderivative = 524.70 \[ \int \cos ^3(a+b x) \csc (c+b x) \, dx=\text {Too large to display} \] Input:
integrate(cos(b*x+a)**3*csc(b*x+c),x)
Output:
3*Piecewise((0, Eq(b, 0) & Eq(c, 0)), (sin(b*x)**2/(2*b), Eq(c, 0)), (0, E q(b, 0)), (-b*x*tan(c/2)**5*tan(b*x/2)**4/(b*tan(c/2)**6*tan(b*x/2)**4 + 2 *b*tan(c/2)**6*tan(b*x/2)**2 + b*tan(c/2)**6 + 3*b*tan(c/2)**4*tan(b*x/2)* *4 + 6*b*tan(c/2)**4*tan(b*x/2)**2 + 3*b*tan(c/2)**4 + 3*b*tan(c/2)**2*tan (b*x/2)**4 + 6*b*tan(c/2)**2*tan(b*x/2)**2 + 3*b*tan(c/2)**2 + b*tan(b*x/2 )**4 + 2*b*tan(b*x/2)**2 + b) - 2*b*x*tan(c/2)**5*tan(b*x/2)**2/(b*tan(c/2 )**6*tan(b*x/2)**4 + 2*b*tan(c/2)**6*tan(b*x/2)**2 + b*tan(c/2)**6 + 3*b*t an(c/2)**4*tan(b*x/2)**4 + 6*b*tan(c/2)**4*tan(b*x/2)**2 + 3*b*tan(c/2)**4 + 3*b*tan(c/2)**2*tan(b*x/2)**4 + 6*b*tan(c/2)**2*tan(b*x/2)**2 + 3*b*tan (c/2)**2 + b*tan(b*x/2)**4 + 2*b*tan(b*x/2)**2 + b) - b*x*tan(c/2)**5/(b*t an(c/2)**6*tan(b*x/2)**4 + 2*b*tan(c/2)**6*tan(b*x/2)**2 + b*tan(c/2)**6 + 3*b*tan(c/2)**4*tan(b*x/2)**4 + 6*b*tan(c/2)**4*tan(b*x/2)**2 + 3*b*tan(c /2)**4 + 3*b*tan(c/2)**2*tan(b*x/2)**4 + 6*b*tan(c/2)**2*tan(b*x/2)**2 + 3 *b*tan(c/2)**2 + b*tan(b*x/2)**4 + 2*b*tan(b*x/2)**2 + b) + 6*b*x*tan(c/2) **3*tan(b*x/2)**4/(b*tan(c/2)**6*tan(b*x/2)**4 + 2*b*tan(c/2)**6*tan(b*x/2 )**2 + b*tan(c/2)**6 + 3*b*tan(c/2)**4*tan(b*x/2)**4 + 6*b*tan(c/2)**4*tan (b*x/2)**2 + 3*b*tan(c/2)**4 + 3*b*tan(c/2)**2*tan(b*x/2)**4 + 6*b*tan(c/2 )**2*tan(b*x/2)**2 + 3*b*tan(c/2)**2 + b*tan(b*x/2)**4 + 2*b*tan(b*x/2)**2 + b) + 12*b*x*tan(c/2)**3*tan(b*x/2)**2/(b*tan(c/2)**6*tan(b*x/2)**4 + 2* b*tan(c/2)**6*tan(b*x/2)**2 + b*tan(c/2)**6 + 3*b*tan(c/2)**4*tan(b*x/2...
Leaf count of result is larger than twice the leaf count of optimal. 155 vs. \(2 (57) = 114\).
Time = 0.06 (sec) , antiderivative size = 155, normalized size of antiderivative = 2.46 \[ \int \cos ^3(a+b x) \csc (c+b x) \, dx=\frac {2 \, {\left (3 \, b \sin \left (-a + c\right ) + b \sin \left (-3 \, a + 3 \, c\right )\right )} x + {\left (3 \, \cos \left (-a + c\right ) + \cos \left (-3 \, a + 3 \, c\right )\right )} \log \left (\cos \left (b x\right )^{2} + 2 \, \cos \left (b x\right ) \cos \left (c\right ) + \cos \left (c\right )^{2} + \sin \left (b x\right )^{2} - 2 \, \sin \left (b x\right ) \sin \left (c\right ) + \sin \left (c\right )^{2}\right ) + {\left (3 \, \cos \left (-a + c\right ) + \cos \left (-3 \, a + 3 \, c\right )\right )} \log \left (\cos \left (b x\right )^{2} - 2 \, \cos \left (b x\right ) \cos \left (c\right ) + \cos \left (c\right )^{2} + \sin \left (b x\right )^{2} + 2 \, \sin \left (b x\right ) \sin \left (c\right ) + \sin \left (c\right )^{2}\right ) + 2 \, \cos \left (2 \, b x + 3 \, a - c\right )}{8 \, b} \] Input:
integrate(cos(b*x+a)^3*csc(b*x+c),x, algorithm="maxima")
Output:
1/8*(2*(3*b*sin(-a + c) + b*sin(-3*a + 3*c))*x + (3*cos(-a + c) + cos(-3*a + 3*c))*log(cos(b*x)^2 + 2*cos(b*x)*cos(c) + cos(c)^2 + sin(b*x)^2 - 2*si n(b*x)*sin(c) + sin(c)^2) + (3*cos(-a + c) + cos(-3*a + 3*c))*log(cos(b*x) ^2 - 2*cos(b*x)*cos(c) + cos(c)^2 + sin(b*x)^2 + 2*sin(b*x)*sin(c) + sin(c )^2) + 2*cos(2*b*x + 3*a - c))/b
Leaf count of result is larger than twice the leaf count of optimal. 3325 vs. \(2 (57) = 114\).
Time = 0.21 (sec) , antiderivative size = 3325, normalized size of antiderivative = 52.78 \[ \int \cos ^3(a+b x) \csc (c+b x) \, dx=\text {Too large to display} \] Input:
integrate(cos(b*x+a)^3*csc(b*x+c),x, algorithm="giac")
Output:
-1/2*(2*(3*tan(1/2*a)^6*tan(1/2*c)^5 - 3*tan(1/2*a)^5*tan(1/2*c)^6 - 2*tan (1/2*a)^6*tan(1/2*c)^3 + 21*tan(1/2*a)^5*tan(1/2*c)^4 - 21*tan(1/2*a)^4*ta n(1/2*c)^5 + 2*tan(1/2*a)^3*tan(1/2*c)^6 + 3*tan(1/2*a)^6*tan(1/2*c) - 21* tan(1/2*a)^5*tan(1/2*c)^2 + 78*tan(1/2*a)^4*tan(1/2*c)^3 - 78*tan(1/2*a)^3 *tan(1/2*c)^4 + 21*tan(1/2*a)^2*tan(1/2*c)^5 - 3*tan(1/2*a)*tan(1/2*c)^6 + 3*tan(1/2*a)^5 - 21*tan(1/2*a)^4*tan(1/2*c) + 78*tan(1/2*a)^3*tan(1/2*c)^ 2 - 78*tan(1/2*a)^2*tan(1/2*c)^3 + 21*tan(1/2*a)*tan(1/2*c)^4 - 3*tan(1/2* c)^5 - 2*tan(1/2*a)^3 + 21*tan(1/2*a)^2*tan(1/2*c) - 21*tan(1/2*a)*tan(1/2 *c)^2 + 2*tan(1/2*c)^3 + 3*tan(1/2*a) - 3*tan(1/2*c))*(b*x + a)/(tan(1/2*a )^6*tan(1/2*c)^6 + 3*tan(1/2*a)^6*tan(1/2*c)^4 + 3*tan(1/2*a)^4*tan(1/2*c) ^6 + 3*tan(1/2*a)^6*tan(1/2*c)^2 + 9*tan(1/2*a)^4*tan(1/2*c)^4 + 3*tan(1/2 *a)^2*tan(1/2*c)^6 + tan(1/2*a)^6 + 9*tan(1/2*a)^4*tan(1/2*c)^2 + 9*tan(1/ 2*a)^2*tan(1/2*c)^4 + tan(1/2*c)^6 + 3*tan(1/2*a)^4 + 9*tan(1/2*a)^2*tan(1 /2*c)^2 + 3*tan(1/2*c)^4 + 3*tan(1/2*a)^2 + 3*tan(1/2*c)^2 + 1) + (tan(1/2 *a)^6*tan(1/2*c)^6 - 3*tan(1/2*a)^6*tan(1/2*c)^4 + 12*tan(1/2*a)^5*tan(1/2 *c)^5 - 3*tan(1/2*a)^4*tan(1/2*c)^6 + 3*tan(1/2*a)^6*tan(1/2*c)^2 - 24*tan (1/2*a)^5*tan(1/2*c)^3 + 57*tan(1/2*a)^4*tan(1/2*c)^4 - 24*tan(1/2*a)^3*ta n(1/2*c)^5 + 3*tan(1/2*a)^2*tan(1/2*c)^6 - tan(1/2*a)^6 + 12*tan(1/2*a)^5* tan(1/2*c) - 57*tan(1/2*a)^4*tan(1/2*c)^2 + 112*tan(1/2*a)^3*tan(1/2*c)^3 - 57*tan(1/2*a)^2*tan(1/2*c)^4 + 12*tan(1/2*a)*tan(1/2*c)^5 - tan(1/2*c...
Time = 1.12 (sec) , antiderivative size = 165, normalized size of antiderivative = 2.62 \[ \int \cos ^3(a+b x) \csc (c+b x) \, dx=\frac {{\mathrm {e}}^{-a\,3{}\mathrm {i}+c\,1{}\mathrm {i}-b\,x\,2{}\mathrm {i}}}{8\,b}+\frac {{\mathrm {e}}^{a\,3{}\mathrm {i}-c\,1{}\mathrm {i}+b\,x\,2{}\mathrm {i}}}{8\,b}-\frac {x\,{\mathrm {e}}^{-a\,3{}\mathrm {i}+c\,1{}\mathrm {i}}\,\left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\,3{}\mathrm {i}+{\mathrm {e}}^{c\,2{}\mathrm {i}}\,1{}\mathrm {i}\right )}{4}+\frac {{\mathrm {e}}^{-a\,6{}\mathrm {i}+c\,6{}\mathrm {i}}\,\ln \left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{b\,x\,2{}\mathrm {i}}-{\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}\right )\,\left (8\,b\,{\mathrm {e}}^{a\,3{}\mathrm {i}-c\,3{}\mathrm {i}}+24\,b\,{\mathrm {e}}^{a\,5{}\mathrm {i}-c\,5{}\mathrm {i}}+24\,b\,{\mathrm {e}}^{a\,7{}\mathrm {i}-c\,7{}\mathrm {i}}+8\,b\,{\mathrm {e}}^{a\,9{}\mathrm {i}-c\,9{}\mathrm {i}}\right )}{64\,b^2} \] Input:
int(cos(a + b*x)^3/sin(c + b*x),x)
Output:
exp(c*1i - a*3i - b*x*2i)/(8*b) + exp(a*3i - c*1i + b*x*2i)/(8*b) - (x*exp (c*1i - a*3i)*(exp(a*2i)*3i + exp(c*2i)*1i))/4 + (exp(c*6i - a*6i)*log(exp (a*2i)*exp(b*x*2i) - exp(a*2i)*exp(-c*2i))*(8*b*exp(a*3i - c*3i) + 24*b*ex p(a*5i - c*5i) + 24*b*exp(a*7i - c*7i) + 8*b*exp(a*9i - c*9i)))/(64*b^2)
\[ \int \cos ^3(a+b x) \csc (c+b x) \, dx=\int \cos \left (b x +a \right )^{3} \csc \left (b x +c \right )d x \] Input:
int(cos(b*x+a)^3*csc(b*x+c),x)
Output:
int(cos(a + b*x)**3*csc(b*x + c),x)