3.941 \(\int f^{a+b x} (\cos (c+d x)-i \sin (c+d x))^n \, dx\)

Optimal. Leaf size=36 \[ -\frac {f^{a+b x} \left (e^{-i (c+d x)}\right )^n}{-b \log (f)+i d n} \]

[Out]

-exp(-I*(d*x+c))^n*f^(b*x+a)/(I*d*n-b*ln(f))

________________________________________________________________________________________

Rubi [A]  time = 0.10, antiderivative size = 36, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 27, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.148, Rules used = {4614, 2281, 2287, 2194} \[ -\frac {f^{a+b x} \left (e^{-i (c+d x)}\right )^n}{-b \log (f)+i d n} \]

Antiderivative was successfully verified.

[In]

Int[f^(a + b*x)*(Cos[c + d*x] - I*Sin[c + d*x])^n,x]

[Out]

-(((E^((-I)*(c + d*x)))^n*f^(a + b*x))/(I*d*n - b*Log[f]))

Rule 2194

Int[((F_)^((c_.)*((a_.) + (b_.)*(x_))))^(n_.), x_Symbol] :> Simp[(F^(c*(a + b*x)))^n/(b*c*n*Log[F]), x] /; Fre
eQ[{F, a, b, c, n}, x]

Rule 2281

Int[(u_.)*((a_.)*(F_)^(v_))^(n_), x_Symbol] :> Dist[(a*F^v)^n/F^(n*v), Int[u*F^(n*v), x], x] /; FreeQ[{F, a, n
}, x] &&  !IntegerQ[n]

Rule 2287

Int[(u_.)*(F_)^(v_)*(G_)^(w_), x_Symbol] :> With[{z = v*Log[F] + w*Log[G]}, Int[u*NormalizeIntegrand[E^z, x],
x] /; BinomialQ[z, x] || (PolynomialQ[z, x] && LeQ[Exponent[z, x], 2])] /; FreeQ[{F, G}, x]

Rule 4614

Int[(u_.)*(Cos[v_]*(a_.) + (b_.)*Sin[v_])^(n_.), x_Symbol] :> Int[u*(a/E^((a*v)/b))^n, x] /; FreeQ[{a, b, n},
x] && EqQ[a^2 + b^2, 0]

Rubi steps

\begin {align*} \int f^{a+b x} (\cos (c+d x)-i \sin (c+d x))^n \, dx &=\int \left (e^{-i (c+d x)}\right )^n f^{a+b x} \, dx\\ &=\left (e^{i n (c+d x)} \left (e^{-i (c+d x)}\right )^n\right ) \int e^{-i n (c+d x)} f^{a+b x} \, dx\\ &=\left (e^{i n (c+d x)} \left (e^{-i (c+d x)}\right )^n\right ) \int \exp (-i c n+a \log (f)-x (i d n-b \log (f))) \, dx\\ &=-\frac {\left (e^{-i (c+d x)}\right )^n f^{a+b x}}{i d n-b \log (f)}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.09, size = 43, normalized size = 1.19 \[ \frac {i f^{a+b x} (\cos (c+d x)-i \sin (c+d x))^n}{d n+i b \log (f)} \]

Antiderivative was successfully verified.

[In]

Integrate[f^(a + b*x)*(Cos[c + d*x] - I*Sin[c + d*x])^n,x]

[Out]

(I*f^(a + b*x)*(Cos[c + d*x] - I*Sin[c + d*x])^n)/(d*n + I*b*Log[f])

________________________________________________________________________________________

fricas [A]  time = 0.93, size = 30, normalized size = 0.83 \[ \frac {f^{b x + a} e^{\left (-i \, d n x - i \, c n\right )}}{-i \, d n + b \log \relax (f)} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(f^(b*x+a)*(cos(d*x+c)-I*sin(d*x+c))^n,x, algorithm="fricas")

[Out]

f^(b*x + a)*e^(-I*d*n*x - I*c*n)/(-I*d*n + b*log(f))

________________________________________________________________________________________

giac [A]  time = 0.83, size = 31, normalized size = 0.86 \[ \frac {f^{a} e^{\left (-i \, d n x + b x \log \relax (f) - i \, c n\right )}}{-i \, d n + b \log \relax (f)} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(f^(b*x+a)*(cos(d*x+c)-I*sin(d*x+c))^n,x, algorithm="giac")

[Out]

f^a*e^(-I*d*n*x + b*x*log(f) - I*c*n)/(-I*d*n + b*log(f))

________________________________________________________________________________________

maple [B]  time = 0.39, size = 86, normalized size = 2.39 \[ \frac {{\mathrm e}^{\left (b x +a \right ) \ln \relax (f )} {\mathrm e}^{n \ln \left (\frac {1-\left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )}-\frac {2 i \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )}\right )}}{-i d n +b \ln \relax (f )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(f^(b*x+a)*(cos(d*x+c)-I*sin(d*x+c))^n,x)

[Out]

1/(-I*d*n+b*ln(f))*exp((b*x+a)*ln(f))*exp(n*ln((1-tan(1/2*d*x+1/2*c)^2)/(1+tan(1/2*d*x+1/2*c)^2)-2*I*tan(1/2*d
*x+1/2*c)/(1+tan(1/2*d*x+1/2*c)^2)))

________________________________________________________________________________________

maxima [A]  time = 0.49, size = 62, normalized size = 1.72 \[ \frac {f^{b x} f^{a} \cos \left (d n x\right ) - i \, f^{b x} f^{a} \sin \left (d n x\right )}{{\left (-i \, d n + b \log \relax (f)\right )} \cos \left (c n\right ) + {\left (d n + i \, b \log \relax (f)\right )} \sin \left (c n\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(f^(b*x+a)*(cos(d*x+c)-I*sin(d*x+c))^n,x, algorithm="maxima")

[Out]

(f^(b*x)*f^a*cos(d*n*x) - I*f^(b*x)*f^a*sin(d*n*x))/((-I*d*n + b*log(f))*cos(c*n) + (d*n + I*b*log(f))*sin(c*n
))

________________________________________________________________________________________

mupad [B]  time = 3.35, size = 35, normalized size = 0.97 \[ -\frac {f^{a+b\,x}\,{\left ({\mathrm {e}}^{-c\,1{}\mathrm {i}-d\,x\,1{}\mathrm {i}}\right )}^n}{-b\,\ln \relax (f)+d\,n\,1{}\mathrm {i}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(f^(a + b*x)*(cos(c + d*x) - sin(c + d*x)*1i)^n,x)

[Out]

-(f^(a + b*x)*exp(- c*1i - d*x*1i)^n)/(d*n*1i - b*log(f))

________________________________________________________________________________________

sympy [A]  time = 6.66, size = 107, normalized size = 2.97 \[ \begin {cases} - \frac {f^{a} f^{b x} \left (- i \sin {\left (c + d x \right )} + \cos {\left (c + d x \right )}\right )^{n}}{- b \log {\relax (f )} + i d n} & \text {for}\: b \neq \frac {i d n}{\log {\relax (f )}} \\f^{a} x \left (- i \sin {\left (c + d x \right )} + \cos {\left (c + d x \right )}\right )^{n} e^{i d n x} + \frac {i f^{a} \left (- i \sin {\left (c + d x \right )} + \cos {\left (c + d x \right )}\right )^{n} e^{i d n x}}{d n} & \text {otherwise} \end {cases} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(f**(b*x+a)*(cos(d*x+c)-I*sin(d*x+c))**n,x)

[Out]

Piecewise((-f**a*f**(b*x)*(-I*sin(c + d*x) + cos(c + d*x))**n/(-b*log(f) + I*d*n), Ne(b, I*d*n/log(f))), (f**a
*x*(-I*sin(c + d*x) + cos(c + d*x))**n*exp(I*d*n*x) + I*f**a*(-I*sin(c + d*x) + cos(c + d*x))**n*exp(I*d*n*x)/
(d*n), True))

________________________________________________________________________________________