3.304 \(\int \frac {A+B \log (x)}{\sqrt {a-b \log (x)}} \, dx\)

Optimal. Leaf size=71 \[ -\frac {\sqrt {\pi } e^{a/b} (2 a B+2 A b-b B) \text {erf}\left (\frac {\sqrt {a-b \log (x)}}{\sqrt {b}}\right )}{2 b^{3/2}}-\frac {B x \sqrt {a-b \log (x)}}{b} \]

[Out]

-1/2*(2*A*b+2*B*a-B*b)*exp(a/b)*erf((a-b*ln(x))^(1/2)/b^(1/2))*Pi^(1/2)/b^(3/2)-B*x*(a-b*ln(x))^(1/2)/b

________________________________________________________________________________________

Rubi [A]  time = 0.08, antiderivative size = 71, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.222, Rules used = {2294, 2299, 2180, 2205} \[ -\frac {\sqrt {\pi } e^{a/b} (2 a B+2 A b-b B) \text {Erf}\left (\frac {\sqrt {a-b \log (x)}}{\sqrt {b}}\right )}{2 b^{3/2}}-\frac {B x \sqrt {a-b \log (x)}}{b} \]

Antiderivative was successfully verified.

[In]

Int[(A + B*Log[x])/Sqrt[a - b*Log[x]],x]

[Out]

-((2*A*b + 2*a*B - b*B)*E^(a/b)*Sqrt[Pi]*Erf[Sqrt[a - b*Log[x]]/Sqrt[b]])/(2*b^(3/2)) - (B*x*Sqrt[a - b*Log[x]
])/b

Rule 2180

Int[(F_)^((g_.)*((e_.) + (f_.)*(x_)))/Sqrt[(c_.) + (d_.)*(x_)], x_Symbol] :> Dist[2/d, Subst[Int[F^(g*(e - (c*
f)/d) + (f*g*x^2)/d), x], x, Sqrt[c + d*x]], x] /; FreeQ[{F, c, d, e, f, g}, x] &&  !$UseGamma === True

Rule 2205

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^2), x_Symbol] :> Simp[(F^a*Sqrt[Pi]*Erf[(c + d*x)*Rt[-(b*Log[F]),
 2]])/(2*d*Rt[-(b*Log[F]), 2]), x] /; FreeQ[{F, a, b, c, d}, x] && NegQ[b]

Rule 2294

Int[((A_.) + Log[(c_.)*((d_.) + (e_.)*(x_))^(n_.)]*(B_.))/Sqrt[Log[(c_.)*((d_.) + (e_.)*(x_))^(n_.)]*(b_.) + (
a_)], x_Symbol] :> Simp[(B*(d + e*x)*Sqrt[a + b*Log[c*(d + e*x)^n]])/(b*e), x] + Dist[(2*A*b - B*(2*a + b*n))/
(2*b), Int[1/Sqrt[a + b*Log[c*(d + e*x)^n]], x], x] /; FreeQ[{a, b, c, d, e, A, B, n}, x]

Rule 2299

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_), x_Symbol] :> Dist[1/(n*c^(1/n)), Subst[Int[E^(x/n)*(a + b*x)^p
, x], x, Log[c*x^n]], x] /; FreeQ[{a, b, c, p}, x] && IntegerQ[1/n]

Rubi steps

\begin {align*} \int \frac {A+B \log (x)}{\sqrt {a-b \log (x)}} \, dx &=-\frac {B x \sqrt {a-b \log (x)}}{b}+\frac {(2 A b+2 a B-b B) \int \frac {1}{\sqrt {a-b \log (x)}} \, dx}{2 b}\\ &=-\frac {B x \sqrt {a-b \log (x)}}{b}+\frac {(2 A b+2 a B-b B) \operatorname {Subst}\left (\int \frac {e^x}{\sqrt {a-b x}} \, dx,x,\log (x)\right )}{2 b}\\ &=-\frac {B x \sqrt {a-b \log (x)}}{b}-\frac {(2 A b+2 a B-b B) \operatorname {Subst}\left (\int e^{\frac {a}{b}-\frac {x^2}{b}} \, dx,x,\sqrt {a-b \log (x)}\right )}{b^2}\\ &=-\frac {(2 A b+2 a B-b B) e^{a/b} \sqrt {\pi } \text {erf}\left (\frac {\sqrt {a-b \log (x)}}{\sqrt {b}}\right )}{2 b^{3/2}}-\frac {B x \sqrt {a-b \log (x)}}{b}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.13, size = 79, normalized size = 1.11 \[ \frac {e^{a/b} (2 a B+2 A b-b B) \sqrt {\frac {a}{b}-\log (x)} \Gamma \left (\frac {1}{2},\frac {a}{b}-\log (x)\right )-2 B x (a-b \log (x))}{2 b \sqrt {a-b \log (x)}} \]

Antiderivative was successfully verified.

[In]

Integrate[(A + B*Log[x])/Sqrt[a - b*Log[x]],x]

[Out]

((2*A*b + 2*a*B - b*B)*E^(a/b)*Gamma[1/2, a/b - Log[x]]*Sqrt[a/b - Log[x]] - 2*B*x*(a - b*Log[x]))/(2*b*Sqrt[a
 - b*Log[x]])

________________________________________________________________________________________

fricas [F(-2)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: TypeError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*log(x))/(a-b*log(x))^(1/2),x, algorithm="fricas")

[Out]

Exception raised: TypeError >>  Error detected within library code:   integrate: implementation incomplete (co
nstant residues)

________________________________________________________________________________________

giac [A]  time = 0.31, size = 106, normalized size = 1.49 \[ \frac {\sqrt {\pi } B a \operatorname {erf}\left (-\frac {\sqrt {-b \log \relax (x) + a}}{\sqrt {b}}\right ) e^{\frac {a}{b}}}{b^{\frac {3}{2}}} + \frac {\sqrt {\pi } A \operatorname {erf}\left (-\frac {\sqrt {-b \log \relax (x) + a}}{\sqrt {b}}\right ) e^{\frac {a}{b}}}{\sqrt {b}} - \frac {\sqrt {\pi } B \operatorname {erf}\left (-\frac {\sqrt {-b \log \relax (x) + a}}{\sqrt {b}}\right ) e^{\frac {a}{b}}}{2 \, \sqrt {b}} - \frac {\sqrt {-b \log \relax (x) + a} B x}{b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*log(x))/(a-b*log(x))^(1/2),x, algorithm="giac")

[Out]

sqrt(pi)*B*a*erf(-sqrt(-b*log(x) + a)/sqrt(b))*e^(a/b)/b^(3/2) + sqrt(pi)*A*erf(-sqrt(-b*log(x) + a)/sqrt(b))*
e^(a/b)/sqrt(b) - 1/2*sqrt(pi)*B*erf(-sqrt(-b*log(x) + a)/sqrt(b))*e^(a/b)/sqrt(b) - sqrt(-b*log(x) + a)*B*x/b

________________________________________________________________________________________

maple [F]  time = 0.15, size = 0, normalized size = 0.00 \[ \int \frac {B \ln \relax (x )+A}{\sqrt {-b \ln \relax (x )+a}}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((B*ln(x)+A)/(-b*ln(x)+a)^(1/2),x)

[Out]

int((B*ln(x)+A)/(-b*ln(x)+a)^(1/2),x)

________________________________________________________________________________________

maxima [B]  time = 0.66, size = 130, normalized size = 1.83 \[ -\frac {\frac {2 \, \sqrt {\pi } B a \operatorname {erf}\left (\frac {\sqrt {-b \log \relax (x) + a}}{\sqrt {b}}\right ) e^{\frac {a}{b}}}{\sqrt {b}} + 2 \, \sqrt {\pi } A \sqrt {b} \operatorname {erf}\left (\frac {\sqrt {-b \log \relax (x) + a}}{\sqrt {b}}\right ) e^{\frac {a}{b}} - \frac {{\left (\sqrt {\pi } b^{\frac {3}{2}} \operatorname {erf}\left (\frac {\sqrt {-b \log \relax (x) + a}}{\sqrt {b}}\right ) e^{\frac {a}{b}} - 2 \, \sqrt {-b \log \relax (x) + a} b e^{\left (\frac {b \log \relax (x) - a}{b} + \frac {a}{b}\right )}\right )} B}{b}}{2 \, b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*log(x))/(a-b*log(x))^(1/2),x, algorithm="maxima")

[Out]

-1/2*(2*sqrt(pi)*B*a*erf(sqrt(-b*log(x) + a)/sqrt(b))*e^(a/b)/sqrt(b) + 2*sqrt(pi)*A*sqrt(b)*erf(sqrt(-b*log(x
) + a)/sqrt(b))*e^(a/b) - (sqrt(pi)*b^(3/2)*erf(sqrt(-b*log(x) + a)/sqrt(b))*e^(a/b) - 2*sqrt(-b*log(x) + a)*b
*e^((b*log(x) - a)/b + a/b))*B/b)/b

________________________________________________________________________________________

mupad [F]  time = 0.00, size = -1, normalized size = -0.01 \[ \int \frac {A+B\,\ln \relax (x)}{\sqrt {a-b\,\ln \relax (x)}} \,d x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((A + B*log(x))/(a - b*log(x))^(1/2),x)

[Out]

int((A + B*log(x))/(a - b*log(x))^(1/2), x)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {A + B \log {\relax (x )}}{\sqrt {a - b \log {\relax (x )}}}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*ln(x))/(a-b*ln(x))**(1/2),x)

[Out]

Integral((A + B*log(x))/sqrt(a - b*log(x)), x)

________________________________________________________________________________________