Integrand size = 19, antiderivative size = 79 \[ \int \sin ^4(c+d x) (a+b \tan (c+d x)) \, dx=\frac {3 a x}{8}+\frac {b \cos ^2(c+d x)}{d}-\frac {b \log (\cos (c+d x))}{d}-\frac {5 a \cos (c+d x) \sin (c+d x)}{8 d}-\frac {\cos ^4(c+d x) (b-a \tan (c+d x))}{4 d} \] Output:
3/8*a*x+b*cos(d*x+c)^2/d-b*ln(cos(d*x+c))/d-5/8*a*cos(d*x+c)*sin(d*x+c)/d- 1/4*cos(d*x+c)^4*(b-a*tan(d*x+c))/d
Time = 0.09 (sec) , antiderivative size = 82, normalized size of antiderivative = 1.04 \[ \int \sin ^4(c+d x) (a+b \tan (c+d x)) \, dx=\frac {3 a (c+d x)}{8 d}-\frac {b \left (-\cos ^2(c+d x)+\frac {1}{4} \cos ^4(c+d x)+\log (\cos (c+d x))\right )}{d}-\frac {a \sin (2 (c+d x))}{4 d}+\frac {a \sin (4 (c+d x))}{32 d} \] Input:
Integrate[Sin[c + d*x]^4*(a + b*Tan[c + d*x]),x]
Output:
(3*a*(c + d*x))/(8*d) - (b*(-Cos[c + d*x]^2 + Cos[c + d*x]^4/4 + Log[Cos[c + d*x]]))/d - (a*Sin[2*(c + d*x)])/(4*d) + (a*Sin[4*(c + d*x)])/(32*d)
Time = 0.35 (sec) , antiderivative size = 95, normalized size of antiderivative = 1.20, number of steps used = 8, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.368, Rules used = {3042, 4889, 530, 2345, 452, 216, 240}
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 \sin ^4(c+d x) (a+b \tan (c+d x)) \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \sin (c+d x)^4 (a+b \tan (c+d x))dx\) |
\(\Big \downarrow \) 4889 |
\(\displaystyle \frac {\int \frac {\tan ^4(c+d x) (a+b \tan (c+d x))}{\left (\tan ^2(c+d x)+1\right )^3}d\tan (c+d x)}{d}\) |
\(\Big \downarrow \) 530 |
\(\displaystyle \frac {-\frac {1}{4} \int \frac {-4 b \tan ^3(c+d x)-4 a \tan ^2(c+d x)+4 b \tan (c+d x)+a}{\left (\tan ^2(c+d x)+1\right )^2}d\tan (c+d x)-\frac {b-a \tan (c+d x)}{4 \left (\tan ^2(c+d x)+1\right )^2}}{d}\) |
\(\Big \downarrow \) 2345 |
\(\displaystyle \frac {\frac {1}{4} \left (\frac {1}{2} \int \frac {3 a+8 b \tan (c+d x)}{\tan ^2(c+d x)+1}d\tan (c+d x)+\frac {8 b-5 a \tan (c+d x)}{2 \left (\tan ^2(c+d x)+1\right )}\right )-\frac {b-a \tan (c+d x)}{4 \left (\tan ^2(c+d x)+1\right )^2}}{d}\) |
\(\Big \downarrow \) 452 |
\(\displaystyle \frac {\frac {1}{4} \left (\frac {1}{2} \left (3 a \int \frac {1}{\tan ^2(c+d x)+1}d\tan (c+d x)+8 b \int \frac {\tan (c+d x)}{\tan ^2(c+d x)+1}d\tan (c+d x)\right )+\frac {8 b-5 a \tan (c+d x)}{2 \left (\tan ^2(c+d x)+1\right )}\right )-\frac {b-a \tan (c+d x)}{4 \left (\tan ^2(c+d x)+1\right )^2}}{d}\) |
\(\Big \downarrow \) 216 |
\(\displaystyle \frac {\frac {1}{4} \left (\frac {1}{2} \left (8 b \int \frac {\tan (c+d x)}{\tan ^2(c+d x)+1}d\tan (c+d x)+3 a \arctan (\tan (c+d x))\right )+\frac {8 b-5 a \tan (c+d x)}{2 \left (\tan ^2(c+d x)+1\right )}\right )-\frac {b-a \tan (c+d x)}{4 \left (\tan ^2(c+d x)+1\right )^2}}{d}\) |
\(\Big \downarrow \) 240 |
\(\displaystyle \frac {\frac {1}{4} \left (\frac {1}{2} \left (3 a \arctan (\tan (c+d x))+4 b \log \left (\tan ^2(c+d x)+1\right )\right )+\frac {8 b-5 a \tan (c+d x)}{2 \left (\tan ^2(c+d x)+1\right )}\right )-\frac {b-a \tan (c+d x)}{4 \left (\tan ^2(c+d x)+1\right )^2}}{d}\) |
Input:
Int[Sin[c + d*x]^4*(a + b*Tan[c + d*x]),x]
Output:
(-1/4*(b - a*Tan[c + d*x])/(1 + Tan[c + d*x]^2)^2 + ((3*a*ArcTan[Tan[c + d *x]] + 4*b*Log[1 + Tan[c + d*x]^2])/2 + (8*b - 5*a*Tan[c + d*x])/(2*(1 + T an[c + d*x]^2)))/4)/d
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[b, 2]))*A rcTan[Rt[b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a , 0] || GtQ[b, 0])
Int[(x_)/((a_) + (b_.)*(x_)^2), x_Symbol] :> Simp[Log[RemoveContent[a + b*x ^2, x]]/(2*b), x] /; FreeQ[{a, b}, x]
Int[((c_) + (d_.)*(x_))/((a_) + (b_.)*(x_)^2), x_Symbol] :> Simp[c Int[1/ (a + b*x^2), x], x] + Simp[d Int[x/(a + b*x^2), x], x] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c^2 + a*d^2, 0]
Int[(x_)^(m_.)*((c_) + (d_.)*(x_))^(n_.)*((a_) + (b_.)*(x_)^2)^(p_), x_Symb ol] :> With[{Qx = PolynomialQuotient[x^m*(c + d*x)^n, a + b*x^2, x], e = Co eff[PolynomialRemainder[x^m*(c + d*x)^n, a + b*x^2, x], x, 0], f = Coeff[Po lynomialRemainder[x^m*(c + d*x)^n, a + b*x^2, x], x, 1]}, Simp[(a*f - b*e*x )*((a + b*x^2)^(p + 1)/(2*a*b*(p + 1))), x] + Simp[1/(2*a*(p + 1)) Int[(a + b*x^2)^(p + 1)*ExpandToSum[2*a*(p + 1)*Qx + e*(2*p + 3), x], x], x]] /; FreeQ[{a, b, c, d}, x] && IGtQ[n, 0] && IGtQ[m, 0] && LtQ[p, -1] && EqQ[n, 1] && IntegerQ[2*p]
Int[(Pq_)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> With[{Q = PolynomialQuot ient[Pq, a + b*x^2, x], f = Coeff[PolynomialRemainder[Pq, a + b*x^2, x], x, 0], g = Coeff[PolynomialRemainder[Pq, a + b*x^2, x], x, 1]}, Simp[(a*g - b *f*x)*((a + b*x^2)^(p + 1)/(2*a*b*(p + 1))), x] + Simp[1/(2*a*(p + 1)) In t[(a + b*x^2)^(p + 1)*ExpandToSum[2*a*(p + 1)*Q + f*(2*p + 3), x], x], x]] /; FreeQ[{a, b}, x] && PolyQ[Pq, x] && LtQ[p, -1]
Int[u_, x_Symbol] :> With[{v = FunctionOfTrig[u, x]}, With[{d = FreeFactors [Tan[v], x]}, Simp[d/Coefficient[v, x, 1] Subst[Int[SubstFor[1/(1 + d^2*x ^2), Tan[v]/d, u, x], x], x, Tan[v]/d], x]] /; !FalseQ[v] && FunctionOfQ[N onfreeFactors[Tan[v], x], u, x]] /; InverseFunctionFreeQ[u, x] && !MatchQ[ u, (v_.)*((c_.)*tan[w_]^(n_.)*tan[z_]^(n_.))^(p_.) /; FreeQ[{c, p}, x] && I ntegerQ[n] && LinearQ[w, x] && EqQ[z, 2*w]]
Time = 2.88 (sec) , antiderivative size = 73, normalized size of antiderivative = 0.92
method | result | size |
derivativedivides | \(\frac {a \left (-\frac {\left (\sin \left (d x +c \right )^{3}+\frac {3 \sin \left (d x +c \right )}{2}\right ) \cos \left (d x +c \right )}{4}+\frac {3 d x}{8}+\frac {3 c}{8}\right )+b \left (-\frac {\sin \left (d x +c \right )^{4}}{4}-\frac {\sin \left (d x +c \right )^{2}}{2}-\ln \left (\cos \left (d x +c \right )\right )\right )}{d}\) | \(73\) |
default | \(\frac {a \left (-\frac {\left (\sin \left (d x +c \right )^{3}+\frac {3 \sin \left (d x +c \right )}{2}\right ) \cos \left (d x +c \right )}{4}+\frac {3 d x}{8}+\frac {3 c}{8}\right )+b \left (-\frac {\sin \left (d x +c \right )^{4}}{4}-\frac {\sin \left (d x +c \right )^{2}}{2}-\ln \left (\cos \left (d x +c \right )\right )\right )}{d}\) | \(73\) |
risch | \(i b x +\frac {3 a x}{8}+\frac {3 \,{\mathrm e}^{2 i \left (d x +c \right )} b}{16 d}+\frac {i {\mathrm e}^{2 i \left (d x +c \right )} a}{8 d}+\frac {3 \,{\mathrm e}^{-2 i \left (d x +c \right )} b}{16 d}-\frac {i {\mathrm e}^{-2 i \left (d x +c \right )} a}{8 d}+\frac {2 i b c}{d}-\frac {b \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )}{d}-\frac {b \cos \left (4 d x +4 c \right )}{32 d}+\frac {a \sin \left (4 d x +4 c \right )}{32 d}\) | \(129\) |
Input:
int(sin(d*x+c)^4*(a+b*tan(d*x+c)),x,method=_RETURNVERBOSE)
Output:
1/d*(a*(-1/4*(sin(d*x+c)^3+3/2*sin(d*x+c))*cos(d*x+c)+3/8*d*x+3/8*c)+b*(-1 /4*sin(d*x+c)^4-1/2*sin(d*x+c)^2-ln(cos(d*x+c))))
Time = 0.09 (sec) , antiderivative size = 74, normalized size of antiderivative = 0.94 \[ \int \sin ^4(c+d x) (a+b \tan (c+d x)) \, dx=-\frac {2 \, b \cos \left (d x + c\right )^{4} - 3 \, a d x - 8 \, b \cos \left (d x + c\right )^{2} + 8 \, b \log \left (-\cos \left (d x + c\right )\right ) - {\left (2 \, a \cos \left (d x + c\right )^{3} - 5 \, a \cos \left (d x + c\right )\right )} \sin \left (d x + c\right )}{8 \, d} \] Input:
integrate(sin(d*x+c)^4*(a+b*tan(d*x+c)),x, algorithm="fricas")
Output:
-1/8*(2*b*cos(d*x + c)^4 - 3*a*d*x - 8*b*cos(d*x + c)^2 + 8*b*log(-cos(d*x + c)) - (2*a*cos(d*x + c)^3 - 5*a*cos(d*x + c))*sin(d*x + c))/d
\[ \int \sin ^4(c+d x) (a+b \tan (c+d x)) \, dx=\int \left (a + b \tan {\left (c + d x \right )}\right ) \sin ^{4}{\left (c + d x \right )}\, dx \] Input:
integrate(sin(d*x+c)**4*(a+b*tan(d*x+c)),x)
Output:
Integral((a + b*tan(c + d*x))*sin(c + d*x)**4, x)
Time = 0.11 (sec) , antiderivative size = 87, normalized size of antiderivative = 1.10 \[ \int \sin ^4(c+d x) (a+b \tan (c+d x)) \, dx=\frac {3 \, {\left (d x + c\right )} a + 4 \, b \log \left (\tan \left (d x + c\right )^{2} + 1\right ) - \frac {5 \, a \tan \left (d x + c\right )^{3} - 8 \, b \tan \left (d x + c\right )^{2} + 3 \, a \tan \left (d x + c\right ) - 6 \, b}{\tan \left (d x + c\right )^{4} + 2 \, \tan \left (d x + c\right )^{2} + 1}}{8 \, d} \] Input:
integrate(sin(d*x+c)^4*(a+b*tan(d*x+c)),x, algorithm="maxima")
Output:
1/8*(3*(d*x + c)*a + 4*b*log(tan(d*x + c)^2 + 1) - (5*a*tan(d*x + c)^3 - 8 *b*tan(d*x + c)^2 + 3*a*tan(d*x + c) - 6*b)/(tan(d*x + c)^4 + 2*tan(d*x + c)^2 + 1))/d
Time = 0.15 (sec) , antiderivative size = 81, normalized size of antiderivative = 1.03 \[ \int \sin ^4(c+d x) (a+b \tan (c+d x)) \, dx=\frac {3 \, {\left (d x + c\right )} a}{8 \, d} + \frac {b \log \left (\tan \left (d x + c\right )^{2} + 1\right )}{2 \, d} - \frac {5 \, a \tan \left (d x + c\right )^{3} - 8 \, b \tan \left (d x + c\right )^{2} + 3 \, a \tan \left (d x + c\right ) - 6 \, b}{8 \, {\left (\tan \left (d x + c\right )^{2} + 1\right )}^{2} d} \] Input:
integrate(sin(d*x+c)^4*(a+b*tan(d*x+c)),x, algorithm="giac")
Output:
3/8*(d*x + c)*a/d + 1/2*b*log(tan(d*x + c)^2 + 1)/d - 1/8*(5*a*tan(d*x + c )^3 - 8*b*tan(d*x + c)^2 + 3*a*tan(d*x + c) - 6*b)/((tan(d*x + c)^2 + 1)^2 *d)
Time = 0.83 (sec) , antiderivative size = 155, normalized size of antiderivative = 1.96 \[ \int \sin ^4(c+d x) (a+b \tan (c+d x)) \, dx=\frac {3\,a\,x}{8}+\frac {b\,\ln \left ({\mathrm {tan}\left (c+d\,x\right )}^2+1\right )}{2\,d}+\frac {3\,b}{4\,d\,\left ({\mathrm {tan}\left (c+d\,x\right )}^4+2\,{\mathrm {tan}\left (c+d\,x\right )}^2+1\right )}-\frac {5\,a\,{\mathrm {tan}\left (c+d\,x\right )}^3}{8\,d\,\left ({\mathrm {tan}\left (c+d\,x\right )}^4+2\,{\mathrm {tan}\left (c+d\,x\right )}^2+1\right )}+\frac {b\,{\mathrm {tan}\left (c+d\,x\right )}^2}{d\,\left ({\mathrm {tan}\left (c+d\,x\right )}^4+2\,{\mathrm {tan}\left (c+d\,x\right )}^2+1\right )}-\frac {3\,a\,\mathrm {tan}\left (c+d\,x\right )}{8\,d\,\left ({\mathrm {tan}\left (c+d\,x\right )}^4+2\,{\mathrm {tan}\left (c+d\,x\right )}^2+1\right )} \] Input:
int(sin(c + d*x)^4*(a + b*tan(c + d*x)),x)
Output:
(3*a*x)/8 + (b*log(tan(c + d*x)^2 + 1))/(2*d) + (3*b)/(4*d*(2*tan(c + d*x) ^2 + tan(c + d*x)^4 + 1)) - (5*a*tan(c + d*x)^3)/(8*d*(2*tan(c + d*x)^2 + tan(c + d*x)^4 + 1)) + (b*tan(c + d*x)^2)/(d*(2*tan(c + d*x)^2 + tan(c + d *x)^4 + 1)) - (3*a*tan(c + d*x))/(8*d*(2*tan(c + d*x)^2 + tan(c + d*x)^4 + 1))
Time = 0.16 (sec) , antiderivative size = 116, normalized size of antiderivative = 1.47 \[ \int \sin ^4(c+d x) (a+b \tan (c+d x)) \, dx=\frac {-2 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{3} a -3 \cos \left (d x +c \right ) \sin \left (d x +c \right ) a +8 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1\right ) b -8 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right ) b -8 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right ) b -2 \sin \left (d x +c \right )^{4} b -4 \sin \left (d x +c \right )^{2} b +3 a c +3 a d x}{8 d} \] Input:
int(sin(d*x+c)^4*(a+b*tan(d*x+c)),x)
Output:
( - 2*cos(c + d*x)*sin(c + d*x)**3*a - 3*cos(c + d*x)*sin(c + d*x)*a + 8*l og(tan((c + d*x)/2)**2 + 1)*b - 8*log(tan((c + d*x)/2) - 1)*b - 8*log(tan( (c + d*x)/2) + 1)*b - 2*sin(c + d*x)**4*b - 4*sin(c + d*x)**2*b + 3*a*c + 3*a*d*x)/(8*d)