3.2.13 \(\int x \sec ^2(4 x) \, dx\) [113]

Optimal. Leaf size=19 \[ \frac {1}{16} \log (\cos (4 x))+\frac {1}{4} x \tan (4 x) \]

[Out]

1/16*ln(cos(4*x))+1/4*x*tan(4*x)

________________________________________________________________________________________

Rubi [A]
time = 0.01, antiderivative size = 19, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, integrand size = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {4269, 3556} \begin {gather*} \frac {1}{4} x \tan (4 x)+\frac {1}{16} \log (\cos (4 x)) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[x*Sec[4*x]^2,x]

[Out]

Log[Cos[4*x]]/16 + (x*Tan[4*x])/4

Rule 3556

Int[tan[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-Log[RemoveContent[Cos[c + d*x], x]]/d, x] /; FreeQ[{c, d}, x]

Rule 4269

Int[csc[(e_.) + (f_.)*(x_)]^2*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[(-(c + d*x)^m)*(Cot[e + f*x]/f), x
] + Dist[d*(m/f), Int[(c + d*x)^(m - 1)*Cot[e + f*x], x], x] /; FreeQ[{c, d, e, f}, x] && GtQ[m, 0]

Rubi steps

\begin {gather*} \begin {aligned} \text {Integral} &=\frac {1}{4} x \tan (4 x)-\frac {1}{4} \int \tan (4 x) \, dx\\ &=\frac {1}{16} \log (\cos (4 x))+\frac {1}{4} x \tan (4 x)\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]
time = 0.01, size = 19, normalized size = 1.00 \begin {gather*} \frac {1}{16} \log (\cos (4 x))+\frac {1}{4} x \tan (4 x) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[x*Sec[4*x]^2,x]

[Out]

Log[Cos[4*x]]/16 + (x*Tan[4*x])/4

________________________________________________________________________________________

Maple [A]
time = 0.12, size = 16, normalized size = 0.84

method result size
derivativedivides \(\frac {\ln \left (\cos \left (4 x \right )\right )}{16}+\frac {x \tan \left (4 x \right )}{4}\) \(16\)
default \(\frac {\ln \left (\cos \left (4 x \right )\right )}{16}+\frac {x \tan \left (4 x \right )}{4}\) \(16\)
risch \(-\frac {i x}{2}+\frac {i x}{2 \,{\mathrm e}^{8 i x}+2}+\frac {\ln \left ({\mathrm e}^{8 i x}+1\right )}{16}\) \(29\)
norman \(-\frac {x \tan \left (2 x \right )}{2 \left (\tan ^{2}\left (2 x \right )-1\right )}+\frac {\ln \left (\tan \left (2 x \right )-1\right )}{16}+\frac {\ln \left (\tan \left (2 x \right )+1\right )}{16}-\frac {\ln \left (1+\tan ^{2}\left (2 x \right )\right )}{16}\) \(48\)
parallelrisch \(\frac {\ln \left (\tan \left (2 x \right )-1\right ) \cos \left (4 x \right )+\ln \left (\tan \left (2 x \right )+1\right ) \cos \left (4 x \right )-\ln \left (\sec ^{2}\left (2 x \right )\right ) \cos \left (4 x \right )+4 x \sin \left (4 x \right )}{16 \cos \left (4 x \right )}\) \(54\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*sec(4*x)^2,x,method=_RETURNVERBOSE)

[Out]

1/16*ln(cos(4*x))+1/4*x*tan(4*x)

________________________________________________________________________________________

Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 74 vs. \(2 (15) = 30\).
time = 0.46, size = 74, normalized size = 3.89 \begin {gather*} \frac {{\left (\cos \left (8 \, x\right )^{2} + \sin \left (8 \, x\right )^{2} + 2 \, \cos \left (8 \, x\right ) + 1\right )} \log \left (\cos \left (8 \, x\right )^{2} + \sin \left (8 \, x\right )^{2} + 2 \, \cos \left (8 \, x\right ) + 1\right ) + 16 \, x \sin \left (8 \, x\right )}{32 \, {\left (\cos \left (8 \, x\right )^{2} + \sin \left (8 \, x\right )^{2} + 2 \, \cos \left (8 \, x\right ) + 1\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*sec(4*x)^2,x, algorithm="maxima")

[Out]

1/32*((cos(8*x)^2 + sin(8*x)^2 + 2*cos(8*x) + 1)*log(cos(8*x)^2 + sin(8*x)^2 + 2*cos(8*x) + 1) + 16*x*sin(8*x)
)/(cos(8*x)^2 + sin(8*x)^2 + 2*cos(8*x) + 1)

________________________________________________________________________________________

Fricas [A]
time = 0.64, size = 28, normalized size = 1.47 \begin {gather*} \frac {\cos \left (4 \, x\right ) \log \left (-\cos \left (4 \, x\right )\right ) + 4 \, x \sin \left (4 \, x\right )}{16 \, \cos \left (4 \, x\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*sec(4*x)^2,x, algorithm="fricas")

[Out]

1/16*(cos(4*x)*log(-cos(4*x)) + 4*x*sin(4*x))/cos(4*x)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int x \sec ^{2}{\left (4 x \right )}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*sec(4*x)**2,x)

[Out]

Integral(x*sec(4*x)**2, x)

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 103 vs. \(2 (15) = 30\).
time = 0.45, size = 103, normalized size = 5.42 \begin {gather*} \frac {\log \left (\frac {4 \, {\left (\tan \left (2 \, x\right )^{4} - 2 \, \tan \left (2 \, x\right )^{2} + 1\right )}}{\tan \left (2 \, x\right )^{4} + 2 \, \tan \left (2 \, x\right )^{2} + 1}\right ) \tan \left (2 \, x\right )^{2} - 16 \, x \tan \left (2 \, x\right ) - \log \left (\frac {4 \, {\left (\tan \left (2 \, x\right )^{4} - 2 \, \tan \left (2 \, x\right )^{2} + 1\right )}}{\tan \left (2 \, x\right )^{4} + 2 \, \tan \left (2 \, x\right )^{2} + 1}\right )}{32 \, {\left (\tan \left (2 \, x\right )^{2} - 1\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*sec(4*x)^2,x, algorithm="giac")

[Out]

1/32*(log(4*(tan(2*x)^4 - 2*tan(2*x)^2 + 1)/(tan(2*x)^4 + 2*tan(2*x)^2 + 1))*tan(2*x)^2 - 16*x*tan(2*x) - log(
4*(tan(2*x)^4 - 2*tan(2*x)^2 + 1)/(tan(2*x)^4 + 2*tan(2*x)^2 + 1)))/(tan(2*x)^2 - 1)

________________________________________________________________________________________

Mupad [B]
time = 0.08, size = 15, normalized size = 0.79 \begin {gather*} \frac {\ln \left (\cos \left (4\,x\right )\right )}{16}+\frac {x\,\mathrm {tan}\left (4\,x\right )}{4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x/cos(4*x)^2,x)

[Out]

log(cos(4*x))/16 + (x*tan(4*x))/4

________________________________________________________________________________________

Chatgpt [F] Failed to verify
time = 1.00, size = 8, normalized size = 0.42 \begin {gather*} \frac {1}{4 \sin \left (4 x \right )} \end {gather*}

Warning: Unable to verify antiderivative.

[In]

int(x*sec(4*x)^2,x)

[Out]

1/4/sin(4*x)

________________________________________________________________________________________