Optimal. Leaf size=598 \[ -\frac {a 2^{-\frac {m}{2}-\frac {1}{2}} \left (a^2 (m+2)+2 a b-b^2\right ) (1-\sin (c+d x))^2 (e \cos (c+d x))^{-m-3} \left (\frac {(a+b) (\sin (c+d x)+1)}{a+b \sin (c+d x)}\right )^{\frac {m+3}{2}} (a+b \sin (c+d x))^{m+1} \, _2F_1\left (\frac {1-m}{2},\frac {m+3}{2};\frac {3-m}{2};\frac {(a-b) (1-\sin (c+d x))}{2 (a+b \sin (c+d x))}\right )}{d e (1-m) (m+3) (a-b) (a+b)^3}+\frac {a (\sin (c+d x)+1) (e \cos (c+d x))^{-m-3} (a+b \sin (c+d x))^{m+1}}{d e (m+3) \left (a^2-b^2\right )}-\frac {a b 2^{\frac {3}{2}-\frac {m}{2}} (e \cos (c+d x))^{-m-1} \left (\frac {(a+b) (\sin (c+d x)+1)}{a+b \sin (c+d x)}\right )^{\frac {m+1}{2}} (a+b \sin (c+d x))^{m+1} \, _2F_1\left (\frac {1}{2} (-m-1),\frac {m+1}{2};\frac {1-m}{2};\frac {(a-b) (1-\sin (c+d x))}{2 (a+b \sin (c+d x))}\right )}{d e^3 (m+1) (m+3) (a-b)^2 (a+b)}+\frac {2 b (e \cos (c+d x))^{-m-1} (a+b \sin (c+d x))^{m+1}}{d e^3 (m+1) (m+3) (a-b)^2}+\frac {a (a (m+2)+3 b) (1-\sin (c+d x)) (\sin (c+d x)+1) (e \cos (c+d x))^{-m-3} (a+b \sin (c+d x))^{m+1}}{d e (m+1) (m+3) (a-b) (a+b)^2}-\frac {(e \cos (c+d x))^{-m-3} (a+b \sin (c+d x))^{m+1}}{d e (m+3) (a-b)} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 1.02, antiderivative size = 598, normalized size of antiderivative = 1.00, number of steps used = 9, number of rules used = 7, integrand size = 27, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.259, Rules used = {2700, 2699, 2920, 132, 129, 155, 12} \[ -\frac {a 2^{-\frac {m}{2}-\frac {1}{2}} \left (a^2 (m+2)+2 a b-b^2\right ) (1-\sin (c+d x))^2 (e \cos (c+d x))^{-m-3} \left (\frac {(a+b) (\sin (c+d x)+1)}{a+b \sin (c+d x)}\right )^{\frac {m+3}{2}} (a+b \sin (c+d x))^{m+1} \, _2F_1\left (\frac {1-m}{2},\frac {m+3}{2};\frac {3-m}{2};\frac {(a-b) (1-\sin (c+d x))}{2 (a+b \sin (c+d x))}\right )}{d e (1-m) (m+3) (a-b) (a+b)^3}+\frac {a (\sin (c+d x)+1) (e \cos (c+d x))^{-m-3} (a+b \sin (c+d x))^{m+1}}{d e (m+3) \left (a^2-b^2\right )}-\frac {a b 2^{\frac {3}{2}-\frac {m}{2}} (e \cos (c+d x))^{-m-1} \left (\frac {(a+b) (\sin (c+d x)+1)}{a+b \sin (c+d x)}\right )^{\frac {m+1}{2}} (a+b \sin (c+d x))^{m+1} \, _2F_1\left (\frac {1}{2} (-m-1),\frac {m+1}{2};\frac {1-m}{2};\frac {(a-b) (1-\sin (c+d x))}{2 (a+b \sin (c+d x))}\right )}{d e^3 (m+1) (m+3) (a-b)^2 (a+b)}+\frac {2 b (e \cos (c+d x))^{-m-1} (a+b \sin (c+d x))^{m+1}}{d e^3 (m+1) (m+3) (a-b)^2}+\frac {a (a (m+2)+3 b) (1-\sin (c+d x)) (\sin (c+d x)+1) (e \cos (c+d x))^{-m-3} (a+b \sin (c+d x))^{m+1}}{d e (m+1) (m+3) (a-b) (a+b)^2}-\frac {(e \cos (c+d x))^{-m-3} (a+b \sin (c+d x))^{m+1}}{d e (m+3) (a-b)} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 129
Rule 132
Rule 155
Rule 2699
Rule 2700
Rule 2920
Rubi steps
\begin {align*} \int (e \cos (c+d x))^{-4-m} (a+b \sin (c+d x))^m \, dx &=-\frac {(e \cos (c+d x))^{-3-m} (a+b \sin (c+d x))^{1+m}}{(a-b) d e (3+m)}+\frac {a \int \frac {(e \cos (c+d x))^{-2-m} (a+b \sin (c+d x))^m}{1-\sin (c+d x)} \, dx}{(a-b) e^2}-\frac {(2 b) \int (e \cos (c+d x))^{-2-m} (a+b \sin (c+d x))^m \, dx}{(a-b) e^2 (3+m)}\\ &=-\frac {(e \cos (c+d x))^{-3-m} (a+b \sin (c+d x))^{1+m}}{(a-b) d e (3+m)}+\frac {2 b (e \cos (c+d x))^{-1-m} (a+b \sin (c+d x))^{1+m}}{(a-b)^2 d e^3 (1+m) (3+m)}-\frac {(2 a b) \int \frac {(e \cos (c+d x))^{-m} (a+b \sin (c+d x))^m}{1-\sin (c+d x)} \, dx}{(a-b)^2 e^4 (3+m)}+\frac {\left (a (e \cos (c+d x))^{-3-m} (1-\sin (c+d x))^{\frac {3+m}{2}} (1+\sin (c+d x))^{\frac {3+m}{2}}\right ) \operatorname {Subst}\left (\int (1-x)^{-1+\frac {1}{2} (-3-m)} (1+x)^{\frac {1}{2} (-3-m)} (a+b x)^m \, dx,x,\sin (c+d x)\right )}{(a-b) d e}\\ &=-\frac {(e \cos (c+d x))^{-3-m} (a+b \sin (c+d x))^{1+m}}{(a-b) d e (3+m)}+\frac {2 b (e \cos (c+d x))^{-1-m} (a+b \sin (c+d x))^{1+m}}{(a-b)^2 d e^3 (1+m) (3+m)}+\frac {a (e \cos (c+d x))^{-3-m} (1+\sin (c+d x)) (a+b \sin (c+d x))^{1+m}}{\left (a^2-b^2\right ) d e (3+m)}-\frac {\left (2 a b (e \cos (c+d x))^{-1-m} (1-\sin (c+d x))^{\frac {1+m}{2}} (1+\sin (c+d x))^{\frac {1+m}{2}}\right ) \operatorname {Subst}\left (\int (1-x)^{-1+\frac {1}{2} (-1-m)} (1+x)^{\frac {1}{2} (-1-m)} (a+b x)^m \, dx,x,\sin (c+d x)\right )}{(a-b)^2 d e^3 (3+m)}-\frac {\left (a (e \cos (c+d x))^{-3-m} (1-\sin (c+d x))^{\frac {3+m}{2}} (1+\sin (c+d x))^{\frac {3+m}{2}}\right ) \operatorname {Subst}\left (\int (1-x)^{\frac {1}{2} (-3-m)} (1+x)^{\frac {1}{2} (-3-m)} (-2 b-a (2+m)-b x) (a+b x)^m \, dx,x,\sin (c+d x)\right )}{(a-b) (a+b) d e (3+m)}\\ &=-\frac {(e \cos (c+d x))^{-3-m} (a+b \sin (c+d x))^{1+m}}{(a-b) d e (3+m)}+\frac {2 b (e \cos (c+d x))^{-1-m} (a+b \sin (c+d x))^{1+m}}{(a-b)^2 d e^3 (1+m) (3+m)}+\frac {a (e \cos (c+d x))^{-3-m} (1+\sin (c+d x)) (a+b \sin (c+d x))^{1+m}}{\left (a^2-b^2\right ) d e (3+m)}+\frac {a (3 b+a (2+m)) (e \cos (c+d x))^{-3-m} (1-\sin (c+d x)) (1+\sin (c+d x)) (a+b \sin (c+d x))^{1+m}}{(a-b) (a+b)^2 d e (1+m) (3+m)}-\frac {2^{\frac {3}{2}-\frac {m}{2}} a b (e \cos (c+d x))^{-1-m} \, _2F_1\left (\frac {1}{2} (-1-m),\frac {1+m}{2};\frac {1-m}{2};\frac {(a-b) (1-\sin (c+d x))}{2 (a+b \sin (c+d x))}\right ) \left (\frac {(a+b) (1+\sin (c+d x))}{a+b \sin (c+d x)}\right )^{\frac {1+m}{2}} (a+b \sin (c+d x))^{1+m}}{(a-b)^2 (a+b) d e^3 (1+m) (3+m)}+\frac {\left (a (e \cos (c+d x))^{-3-m} (1-\sin (c+d x))^{\frac {3+m}{2}} (1+\sin (c+d x))^{\frac {3+m}{2}}\right ) \operatorname {Subst}\left (\int (1+m) \left (2 a b-b^2+a^2 (2+m)\right ) (1-x)^{1+\frac {1}{2} (-3-m)} (1+x)^{\frac {1}{2} (-3-m)} (a+b x)^m \, dx,x,\sin (c+d x)\right )}{2 (-a-b) (a-b) (a+b) d e \left (1+\frac {1}{2} (-3-m)\right ) (3+m)}\\ &=-\frac {(e \cos (c+d x))^{-3-m} (a+b \sin (c+d x))^{1+m}}{(a-b) d e (3+m)}+\frac {2 b (e \cos (c+d x))^{-1-m} (a+b \sin (c+d x))^{1+m}}{(a-b)^2 d e^3 (1+m) (3+m)}+\frac {a (e \cos (c+d x))^{-3-m} (1+\sin (c+d x)) (a+b \sin (c+d x))^{1+m}}{\left (a^2-b^2\right ) d e (3+m)}+\frac {a (3 b+a (2+m)) (e \cos (c+d x))^{-3-m} (1-\sin (c+d x)) (1+\sin (c+d x)) (a+b \sin (c+d x))^{1+m}}{(a-b) (a+b)^2 d e (1+m) (3+m)}-\frac {2^{\frac {3}{2}-\frac {m}{2}} a b (e \cos (c+d x))^{-1-m} \, _2F_1\left (\frac {1}{2} (-1-m),\frac {1+m}{2};\frac {1-m}{2};\frac {(a-b) (1-\sin (c+d x))}{2 (a+b \sin (c+d x))}\right ) \left (\frac {(a+b) (1+\sin (c+d x))}{a+b \sin (c+d x)}\right )^{\frac {1+m}{2}} (a+b \sin (c+d x))^{1+m}}{(a-b)^2 (a+b) d e^3 (1+m) (3+m)}+\frac {\left (a (1+m) \left (2 a b-b^2+a^2 (2+m)\right ) (e \cos (c+d x))^{-3-m} (1-\sin (c+d x))^{\frac {3+m}{2}} (1+\sin (c+d x))^{\frac {3+m}{2}}\right ) \operatorname {Subst}\left (\int (1-x)^{1+\frac {1}{2} (-3-m)} (1+x)^{\frac {1}{2} (-3-m)} (a+b x)^m \, dx,x,\sin (c+d x)\right )}{2 (-a-b) (a-b) (a+b) d e \left (1+\frac {1}{2} (-3-m)\right ) (3+m)}\\ &=-\frac {(e \cos (c+d x))^{-3-m} (a+b \sin (c+d x))^{1+m}}{(a-b) d e (3+m)}+\frac {2 b (e \cos (c+d x))^{-1-m} (a+b \sin (c+d x))^{1+m}}{(a-b)^2 d e^3 (1+m) (3+m)}+\frac {a (e \cos (c+d x))^{-3-m} (1+\sin (c+d x)) (a+b \sin (c+d x))^{1+m}}{\left (a^2-b^2\right ) d e (3+m)}+\frac {a (3 b+a (2+m)) (e \cos (c+d x))^{-3-m} (1-\sin (c+d x)) (1+\sin (c+d x)) (a+b \sin (c+d x))^{1+m}}{(a-b) (a+b)^2 d e (1+m) (3+m)}-\frac {2^{\frac {3}{2}-\frac {m}{2}} a b (e \cos (c+d x))^{-1-m} \, _2F_1\left (\frac {1}{2} (-1-m),\frac {1+m}{2};\frac {1-m}{2};\frac {(a-b) (1-\sin (c+d x))}{2 (a+b \sin (c+d x))}\right ) \left (\frac {(a+b) (1+\sin (c+d x))}{a+b \sin (c+d x)}\right )^{\frac {1+m}{2}} (a+b \sin (c+d x))^{1+m}}{(a-b)^2 (a+b) d e^3 (1+m) (3+m)}-\frac {2^{-\frac {1}{2}-\frac {m}{2}} a \left (2 a b-b^2+a^2 (2+m)\right ) (e \cos (c+d x))^{-3-m} \, _2F_1\left (\frac {1-m}{2},\frac {3+m}{2};\frac {3-m}{2};\frac {(a-b) (1-\sin (c+d x))}{2 (a+b \sin (c+d x))}\right ) (1-\sin (c+d x))^2 \left (\frac {(a+b) (1+\sin (c+d x))}{a+b \sin (c+d x)}\right )^{\frac {3+m}{2}} (a+b \sin (c+d x))^{1+m}}{(a-b) (a+b)^3 d e (1-m) (3+m)}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 6.10, size = 826, normalized size = 1.38 \[ \frac {\cos (c+d x) (a+b \sin (c+d x))^{m+1} (e \cos (c+d x))^{-m-4}}{(a-b) d (-m-3)}+\frac {2 b \cos ^{m+4}(c+d x) \left (\frac {2^{\frac {1}{2} (-m-1)+1} a \, _2F_1\left (\frac {1}{2} (-m-1),\frac {m+1}{2};\frac {1}{2} (-m-1)+1;-\frac {(b-a) (1-\sin (c+d x))}{2 (a+b \sin (c+d x))}\right ) (1-\sin (c+d x))^{\frac {1}{2} (-m-1)+\frac {m+1}{2}} (\sin (c+d x)+1)^{\frac {1}{2} (-m-1)+\frac {m+1}{2}} \left (-\frac {(-a-b) (\sin (c+d x)+1)}{a+b \sin (c+d x)}\right )^{\frac {m+1}{2}} (a+b \sin (c+d x))^{m+1} \cos ^{-m-1}(c+d x)}{(-a-b) (a-b) d (-m-1)}+\frac {(a+b \sin (c+d x))^{m+1} \cos ^{-m-1}(c+d x)}{(a-b) d (-m-1)}\right ) (e \cos (c+d x))^{-m-4}}{(a-b) (-m-3)}+\frac {a \cos (c+d x) (1-\sin (c+d x))^{\frac {m+3}{2}} (\sin (c+d x)+1)^{\frac {m+3}{2}} \left (\frac {(1-\sin (c+d x))^{\frac {1}{2} (-m-3)} (\sin (c+d x)+1)^{\frac {1}{2} (-m-3)+1} (a+b \sin (c+d x))^{m+1}}{(-a-b) (-m-3)}-\frac {-\frac {(3 b+a (m+2)) (1-\sin (c+d x))^{\frac {1}{2} (-m-3)+1} (a+b \sin (c+d x))^{m+1} (\sin (c+d x)+1)^{\frac {1}{2} (-m-3)+1}}{2 (-a-b) \left (\frac {1}{2} (-m-3)+1\right )}-\frac {2^{\frac {1}{2} (-m-3)-1} (m+1) \left ((m+2) a^2+2 b a-b^2\right ) \, _2F_1\left (\frac {1}{2} (-m-3)+2,\frac {m+3}{2};\frac {1}{2} (-m-3)+3;-\frac {(b-a) (1-\sin (c+d x))}{2 (a+b \sin (c+d x))}\right ) (1-\sin (c+d x))^{\frac {1}{2} (-m-3)+2} \left (-\frac {(-a-b) (\sin (c+d x)+1)}{a+b \sin (c+d x)}\right )^{\frac {m+3}{2}} (a+b \sin (c+d x))^{m+1} (\sin (c+d x)+1)^{\frac {1}{2} (-m-3)}}{(-a-b)^2 \left (\frac {1}{2} (-m-3)+1\right ) \left (\frac {1}{2} (-m-3)+2\right )}}{(-a-b) (-m-3)}\right ) (e \cos (c+d x))^{-m-4}}{(a-b) d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [F] time = 0.89, size = 0, normalized size = 0.00 \[ {\rm integral}\left (\left (e \cos \left (d x + c\right )\right )^{-m - 4} {\left (b \sin \left (d x + c\right ) + a\right )}^{m}, x\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \left (e \cos \left (d x + c\right )\right )^{-m - 4} {\left (b \sin \left (d x + c\right ) + a\right )}^{m}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [F] time = 0.36, size = 0, normalized size = 0.00 \[ \int \left (e \cos \left (d x +c \right )\right )^{-4-m} \left (a +b \sin \left (d x +c \right )\right )^{m}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \left (e \cos \left (d x + c\right )\right )^{-m - 4} {\left (b \sin \left (d x + c\right ) + a\right )}^{m}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [F] time = 0.00, size = -1, normalized size = -0.00 \[ \int \frac {{\left (a+b\,\sin \left (c+d\,x\right )\right )}^m}{{\left (e\,\cos \left (c+d\,x\right )\right )}^{m+4}} \,d x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________