\(\int \frac {(a+b \sin (e+f x))^2}{(c+d x)^3} \, dx\) [162]

Optimal result
Mathematica [A] (verified)
Rubi [A] (verified)
Maple [A] (verified)
Fricas [A] (verification not implemented)
Sympy [F]
Maxima [C] (verification not implemented)
Giac [C] (verification not implemented)
Mupad [F(-1)]
Reduce [F]

Optimal result

Integrand size = 20, antiderivative size = 245 \[ \int \frac {(a+b \sin (e+f x))^2}{(c+d x)^3} \, dx=-\frac {a^2}{2 d (c+d x)^2}-\frac {a b f \cos (e+f x)}{d^2 (c+d x)}+\frac {b^2 f^2 \cos \left (2 e-\frac {2 c f}{d}\right ) \operatorname {CosIntegral}\left (\frac {2 c f}{d}+2 f x\right )}{d^3}-\frac {a b f^2 \operatorname {CosIntegral}\left (\frac {c f}{d}+f x\right ) \sin \left (e-\frac {c f}{d}\right )}{d^3}-\frac {a b \sin (e+f x)}{d (c+d x)^2}-\frac {b^2 f \cos (e+f x) \sin (e+f x)}{d^2 (c+d x)}-\frac {b^2 \sin ^2(e+f x)}{2 d (c+d x)^2}-\frac {a b f^2 \cos \left (e-\frac {c f}{d}\right ) \text {Si}\left (\frac {c f}{d}+f x\right )}{d^3}-\frac {b^2 f^2 \sin \left (2 e-\frac {2 c f}{d}\right ) \text {Si}\left (\frac {2 c f}{d}+2 f x\right )}{d^3} \] Output:

-1/2*a^2/d/(d*x+c)^2-a*b*f*cos(f*x+e)/d^2/(d*x+c)+b^2*f^2*cos(-2*e+2*c*f/d 
)*Ci(2*c*f/d+2*f*x)/d^3+a*b*f^2*Ci(c*f/d+f*x)*sin(-e+c*f/d)/d^3-a*b*sin(f* 
x+e)/d/(d*x+c)^2-b^2*f*cos(f*x+e)*sin(f*x+e)/d^2/(d*x+c)-1/2*b^2*sin(f*x+e 
)^2/d/(d*x+c)^2-a*b*f^2*cos(-e+c*f/d)*Si(c*f/d+f*x)/d^3+b^2*f^2*sin(-2*e+2 
*c*f/d)*Si(2*c*f/d+2*f*x)/d^3
 

Mathematica [A] (verified)

Time = 1.41 (sec) , antiderivative size = 395, normalized size of antiderivative = 1.61 \[ \int \frac {(a+b \sin (e+f x))^2}{(c+d x)^3} \, dx=-\frac {2 a^2 d^2+b^2 d^2+4 a b c d f \cos (e+f x)+4 a b d^2 f x \cos (e+f x)-b^2 d^2 \cos (2 (e+f x))-4 b^2 f^2 (c+d x)^2 \cos \left (2 e-\frac {2 c f}{d}\right ) \operatorname {CosIntegral}\left (\frac {2 f (c+d x)}{d}\right )+4 a b f^2 (c+d x)^2 \operatorname {CosIntegral}\left (f \left (\frac {c}{d}+x\right )\right ) \sin \left (e-\frac {c f}{d}\right )+4 a b d^2 \sin (e+f x)+2 b^2 c d f \sin (2 (e+f x))+2 b^2 d^2 f x \sin (2 (e+f x))+4 a b c^2 f^2 \cos \left (e-\frac {c f}{d}\right ) \text {Si}\left (f \left (\frac {c}{d}+x\right )\right )+8 a b c d f^2 x \cos \left (e-\frac {c f}{d}\right ) \text {Si}\left (f \left (\frac {c}{d}+x\right )\right )+4 a b d^2 f^2 x^2 \cos \left (e-\frac {c f}{d}\right ) \text {Si}\left (f \left (\frac {c}{d}+x\right )\right )+4 b^2 c^2 f^2 \sin \left (2 e-\frac {2 c f}{d}\right ) \text {Si}\left (\frac {2 f (c+d x)}{d}\right )+8 b^2 c d f^2 x \sin \left (2 e-\frac {2 c f}{d}\right ) \text {Si}\left (\frac {2 f (c+d x)}{d}\right )+4 b^2 d^2 f^2 x^2 \sin \left (2 e-\frac {2 c f}{d}\right ) \text {Si}\left (\frac {2 f (c+d x)}{d}\right )}{4 d^3 (c+d x)^2} \] Input:

Integrate[(a + b*Sin[e + f*x])^2/(c + d*x)^3,x]
 

Output:

-1/4*(2*a^2*d^2 + b^2*d^2 + 4*a*b*c*d*f*Cos[e + f*x] + 4*a*b*d^2*f*x*Cos[e 
 + f*x] - b^2*d^2*Cos[2*(e + f*x)] - 4*b^2*f^2*(c + d*x)^2*Cos[2*e - (2*c* 
f)/d]*CosIntegral[(2*f*(c + d*x))/d] + 4*a*b*f^2*(c + d*x)^2*CosIntegral[f 
*(c/d + x)]*Sin[e - (c*f)/d] + 4*a*b*d^2*Sin[e + f*x] + 2*b^2*c*d*f*Sin[2* 
(e + f*x)] + 2*b^2*d^2*f*x*Sin[2*(e + f*x)] + 4*a*b*c^2*f^2*Cos[e - (c*f)/ 
d]*SinIntegral[f*(c/d + x)] + 8*a*b*c*d*f^2*x*Cos[e - (c*f)/d]*SinIntegral 
[f*(c/d + x)] + 4*a*b*d^2*f^2*x^2*Cos[e - (c*f)/d]*SinIntegral[f*(c/d + x) 
] + 4*b^2*c^2*f^2*Sin[2*e - (2*c*f)/d]*SinIntegral[(2*f*(c + d*x))/d] + 8* 
b^2*c*d*f^2*x*Sin[2*e - (2*c*f)/d]*SinIntegral[(2*f*(c + d*x))/d] + 4*b^2* 
d^2*f^2*x^2*Sin[2*e - (2*c*f)/d]*SinIntegral[(2*f*(c + d*x))/d])/(d^3*(c + 
 d*x)^2)
 

Rubi [A] (verified)

Time = 0.69 (sec) , antiderivative size = 245, 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.150, Rules used = {3042, 3798, 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 {(a+b \sin (e+f x))^2}{(c+d x)^3} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {(a+b \sin (e+f x))^2}{(c+d x)^3}dx\)

\(\Big \downarrow \) 3798

\(\displaystyle \int \left (\frac {a^2}{(c+d x)^3}+\frac {2 a b \sin (e+f x)}{(c+d x)^3}+\frac {b^2 \sin ^2(e+f x)}{(c+d x)^3}\right )dx\)

\(\Big \downarrow \) 2009

\(\displaystyle -\frac {a^2}{2 d (c+d x)^2}-\frac {a b f^2 \operatorname {CosIntegral}\left (x f+\frac {c f}{d}\right ) \sin \left (e-\frac {c f}{d}\right )}{d^3}-\frac {a b f^2 \cos \left (e-\frac {c f}{d}\right ) \text {Si}\left (x f+\frac {c f}{d}\right )}{d^3}-\frac {a b f \cos (e+f x)}{d^2 (c+d x)}-\frac {a b \sin (e+f x)}{d (c+d x)^2}+\frac {b^2 f^2 \operatorname {CosIntegral}\left (2 x f+\frac {2 c f}{d}\right ) \cos \left (2 e-\frac {2 c f}{d}\right )}{d^3}-\frac {b^2 f^2 \sin \left (2 e-\frac {2 c f}{d}\right ) \text {Si}\left (2 x f+\frac {2 c f}{d}\right )}{d^3}-\frac {b^2 f \sin (e+f x) \cos (e+f x)}{d^2 (c+d x)}-\frac {b^2 \sin ^2(e+f x)}{2 d (c+d x)^2}\)

Input:

Int[(a + b*Sin[e + f*x])^2/(c + d*x)^3,x]
 

Output:

-1/2*a^2/(d*(c + d*x)^2) - (a*b*f*Cos[e + f*x])/(d^2*(c + d*x)) + (b^2*f^2 
*Cos[2*e - (2*c*f)/d]*CosIntegral[(2*c*f)/d + 2*f*x])/d^3 - (a*b*f^2*CosIn 
tegral[(c*f)/d + f*x]*Sin[e - (c*f)/d])/d^3 - (a*b*Sin[e + f*x])/(d*(c + d 
*x)^2) - (b^2*f*Cos[e + f*x]*Sin[e + f*x])/(d^2*(c + d*x)) - (b^2*Sin[e + 
f*x]^2)/(2*d*(c + d*x)^2) - (a*b*f^2*Cos[e - (c*f)/d]*SinIntegral[(c*f)/d 
+ f*x])/d^3 - (b^2*f^2*Sin[2*e - (2*c*f)/d]*SinIntegral[(2*c*f)/d + 2*f*x] 
)/d^3
 

Defintions of rubi rules used

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 3798
Int[((c_.) + (d_.)*(x_))^(m_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(n_.) 
, x_Symbol] :> Int[ExpandIntegrand[(c + d*x)^m, (a + b*Sin[e + f*x])^n, x], 
 x] /; FreeQ[{a, b, c, d, e, f, m}, x] && IGtQ[n, 0] && (EqQ[n, 1] || IGtQ[ 
m, 0] || NeQ[a^2 - b^2, 0])
 
Maple [A] (verified)

Time = 2.03 (sec) , antiderivative size = 359, normalized size of antiderivative = 1.47

method result size
parts \(-\frac {a^{2}}{2 d \left (d x +c \right )^{2}}+\frac {b^{2} \left (-\frac {f^{3}}{4 \left (c f -d e +d \left (f x +e \right )\right )^{2} d}-\frac {f^{3} \left (-\frac {\cos \left (2 f x +2 e \right )}{\left (c f -d e +d \left (f x +e \right )\right )^{2} d}-\frac {-\frac {2 \sin \left (2 f x +2 e \right )}{\left (c f -d e +d \left (f x +e \right )\right ) d}+\frac {\frac {4 \,\operatorname {Si}\left (2 f x +2 e +\frac {2 c f -2 d e}{d}\right ) \sin \left (\frac {2 c f -2 d e}{d}\right )}{d}+\frac {4 \,\operatorname {Ci}\left (2 f x +2 e +\frac {2 c f -2 d e}{d}\right ) \cos \left (\frac {2 c f -2 d e}{d}\right )}{d}}{d}}{d}\right )}{4}\right )}{f}+2 a b \,f^{2} \left (-\frac {\sin \left (f x +e \right )}{2 \left (c f -d e +d \left (f x +e \right )\right )^{2} d}+\frac {-\frac {\cos \left (f x +e \right )}{\left (c f -d e +d \left (f x +e \right )\right ) d}-\frac {\frac {\operatorname {Si}\left (f x +e +\frac {c f -d e}{d}\right ) \cos \left (\frac {c f -d e}{d}\right )}{d}-\frac {\operatorname {Ci}\left (f x +e +\frac {c f -d e}{d}\right ) \sin \left (\frac {c f -d e}{d}\right )}{d}}{d}}{2 d}\right )\) \(359\)
derivativedivides \(\frac {-\frac {f^{3} a^{2}}{2 \left (c f -d e +d \left (f x +e \right )\right )^{2} d}+2 a b \,f^{3} \left (-\frac {\sin \left (f x +e \right )}{2 \left (c f -d e +d \left (f x +e \right )\right )^{2} d}+\frac {-\frac {\cos \left (f x +e \right )}{\left (c f -d e +d \left (f x +e \right )\right ) d}-\frac {\frac {\operatorname {Si}\left (f x +e +\frac {c f -d e}{d}\right ) \cos \left (\frac {c f -d e}{d}\right )}{d}-\frac {\operatorname {Ci}\left (f x +e +\frac {c f -d e}{d}\right ) \sin \left (\frac {c f -d e}{d}\right )}{d}}{d}}{2 d}\right )-\frac {b^{2} f^{3}}{4 \left (c f -d e +d \left (f x +e \right )\right )^{2} d}-\frac {b^{2} f^{3} \left (-\frac {\cos \left (2 f x +2 e \right )}{\left (c f -d e +d \left (f x +e \right )\right )^{2} d}-\frac {-\frac {2 \sin \left (2 f x +2 e \right )}{\left (c f -d e +d \left (f x +e \right )\right ) d}+\frac {\frac {4 \,\operatorname {Si}\left (2 f x +2 e +\frac {2 c f -2 d e}{d}\right ) \sin \left (\frac {2 c f -2 d e}{d}\right )}{d}+\frac {4 \,\operatorname {Ci}\left (2 f x +2 e +\frac {2 c f -2 d e}{d}\right ) \cos \left (\frac {2 c f -2 d e}{d}\right )}{d}}{d}}{d}\right )}{4}}{f}\) \(374\)
default \(\frac {-\frac {f^{3} a^{2}}{2 \left (c f -d e +d \left (f x +e \right )\right )^{2} d}+2 a b \,f^{3} \left (-\frac {\sin \left (f x +e \right )}{2 \left (c f -d e +d \left (f x +e \right )\right )^{2} d}+\frac {-\frac {\cos \left (f x +e \right )}{\left (c f -d e +d \left (f x +e \right )\right ) d}-\frac {\frac {\operatorname {Si}\left (f x +e +\frac {c f -d e}{d}\right ) \cos \left (\frac {c f -d e}{d}\right )}{d}-\frac {\operatorname {Ci}\left (f x +e +\frac {c f -d e}{d}\right ) \sin \left (\frac {c f -d e}{d}\right )}{d}}{d}}{2 d}\right )-\frac {b^{2} f^{3}}{4 \left (c f -d e +d \left (f x +e \right )\right )^{2} d}-\frac {b^{2} f^{3} \left (-\frac {\cos \left (2 f x +2 e \right )}{\left (c f -d e +d \left (f x +e \right )\right )^{2} d}-\frac {-\frac {2 \sin \left (2 f x +2 e \right )}{\left (c f -d e +d \left (f x +e \right )\right ) d}+\frac {\frac {4 \,\operatorname {Si}\left (2 f x +2 e +\frac {2 c f -2 d e}{d}\right ) \sin \left (\frac {2 c f -2 d e}{d}\right )}{d}+\frac {4 \,\operatorname {Ci}\left (2 f x +2 e +\frac {2 c f -2 d e}{d}\right ) \cos \left (\frac {2 c f -2 d e}{d}\right )}{d}}{d}}{d}\right )}{4}}{f}\) \(374\)
risch \(\frac {i f^{2} a b \,{\mathrm e}^{\frac {i \left (c f -d e \right )}{d}} \operatorname {expIntegral}_{1}\left (i f x +i e +\frac {i \left (c f -d e \right )}{d}\right )}{2 d^{3}}-\frac {a^{2}}{2 d \left (d x +c \right )^{2}}-\frac {b^{2}}{4 d \left (d x +c \right )^{2}}-\frac {b^{2} f^{2} {\mathrm e}^{\frac {2 i \left (c f -d e \right )}{d}} \operatorname {expIntegral}_{1}\left (2 i f x +2 i e +\frac {2 i \left (c f -d e \right )}{d}\right )}{2 d^{3}}-\frac {b^{2} f^{2} {\mathrm e}^{-\frac {2 i \left (c f -d e \right )}{d}} \operatorname {expIntegral}_{1}\left (-2 i f x -2 i e -\frac {2 \left (i c f -i d e \right )}{d}\right )}{2 d^{3}}-\frac {i a b \,f^{2} {\mathrm e}^{-\frac {i \left (c f -d e \right )}{d}} \operatorname {expIntegral}_{1}\left (-i f x -i e -\frac {i c f -i d e}{d}\right )}{2 d^{3}}+\frac {i a b \left (-2 i d^{3} f^{3} x^{3}-6 i c \,d^{2} f^{3} x^{2}-6 i c^{2} d \,f^{3} x -2 i c^{3} f^{3}\right ) \cos \left (f x +e \right )}{2 d^{2} \left (d x +c \right )^{2} \left (-d^{2} x^{2} f^{2}-2 c d \,f^{2} x -c^{2} f^{2}\right )}-\frac {a b \left (-2 d^{2} x^{2} f^{2}-4 c d \,f^{2} x -2 c^{2} f^{2}\right ) \sin \left (f x +e \right )}{2 d \left (d x +c \right )^{2} \left (-d^{2} x^{2} f^{2}-2 c d \,f^{2} x -c^{2} f^{2}\right )}+\frac {b^{2} \left (-2 d^{3} f^{2} x^{2}-4 c \,d^{2} f^{2} x -2 c^{2} d \,f^{2}\right ) \cos \left (2 f x +2 e \right )}{8 d^{2} \left (d x +c \right )^{2} \left (-d^{2} x^{2} f^{2}-2 c d \,f^{2} x -c^{2} f^{2}\right )}-\frac {i b^{2} \left (4 i d^{3} f^{3} x^{3}+12 i c \,d^{2} f^{3} x^{2}+12 i c^{2} d \,f^{3} x +4 i c^{3} f^{3}\right ) \sin \left (2 f x +2 e \right )}{8 d^{2} \left (d x +c \right )^{2} \left (-d^{2} x^{2} f^{2}-2 c d \,f^{2} x -c^{2} f^{2}\right )}\) \(605\)

Input:

int((a+b*sin(f*x+e))^2/(d*x+c)^3,x,method=_RETURNVERBOSE)
 

Output:

-1/2*a^2/d/(d*x+c)^2+b^2/f*(-1/4*f^3/(c*f-d*e+d*(f*x+e))^2/d-1/4*f^3*(-cos 
(2*f*x+2*e)/(c*f-d*e+d*(f*x+e))^2/d-(-2*sin(2*f*x+2*e)/(c*f-d*e+d*(f*x+e)) 
/d+2*(2*Si(2*f*x+2*e+2*(c*f-d*e)/d)*sin(2*(c*f-d*e)/d)/d+2*Ci(2*f*x+2*e+2* 
(c*f-d*e)/d)*cos(2*(c*f-d*e)/d)/d)/d)/d))+2*a*b*f^2*(-1/2*sin(f*x+e)/(c*f- 
d*e+d*(f*x+e))^2/d+1/2*(-cos(f*x+e)/(c*f-d*e+d*(f*x+e))/d-(Si(f*x+e+(c*f-d 
*e)/d)*cos((c*f-d*e)/d)/d-Ci(f*x+e+(c*f-d*e)/d)*sin((c*f-d*e)/d)/d)/d)/d)
 

Fricas [A] (verification not implemented)

Time = 0.10 (sec) , antiderivative size = 368, normalized size of antiderivative = 1.50 \[ \int \frac {(a+b \sin (e+f x))^2}{(c+d x)^3} \, dx=\frac {b^{2} d^{2} \cos \left (f x + e\right )^{2} - {\left (a^{2} + b^{2}\right )} d^{2} + 2 \, {\left (b^{2} d^{2} f^{2} x^{2} + 2 \, b^{2} c d f^{2} x + b^{2} c^{2} f^{2}\right )} \cos \left (-\frac {2 \, {\left (d e - c f\right )}}{d}\right ) \operatorname {Ci}\left (\frac {2 \, {\left (d f x + c f\right )}}{d}\right ) + 2 \, {\left (a b d^{2} f^{2} x^{2} + 2 \, a b c d f^{2} x + a b c^{2} f^{2}\right )} \operatorname {Ci}\left (\frac {d f x + c f}{d}\right ) \sin \left (-\frac {d e - c f}{d}\right ) + 2 \, {\left (b^{2} d^{2} f^{2} x^{2} + 2 \, b^{2} c d f^{2} x + b^{2} c^{2} f^{2}\right )} \sin \left (-\frac {2 \, {\left (d e - c f\right )}}{d}\right ) \operatorname {Si}\left (\frac {2 \, {\left (d f x + c f\right )}}{d}\right ) - 2 \, {\left (a b d^{2} f^{2} x^{2} + 2 \, a b c d f^{2} x + a b c^{2} f^{2}\right )} \cos \left (-\frac {d e - c f}{d}\right ) \operatorname {Si}\left (\frac {d f x + c f}{d}\right ) - 2 \, {\left (a b d^{2} f x + a b c d f\right )} \cos \left (f x + e\right ) - 2 \, {\left (a b d^{2} + {\left (b^{2} d^{2} f x + b^{2} c d f\right )} \cos \left (f x + e\right )\right )} \sin \left (f x + e\right )}{2 \, {\left (d^{5} x^{2} + 2 \, c d^{4} x + c^{2} d^{3}\right )}} \] Input:

integrate((a+b*sin(f*x+e))^2/(d*x+c)^3,x, algorithm="fricas")
 

Output:

1/2*(b^2*d^2*cos(f*x + e)^2 - (a^2 + b^2)*d^2 + 2*(b^2*d^2*f^2*x^2 + 2*b^2 
*c*d*f^2*x + b^2*c^2*f^2)*cos(-2*(d*e - c*f)/d)*cos_integral(2*(d*f*x + c* 
f)/d) + 2*(a*b*d^2*f^2*x^2 + 2*a*b*c*d*f^2*x + a*b*c^2*f^2)*cos_integral(( 
d*f*x + c*f)/d)*sin(-(d*e - c*f)/d) + 2*(b^2*d^2*f^2*x^2 + 2*b^2*c*d*f^2*x 
 + b^2*c^2*f^2)*sin(-2*(d*e - c*f)/d)*sin_integral(2*(d*f*x + c*f)/d) - 2* 
(a*b*d^2*f^2*x^2 + 2*a*b*c*d*f^2*x + a*b*c^2*f^2)*cos(-(d*e - c*f)/d)*sin_ 
integral((d*f*x + c*f)/d) - 2*(a*b*d^2*f*x + a*b*c*d*f)*cos(f*x + e) - 2*( 
a*b*d^2 + (b^2*d^2*f*x + b^2*c*d*f)*cos(f*x + e))*sin(f*x + e))/(d^5*x^2 + 
 2*c*d^4*x + c^2*d^3)
 

Sympy [F]

\[ \int \frac {(a+b \sin (e+f x))^2}{(c+d x)^3} \, dx=\int \frac {\left (a + b \sin {\left (e + f x \right )}\right )^{2}}{\left (c + d x\right )^{3}}\, dx \] Input:

integrate((a+b*sin(f*x+e))**2/(d*x+c)**3,x)
 

Output:

Integral((a + b*sin(e + f*x))**2/(c + d*x)**3, x)
 

Maxima [C] (verification not implemented)

Result contains complex when optimal does not.

Time = 0.25 (sec) , antiderivative size = 476, normalized size of antiderivative = 1.94 \[ \int \frac {(a+b \sin (e+f x))^2}{(c+d x)^3} \, dx=-\frac {\frac {2 \, a^{2} f^{3}}{{\left (f x + e\right )}^{2} d^{3} + d^{3} e^{2} - 2 \, c d^{2} e f + c^{2} d f^{2} - 2 \, {\left (d^{3} e - c d^{2} f\right )} {\left (f x + e\right )}} - \frac {4 \, {\left (f^{3} {\left (-i \, E_{3}\left (\frac {i \, {\left (f x + e\right )} d - i \, d e + i \, c f}{d}\right ) + i \, E_{3}\left (-\frac {i \, {\left (f x + e\right )} d - i \, d e + i \, c f}{d}\right )\right )} \cos \left (-\frac {d e - c f}{d}\right ) + f^{3} {\left (E_{3}\left (\frac {i \, {\left (f x + e\right )} d - i \, d e + i \, c f}{d}\right ) + E_{3}\left (-\frac {i \, {\left (f x + e\right )} d - i \, d e + i \, c f}{d}\right )\right )} \sin \left (-\frac {d e - c f}{d}\right )\right )} a b}{{\left (f x + e\right )}^{2} d^{3} + d^{3} e^{2} - 2 \, c d^{2} e f + c^{2} d f^{2} - 2 \, {\left (d^{3} e - c d^{2} f\right )} {\left (f x + e\right )}} - \frac {{\left (f^{3} {\left (E_{3}\left (\frac {2 \, {\left (-i \, {\left (f x + e\right )} d + i \, d e - i \, c f\right )}}{d}\right ) + E_{3}\left (-\frac {2 \, {\left (-i \, {\left (f x + e\right )} d + i \, d e - i \, c f\right )}}{d}\right )\right )} \cos \left (-\frac {2 \, {\left (d e - c f\right )}}{d}\right ) - f^{3} {\left (i \, E_{3}\left (\frac {2 \, {\left (-i \, {\left (f x + e\right )} d + i \, d e - i \, c f\right )}}{d}\right ) - i \, E_{3}\left (-\frac {2 \, {\left (-i \, {\left (f x + e\right )} d + i \, d e - i \, c f\right )}}{d}\right )\right )} \sin \left (-\frac {2 \, {\left (d e - c f\right )}}{d}\right ) - f^{3}\right )} b^{2}}{{\left (f x + e\right )}^{2} d^{3} + d^{3} e^{2} - 2 \, c d^{2} e f + c^{2} d f^{2} - 2 \, {\left (d^{3} e - c d^{2} f\right )} {\left (f x + e\right )}}}{4 \, f} \] Input:

integrate((a+b*sin(f*x+e))^2/(d*x+c)^3,x, algorithm="maxima")
 

Output:

-1/4*(2*a^2*f^3/((f*x + e)^2*d^3 + d^3*e^2 - 2*c*d^2*e*f + c^2*d*f^2 - 2*( 
d^3*e - c*d^2*f)*(f*x + e)) - 4*(f^3*(-I*exp_integral_e(3, (I*(f*x + e)*d 
- I*d*e + I*c*f)/d) + I*exp_integral_e(3, -(I*(f*x + e)*d - I*d*e + I*c*f) 
/d))*cos(-(d*e - c*f)/d) + f^3*(exp_integral_e(3, (I*(f*x + e)*d - I*d*e + 
 I*c*f)/d) + exp_integral_e(3, -(I*(f*x + e)*d - I*d*e + I*c*f)/d))*sin(-( 
d*e - c*f)/d))*a*b/((f*x + e)^2*d^3 + d^3*e^2 - 2*c*d^2*e*f + c^2*d*f^2 - 
2*(d^3*e - c*d^2*f)*(f*x + e)) - (f^3*(exp_integral_e(3, 2*(-I*(f*x + e)*d 
 + I*d*e - I*c*f)/d) + exp_integral_e(3, -2*(-I*(f*x + e)*d + I*d*e - I*c* 
f)/d))*cos(-2*(d*e - c*f)/d) - f^3*(I*exp_integral_e(3, 2*(-I*(f*x + e)*d 
+ I*d*e - I*c*f)/d) - I*exp_integral_e(3, -2*(-I*(f*x + e)*d + I*d*e - I*c 
*f)/d))*sin(-2*(d*e - c*f)/d) - f^3)*b^2/((f*x + e)^2*d^3 + d^3*e^2 - 2*c* 
d^2*e*f + c^2*d*f^2 - 2*(d^3*e - c*d^2*f)*(f*x + e)))/f
 

Giac [C] (verification not implemented)

Result contains higher order function than in optimal. Order 9 vs. order 4.

Time = 2.20 (sec) , antiderivative size = 120406, normalized size of antiderivative = 491.45 \[ \int \frac {(a+b \sin (e+f x))^2}{(c+d x)^3} \, dx=\text {Too large to display} \] Input:

integrate((a+b*sin(f*x+e))^2/(d*x+c)^3,x, algorithm="giac")
 

Output:

-1/2*(a*b*d^2*f^2*x^2*imag_part(cos_integral(f*x + c*f/d))*tan(f*x)^2*tan( 
1/2*f*x)^2*tan(1/2*e)^2*tan(e)^2*tan(c*f/d)^2*tan(1/2*c*f/d)^2 - a*b*d^2*f 
^2*x^2*imag_part(cos_integral(-f*x - c*f/d))*tan(f*x)^2*tan(1/2*f*x)^2*tan 
(1/2*e)^2*tan(e)^2*tan(c*f/d)^2*tan(1/2*c*f/d)^2 - b^2*d^2*f^2*x^2*real_pa 
rt(cos_integral(2*f*x + 2*c*f/d))*tan(f*x)^2*tan(1/2*f*x)^2*tan(1/2*e)^2*t 
an(e)^2*tan(c*f/d)^2*tan(1/2*c*f/d)^2 - b^2*d^2*f^2*x^2*real_part(cos_inte 
gral(-2*f*x - 2*c*f/d))*tan(f*x)^2*tan(1/2*f*x)^2*tan(1/2*e)^2*tan(e)^2*ta 
n(c*f/d)^2*tan(1/2*c*f/d)^2 + 2*a*b*d^2*f^2*x^2*sin_integral((d*f*x + c*f) 
/d)*tan(f*x)^2*tan(1/2*f*x)^2*tan(1/2*e)^2*tan(e)^2*tan(c*f/d)^2*tan(1/2*c 
*f/d)^2 + 2*a*b*d^2*f^2*x^2*real_part(cos_integral(f*x + c*f/d))*tan(f*x)^ 
2*tan(1/2*f*x)^2*tan(1/2*e)^2*tan(e)^2*tan(c*f/d)^2*tan(1/2*c*f/d) + 2*a*b 
*d^2*f^2*x^2*real_part(cos_integral(-f*x - c*f/d))*tan(f*x)^2*tan(1/2*f*x) 
^2*tan(1/2*e)^2*tan(e)^2*tan(c*f/d)^2*tan(1/2*c*f/d) + 2*b^2*d^2*f^2*x^2*i 
mag_part(cos_integral(2*f*x + 2*c*f/d))*tan(f*x)^2*tan(1/2*f*x)^2*tan(1/2* 
e)^2*tan(e)^2*tan(c*f/d)*tan(1/2*c*f/d)^2 - 2*b^2*d^2*f^2*x^2*imag_part(co 
s_integral(-2*f*x - 2*c*f/d))*tan(f*x)^2*tan(1/2*f*x)^2*tan(1/2*e)^2*tan(e 
)^2*tan(c*f/d)*tan(1/2*c*f/d)^2 + 4*b^2*d^2*f^2*x^2*sin_integral(2*(d*f*x 
+ c*f)/d)*tan(f*x)^2*tan(1/2*f*x)^2*tan(1/2*e)^2*tan(e)^2*tan(c*f/d)*tan(1 
/2*c*f/d)^2 - 2*b^2*d^2*f^2*x^2*imag_part(cos_integral(2*f*x + 2*c*f/d))*t 
an(f*x)^2*tan(1/2*f*x)^2*tan(1/2*e)^2*tan(e)*tan(c*f/d)^2*tan(1/2*c*f/d...
 

Mupad [F(-1)]

Timed out. \[ \int \frac {(a+b \sin (e+f x))^2}{(c+d x)^3} \, dx=\int \frac {{\left (a+b\,\sin \left (e+f\,x\right )\right )}^2}{{\left (c+d\,x\right )}^3} \,d x \] Input:

int((a + b*sin(e + f*x))^2/(c + d*x)^3,x)
 

Output:

int((a + b*sin(e + f*x))^2/(c + d*x)^3, x)
 

Reduce [F]

\[ \int \frac {(a+b \sin (e+f x))^2}{(c+d x)^3} \, dx=\text {too large to display} \] Input:

int((a+b*sin(f*x+e))^2/(d*x+c)^3,x)
 

Output:

( - 2*cos(e + f*x)*sin(e + f*x)*a*b*c*d**2 + 2*cos(e + f*x)*sin(e + f*x)*b 
**2*c**2*d*f + 2*cos(e + f*x)*sin(e + f*x)*b**2*c*d**2*f*x - 8*cos(e + f*x 
)*b**2*c*d**2 - 16*int(x**2/(tan((e + f*x)/2)**4*c**3 + 3*tan((e + f*x)/2) 
**4*c**2*d*x + 3*tan((e + f*x)/2)**4*c*d**2*x**2 + tan((e + f*x)/2)**4*d** 
3*x**3 + 2*tan((e + f*x)/2)**2*c**3 + 6*tan((e + f*x)/2)**2*c**2*d*x + 6*t 
an((e + f*x)/2)**2*c*d**2*x**2 + 2*tan((e + f*x)/2)**2*d**3*x**3 + c**3 + 
3*c**2*d*x + 3*c*d**2*x**2 + d**3*x**3),x)*b**2*c**3*d**3*f**2 - 32*int(x* 
*2/(tan((e + f*x)/2)**4*c**3 + 3*tan((e + f*x)/2)**4*c**2*d*x + 3*tan((e + 
 f*x)/2)**4*c*d**2*x**2 + tan((e + f*x)/2)**4*d**3*x**3 + 2*tan((e + f*x)/ 
2)**2*c**3 + 6*tan((e + f*x)/2)**2*c**2*d*x + 6*tan((e + f*x)/2)**2*c*d**2 
*x**2 + 2*tan((e + f*x)/2)**2*d**3*x**3 + c**3 + 3*c**2*d*x + 3*c*d**2*x** 
2 + d**3*x**3),x)*b**2*c**2*d**4*f**2*x - 16*int(x**2/(tan((e + f*x)/2)**4 
*c**3 + 3*tan((e + f*x)/2)**4*c**2*d*x + 3*tan((e + f*x)/2)**4*c*d**2*x**2 
 + tan((e + f*x)/2)**4*d**3*x**3 + 2*tan((e + f*x)/2)**2*c**3 + 6*tan((e + 
 f*x)/2)**2*c**2*d*x + 6*tan((e + f*x)/2)**2*c*d**2*x**2 + 2*tan((e + f*x) 
/2)**2*d**3*x**3 + c**3 + 3*c**2*d*x + 3*c*d**2*x**2 + d**3*x**3),x)*b**2* 
c*d**5*f**2*x**2 - 16*int(tan((e + f*x)/2)/(tan((e + f*x)/2)**4*c**3 + 3*t 
an((e + f*x)/2)**4*c**2*d*x + 3*tan((e + f*x)/2)**4*c*d**2*x**2 + tan((e + 
 f*x)/2)**4*d**3*x**3 + 2*tan((e + f*x)/2)**2*c**3 + 6*tan((e + f*x)/2)**2 
*c**2*d*x + 6*tan((e + f*x)/2)**2*c*d**2*x**2 + 2*tan((e + f*x)/2)**2*d...