Integrand size = 13, antiderivative size = 36 \[ \int \csc (c+b x) \sec (a+b x) \, dx=-\frac {\log (\cos (a+b x)) \sec (a-c)}{b}+\frac {\log (\sin (c+b x)) \sec (a-c)}{b} \] Output:
-ln(cos(b*x+a))*sec(a-c)/b+ln(sin(b*x+c))*sec(a-c)/b
Time = 0.15 (sec) , antiderivative size = 28, normalized size of antiderivative = 0.78 \[ \int \csc (c+b x) \sec (a+b x) \, dx=-\frac {(\log (\cos (a+b x))-\log (\sin (c+b x))) \sec (a-c)}{b} \] Input:
Integrate[Csc[c + b*x]*Sec[a + b*x],x]
Output:
-(((Log[Cos[a + b*x]] - Log[Sin[c + b*x]])*Sec[a - c])/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 \sec (a+b x) \csc (b x+c) \, dx\) |
\(\Big \downarrow \) 7299 |
\(\displaystyle \int \sec (a+b x) \csc (b x+c)dx\) |
Input:
Int[Csc[c + b*x]*Sec[a + b*x],x]
Output:
$Aborted
Time = 0.49 (sec) , antiderivative size = 53, normalized size of antiderivative = 1.47
method | result | size |
default | \(\frac {\ln \left (\tan \left (b x +a \right ) \cos \left (a \right ) \cos \left (c \right )+\tan \left (b x +a \right ) \sin \left (a \right ) \sin \left (c \right )-\sin \left (a \right ) \cos \left (c \right )+\cos \left (a \right ) \sin \left (c \right )\right )}{b \left (\cos \left (a \right ) \cos \left (c \right )+\sin \left (a \right ) \sin \left (c \right )\right )}\) | \(53\) |
risch | \(\frac {2 \ln \left ({\mathrm e}^{2 i \left (b x +a \right )}-{\mathrm e}^{2 i \left (a -c \right )}\right ) {\mathrm e}^{i \left (a +c \right )}}{\left ({\mathrm e}^{2 i a}+{\mathrm e}^{2 i c}\right ) b}-\frac {2 \ln \left ({\mathrm e}^{2 i \left (b x +a \right )}+1\right ) {\mathrm e}^{i \left (a +c \right )}}{\left ({\mathrm e}^{2 i a}+{\mathrm e}^{2 i c}\right ) b}\) | \(86\) |
Input:
int(csc(b*x+c)*sec(b*x+a),x,method=_RETURNVERBOSE)
Output:
1/b/(cos(a)*cos(c)+sin(a)*sin(c))*ln(tan(b*x+a)*cos(a)*cos(c)+tan(b*x+a)*s in(a)*sin(c)-sin(a)*cos(c)+cos(a)*sin(c))
Leaf count of result is larger than twice the leaf count of optimal. 111 vs. \(2 (36) = 72\).
Time = 0.08 (sec) , antiderivative size = 111, normalized size of antiderivative = 3.08 \[ \int \csc (c+b x) \sec (a+b x) \, dx=\frac {\log \left (-\frac {1}{4} \, \cos \left (b x + c\right )^{2} + \frac {1}{4}\right ) - \log \left (\frac {4 \, {\left (2 \, \cos \left (b x + c\right ) \cos \left (-a + c\right ) \sin \left (b x + c\right ) \sin \left (-a + c\right ) + {\left (2 \, \cos \left (-a + c\right )^{2} - 1\right )} \cos \left (b x + c\right )^{2} - \cos \left (-a + c\right )^{2} + 1\right )}}{\cos \left (-a + c\right )^{2} + 2 \, \cos \left (-a + c\right ) + 1}\right )}{2 \, b \cos \left (-a + c\right )} \] Input:
integrate(csc(b*x+c)*sec(b*x+a),x, algorithm="fricas")
Output:
1/2*(log(-1/4*cos(b*x + c)^2 + 1/4) - log(4*(2*cos(b*x + c)*cos(-a + c)*si n(b*x + c)*sin(-a + c) + (2*cos(-a + c)^2 - 1)*cos(b*x + c)^2 - cos(-a + c )^2 + 1)/(cos(-a + c)^2 + 2*cos(-a + c) + 1)))/(b*cos(-a + c))
\[ \int \csc (c+b x) \sec (a+b x) \, dx=\int \csc {\left (b x + c \right )} \sec {\left (a + b x \right )}\, dx \] Input:
integrate(csc(b*x+c)*sec(b*x+a),x)
Output:
Integral(csc(b*x + c)*sec(a + b*x), x)
Leaf count of result is larger than twice the leaf count of optimal. 430 vs. \(2 (36) = 72\).
Time = 0.06 (sec) , antiderivative size = 430, normalized size of antiderivative = 11.94 \[ \int \csc (c+b x) \sec (a+b x) \, dx =\text {Too large to display} \] Input:
integrate(csc(b*x+c)*sec(b*x+a),x, algorithm="maxima")
Output:
-(2*((sin(2*a) + sin(2*c))*cos(a + c) - (cos(2*a) + cos(2*c))*sin(a + c))* arctan2(sin(2*b*x) - sin(2*a), cos(2*b*x) + cos(2*a)) - 2*((sin(2*a) + sin (2*c))*cos(a + c) - (cos(2*a) + cos(2*c))*sin(a + c))*arctan2(sin(b*x) + s in(c), cos(b*x) - cos(c)) - 2*((sin(2*a) + sin(2*c))*cos(a + c) - (cos(2*a ) + cos(2*c))*sin(a + c))*arctan2(sin(b*x) - sin(c), cos(b*x) + cos(c)) + ((cos(2*a) + cos(2*c))*cos(a + c) + (sin(2*a) + sin(2*c))*sin(a + c))*log( cos(2*b*x)^2 + 2*cos(2*b*x)*cos(2*a) + cos(2*a)^2 + sin(2*b*x)^2 - 2*sin(2 *b*x)*sin(2*a) + sin(2*a)^2) - ((cos(2*a) + cos(2*c))*cos(a + c) + (sin(2* a) + sin(2*c))*sin(a + 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) - ((cos(2*a) + cos(2*c))*cos(a + c) + (sin(2*a) + sin(2*c))*sin(a + 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*b*cos(2*a)* cos(2*c) + b*cos(2*c)^2 + 2*b*sin(2*a)*sin(2*c) + b*sin(2*c)^2 + (cos(2*a) ^2 + sin(2*a)^2)*b)
Leaf count of result is larger than twice the leaf count of optimal. 391 vs. \(2 (36) = 72\).
Time = 0.15 (sec) , antiderivative size = 391, normalized size of antiderivative = 10.86 \[ \int \csc (c+b x) \sec (a+b x) \, dx =\text {Too large to display} \] Input:
integrate(csc(b*x+c)*sec(b*x+a),x, algorithm="giac")
Output:
-((tan(1/2*a)^4*tan(1/2*c)^3 - tan(1/2*a)^3*tan(1/2*c)^4 + tan(1/2*a)^4*ta n(1/2*c) - tan(1/2*a)*tan(1/2*c)^4 + tan(1/2*a)^3 - tan(1/2*c)^3 + tan(1/2 *a) - tan(1/2*c))*log(abs(2*tan(b*x + c)*tan(1/2*a)^2*tan(1/2*c) - 2*tan(b *x + c)*tan(1/2*a)*tan(1/2*c)^2 - tan(1/2*a)^2*tan(1/2*c)^2 + 2*tan(b*x + c)*tan(1/2*a) + tan(1/2*a)^2 - 2*tan(b*x + c)*tan(1/2*c) - 4*tan(1/2*a)*ta n(1/2*c) + tan(1/2*c)^2 - 1))/(tan(1/2*a)^4*tan(1/2*c)^3 - tan(1/2*a)^3*ta n(1/2*c)^4 - tan(1/2*a)^4*tan(1/2*c) + 6*tan(1/2*a)^3*tan(1/2*c)^2 - 6*tan (1/2*a)^2*tan(1/2*c)^3 + tan(1/2*a)*tan(1/2*c)^4 - tan(1/2*a)^3 + 6*tan(1/ 2*a)^2*tan(1/2*c) - 6*tan(1/2*a)*tan(1/2*c)^2 + tan(1/2*c)^3 + tan(1/2*a) - tan(1/2*c)) - (tan(1/2*a)^2*tan(1/2*c)^2 + tan(1/2*a)^2 + tan(1/2*c)^2 + 1)*log(abs(tan(b*x + c)))/(tan(1/2*a)^2*tan(1/2*c)^2 - tan(1/2*a)^2 + 4*t an(1/2*a)*tan(1/2*c) - tan(1/2*c)^2 + 1))/b
Time = 23.77 (sec) , antiderivative size = 311, normalized size of antiderivative = 8.64 \[ \int \csc (c+b x) \sec (a+b x) \, dx=-\frac {4\,\sqrt {{\mathrm {e}}^{a\,2{}\mathrm {i}-c\,2{}\mathrm {i}}}\,\mathrm {atan}\left (\frac {{\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{b\,x\,2{}\mathrm {i}}\,\left (\frac {2\,{\mathrm {e}}^{a\,1{}\mathrm {i}}\,{\mathrm {e}}^{-c\,1{}\mathrm {i}}}{b\,{\left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}\right )}^{3/2}}-\frac {2\,{\mathrm {e}}^{-a\,3{}\mathrm {i}}\,{\mathrm {e}}^{c\,3{}\mathrm {i}}\,\left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}-1\right )\,\left (b\,\sqrt {{\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}}-b\,{\left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}\right )}^{3/2}\right )}{\sqrt {-b^2\,{\left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}+1\right )}^2}\,\sqrt {-b^2-2\,b^2\,{\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}-b^2\,{\mathrm {e}}^{a\,4{}\mathrm {i}}\,{\mathrm {e}}^{-c\,4{}\mathrm {i}}}}\right )\,\sqrt {-b^2-2\,b^2\,{\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}-b^2\,{\mathrm {e}}^{a\,4{}\mathrm {i}}\,{\mathrm {e}}^{-c\,4{}\mathrm {i}}}}{4}+\frac {b\,{\mathrm {e}}^{-a\,3{}\mathrm {i}}\,{\mathrm {e}}^{c\,3{}\mathrm {i}}\,\left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}-1\right )\,{\left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}\right )}^{3/2}}{\sqrt {-b^2\,{\left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{-c\,2{}\mathrm {i}}+1\right )}^2}}\right )}{\sqrt {-2\,b^2\,{\mathrm {e}}^{a\,2{}\mathrm {i}-c\,2{}\mathrm {i}}-b^2\,{\mathrm {e}}^{a\,4{}\mathrm {i}-c\,4{}\mathrm {i}}-b^2}} \] Input:
int(1/(cos(a + b*x)*sin(c + b*x)),x)
Output:
-(4*exp(a*2i - c*2i)^(1/2)*atan((exp(a*2i)*exp(b*x*2i)*((2*exp(a*1i)*exp(- c*1i))/(b*(exp(a*2i)*exp(-c*2i))^(3/2)) - (2*exp(-a*3i)*exp(c*3i)*(exp(a*2 i)*exp(-c*2i) - 1)*(b*(exp(a*2i)*exp(-c*2i))^(1/2) - b*(exp(a*2i)*exp(-c*2 i))^(3/2)))/((-b^2*(exp(a*2i)*exp(-c*2i) + 1)^2)^(1/2)*(- b^2 - 2*b^2*exp( a*2i)*exp(-c*2i) - b^2*exp(a*4i)*exp(-c*4i))^(1/2)))*(- b^2 - 2*b^2*exp(a* 2i)*exp(-c*2i) - b^2*exp(a*4i)*exp(-c*4i))^(1/2))/4 + (b*exp(-a*3i)*exp(c* 3i)*(exp(a*2i)*exp(-c*2i) - 1)*(exp(a*2i)*exp(-c*2i))^(3/2))/(-b^2*(exp(a* 2i)*exp(-c*2i) + 1)^2)^(1/2)))/(- 2*b^2*exp(a*2i - c*2i) - b^2*exp(a*4i - c*4i) - b^2)^(1/2)
\[ \int \csc (c+b x) \sec (a+b x) \, dx=\frac {\left (\int \frac {1}{\sin \left (b x +c \right )}d x \right ) b +\left (\int \frac {1}{\cos \left (b x +a \right ) \sin \left (b x +c \right )}d x \right ) b -\mathrm {log}\left (\tan \left (\frac {b x}{2}+\frac {c}{2}\right )\right )}{b} \] Input:
int(csc(b*x+c)*sec(b*x+a),x)
Output:
(int(1/sin(b*x + c),x)*b + int(1/(cos(a + b*x)*sin(b*x + c)),x)*b - log(ta n((b*x + c)/2)))/b