text:
@testset "3.2.1 (f+g x)^m (A+B log(e ((a+b x) over (c+d x))^n))^p" begin
    (A, B, a, b, c, d, e, f, g, h, n, x, ) = @variables A B a b c d e f g h n x

    #= ::Package:: =#

    #= ::Title:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*((a+b*x)/(c+d*x))^n))^p=#

    #= ::Section::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*((a+b*x)/(c+d*x))^n))^p*when*b*f-a*g=0=#

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*((a+b*x)/(c+d*x))^n))^p*and*b*f-a*g=0=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(a*g + b*g*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 4, (B*(b*c - a*d)^4*g^4*n*x)/(5*d^4) - (B*(b*c - a*d)^3*g^4*n*(a + b*x)^2)/(10*b*d^3) + (B*(b*c - a*d)^2*g^4*n*(a + b*x)^3)/(15*b*d^2) - (B*(b*c - a*d)*g^4*n*(a + b*x)^4)/(20*b*d) + (g^4*(a + b*x)^5*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(5*b) - (B*(b*c - a*d)^5*g^4*n*log(c + d*x))/(5*b*d^5)]
    @test_int [(a*g + b*g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 4, -(B*(b*c - a*d)^3*g^3*n*x)/(4*d^3) + (B*(b*c - a*d)^2*g^3*n*(a + b*x)^2)/(8*b*d^2) - (B*(b*c - a*d)*g^3*n*(a + b*x)^3)/(12*b*d) + (g^3*(a + b*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(4*b) + (B*(b*c - a*d)^4*g^3*n*log(c + d*x))/(4*b*d^4)]
    @test_int [(a*g + b*g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 4, (B*(b*c - a*d)^2*g^2*n*x)/(3*d^2) - (B*(b*c - a*d)*g^2*n*(a + b*x)^2)/(6*b*d) + (g^2*(a + b*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*b) - (B*(b*c - a*d)^3*g^2*n*log(c + d*x))/(3*b*d^3)]
    @test_int [(a*g + b*g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 4, -(B*(b*c - a*d)*g*n*x)/(2*d) + (g*(a + b*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(2*b) + (B*(b*c - a*d)^2*g*n*log(c + d*x))/(2*b*d^2)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(a*g + b*g*x)^1, x, 5, -((log(-((b*c - a*d)/(d*(a + b*x))))*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(b*g)) + (B*n*PolyLog(2, 1 + (b*c - a*d)/(d*(a + b*x))))/(b*g)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(a*g + b*g*x)^2, x, 2, -((B*n)/(b*g^2*(a + b*x))) - ((c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*c - a*d)*g^2*(a + b*x)), -((B*n*(c + d*x))/((b*c - a*d)*g^2*(a + b*x))) - ((c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*c - a*d)*g^2*(a + b*x))]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(a*g + b*g*x)^3, x, 4, -(B*n)/(4*b*g^3*(a + b*x)^2) + (B*d*n)/(2*b*(b*c - a*d)*g^3*(a + b*x)) + (B*d^2*n*log(a + b*x))/(2*b*(b*c - a*d)^2*g^3) - (A + B*log(e*((a + b*x)/(c + d*x))^n))/(2*b*g^3*(a + b*x)^2) - (B*d^2*n*log(c + d*x))/(2*b*(b*c - a*d)^2*g^3)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(a*g + b*g*x)^4, x, 4, -(B*n)/(9*b*g^4*(a + b*x)^3) + (B*d*n)/(6*b*(b*c - a*d)*g^4*(a + b*x)^2) - (B*d^2*n)/(3*b*(b*c - a*d)^2*g^4*(a + b*x)) - (B*d^3*n*log(a + b*x))/(3*b*(b*c - a*d)^3*g^4) - (A + B*log(e*((a + b*x)/(c + d*x))^n))/(3*b*g^4*(a + b*x)^3) + (B*d^3*n*log(c + d*x))/(3*b*(b*c - a*d)^3*g^4)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(a*g + b*g*x)^5, x, 4, -(B*n)/(16*b*g^5*(a + b*x)^4) + (B*d*n)/(12*b*(b*c - a*d)*g^5*(a + b*x)^3) - (B*d^2*n)/(8*b*(b*c - a*d)^2*g^5*(a + b*x)^2) + (B*d^3*n)/(4*b*(b*c - a*d)^3*g^5*(a + b*x)) + (B*d^4*n*log(a + b*x))/(4*b*(b*c - a*d)^4*g^5) - (A + B*log(e*((a + b*x)/(c + d*x))^n))/(4*b*g^5*(a + b*x)^4) - (B*d^4*n*log(c + d*x))/(4*b*(b*c - a*d)^4*g^5)]

    @test_int [(a*g + b*g*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 8, -((B*(b*c - a*d)*g^4*n*(a + b*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(10*b*d)) + (g^4*(a + b*x)^5*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(5*b) + (B*(b*c - a*d)^2*g^4*n*(a + b*x)^3*(4*A + B*n + 4*B*log(e*((a + b*x)/(c + d*x))^n)))/(30*b*d^2) - (B*(b*c - a*d)^3*g^4*n*(a + b*x)^2*(12*A + 7*B*n + 12*B*log(e*((a + b*x)/(c + d*x))^n)))/(60*b*d^3) + (B*(b*c - a*d)^4*g^4*n*(a + b*x)*(12*A + 13*B*n + 12*B*log(e*((a + b*x)/(c + d*x))^n)))/(30*b*d^4) + (B*(b*c - a*d)^5*g^4*n*(12*A + 25*B*n + 12*B*log(e*((a + b*x)/(c + d*x))^n))*log((b*c - a*d)/(b*(c + d*x))))/(30*b*d^5) + (2*B^2*(b*c - a*d)^5*g^4*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(5*b*d^5)]
    @test_int [(a*g + b*g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 7, -((B*(b*c - a*d)*g^3*n*(a + b*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(6*b*d)) + (g^3*(a + b*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(4*b) + (B*(b*c - a*d)^2*g^3*n*(a + b*x)^2*(3*A + B*n + 3*B*log(e*((a + b*x)/(c + d*x))^n)))/(12*b*d^2) - (B*(b*c - a*d)^3*g^3*n*(a + b*x)*(6*A + 5*B*n + 6*B*log(e*((a + b*x)/(c + d*x))^n)))/(12*b*d^3) - (B*(b*c - a*d)^4*g^3*n*(6*A + 11*B*n + 6*B*log(e*((a + b*x)/(c + d*x))^n))*log((b*c - a*d)/(b*(c + d*x))))/(12*b*d^4) - (B^2*(b*c - a*d)^4*g^3*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(2*b*d^4)]
    @test_int [(a*g + b*g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 6, -((B*(b*c - a*d)*g^2*n*(a + b*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*b*d)) + (g^2*(a + b*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(3*b) + (B*(b*c - a*d)^2*g^2*n*(a + b*x)*(2*A + B*n + 2*B*log(e*((a + b*x)/(c + d*x))^n)))/(3*b*d^2) + (B*(b*c - a*d)^3*g^2*n*(2*A + 3*B*n + 2*B*log(e*((a + b*x)/(c + d*x))^n))*log((b*c - a*d)/(b*(c + d*x))))/(3*b*d^3) + (2*B^2*(b*c - a*d)^3*g^2*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(3*b*d^3)]
    @test_int [(a*g + b*g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 5, -((B*(b*c - a*d)*g*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(b*d)) + (g*(a + b*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(2*b) - (B*(b*c - a*d)^2*g*n*(A + B*n + B*log(e*((a + b*x)/(c + d*x))^n))*log((b*c - a*d)/(b*(c + d*x))))/(b*d^2) - (B^2*(b*c - a*d)^2*g*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^2)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(a*g + b*g*x)^1, x, 4, -(((A + B*log(e*((a + b*x)/(c + d*x))^n))^2*log(1 - (b*(c + d*x))/(d*(a + b*x))))/(b*g)) + (2*B*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(b*g) + (2*B^2*n^2*PolyLog(3, (b*(c + d*x))/(d*(a + b*x))))/(b*g)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(a*g + b*g*x)^2, x, 3, (-2*B^2*n^2*(c + d*x))/((b*c - a*d)*g^2*(a + b*x)) - (2*B*n*(c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*c - a*d)*g^2*(a + b*x)) - ((c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/((b*c - a*d)*g^2*(a + b*x))]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(a*g + b*g*x)^3, x, 7, (2*B^2*d*n^2*(c + d*x))/((b*c - a*d)^2*g^3*(a + b*x)) - (b*B^2*n^2*(c + d*x)^2)/(4*(b*c - a*d)^2*g^3*(a + b*x)^2) + (2*B*d*n*(c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*c - a*d)^2*g^3*(a + b*x)) - (b*B*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(2*(b*c - a*d)^2*g^3*(a + b*x)^2) + (d*(c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/((b*c - a*d)^2*g^3*(a + b*x)) - (b*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(2*(b*c - a*d)^2*g^3*(a + b*x)^2)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(a*g + b*g*x)^4, x, 9, (-2*B^2*d^2*n^2*(c + d*x))/((b*c - a*d)^3*g^4*(a + b*x)) + (b*B^2*d*n^2*(c + d*x)^2)/(2*(b*c - a*d)^3*g^4*(a + b*x)^2) - (2*b^2*B^2*n^2*(c + d*x)^3)/(27*(b*c - a*d)^3*g^4*(a + b*x)^3) - (2*B*d^2*n*(c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*c - a*d)^3*g^4*(a + b*x)) + (b*B*d*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*c - a*d)^3*g^4*(a + b*x)^2) - (2*b^2*B*n*(c + d*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(9*(b*c - a*d)^3*g^4*(a + b*x)^3) - (d^2*(c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/((b*c - a*d)^3*g^4*(a + b*x)) + (b*d*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/((b*c - a*d)^3*g^4*(a + b*x)^2) - (b^2*(c + d*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(3*(b*c - a*d)^3*g^4*(a + b*x)^3)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(a*g + b*g*x)^5, x, 11, (2*B^2*d^3*n^2*(c + d*x))/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*B^2*d^2*n^2*(c + d*x)^2)/(4*(b*c - a*d)^4*g^5*(a + b*x)^2) + (2*b^2*B^2*d*n^2*(c + d*x)^3)/(9*(b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*B^2*n^2*(c + d*x)^4)/(32*(b*c - a*d)^4*g^5*(a + b*x)^4) + (2*B*d^3*n*(c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*B*d^2*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(2*(b*c - a*d)^4*g^5*(a + b*x)^2) + (2*b^2*B*d*n*(c + d*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*(b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*B*n*(c + d*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(8*(b*c - a*d)^4*g^5*(a + b*x)^4) + (d^3*(c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*d^2*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(2*(b*c - a*d)^4*g^5*(a + b*x)^2) + (b^2*d*(c + d*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/((b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*(c + d*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(4*(b*c - a*d)^4*g^5*(a + b*x)^4)]

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [(a*g + b*g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 0, Unintegrable((a*g + b*g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x)]
    @test_int [(a*g + b*g*x)^1/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 0, Unintegrable((a*g + b*g*x)/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x)]
    @test_int [1/((a*g + b*g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x, 0, Unintegrable(1/((a*g + b*g*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x)]
    @test_int [1/((a*g + b*g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x, 3, (ℯ^(A/(B*n))*(e*((a + b*x)/(c + d*x))^n)^n^(-1)*(c + d*x)*ExpIntegralEi(-((A + B*log(e*((a + b*x)/(c + d*x))^n))/(B*n))))/(B*(b*c - a*d)*g^2*n*(a + b*x))]
    @test_int [1/((a*g + b*g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x, 7, (b*ℯ^((2*A)/(B*n))*(e*((a + b*x)/(c + d*x))^n)^(2/n)*(c + d*x)^2*ExpIntegralEi((-2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(B*n)))/(B*(b*c - a*d)^2*g^3*n*(a + b*x)^2) - (d*ℯ^(A/(B*n))*(e*((a + b*x)/(c + d*x))^n)^n^(-1)*(c + d*x)*ExpIntegralEi(-((A + B*log(e*((a + b*x)/(c + d*x))^n))/(B*n))))/(B*(b*c - a*d)^2*g^3*n*(a + b*x))]

    @test_int [(a*g + b*g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 0, Unintegrable((a*g + b*g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x)]
    @test_int [(a*g + b*g*x)^1/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 0, Unintegrable((a*g + b*g*x)/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x)]
    @test_int [1/((a*g + b*g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x, 0, Unintegrable(1/((a*g + b*g*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x)]
    @test_int [1/((a*g + b*g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x, 4, -((ℯ^(A/(B*n))*(e*((a + b*x)/(c + d*x))^n)^n^(-1)*(c + d*x)*ExpIntegralEi(-((A + B*log(e*((a + b*x)/(c + d*x))^n))/(B*n))))/(B^2*(b*c - a*d)*g^2*n^2*(a + b*x))) - (c + d*x)/(B*(b*c - a*d)*g^2*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))]
    @test_int [1/((a*g + b*g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x, 9, (-2*b*ℯ^((2*A)/(B*n))*(e*((a + b*x)/(c + d*x))^n)^(2/n)*(c + d*x)^2*ExpIntegralEi((-2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(B*n)))/(B^2*(b*c - a*d)^2*g^3*n^2*(a + b*x)^2) + (d*ℯ^(A/(B*n))*(e*((a + b*x)/(c + d*x))^n)^n^(-1)*(c + d*x)*ExpIntegralEi(-((A + B*log(e*((a + b*x)/(c + d*x))^n))/(B*n))))/(B^2*(b*c - a*d)^2*g^3*n^2*(a + b*x)) + (d*(c + d*x))/(B*(b*c - a*d)^2*g^3*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))) - (b*(c + d*x)^2)/(B*(b*c - a*d)^2*g^3*n*(a + b*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))]

    #= ::Section::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*((a+b*x)/(c+d*x))^n))^p*when*d*f-c*g=0=#

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*((a+b*x)/(c+d*x))^n))^p*and*d*f-c*g=0=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(c*g + d*g*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 4, -((B*(b*c - a*d)^4*g^4*n*x)/(5*b^4)) - (B*(b*c - a*d)^3*g^4*n*(c + d*x)^2)/(10*b^3*d) - (B*(b*c - a*d)^2*g^4*n*(c + d*x)^3)/(15*b^2*d) - (B*(b*c - a*d)*g^4*n*(c + d*x)^4)/(20*b*d) - (B*(b*c - a*d)^5*g^4*n*log(a + b*x))/(5*b^5*d) + (g^4*(c + d*x)^5*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(5*d)]
    @test_int [(c*g + d*g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 4, -((B*(b*c - a*d)^3*g^3*n*x)/(4*b^3)) - (B*(b*c - a*d)^2*g^3*n*(c + d*x)^2)/(8*b^2*d) - (B*(b*c - a*d)*g^3*n*(c + d*x)^3)/(12*b*d) - (B*(b*c - a*d)^4*g^3*n*log(a + b*x))/(4*b^4*d) + (g^3*(c + d*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(4*d)]
    @test_int [(c*g + d*g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 4, -((B*(b*c - a*d)^2*g^2*n*x)/(3*b^2)) - (B*(b*c - a*d)*g^2*n*(c + d*x)^2)/(6*b*d) - (B*(b*c - a*d)^3*g^2*n*log(a + b*x))/(3*b^3*d) + (g^2*(c + d*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*d)]
    @test_int [(c*g + d*g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 4, -((B*(b*c - a*d)*g*n*x)/(2*b)) - (B*(b*c - a*d)^2*g*n*log(a + b*x))/(2*b^2*d) + (g*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(2*d)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(c*g + d*g*x)^1, x, 5, -(((A + B*log(e*((a + b*x)/(c + d*x))^n))*log((b*c - a*d)/(b*(c + d*x))))/(d*g)) - (B*n*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(d*g)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(c*g + d*g*x)^2, x, 3, (A*(a + b*x))/((b*c - a*d)*g^2*(c + d*x)) - (B*n*(a + b*x))/((b*c - a*d)*g^2*(c + d*x)) + (B*(a + b*x)*log(e*((a + b*x)/(c + d*x))^n))/((b*c - a*d)*g^2*(c + d*x))]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(c*g + d*g*x)^3, x, 4, (B*n)/(4*d*g^3*(c + d*x)^2) + (b*B*n)/(2*d*(b*c - a*d)*g^3*(c + d*x)) + (b^2*B*n*log(a + b*x))/(2*d*(b*c - a*d)^2*g^3) - (A + B*log(e*((a + b*x)/(c + d*x))^n))/(2*d*g^3*(c + d*x)^2) - (b^2*B*n*log(c + d*x))/(2*d*(b*c - a*d)^2*g^3)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(c*g + d*g*x)^4, x, 4, (B*n)/(9*d*g^4*(c + d*x)^3) + (b*B*n)/(6*d*(b*c - a*d)*g^4*(c + d*x)^2) + (b^2*B*n)/(3*d*(b*c - a*d)^2*g^4*(c + d*x)) + (b^3*B*n*log(a + b*x))/(3*d*(b*c - a*d)^3*g^4) - (A + B*log(e*((a + b*x)/(c + d*x))^n))/(3*d*g^4*(c + d*x)^3) - (b^3*B*n*log(c + d*x))/(3*d*(b*c - a*d)^3*g^4)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(c*g + d*g*x)^5, x, 4, (B*n)/(16*d*g^5*(c + d*x)^4) + (b*B*n)/(12*d*(b*c - a*d)*g^5*(c + d*x)^3) + (b^2*B*n)/(8*d*(b*c - a*d)^2*g^5*(c + d*x)^2) + (b^3*B*n)/(4*d*(b*c - a*d)^3*g^5*(c + d*x)) + (b^4*B*n*log(a + b*x))/(4*d*(b*c - a*d)^4*g^5) - (A + B*log(e*((a + b*x)/(c + d*x))^n))/(4*d*g^5*(c + d*x)^4) - (b^4*B*n*log(c + d*x))/(4*d*(b*c - a*d)^4*g^5)]

    @test_int [(c*g + d*g*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 19, (13*B^2*(b*c - a*d)^4*g^4*n^2*x)/(30*b^4) + (7*B^2*(b*c - a*d)^3*g^4*n^2*(c + d*x)^2)/(60*b^3*d) + (B^2*(b*c - a*d)^2*g^4*n^2*(c + d*x)^3)/(30*b^2*d) - (2*B*(b*c - a*d)^4*g^4*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(5*b^5) - (B*(b*c - a*d)^3*g^4*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(5*b^3*d) - (2*B*(b*c - a*d)^2*g^4*n*(c + d*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(15*b^2*d) - (B*(b*c - a*d)*g^4*n*(c + d*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(10*b*d) + (g^4*(c + d*x)^5*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(5*d) + (13*B^2*(b*c - a*d)^5*g^4*n^2*log((a + b*x)/(c + d*x)))/(30*b^5*d) + (5*B^2*(b*c - a*d)^5*g^4*n^2*log(c + d*x))/(6*b^5*d) + (2*B*(b*c - a*d)^5*g^4*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log(1 - (b*(c + d*x))/(d*(a + b*x))))/(5*b^5*d) - (2*B^2*(b*c - a*d)^5*g^4*n^2*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(5*b^5*d)]
    @test_int [(c*g + d*g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 15, (5*B^2*(b*c - a*d)^3*g^3*n^2*x)/(12*b^3) + (B^2*(b*c - a*d)^2*g^3*n^2*(c + d*x)^2)/(12*b^2*d) - (B*(b*c - a*d)^3*g^3*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(2*b^4) - (B*(b*c - a*d)^2*g^3*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(4*b^2*d) - (B*(b*c - a*d)*g^3*n*(c + d*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(6*b*d) + (g^3*(c + d*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(4*d) + (5*B^2*(b*c - a*d)^4*g^3*n^2*log((a + b*x)/(c + d*x)))/(12*b^4*d) + (11*B^2*(b*c - a*d)^4*g^3*n^2*log(c + d*x))/(12*b^4*d) + (B*(b*c - a*d)^4*g^3*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log(1 - (b*(c + d*x))/(d*(a + b*x))))/(2*b^4*d) - (B^2*(b*c - a*d)^4*g^3*n^2*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(2*b^4*d)]
    @test_int [(c*g + d*g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 11, (B^2*(b*c - a*d)^2*g^2*n^2*x)/(3*b^2) - (2*B*(b*c - a*d)^2*g^2*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*b^3) - (B*(b*c - a*d)*g^2*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*b*d) + (g^2*(c + d*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(3*d) + (B^2*(b*c - a*d)^3*g^2*n^2*log((a + b*x)/(c + d*x)))/(3*b^3*d) + (B^2*(b*c - a*d)^3*g^2*n^2*log(c + d*x))/(b^3*d) + (2*B*(b*c - a*d)^3*g^2*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log(1 - (b*(c + d*x))/(d*(a + b*x))))/(3*b^3*d) - (2*B^2*(b*c - a*d)^3*g^2*n^2*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(3*b^3*d)]
    @test_int [(c*g + d*g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 7, -((B*(b*c - a*d)*g*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/b^2) + (g*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(2*d) + (B^2*(b*c - a*d)^2*g*n^2*log(c + d*x))/(b^2*d) + (B*(b*c - a*d)^2*g*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log(1 - (b*(c + d*x))/(d*(a + b*x))))/(b^2*d) - (B^2*(b*c - a*d)^2*g*n^2*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(b^2*d)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(c*g + d*g*x)^1, x, 4, -(((A + B*log(e*((a + b*x)/(c + d*x))^n))^2*log((b*c - a*d)/(b*(c + d*x))))/(d*g)) - (2*B*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(d*g) + (2*B^2*n^2*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/(d*g)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(c*g + d*g*x)^2, x, 4, -((2*A*B*n*(a + b*x))/((b*c - a*d)*g^2*(c + d*x))) + (2*B^2*n^2*(a + b*x))/((b*c - a*d)*g^2*(c + d*x)) - (2*B^2*n*(a + b*x)*log(e*((a + b*x)/(c + d*x))^n))/((b*c - a*d)*g^2*(c + d*x)) + ((a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/((b*c - a*d)*g^2*(c + d*x))]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(c*g + d*g*x)^3, x, 8, -((B^2*d*n^2*(a + b*x)^2)/(4*(b*c - a*d)^2*g^3*(c + d*x)^2)) - (2*A*b*B*n*(a + b*x))/((b*c - a*d)^2*g^3*(c + d*x)) + (2*b*B^2*n^2*(a + b*x))/((b*c - a*d)^2*g^3*(c + d*x)) - (2*b*B^2*n*(a + b*x)*log(e*((a + b*x)/(c + d*x))^n))/((b*c - a*d)^2*g^3*(c + d*x)) + (B*d*n*(a + b*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(2*(b*c - a*d)^2*g^3*(c + d*x)^2) - (d*(a + b*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(2*(b*c - a*d)^2*g^3*(c + d*x)^2) + (b*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/((b*c - a*d)^2*g^3*(c + d*x))]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(c*g + d*g*x)^4, x, 6, (2*B^2*d^2*n^2*(a + b*x)^3)/(27*(b*c - a*d)^3*g^4*(c + d*x)^3) - (b*B^2*d*n^2*(a + b*x)^2)/(2*(b*c - a*d)^3*g^4*(c + d*x)^2) + (2*b^2*B^2*n^2*(a + b*x))/((b*c - a*d)^3*g^4*(c + d*x)) - (2*B*d^2*n*(a + b*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(9*(b*c - a*d)^3*g^4*(c + d*x)^3) + (b*B*d*n*(a + b*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*c - a*d)^3*g^4*(c + d*x)^2) - (2*b^2*B*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*c - a*d)^3*g^4*(c + d*x)) - (A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(3*d*g^4*(c + d*x)^3) + (2*b^3*B*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log((a + b*x)/(c + d*x)))/(3*d*(b*c - a*d)^3*g^4) - (b^3*B^2*n^2*log((a + b*x)/(c + d*x))^2)/(3*d*(b*c - a*d)^3*g^4)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(c*g + d*g*x)^5, x, 5, -((B^2*d^3*n^2*(a + b*x)^4)/(32*(b*c - a*d)^4*g^5*(c + d*x)^4)) + (2*b*B^2*d^2*n^2*(a + b*x)^3)/(9*(b*c - a*d)^4*g^5*(c + d*x)^3) - (3*b^2*B^2*d*n^2*(a + b*x)^2)/(4*(b*c - a*d)^4*g^5*(c + d*x)^2) + (2*b^3*B^2*n^2*(a + b*x))/((b*c - a*d)^4*g^5*(c + d*x)) + (B*d^3*n*(a + b*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(8*(b*c - a*d)^4*g^5*(c + d*x)^4) - (2*b*B*d^2*n*(a + b*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*(b*c - a*d)^4*g^5*(c + d*x)^3) + (3*b^2*B*d*n*(a + b*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(2*(b*c - a*d)^4*g^5*(c + d*x)^2) - (2*b^3*B*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*c - a*d)^4*g^5*(c + d*x)) - (A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(4*d*g^5*(c + d*x)^4) + (b^4*B*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log((a + b*x)/(c + d*x)))/(2*d*(b*c - a*d)^4*g^5) - (b^4*B^2*n^2*log((a + b*x)/(c + d*x))^2)/(4*d*(b*c - a*d)^4*g^5)]

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [(c*g + d*g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 0, Unintegrable((c*g + d*g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x)]
    @test_int [(c*g + d*g*x)^1/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 0, Unintegrable((c*g + d*g*x)/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x)]
    @test_int [1/((c*g + d*g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x, 0, Unintegrable(1/((c*g + d*g*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x)]
    @test_int [1/((c*g + d*g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x, 3, ((a + b*x)*ExpIntegralEi((A + B*log(e*((a + b*x)/(c + d*x))^n))/(B*n)))/(ℯ^(A/(B*n))*(e*((a + b*x)/(c + d*x))^n)^n^(-1)*(B*(b*c - a*d)*g^2*n*(c + d*x)))]
    @test_int [1/((c*g + d*g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x, 7, (b*(a + b*x)*ExpIntegralEi((A + B*log(e*((a + b*x)/(c + d*x))^n))/(B*n)))/(ℯ^(A/(B*n))*(e*((a + b*x)/(c + d*x))^n)^n^(-1)*(B*(b*c - a*d)^2*g^3*n*(c + d*x))) - (d*(a + b*x)^2*ExpIntegralEi((2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(B*n)))/(ℯ^((2*A)/(B*n))*(e*((a + b*x)/(c + d*x))^n)^(2/n)*(B*(b*c - a*d)^2*g^3*n*(c + d*x)^2))]

    @test_int [(c*g + d*g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 0, Unintegrable((c*g + d*g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x)]
    @test_int [(c*g + d*g*x)^1/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 0, Unintegrable((c*g + d*g*x)/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x)]
    @test_int [1/((c*g + d*g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x, 0, Unintegrable(1/((c*g + d*g*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x)]
    @test_int [1/((c*g + d*g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x, 4, ((a + b*x)*ExpIntegralEi((A + B*log(e*((a + b*x)/(c + d*x))^n))/(B*n)))/(ℯ^(A/(B*n))*(e*((a + b*x)/(c + d*x))^n)^n^(-1)*(B^2*(b*c - a*d)*g^2*n^2*(c + d*x))) - (a + b*x)/(B*(b*c - a*d)*g^2*n*(c + d*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))]
    @test_int [1/((c*g + d*g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x, 10, (b*(a + b*x)*ExpIntegralEi((A + B*log(e*((a + b*x)/(c + d*x))^n))/(B*n)))/(ℯ^(A/(B*n))*(e*((a + b*x)/(c + d*x))^n)^n^(-1)*(B^2*(b*c - a*d)^2*g^3*n^2*(c + d*x))) - (2*d*(a + b*x)^2*ExpIntegralEi((2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(B*n)))/(ℯ^((2*A)/(B*n))*(e*((a + b*x)/(c + d*x))^n)^(2/n)*(B^2*(b*c - a*d)^2*g^3*n^2*(c + d*x)^2)) - (a + b*x)/(B*(b*c - a*d)*g^3*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))]

    #= ::Section::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*((a+b*x)/(c+d*x))^n))^p=#

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*((a+b*x)/(c+d*x))^n))^p=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(f + g*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 3, (B*(b*c - a*d)*g*(a^3*d^3*g^3 - a^2*b*d^2*g^2*(5*d*f - c*g) + a*b^2*d*g*(10*d^2*f^2 - 5*c*d*f*g + c^2*g^2) - b^3*(10*d^3*f^3 - 10*c*d^2*f^2*g + 5*c^2*d*f*g^2 - c^3*g^3))*n*x)/(5*b^4*d^4) - (B*(b*c - a*d)*g^2*(a^2*d^2*g^2 - a*b*d*g*(5*d*f - c*g) + b^2*(10*d^2*f^2 - 5*c*d*f*g + c^2*g^2))*n*x^2)/(10*b^3*d^3) - (B*(b*c - a*d)*g^3*(5*b*d*f - b*c*g - a*d*g)*n*x^3)/(15*b^2*d^2) - (B*(b*c - a*d)*g^4*n*x^4)/(20*b*d) - (B*(b*f - a*g)^5*n*log(a + b*x))/(5*b^5*g) + ((f + g*x)^5*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(5*g) + (B*(d*f - c*g)^5*n*log(c + d*x))/(5*d^5*g)]
    @test_int [(f + g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 3, -(B*(b*c - a*d)*g*(a^2*d^2*g^2 - a*b*d*g*(4*d*f - c*g) + b^2*(6*d^2*f^2 - 4*c*d*f*g + c^2*g^2))*n*x)/(4*b^3*d^3) - (B*(b*c - a*d)*g^2*(4*b*d*f - b*c*g - a*d*g)*n*x^2)/(8*b^2*d^2) - (B*(b*c - a*d)*g^3*n*x^3)/(12*b*d) - (B*(b*f - a*g)^4*n*log(a + b*x))/(4*b^4*g) + ((f + g*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(4*g) + (B*(d*f - c*g)^4*n*log(c + d*x))/(4*d^4*g)]
    @test_int [(f + g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 3, -(B*(b*c - a*d)*g*(3*b*d*f - b*c*g - a*d*g)*n*x)/(3*b^2*d^2) - (B*(b*c - a*d)*g^2*n*x^2)/(6*b*d) - (B*(b*f - a*g)^3*n*log(a + b*x))/(3*b^3*g) + ((f + g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*g) + (B*(d*f - c*g)^3*n*log(c + d*x))/(3*d^3*g)]
    @test_int [(f + g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 3, -(B*(b*c - a*d)*g*n*x)/(2*b*d) - (B*(b*f - a*g)^2*n*log(a + b*x))/(2*b^2*g) + ((f + g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(2*g) + (B*(d*f - c*g)^2*n*log(c + d*x))/(2*d^2*g)]
    @test_int [(f + g*x)^0*(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 3, A*x + (B*(a + b*x)*log(e*((a + b*x)/(c + d*x))^n))/b - (B*(b*c - a*d)*n*log(c + d*x))/(b*d)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(f + g*x)^1, x, 7, -((B*n*log(-((g*(a + b*x))/(b*f - a*g)))*log(f + g*x))/g) + ((A + B*log(e*((a + b*x)/(c + d*x))^n))*log(f + g*x))/g + (B*n*log(-((g*(c + d*x))/(d*f - c*g)))*log(f + g*x))/g - (B*n*PolyLog(2, (b*(f + g*x))/(b*f - a*g)))/g + (B*n*PolyLog(2, (d*(f + g*x))/(d*f - c*g)))/g]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(f + g*x)^2, x, 3, ((a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*f - a*g)*(f + g*x)) + (B*(b*c - a*d)*n*log((f + g*x)/(c + d*x)))/((b*f - a*g)*(d*f - c*g))]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(f + g*x)^3, x, 3, -(B*(b*c - a*d)*n)/(2*(b*f - a*g)*(d*f - c*g)*(f + g*x)) + (b^2*B*n*log(a + b*x))/(2*g*(b*f - a*g)^2) - (A + B*log(e*((a + b*x)/(c + d*x))^n))/(2*g*(f + g*x)^2) - (B*d^2*n*log(c + d*x))/(2*g*(d*f - c*g)^2) + (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*n*log(f + g*x))/(2*(b*f - a*g)^2*(d*f - c*g)^2)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(f + g*x)^4, x, 3, -(B*(b*c - a*d)*n)/(6*(b*f - a*g)*(d*f - c*g)*(f + g*x)^2) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*n)/(3*(b*f - a*g)^2*(d*f - c*g)^2*(f + g*x)) + (b^3*B*n*log(a + b*x))/(3*g*(b*f - a*g)^3) - (A + B*log(e*((a + b*x)/(c + d*x))^n))/(3*g*(f + g*x)^3) - (B*d^3*n*log(c + d*x))/(3*g*(d*f - c*g)^3) + (B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*n*log(f + g*x))/(3*(b*f - a*g)^3*(d*f - c*g)^3)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))/(f + g*x)^5, x, 3, -(B*(b*c - a*d)*n)/(12*(b*f - a*g)*(d*f - c*g)*(f + g*x)^3) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*n)/(8*(b*f - a*g)^2*(d*f - c*g)^2*(f + g*x)^2) - (B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*n)/(4*(b*f - a*g)^3*(d*f - c*g)^3*(f + g*x)) + (b^4*B*n*log(a + b*x))/(4*g*(b*f - a*g)^4) - (A + B*log(e*((a + b*x)/(c + d*x))^n))/(4*g*(f + g*x)^4) - (B*d^4*n*log(c + d*x))/(4*g*(d*f - c*g)^4) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*n*log(f + g*x))/(4*(b*f - a*g)^4*(d*f - c*g)^4)]

    @test_int [(f + g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 15, (B^2*(b*c - a*d)^3*g^3*n^2*x)/(6*b^3*d^3) + (B^2*(b*c - a*d)^2*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*n^2*x)/(4*b^3*d^3) + (B^2*(b*c - a*d)^2*g^3*n^2*(c + d*x)^2)/(12*b^2*d^4) - (B*(b*c - a*d)*g*(a^2*d^2*g^2 - 2*a*b*d*g*(2*d*f - c*g) + b^2*(6*d^2*f^2 - 8*c*d*f*g + 3*c^2*g^2))*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(2*b^4*d^3) - (B*(b*c - a*d)*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(4*b^2*d^4) - (B*(b*c - a*d)*g^3*n*(c + d*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(6*b*d^4) - ((b*f - a*g)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(4*b^4*g) + ((f + g*x)^4*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(4*g) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log((b*c - a*d)/(b*(c + d*x))))/(2*b^4*d^4) + (B^2*(b*c - a*d)^4*g^3*n^2*log((a + b*x)/(c + d*x)))/(6*b^4*d^4) + (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*n^2*log((a + b*x)/(c + d*x)))/(4*b^4*d^4) + (B^2*(b*c - a*d)^4*g^3*n^2*log(c + d*x))/(6*b^4*d^4) + (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*n^2*log(c + d*x))/(4*b^4*d^4) + (B^2*(b*c - a*d)^2*g*(a^2*d^2*g^2 - 2*a*b*d*g*(2*d*f - c*g) + b^2*(6*d^2*f^2 - 8*c*d*f*g + 3*c^2*g^2))*n^2*log(c + d*x))/(2*b^4*d^4) - (B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(2*b^4*d^4)]
    @test_int [(f + g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 12, (B^2*(b*c - a*d)^2*g^2*n^2*x)/(3*b^2*d^2) - (2*B*(b*c - a*d)*g*(3*b*d*f - 2*b*c*g - a*d*g)*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*b^3*d^2) - (B*(b*c - a*d)*g^2*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*b*d^3) - ((b*f - a*g)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(3*b^3*g) + ((f + g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(3*g) + (2*B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log((b*c - a*d)/(b*(c + d*x))))/(3*b^3*d^3) + (B^2*(b*c - a*d)^3*g^2*n^2*log((a + b*x)/(c + d*x)))/(3*b^3*d^3) + (B^2*(b*c - a*d)^3*g^2*n^2*log(c + d*x))/(3*b^3*d^3) + (2*B^2*(b*c - a*d)^2*g*(3*b*d*f - 2*b*c*g - a*d*g)*n^2*log(c + d*x))/(3*b^3*d^3) + (2*B^2*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(3*b^3*d^3)]
    @test_int [(f + g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 9, -((B*(b*c - a*d)*g*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(b^2*d)) - ((b*f - a*g)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(2*b^2*g) + ((f + g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(2*g) + (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log((b*c - a*d)/(b*(c + d*x))))/(b^2*d^2) + (B^2*(b*c - a*d)^2*g*n^2*log(c + d*x))/(b^2*d^2) + (B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b^2*d^2)]
    @test_int [(f + g*x)^0*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 6, ((a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/b + (2*B*(b*c - a*d)*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log((b*c - a*d)/(b*(c + d*x))))/(b*d) + (2*B^2*(b*c - a*d)*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(f + g*x)^1, x, 9, -(((A + B*log(e*((a + b*x)/(c + d*x))^n))^2*log((b*c - a*d)/(b*(c + d*x))))/g) + ((A + B*log(e*((a + b*x)/(c + d*x))^n))^2*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/g - (2*B*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/g + (2*B*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/g + (2*B^2*n^2*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/g - (2*B^2*n^2*PolyLog(3, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/g]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(f + g*x)^2, x, 4, ((a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/((b*f - a*g)*(f + g*x)) + (2*B*(b*c - a*d)*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)*(d*f - c*g)) + (2*B^2*(b*c - a*d)*n^2*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)*(d*f - c*g))]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(f + g*x)^3, x, 9, (B*(b*c - a*d)*g*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/((b*f - a*g)^2*(d*f - c*g)*(f + g*x)) + (b^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(2*g*(b*f - a*g)^2) - (A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(2*g*(f + g*x)^2) + (B^2*(b*c - a*d)^2*g*n^2*log((f + g*x)/(c + d*x)))/((b*f - a*g)^2*(d*f - c*g)^2) + (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)^2*(d*f - c*g)^2) + (B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*n^2*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)^2*(d*f - c*g)^2)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(f + g*x)^4, x, 12, (B^2*(b*c - a*d)^2*g^2*n^2*(c + d*x))/(3*(b*f - a*g)^2*(d*f - c*g)^3*(f + g*x)) - (B*(b*c - a*d)*g^2*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*(b*f - a*g)*(d*f - c*g)^3*(f + g*x)^2) + (2*B*(b*c - a*d)*g*(3*b*d*f - b*c*g - 2*a*d*g)*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(3*(b*f - a*g)^3*(d*f - c*g)^2*(f + g*x)) + (b^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(3*g*(b*f - a*g)^3) - (A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(3*g*(f + g*x)^3) + (B^2*(b*c - a*d)^3*g^2*n^2*log((a + b*x)/(c + d*x)))/(3*(b*f - a*g)^3*(d*f - c*g)^3) - (B^2*(b*c - a*d)^3*g^2*n^2*log((f + g*x)/(c + d*x)))/(3*(b*f - a*g)^3*(d*f - c*g)^3) + (2*B^2*(b*c - a*d)^2*g*(3*b*d*f - b*c*g - 2*a*d*g)*n^2*log((f + g*x)/(c + d*x)))/(3*(b*f - a*g)^3*(d*f - c*g)^3) + (2*B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/(3*(b*f - a*g)^3*(d*f - c*g)^3) + (2*B^2*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*n^2*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/(3*(b*f - a*g)^3*(d*f - c*g)^3)]
    @test_int [(A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(f + g*x)^5, x, 15, -((B^2*(b*c - a*d)^2*g^3*n^2*(c + d*x)^2)/(12*(b*f - a*g)^2*(d*f - c*g)^4*(f + g*x)^2)) - (B^2*(b*c - a*d)^3*g^3*n^2*(c + d*x))/(6*(b*f - a*g)^3*(d*f - c*g)^4*(f + g*x)) + (B^2*(b*c - a*d)^2*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*n^2*(c + d*x))/(4*(b*f - a*g)^3*(d*f - c*g)^4*(f + g*x)) + (B*(b*c - a*d)*g^3*n*(c + d*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(6*(b*f - a*g)*(d*f - c*g)^4*(f + g*x)^3) - (B*(b*c - a*d)*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*n*(c + d*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(4*(b*f - a*g)^2*(d*f - c*g)^4*(f + g*x)^2) + (B*(b*c - a*d)*g*(3*a^2*d^2*g^2 - 2*a*b*d*g*(4*d*f - c*g) + b^2*(6*d^2*f^2 - 4*c*d*f*g + c^2*g^2))*n*(a + b*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n)))/(2*(b*f - a*g)^4*(d*f - c*g)^3*(f + g*x)) + (b^4*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(4*g*(b*f - a*g)^4) - (A + B*log(e*((a + b*x)/(c + d*x))^n))^2/(4*g*(f + g*x)^4) - (B^2*(b*c - a*d)^4*g^3*n^2*log((a + b*x)/(c + d*x)))/(6*(b*f - a*g)^4*(d*f - c*g)^4) + (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*n^2*log((a + b*x)/(c + d*x)))/(4*(b*f - a*g)^4*(d*f - c*g)^4) + (B^2*(b*c - a*d)^4*g^3*n^2*log((f + g*x)/(c + d*x)))/(6*(b*f - a*g)^4*(d*f - c*g)^4) - (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*n^2*log((f + g*x)/(c + d*x)))/(4*(b*f - a*g)^4*(d*f - c*g)^4) + (B^2*(b*c - a*d)^2*g*(3*a^2*d^2*g^2 - 2*a*b*d*g*(4*d*f - c*g) + b^2*(6*d^2*f^2 - 4*c*d*f*g + c^2*g^2))*n^2*log((f + g*x)/(c + d*x)))/(2*(b*f - a*g)^4*(d*f - c*g)^4) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*n*(A + B*log(e*((a + b*x)/(c + d*x))^n))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/(2*(b*f - a*g)^4*(d*f - c*g)^4) - (B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*n^2*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/(2*(b*f - a*g)^4*(d*f - c*g)^4)]

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [(f + g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 0, Unintegrable((f + g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x)]
    @test_int [(f + g*x)^1/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 0, Unintegrable((f + g*x)/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x)]
    @test_int [(f + g*x)^0/(A + B*log(e*((a + b*x)/(c + d*x))^n)), x, 0, Unintegrable((A + B*log(e*((a + b*x)/(c + d*x))^n))^(-1), x)]
    @test_int [1/((f + g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x, 0, Unintegrable(1/((f + g*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x)]
    @test_int [1/((f + g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x, 0, Unintegrable(1/((f + g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x)]
    @test_int [1/((f + g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x, 0, Unintegrable(1/((f + g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))), x)]

    @test_int [(f + g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 0, Unintegrable((f + g*x)^2/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x)]
    @test_int [(f + g*x)^1/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 0, Unintegrable((f + g*x)/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x)]
    @test_int [(f + g*x)^0/(A + B*log(e*((a + b*x)/(c + d*x))^n))^2, x, 0, Unintegrable((A + B*log(e*((a + b*x)/(c + d*x))^n))^(-2), x)]
    @test_int [1/((f + g*x)^1*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x, 0, Unintegrable(1/((f + g*x)*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x)]
    @test_int [1/((f + g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x, 0, Unintegrable(1/((f + g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x)]
    @test_int [1/((f + g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x, 0, Unintegrable(1/((f + g*x)^3*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2), x)]

    #= ::Title:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^n/(c+d*x)^n))^p=#

    #= ::Section::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^n/(c+d*x)^n))^p*when*b*f-a*g=0=#

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^1/(c+d*x)^1))^p*when*b*f-a*g=0=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(a*g + b*g*x)^4*(A + B*log((e*(a + b*x))/(c + d*x))), x, 4, (B*(b*c - a*d)^4*g^4*x)/(5*d^4) - (B*(b*c - a*d)^3*g^4*(a + b*x)^2)/(10*b*d^3) + (B*(b*c - a*d)^2*g^4*(a + b*x)^3)/(15*b*d^2) - (B*(b*c - a*d)*g^4*(a + b*x)^4)/(20*b*d) + (g^4*(a + b*x)^5*(A + B*log((e*(a + b*x))/(c + d*x))))/(5*b) - (B*(b*c - a*d)^5*g^4*log(c + d*x))/(5*b*d^5)]
    @test_int [(a*g + b*g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x))), x, 4, -(B*(b*c - a*d)^3*g^3*x)/(4*d^3) + (B*(b*c - a*d)^2*g^3*(a + b*x)^2)/(8*b*d^2) - (B*(b*c - a*d)*g^3*(a + b*x)^3)/(12*b*d) + (g^3*(a + b*x)^4*(A + B*log((e*(a + b*x))/(c + d*x))))/(4*b) + (B*(b*c - a*d)^4*g^3*log(c + d*x))/(4*b*d^4)]
    @test_int [(a*g + b*g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))), x, 4, (B*(b*c - a*d)^2*g^2*x)/(3*d^2) - (B*(b*c - a*d)*g^2*(a + b*x)^2)/(6*b*d) + (g^2*(a + b*x)^3*(A + B*log((e*(a + b*x))/(c + d*x))))/(3*b) - (B*(b*c - a*d)^3*g^2*log(c + d*x))/(3*b*d^3)]
    @test_int [(a*g + b*g*x)^1*(A + B*log((e*(a + b*x))/(c + d*x))), x, 4, -(B*(b*c - a*d)*g*x)/(2*d) + (g*(a + b*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))/(2*b) + (B*(b*c - a*d)^2*g*log(c + d*x))/(2*b*d^2)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))/(a*g + b*g*x)^1, x, 5, -((log(-((b*c - a*d)/(d*(a + b*x))))*(A + B*log((e*(a + b*x))/(c + d*x))))/(b*g)) + (B*PolyLog(2, 1 + (b*c - a*d)/(d*(a + b*x))))/(b*g)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))/(a*g + b*g*x)^2, x, 2, -(B/(b*g^2*(a + b*x))) - ((c + d*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/((b*c - a*d)*g^2*(a + b*x)), -((B*(c + d*x))/((b*c - a*d)*g^2*(a + b*x))) - ((c + d*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/((b*c - a*d)*g^2*(a + b*x))]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))/(a*g + b*g*x)^3, x, 4, -B/(4*b*g^3*(a + b*x)^2) + (B*d)/(2*b*(b*c - a*d)*g^3*(a + b*x)) + (B*d^2*log(a + b*x))/(2*b*(b*c - a*d)^2*g^3) - (A + B*log((e*(a + b*x))/(c + d*x)))/(2*b*g^3*(a + b*x)^2) - (B*d^2*log(c + d*x))/(2*b*(b*c - a*d)^2*g^3)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))/(a*g + b*g*x)^4, x, 4, -B/(9*b*g^4*(a + b*x)^3) + (B*d)/(6*b*(b*c - a*d)*g^4*(a + b*x)^2) - (B*d^2)/(3*b*(b*c - a*d)^2*g^4*(a + b*x)) - (B*d^3*log(a + b*x))/(3*b*(b*c - a*d)^3*g^4) - (A + B*log((e*(a + b*x))/(c + d*x)))/(3*b*g^4*(a + b*x)^3) + (B*d^3*log(c + d*x))/(3*b*(b*c - a*d)^3*g^4)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))/(a*g + b*g*x)^5, x, 4, -B/(16*b*g^5*(a + b*x)^4) + (B*d)/(12*b*(b*c - a*d)*g^5*(a + b*x)^3) - (B*d^2)/(8*b*(b*c - a*d)^2*g^5*(a + b*x)^2) + (B*d^3)/(4*b*(b*c - a*d)^3*g^5*(a + b*x)) + (B*d^4*log(a + b*x))/(4*b*(b*c - a*d)^4*g^5) - (A + B*log((e*(a + b*x))/(c + d*x)))/(4*b*g^5*(a + b*x)^4) - (B*d^4*log(c + d*x))/(4*b*(b*c - a*d)^4*g^5)]

    @test_int [(a*g + b*g*x)^4*(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 8, -((B*(b*c - a*d)*g^4*(a + b*x)^4*(A + B*log((e*(a + b*x))/(c + d*x))))/(10*b*d)) + (g^4*(a + b*x)^5*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(5*b) + (B*(b*c - a*d)^2*g^4*(a + b*x)^3*(4*A + B + 4*B*log((e*(a + b*x))/(c + d*x))))/(30*b*d^2) - (B*(b*c - a*d)^3*g^4*(a + b*x)^2*(12*A + 7*B + 12*B*log((e*(a + b*x))/(c + d*x))))/(60*b*d^3) + (B*(b*c - a*d)^4*g^4*(a + b*x)*(12*A + 13*B + 12*B*log((e*(a + b*x))/(c + d*x))))/(30*b*d^4) + (B*(b*c - a*d)^5*g^4*log((b*c - a*d)/(b*(c + d*x)))*(12*A + 25*B + 12*B*log((e*(a + b*x))/(c + d*x))))/(30*b*d^5) + (2*B^2*(b*c - a*d)^5*g^4*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(5*b*d^5)]
    @test_int [(a*g + b*g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 7, -((B*(b*c - a*d)*g^3*(a + b*x)^3*(A + B*log((e*(a + b*x))/(c + d*x))))/(6*b*d)) + (g^3*(a + b*x)^4*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(4*b) + (B*(b*c - a*d)^2*g^3*(a + b*x)^2*(3*A + B + 3*B*log((e*(a + b*x))/(c + d*x))))/(12*b*d^2) - (B*(b*c - a*d)^3*g^3*(a + b*x)*(6*A + 5*B + 6*B*log((e*(a + b*x))/(c + d*x))))/(12*b*d^3) - (B*(b*c - a*d)^4*g^3*log((b*c - a*d)/(b*(c + d*x)))*(6*A + 11*B + 6*B*log((e*(a + b*x))/(c + d*x))))/(12*b*d^4) - (B^2*(b*c - a*d)^4*g^3*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(2*b*d^4)]
    @test_int [(a*g + b*g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 6, -((B*(b*c - a*d)*g^2*(a + b*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))/(3*b*d)) + (g^2*(a + b*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(3*b) + (B*(b*c - a*d)^2*g^2*(a + b*x)*(2*A + B + 2*B*log((e*(a + b*x))/(c + d*x))))/(3*b*d^2) + (B*(b*c - a*d)^3*g^2*log((b*c - a*d)/(b*(c + d*x)))*(2*A + 3*B + 2*B*log((e*(a + b*x))/(c + d*x))))/(3*b*d^3) + (2*B^2*(b*c - a*d)^3*g^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(3*b*d^3)]
    @test_int [(a*g + b*g*x)^1*(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 5, -((B*(b*c - a*d)*g*(a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/(b*d)) + (g*(a + b*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(2*b) - (B*(b*c - a*d)^2*g*log((b*c - a*d)/(b*(c + d*x)))*(A + B + B*log((e*(a + b*x))/(c + d*x))))/(b*d^2) - (B^2*(b*c - a*d)^2*g*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^2)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))^2/(a*g + b*g*x)^1, x, 4, -(((A + B*log((e*(a + b*x))/(c + d*x)))^2*log(1 - (b*(c + d*x))/(d*(a + b*x))))/(b*g)) + (2*B*(A + B*log((e*(a + b*x))/(c + d*x)))*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(b*g) + (2*B^2*PolyLog(3, (b*(c + d*x))/(d*(a + b*x))))/(b*g)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))^2/(a*g + b*g*x)^2, x, 3, (-2*B^2*(c + d*x))/((b*c - a*d)*g^2*(a + b*x)) - (2*B*(c + d*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/((b*c - a*d)*g^2*(a + b*x)) - ((c + d*x)*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/((b*c - a*d)*g^2*(a + b*x))]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))^2/(a*g + b*g*x)^3, x, 7, (2*B^2*d*(c + d*x))/((b*c - a*d)^2*g^3*(a + b*x)) - (b*B^2*(c + d*x)^2)/(4*(b*c - a*d)^2*g^3*(a + b*x)^2) + (2*B*d*(c + d*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/((b*c - a*d)^2*g^3*(a + b*x)) - (b*B*(c + d*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))/(2*(b*c - a*d)^2*g^3*(a + b*x)^2) + (d*(c + d*x)*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/((b*c - a*d)^2*g^3*(a + b*x)) - (b*(c + d*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(2*(b*c - a*d)^2*g^3*(a + b*x)^2)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))^2/(a*g + b*g*x)^4, x, 9, (-2*B^2*d^2*(c + d*x))/((b*c - a*d)^3*g^4*(a + b*x)) + (b*B^2*d*(c + d*x)^2)/(2*(b*c - a*d)^3*g^4*(a + b*x)^2) - (2*b^2*B^2*(c + d*x)^3)/(27*(b*c - a*d)^3*g^4*(a + b*x)^3) - (2*B*d^2*(c + d*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/((b*c - a*d)^3*g^4*(a + b*x)) + (b*B*d*(c + d*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))/((b*c - a*d)^3*g^4*(a + b*x)^2) - (2*b^2*B*(c + d*x)^3*(A + B*log((e*(a + b*x))/(c + d*x))))/(9*(b*c - a*d)^3*g^4*(a + b*x)^3) - (d^2*(c + d*x)*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/((b*c - a*d)^3*g^4*(a + b*x)) + (b*d*(c + d*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/((b*c - a*d)^3*g^4*(a + b*x)^2) - (b^2*(c + d*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(3*(b*c - a*d)^3*g^4*(a + b*x)^3)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))^2/(a*g + b*g*x)^5, x, 11, (2*B^2*d^3*(c + d*x))/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*B^2*d^2*(c + d*x)^2)/(4*(b*c - a*d)^4*g^5*(a + b*x)^2) + (2*b^2*B^2*d*(c + d*x)^3)/(9*(b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*B^2*(c + d*x)^4)/(32*(b*c - a*d)^4*g^5*(a + b*x)^4) + (2*B*d^3*(c + d*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*B*d^2*(c + d*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))/(2*(b*c - a*d)^4*g^5*(a + b*x)^2) + (2*b^2*B*d*(c + d*x)^3*(A + B*log((e*(a + b*x))/(c + d*x))))/(3*(b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*B*(c + d*x)^4*(A + B*log((e*(a + b*x))/(c + d*x))))/(8*(b*c - a*d)^4*g^5*(a + b*x)^4) + (d^3*(c + d*x)*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*d^2*(c + d*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(2*(b*c - a*d)^4*g^5*(a + b*x)^2) + (b^2*d*(c + d*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/((b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*(c + d*x)^4*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(4*(b*c - a*d)^4*g^5*(a + b*x)^4)]

    @test_int [log(d*(a + b*x)/(b*(c + d*x)))/(c*f + d*f*x), x, 1, PolyLog(2, (b*c - a*d)/(b*(c + d*x)))/(d*f), PolyLog(2, 1 - (d*(a + b*x))/(b*(c + d*x)))/(d*f)]

    @test_int [log(1 + 1/(a + b*x))/(a + b*x), x, 1, PolyLog(2, -(1/(a + b*x)))/b]
    @test_int [log(1 - 1/(a + b*x))/(a + b*x), x, 1, PolyLog(2, 1/(a + b*x))/b]

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [(a*g + b*g*x)^2/(A + B*log((e*(a + b*x))/(c + d*x))), x, 0, Unintegrable((a*g + b*g*x)^2/(A + B*log((e*(a + b*x))/(c + d*x))), x)]
    @test_int [(a*g + b*g*x)^1/(A + B*log((e*(a + b*x))/(c + d*x))), x, 0, Unintegrable((a*g + b*g*x)/(A + B*log((e*(a + b*x))/(c + d*x))), x)]
    @test_int [1/((a*g + b*g*x)^1*(A + B*log((e*(a + b*x))/(c + d*x)))), x, 0, Unintegrable(1/((a*g + b*g*x)*(A + B*log((e*(a + b*x))/(c + d*x)))), x)]
    @test_int [1/((a*g + b*g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))), x, 3, (e*ℯ^(A/B)*ExpIntegralEi(-((A + B*log((e*(a + b*x))/(c + d*x)))/B)))/(B*(b*c - a*d)*g^2)]
    @test_int [1/((a*g + b*g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))), x, 7, (b*e^2*ℯ^((2*A)/B)*ExpIntegralEi((-2*(A + B*log((e*(a + b*x))/(c + d*x))))/B))/(B*(b*c - a*d)^2*g^3) - (d*e*ℯ^(A/B)*ExpIntegralEi(-((A + B*log((e*(a + b*x))/(c + d*x)))/B)))/(B*(b*c - a*d)^2*g^3)]

    @test_int [(a*g + b*g*x)^2/(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 0, Unintegrable((a*g + b*g*x)^2/(A + B*log((e*(a + b*x))/(c + d*x)))^2, x)]
    @test_int [(a*g + b*g*x)^1/(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 0, Unintegrable((a*g + b*g*x)/(A + B*log((e*(a + b*x))/(c + d*x)))^2, x)]
    @test_int [1/((a*g + b*g*x)^1*(A + B*log((e*(a + b*x))/(c + d*x)))^2), x, 0, Unintegrable(1/((a*g + b*g*x)*(A + B*log((e*(a + b*x))/(c + d*x)))^2), x)]
    @test_int [1/((a*g + b*g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2), x, 4, -((e*ℯ^(A/B)*ExpIntegralEi(-((A + B*log((e*(a + b*x))/(c + d*x)))/B)))/(B^2*(b*c - a*d)*g^2)) - (c + d*x)/(B*(b*c - a*d)*g^2*(a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x))))]
    @test_int [1/((a*g + b*g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2), x, 9, (-2*b*e^2*ℯ^((2*A)/B)*ExpIntegralEi((-2*(A + B*log((e*(a + b*x))/(c + d*x))))/B))/(B^2*(b*c - a*d)^2*g^3) + (d*e*ℯ^(A/B)*ExpIntegralEi(-((A + B*log((e*(a + b*x))/(c + d*x)))/B)))/(B^2*(b*c - a*d)^2*g^3) + (d*(c + d*x))/(B*(b*c - a*d)^2*g^3*(a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x)))) - (b*(c + d*x)^2)/(B*(b*c - a*d)^2*g^3*(a + b*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))]

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^2/(c+d*x)^2))^p*when*b*f-a*g=0=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(a*g + b*g*x)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 4, (2*B*(b*c - a*d)^4*g^4*x)/(5*d^4) - (B*(b*c - a*d)^3*g^4*(a + b*x)^2)/(5*b*d^3) + (2*B*(b*c - a*d)^2*g^4*(a + b*x)^3)/(15*b*d^2) - (B*(b*c - a*d)*g^4*(a + b*x)^4)/(10*b*d) + (g^4*(a + b*x)^5*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(5*b) - (2*B*(b*c - a*d)^5*g^4*log(c + d*x))/(5*b*d^5)]
    @test_int [(a*g + b*g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 4, -(B*(b*c - a*d)^3*g^3*x)/(2*d^3) + (B*(b*c - a*d)^2*g^3*(a + b*x)^2)/(4*b*d^2) - (B*(b*c - a*d)*g^3*(a + b*x)^3)/(6*b*d) + (g^3*(a + b*x)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(4*b) + (B*(b*c - a*d)^4*g^3*log(c + d*x))/(2*b*d^4)]
    @test_int [(a*g + b*g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 4, (2*B*(b*c - a*d)^2*g^2*x)/(3*d^2) - (B*(b*c - a*d)*g^2*(a + b*x)^2)/(3*b*d) + (g^2*(a + b*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*b) - (2*B*(b*c - a*d)^3*g^2*log(c + d*x))/(3*b*d^3)]
    @test_int [(a*g + b*g*x)^1*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 4, -((B*(b*c - a*d)*g*x)/d) + (g*(a + b*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(2*b) + (B*(b*c - a*d)^2*g*log(c + d*x))/(b*d^2)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(a*g + b*g*x)^1, x, 5, -((log(-((b*c - a*d)/(d*(a + b*x))))*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(b*g)) + (2*B*PolyLog(2, 1 + (b*c - a*d)/(d*(a + b*x))))/(b*g)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(a*g + b*g*x)^2, x, 2, -((2*B)/(b*g^2*(a + b*x))) - ((c + d*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*c - a*d)*g^2*(a + b*x)), -((2*B*(c + d*x))/((b*c - a*d)*g^2*(a + b*x))) - ((c + d*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*c - a*d)*g^2*(a + b*x))]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(a*g + b*g*x)^3, x, 4, -B/(2*b*g^3*(a + b*x)^2) + (B*d)/(b*(b*c - a*d)*g^3*(a + b*x)) + (B*d^2*log(a + b*x))/(b*(b*c - a*d)^2*g^3) - (A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(2*b*g^3*(a + b*x)^2) - (B*d^2*log(c + d*x))/(b*(b*c - a*d)^2*g^3)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(a*g + b*g*x)^4, x, 4, (-2*B)/(9*b*g^4*(a + b*x)^3) + (B*d)/(3*b*(b*c - a*d)*g^4*(a + b*x)^2) - (2*B*d^2)/(3*b*(b*c - a*d)^2*g^4*(a + b*x)) - (2*B*d^3*log(a + b*x))/(3*b*(b*c - a*d)^3*g^4) - (A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(3*b*g^4*(a + b*x)^3) + (2*B*d^3*log(c + d*x))/(3*b*(b*c - a*d)^3*g^4)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(a*g + b*g*x)^5, x, 4, -B/(8*b*g^5*(a + b*x)^4) + (B*d)/(6*b*(b*c - a*d)*g^5*(a + b*x)^3) - (B*d^2)/(4*b*(b*c - a*d)^2*g^5*(a + b*x)^2) + (B*d^3)/(2*b*(b*c - a*d)^3*g^5*(a + b*x)) + (B*d^4*log(a + b*x))/(2*b*(b*c - a*d)^4*g^5) - (A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(4*b*g^5*(a + b*x)^4) - (B*d^4*log(c + d*x))/(2*b*(b*c - a*d)^4*g^5)]

    @test_int [(a*g + b*g*x)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 8, -((B*(b*c - a*d)*g^4*(a + b*x)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(5*b*d)) + (g^4*(a + b*x)^5*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(5*b) + (2*B*(b*c - a*d)^2*g^4*(a + b*x)^3*(2*A + B + 2*B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(15*b*d^2) - (B*(b*c - a*d)^3*g^4*(a + b*x)^2*(6*A + 7*B + 6*B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(15*b*d^3) + (2*B*(b*c - a*d)^4*g^4*(a + b*x)*(6*A + 13*B + 6*B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(15*b*d^4) + (2*B*(b*c - a*d)^5*g^4*(6*A + 25*B + 6*B*log((e*(a + b*x)^2)/(c + d*x)^2))*log((b*c - a*d)/(b*(c + d*x))))/(15*b*d^5) + (8*B^2*(b*c - a*d)^5*g^4*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(5*b*d^5)]
    @test_int [(a*g + b*g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 7, -((B*(b*c - a*d)*g^3*(a + b*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*b*d)) + (g^3*(a + b*x)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(4*b) + (B*(b*c - a*d)^2*g^3*(a + b*x)^2*(3*A + 2*B + 3*B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(6*b*d^2) - (B*(b*c - a*d)^3*g^3*(a + b*x)*(3*A + 5*B + 3*B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*b*d^3) - (B*(b*c - a*d)^4*g^3*(3*A + 11*B + 3*B*log((e*(a + b*x)^2)/(c + d*x)^2))*log((b*c - a*d)/(b*(c + d*x))))/(3*b*d^4) - (2*B^2*(b*c - a*d)^4*g^3*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^4)]
    @test_int [(a*g + b*g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 6, -((2*B*(b*c - a*d)*g^2*(a + b*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*b*d)) + (g^2*(a + b*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(3*b) + (4*B*(b*c - a*d)^2*g^2*(a + b*x)*(A + B + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*b*d^2) + (4*B*(b*c - a*d)^3*g^2*(A + 3*B + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log((b*c - a*d)/(b*(c + d*x))))/(3*b*d^3) + (8*B^2*(b*c - a*d)^3*g^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(3*b*d^3)]
    @test_int [(a*g + b*g*x)^1*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 5, -((2*B*(b*c - a*d)*g*(a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(b*d)) + (g*(a + b*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(2*b) - (2*B*(b*c - a*d)^2*g*(A + 2*B + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log((b*c - a*d)/(b*(c + d*x))))/(b*d^2) - (4*B^2*(b*c - a*d)^2*g*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^2)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(a*g + b*g*x)^1, x, 4, -(((A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2*log(1 - (b*(c + d*x))/(d*(a + b*x))))/(b*g)) + (4*B*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(b*g) + (8*B^2*PolyLog(3, (b*(c + d*x))/(d*(a + b*x))))/(b*g)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(a*g + b*g*x)^2, x, 3, (-8*B^2*(c + d*x))/((b*c - a*d)*g^2*(a + b*x)) - (4*B*(c + d*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*c - a*d)*g^2*(a + b*x)) - ((c + d*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/((b*c - a*d)*g^2*(a + b*x))]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(a*g + b*g*x)^3, x, 7, (8*B^2*d*(c + d*x))/((b*c - a*d)^2*g^3*(a + b*x)) - (b*B^2*(c + d*x)^2)/((b*c - a*d)^2*g^3*(a + b*x)^2) + (4*B*d*(c + d*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*c - a*d)^2*g^3*(a + b*x)) - (b*B*(c + d*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*c - a*d)^2*g^3*(a + b*x)^2) + (d*(c + d*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/((b*c - a*d)^2*g^3*(a + b*x)) - (b*(c + d*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(2*(b*c - a*d)^2*g^3*(a + b*x)^2)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(a*g + b*g*x)^4, x, 9, (-8*B^2*d^2*(c + d*x))/((b*c - a*d)^3*g^4*(a + b*x)) + (2*b*B^2*d*(c + d*x)^2)/((b*c - a*d)^3*g^4*(a + b*x)^2) - (8*b^2*B^2*(c + d*x)^3)/(27*(b*c - a*d)^3*g^4*(a + b*x)^3) - (4*B*d^2*(c + d*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*c - a*d)^3*g^4*(a + b*x)) + (2*b*B*d*(c + d*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*c - a*d)^3*g^4*(a + b*x)^2) - (4*b^2*B*(c + d*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(9*(b*c - a*d)^3*g^4*(a + b*x)^3) - (d^2*(c + d*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/((b*c - a*d)^3*g^4*(a + b*x)) + (b*d*(c + d*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/((b*c - a*d)^3*g^4*(a + b*x)^2) - (b^2*(c + d*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(3*(b*c - a*d)^3*g^4*(a + b*x)^3)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(a*g + b*g*x)^5, x, 11, (8*B^2*d^3*(c + d*x))/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*B^2*d^2*(c + d*x)^2)/((b*c - a*d)^4*g^5*(a + b*x)^2) + (8*b^2*B^2*d*(c + d*x)^3)/(9*(b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*B^2*(c + d*x)^4)/(8*(b*c - a*d)^4*g^5*(a + b*x)^4) + (4*B*d^3*(c + d*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*B*d^2*(c + d*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*c - a*d)^4*g^5*(a + b*x)^2) + (4*b^2*B*d*(c + d*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*(b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*B*(c + d*x)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(4*(b*c - a*d)^4*g^5*(a + b*x)^4) + (d^3*(c + d*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*d^2*(c + d*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(2*(b*c - a*d)^4*g^5*(a + b*x)^2) + (b^2*d*(c + d*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/((b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*(c + d*x)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(4*(b*c - a*d)^4*g^5*(a + b*x)^4)]

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [(a*g + b*g*x)^2/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 0, Unintegrable((a*g + b*g*x)^2/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x)]
    @test_int [(a*g + b*g*x)^1/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 0, Unintegrable((a*g + b*g*x)/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x)]
    @test_int [1/((a*g + b*g*x)^1*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))), x, 0, Unintegrable(1/((a*g + b*g*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))), x)]
    @test_int [1/((a*g + b*g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))), x, 3, (ℯ^(A/(2*B))*sqrt((e*(a + b*x)^2)/(c + d*x)^2)*(c + d*x)*ExpIntegralEi(-(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(2*B)))/(2*B*(b*c - a*d)*g^2*(a + b*x))]
    @test_int [1/((a*g + b*g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))), x, 7, (b*e*ℯ^(A/B)*ExpIntegralEi(-((A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/B)))/(2*B*(b*c - a*d)^2*g^3) - (d*ℯ^(A/(2*B))*sqrt((e*(a + b*x)^2)/(c + d*x)^2)*(c + d*x)*ExpIntegralEi(-(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(2*B)))/(2*B*(b*c - a*d)^2*g^3*(a + b*x))]

    @test_int [(a*g + b*g*x)^2/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 0, Unintegrable((a*g + b*g*x)^2/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x)]
    @test_int [(a*g + b*g*x)^1/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 0, Unintegrable((a*g + b*g*x)/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x)]
    @test_int [1/((a*g + b*g*x)^1*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2), x, 0, Unintegrable(1/((a*g + b*g*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2), x)]
    @test_int [1/((a*g + b*g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2), x, 4, -(ℯ^(A/(2*B))*sqrt((e*(a + b*x)^2)/(c + d*x)^2)*(c + d*x)*ExpIntegralEi(-(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(2*B)))/(4*B^2*(b*c - a*d)*g^2*(a + b*x)) - (c + d*x)/(2*B*(b*c - a*d)*g^2*(a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))]
    @test_int [1/((a*g + b*g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2), x, 9, -(b*e*ℯ^(A/B)*ExpIntegralEi(-((A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/B)))/(2*B^2*(b*c - a*d)^2*g^3) + (d*ℯ^(A/(2*B))*sqrt((e*(a + b*x)^2)/(c + d*x)^2)*(c + d*x)*ExpIntegralEi(-(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(2*B)))/(4*B^2*(b*c - a*d)^2*g^3*(a + b*x)) + (d*(c + d*x))/(2*B*(b*c - a*d)^2*g^3*(a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))) - (b*(c + d*x)^2)/(2*B*(b*c - a*d)^2*g^3*(a + b*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))]

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^n/(c+d*x)^n))^p*when*b*f-a*g=0=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))*(a + b*x)^4, x, 3, (B*(b*c - a*d)^4*n*x)/(5*d^4) - (B*(b*c - a*d)^3*n*(a + b*x)^2)/(10*b*d^3) + (B*(b*c - a*d)^2*n*(a + b*x)^3)/(15*b*d^2) - (B*(b*c - a*d)*n*(a + b*x)^4)/(20*b*d) - (B*(b*c - a*d)^5*n*log(c + d*x))/(5*b*d^5) + ((a + b*x)^5*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(5*b)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))*(a + b*x)^3, x, 3, -((B*(b*c - a*d)^3*n*x)/(4*d^3)) + (B*(b*c - a*d)^2*n*(a + b*x)^2)/(8*b*d^2) - (B*(b*c - a*d)*n*(a + b*x)^3)/(12*b*d) + (B*(b*c - a*d)^4*n*log(c + d*x))/(4*b*d^4) + ((a + b*x)^4*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(4*b)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))*(a + b*x)^2, x, 3, (B*(b*c - a*d)^2*n*x)/(3*d^2) - (B*(b*c - a*d)*n*(a + b*x)^2)/(6*b*d) - (B*(b*c - a*d)^3*n*log(c + d*x))/(3*b*d^3) + ((a + b*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(3*b)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))*(a + b*x)^1, x, 3, -((B*(b*c - a*d)*n*x)/(2*d)) + (B*(b*c - a*d)^2*n*log(c + d*x))/(2*b*d^2) + ((a + b*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(2*b)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))/(a + b*x)^1, x, 5, -((log(-((b*c - a*d)/(d*(a + b*x))))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/b) + (B*n*PolyLog(2, 1 + (b*c - a*d)/(d*(a + b*x))))/b]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))/(a + b*x)^2, x, 3, -((B*n)/(b*(a + b*x))) - (B*d*n*log(a + b*x))/(b*(b*c - a*d)) + (B*d*n*log(c + d*x))/(b*(b*c - a*d)) - (A + B*log((e*(a + b*x)^n)/(c + d*x)^n))/(b*(a + b*x))]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))/(a + b*x)^3, x, 3, -((B*n)/(4*b*(a + b*x)^2)) + (B*d*n)/(2*b*(b*c - a*d)*(a + b*x)) + (B*d^2*n*log(a + b*x))/(2*b*(b*c - a*d)^2) - (B*d^2*n*log(c + d*x))/(2*b*(b*c - a*d)^2) - (A + B*log((e*(a + b*x)^n)/(c + d*x)^n))/(2*b*(a + b*x)^2)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))/(a + b*x)^4, x, 3, -((B*n)/(9*b*(a + b*x)^3)) + (B*d*n)/(6*b*(b*c - a*d)*(a + b*x)^2) - (B*d^2*n)/(3*b*(b*c - a*d)^2*(a + b*x)) - (B*d^3*n*log(a + b*x))/(3*b*(b*c - a*d)^3) + (B*d^3*n*log(c + d*x))/(3*b*(b*c - a*d)^3) - (A + B*log((e*(a + b*x)^n)/(c + d*x)^n))/(3*b*(a + b*x)^3)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))/(a + b*x)^5, x, 3, -((B*n)/(16*b*(a + b*x)^4)) + (B*d*n)/(12*b*(b*c - a*d)*(a + b*x)^3) - (B*d^2*n)/(8*b*(b*c - a*d)^2*(a + b*x)^2) + (B*d^3*n)/(4*b*(b*c - a*d)^3*(a + b*x)) + (B*d^4*n*log(a + b*x))/(4*b*(b*c - a*d)^4) - (B*d^4*n*log(c + d*x))/(4*b*(b*c - a*d)^4) - (A + B*log((e*(a + b*x)^n)/(c + d*x)^n))/(4*b*(a + b*x)^4)]

    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2*(a + b*x)^3, x, 8, -((B*(b*c - a*d)*n*(a + b*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(6*b*d)) + ((a + b*x)^4*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(4*b) + (B*(b*c - a*d)^2*n*(a + b*x)^2*(3*A + B*n + 3*B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(12*b*d^2) - (B*(b*c - a*d)^3*n*(a + b*x)*(6*A + 5*B*n + 6*B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(12*b*d^3) - (B*(b*c - a*d)^4*n*log((b*c - a*d)/(b*(c + d*x)))*(6*A + 11*B*n + 6*B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(12*b*d^4) - (B^2*(b*c - a*d)^4*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(2*b*d^4)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2*(a + b*x)^2, x, 7, -((B*(b*c - a*d)*n*(a + b*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(3*b*d)) + ((a + b*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(3*b) + (B*(b*c - a*d)^2*n*(a + b*x)*(2*A + B*n + 2*B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(3*b*d^2) + (B*(b*c - a*d)^3*n*log((b*c - a*d)/(b*(c + d*x)))*(2*A + 3*B*n + 2*B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(3*b*d^3) + (2*B^2*(b*c - a*d)^3*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(3*b*d^3)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2*(a + b*x)^1, x, 6, -((B*(b*c - a*d)*n*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b*d)) + ((a + b*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*b) - (B*(b*c - a*d)^2*n*log((b*c - a*d)/(b*(c + d*x)))*(A + B*n + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b*d^2) - (B^2*(b*c - a*d)^2*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^2)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2/(a + b*x)^1, x, 5, -(((A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2*log(1 - (b*(c + d*x))/(d*(a + b*x))))/b) + (2*B*n*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/b + (2*B^2*n^2*PolyLog(3, (b*(c + d*x))/(d*(a + b*x))))/b]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2/(a + b*x)^2, x, 4, -((2*n^2*(c + d*x)*B^2)/((b*c - a*d)*(a + b*x))) - (2*n*(c + d*x)*B*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/((b*c - a*d)*(a + b*x)) - ((c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)*(a + b*x))]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2/(a + b*x)^3, x, 8, (2*B^2*d*n^2*(c + d*x))/((b*c - a*d)^2*(a + b*x)) - (b*B^2*n^2*(c + d*x)^2)/(4*(b*c - a*d)^2*(a + b*x)^2) + (2*B*d*n*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/((b*c - a*d)^2*(a + b*x)) - (b*B*n*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(2*(b*c - a*d)^2*(a + b*x)^2) + (d*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)^2*(a + b*x)) - (b*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*(b*c - a*d)^2*(a + b*x)^2)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2/(a + b*x)^4, x, 10, -((2*B^2*d^2*n^2*(c + d*x))/((b*c - a*d)^3*(a + b*x))) + (b*B^2*d*n^2*(c + d*x)^2)/(2*(b*c - a*d)^3*(a + b*x)^2) - (2*b^2*B^2*n^2*(c + d*x)^3)/(27*(b*c - a*d)^3*(a + b*x)^3) - (2*B*d^2*n*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/((b*c - a*d)^3*(a + b*x)) + (b*B*d*n*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/((b*c - a*d)^3*(a + b*x)^2) - (2*b^2*B*n*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(9*(b*c - a*d)^3*(a + b*x)^3) - (d^2*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)^3*(a + b*x)) + (b*d*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)^3*(a + b*x)^2) - (b^2*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(3*(b*c - a*d)^3*(a + b*x)^3)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2/(a + b*x)^5, x, 12, (2*B^2*d^3*n^2*(c + d*x))/((b*c - a*d)^4*(a + b*x)) - (3*b*B^2*d^2*n^2*(c + d*x)^2)/(4*(b*c - a*d)^4*(a + b*x)^2) + (2*b^2*B^2*d*n^2*(c + d*x)^3)/(9*(b*c - a*d)^4*(a + b*x)^3) - (b^3*B^2*n^2*(c + d*x)^4)/(32*(b*c - a*d)^4*(a + b*x)^4) + (2*B*d^3*n*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/((b*c - a*d)^4*(a + b*x)) - (3*b*B*d^2*n*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(2*(b*c - a*d)^4*(a + b*x)^2) + (2*b^2*B*d*n*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(3*(b*c - a*d)^4*(a + b*x)^3) - (b^3*B*n*(c + d*x)^4*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(8*(b*c - a*d)^4*(a + b*x)^4) + (d^3*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)^4*(a + b*x)) - (3*b*d^2*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*(b*c - a*d)^4*(a + b*x)^2) + (b^2*d*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)^4*(a + b*x)^3) - (b^3*(c + d*x)^4*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(4*(b*c - a*d)^4*(a + b*x)^4)]

    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3*(a + b*x)^3, x, 27, -((B^3*(b*c - a*d)^3*n^3*x)/(4*d^3)) - (B^3*(b*c - a*d)^4*n^3*log((a + b*x)/(c + d*x)))/(4*b*d^4) + (3*B^3*(b*c - a*d)^4*n^3*log(c + d*x))/(2*b*d^4) - (7*B^2*(b*c - a*d)^3*n^2*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(4*b*d^3) + (b*B^2*(b*c - a*d)^2*n^2*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(4*d^4) - (9*B^2*(b*c - a*d)^4*n^2*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(2*b*d^4) - (9*B*(b*c - a*d)^3*n*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(4*b*d^3) + (9*b*B*(b*c - a*d)^2*n*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(8*d^4) - (b^2*B*(b*c - a*d)*n*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(4*d^4) - (3*B*(b*c - a*d)^4*n*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(4*b*d^4) + ((a + b*x)^4*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(4*b) + (7*B^2*(b*c - a*d)^4*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*log(1 - (b*(c + d*x))/(d*(a + b*x))))/(4*b*d^4) - (9*B^3*(b*c - a*d)^4*n^3*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(2*b*d^4) - (3*B^2*(b*c - a*d)^4*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(2*b*d^4) - (7*B^3*(b*c - a*d)^4*n^3*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(4*b*d^4) + (3*B^3*(b*c - a*d)^4*n^3*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/(2*b*d^4)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3*(a + b*x)^2, x, 17, -((B^3*(b*c - a*d)^3*n^3*log(c + d*x))/(b*d^3)) + (B^2*(b*c - a*d)^2*n^2*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b*d^2) + (4*B^2*(b*c - a*d)^3*n^2*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b*d^3) + (2*B*(b*c - a*d)^2*n*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(b*d^2) - (b*B*(b*c - a*d)*n*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*d^3) + (B*(b*c - a*d)^3*n*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(b*d^3) + ((a + b*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(3*b) - (B^2*(b*c - a*d)^3*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*log(1 - (b*(c + d*x))/(d*(a + b*x))))/(b*d^3) + (4*B^3*(b*c - a*d)^3*n^3*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^3) + (2*B^2*(b*c - a*d)^3*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^3) + (B^3*(b*c - a*d)^3*n^3*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(b*d^3) - (2*B^3*(b*c - a*d)^3*n^3*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/(b*d^3)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3*(a + b*x)^1, x, 11, -((3*B^2*(b*c - a*d)^2*n^2*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b*d^2)) - (3*B*(b*c - a*d)*n*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*b*d) - (3*B*(b*c - a*d)^2*n*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*b*d^2) + ((a + b*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(2*b) - (3*B^3*(b*c - a*d)^2*n^3*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^2) - (3*B^2*(b*c - a*d)^2*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^2) + (3*B^3*(b*c - a*d)^2*n^3*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/(b*d^2)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3/(a + b*x)^1, x, 6, -(((A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3*log(1 - (b*(c + d*x))/(d*(a + b*x))))/b) + (3*B*n*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/b + (6*B^2*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(3, (b*(c + d*x))/(d*(a + b*x))))/b + (6*B^3*n^3*PolyLog(4, (b*(c + d*x))/(d*(a + b*x))))/b]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3/(a + b*x)^2, x, 5, -((6*B^3*n^3*(c + d*x))/((b*c - a*d)*(a + b*x))) - (6*B^2*n^2*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/((b*c - a*d)*(a + b*x)) - (3*B*n*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)*(a + b*x)) - ((c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/((b*c - a*d)*(a + b*x))]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3/(a + b*x)^3, x, 10, (6*B^3*d*n^3*(c + d*x))/((b*c - a*d)^2*(a + b*x)) - (3*b*B^3*n^3*(c + d*x)^2)/(8*(b*c - a*d)^2*(a + b*x)^2) + (6*B^2*d*n^2*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/((b*c - a*d)^2*(a + b*x)) - (3*b*B^2*n^2*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(4*(b*c - a*d)^2*(a + b*x)^2) + (3*B*d*n*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)^2*(a + b*x)) - (3*b*B*n*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(4*(b*c - a*d)^2*(a + b*x)^2) + (d*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/((b*c - a*d)^2*(a + b*x)) - (b*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(2*(b*c - a*d)^2*(a + b*x)^2)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3/(a + b*x)^4, x, 13, -((6*B^3*d^2*n^3*(c + d*x))/((b*c - a*d)^3*(a + b*x))) + (3*b*B^3*d*n^3*(c + d*x)^2)/(4*(b*c - a*d)^3*(a + b*x)^2) - (2*b^2*B^3*n^3*(c + d*x)^3)/(27*(b*c - a*d)^3*(a + b*x)^3) - (6*B^2*d^2*n^2*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/((b*c - a*d)^3*(a + b*x)) + (3*b*B^2*d*n^2*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(2*(b*c - a*d)^3*(a + b*x)^2) - (2*b^2*B^2*n^2*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(9*(b*c - a*d)^3*(a + b*x)^3) - (3*B*d^2*n*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)^3*(a + b*x)) + (3*b*B*d*n*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*(b*c - a*d)^3*(a + b*x)^2) - (b^2*B*n*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(3*(b*c - a*d)^3*(a + b*x)^3) - (d^2*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/((b*c - a*d)^3*(a + b*x)) + (b*d*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/((b*c - a*d)^3*(a + b*x)^2) - (b^2*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(3*(b*c - a*d)^3*(a + b*x)^3)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3/(a + b*x)^5, x, 16, (6*B^3*d^3*n^3*(c + d*x))/((b*c - a*d)^4*(a + b*x)) - (9*b*B^3*d^2*n^3*(c + d*x)^2)/(8*(b*c - a*d)^4*(a + b*x)^2) + (2*b^2*B^3*d*n^3*(c + d*x)^3)/(9*(b*c - a*d)^4*(a + b*x)^3) - (3*b^3*B^3*n^3*(c + d*x)^4)/(128*(b*c - a*d)^4*(a + b*x)^4) + (6*B^2*d^3*n^2*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/((b*c - a*d)^4*(a + b*x)) - (9*b*B^2*d^2*n^2*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(4*(b*c - a*d)^4*(a + b*x)^2) + (2*b^2*B^2*d*n^2*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(3*(b*c - a*d)^4*(a + b*x)^3) - (3*b^3*B^2*n^2*(c + d*x)^4*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(32*(b*c - a*d)^4*(a + b*x)^4) + (3*B*d^3*n*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)^4*(a + b*x)) - (9*b*B*d^2*n*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(4*(b*c - a*d)^4*(a + b*x)^2) + (b^2*B*d*n*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*c - a*d)^4*(a + b*x)^3) - (3*b^3*B*n*(c + d*x)^4*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(16*(b*c - a*d)^4*(a + b*x)^4) + (d^3*(c + d*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/((b*c - a*d)^4*(a + b*x)) - (3*b*d^2*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(2*(b*c - a*d)^4*(a + b*x)^2) + (b^2*d*(c + d*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/((b*c - a*d)^4*(a + b*x)^3) - (b^3*(c + d*x)^4*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(4*(b*c - a*d)^4*(a + b*x)^4)]

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [1/((a*g + b*g*x)^2*(A + B*log(e*(a + b*x)^n/(c + d*x)^n))), x, 4, (ℯ^(A/(B*n))*(c + d*x)*((e*(a + b*x)^n)/(c + d*x)^n)^(1/n)*ExpIntegralEi(-((A + B*log((e*(a + b*x)^n)/(c + d*x)^n))/(B*n))))/(B*(b*c - a*d)*g^2*n*(a + b*x))]

    #= ::Section::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^n/(c+d*x)^n))^p*when*d*f-c*g=0=#

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^1/(c+d*x)^1))^p*when*d*f-c*g=0=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(a*g + b*g*x)^4*(A + B*log((e*(c + d*x))/(a + b*x))), x, 4, -(B*(b*c - a*d)^4*g^4*x)/(5*d^4) + (B*(b*c - a*d)^3*g^4*(a + b*x)^2)/(10*b*d^3) - (B*(b*c - a*d)^2*g^4*(a + b*x)^3)/(15*b*d^2) + (B*(b*c - a*d)*g^4*(a + b*x)^4)/(20*b*d) + (B*(b*c - a*d)^5*g^4*log(c + d*x))/(5*b*d^5) + (g^4*(a + b*x)^5*(A + B*log((e*(c + d*x))/(a + b*x))))/(5*b)]
    @test_int [(a*g + b*g*x)^3*(A + B*log((e*(c + d*x))/(a + b*x))), x, 4, (B*(b*c - a*d)^3*g^3*x)/(4*d^3) - (B*(b*c - a*d)^2*g^3*(a + b*x)^2)/(8*b*d^2) + (B*(b*c - a*d)*g^3*(a + b*x)^3)/(12*b*d) - (B*(b*c - a*d)^4*g^3*log(c + d*x))/(4*b*d^4) + (g^3*(a + b*x)^4*(A + B*log((e*(c + d*x))/(a + b*x))))/(4*b)]
    @test_int [(a*g + b*g*x)^2*(A + B*log((e*(c + d*x))/(a + b*x))), x, 4, -(B*(b*c - a*d)^2*g^2*x)/(3*d^2) + (B*(b*c - a*d)*g^2*(a + b*x)^2)/(6*b*d) + (B*(b*c - a*d)^3*g^2*log(c + d*x))/(3*b*d^3) + (g^2*(a + b*x)^3*(A + B*log((e*(c + d*x))/(a + b*x))))/(3*b)]
    @test_int [(a*g + b*g*x)^1*(A + B*log((e*(c + d*x))/(a + b*x))), x, 4, (B*(b*c - a*d)*g*x)/(2*d) - (B*(b*c - a*d)^2*g*log(c + d*x))/(2*b*d^2) + (g*(a + b*x)^2*(A + B*log((e*(c + d*x))/(a + b*x))))/(2*b)]
    @test_int [(A + B*log((e*(c + d*x))/(a + b*x)))/(a*g + b*g*x)^1, x, 5, -((log(-((b*c - a*d)/(d*(a + b*x))))*(A + B*log((e*(c + d*x))/(a + b*x))))/(b*g)) - (B*PolyLog(2, 1 + (b*c - a*d)/(d*(a + b*x))))/(b*g)]
    @test_int [(A + B*log((e*(c + d*x))/(a + b*x)))/(a*g + b*g*x)^2, x, 3, -((A - B)/(b*g^2*(a + b*x))) - (B*(c + d*x)*log((e*(c + d*x))/(a + b*x)))/((b*c - a*d)*g^2*(a + b*x)), -((A*(c + d*x))/((b*c - a*d)*g^2*(a + b*x))) + (B*(c + d*x))/((b*c - a*d)*g^2*(a + b*x)) - (B*(c + d*x)*log((e*(c + d*x))/(a + b*x)))/((b*c - a*d)*g^2*(a + b*x))]
    @test_int [(A + B*log((e*(c + d*x))/(a + b*x)))/(a*g + b*g*x)^3, x, 4, B/(4*b*g^3*(a + b*x)^2) - (B*d)/(2*b*(b*c - a*d)*g^3*(a + b*x)) - (B*d^2*log(a + b*x))/(2*b*(b*c - a*d)^2*g^3) + (B*d^2*log(c + d*x))/(2*b*(b*c - a*d)^2*g^3) - (A + B*log((e*(c + d*x))/(a + b*x)))/(2*b*g^3*(a + b*x)^2)]
    @test_int [(A + B*log((e*(c + d*x))/(a + b*x)))/(a*g + b*g*x)^4, x, 4, B/(9*b*g^4*(a + b*x)^3) - (B*d)/(6*b*(b*c - a*d)*g^4*(a + b*x)^2) + (B*d^2)/(3*b*(b*c - a*d)^2*g^4*(a + b*x)) + (B*d^3*log(a + b*x))/(3*b*(b*c - a*d)^3*g^4) - (B*d^3*log(c + d*x))/(3*b*(b*c - a*d)^3*g^4) - (A + B*log((e*(c + d*x))/(a + b*x)))/(3*b*g^4*(a + b*x)^3)]
    @test_int [(A + B*log((e*(c + d*x))/(a + b*x)))/(a*g + b*g*x)^5, x, 4, B/(16*b*g^5*(a + b*x)^4) - (B*d)/(12*b*(b*c - a*d)*g^5*(a + b*x)^3) + (B*d^2)/(8*b*(b*c - a*d)^2*g^5*(a + b*x)^2) - (B*d^3)/(4*b*(b*c - a*d)^3*g^5*(a + b*x)) - (B*d^4*log(a + b*x))/(4*b*(b*c - a*d)^4*g^5) + (B*d^4*log(c + d*x))/(4*b*(b*c - a*d)^4*g^5) - (A + B*log((e*(c + d*x))/(a + b*x)))/(4*b*g^5*(a + b*x)^4)]

    @test_int [(a*g + b*g*x)^4*(A + B*log((e*(c + d*x))/(a + b*x)))^2, x, 19, (13*B^2*(b*c - a*d)^4*g^4*x)/(30*d^4) - (7*B^2*(b*c - a*d)^3*g^4*(a + b*x)^2)/(60*b*d^3) + (B^2*(b*c - a*d)^2*g^4*(a + b*x)^3)/(30*b*d^2) - (5*B^2*(b*c - a*d)^5*g^4*log(a + b*x))/(6*b*d^5) - (13*B^2*(b*c - a*d)^5*g^4*log((c + d*x)/(a + b*x)))/(30*b*d^5) + (B*(b*c - a*d)^3*g^4*(a + b*x)^2*(A + B*log((e*(c + d*x))/(a + b*x))))/(5*b*d^3) - (2*B*(b*c - a*d)^2*g^4*(a + b*x)^3*(A + B*log((e*(c + d*x))/(a + b*x))))/(15*b*d^2) + (B*(b*c - a*d)*g^4*(a + b*x)^4*(A + B*log((e*(c + d*x))/(a + b*x))))/(10*b*d) - (2*B*(b*c - a*d)^4*g^4*(c + d*x)*(A + B*log((e*(c + d*x))/(a + b*x))))/(5*d^5) + (g^4*(a + b*x)^5*(A + B*log((e*(c + d*x))/(a + b*x)))^2)/(5*b) - (2*B*(b*c - a*d)^5*g^4*(A + B*log((e*(c + d*x))/(a + b*x)))*log(1 - (d*(a + b*x))/(b*(c + d*x))))/(5*b*d^5) + (2*B^2*(b*c - a*d)^5*g^4*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(5*b*d^5)]
    @test_int [(a*g + b*g*x)^3*(A + B*log((e*(c + d*x))/(a + b*x)))^2, x, 15, -((5*B^2*(b*c - a*d)^3*g^3*x)/(12*d^3)) + (B^2*(b*c - a*d)^2*g^3*(a + b*x)^2)/(12*b*d^2) + (11*B^2*(b*c - a*d)^4*g^3*log(a + b*x))/(12*b*d^4) + (5*B^2*(b*c - a*d)^4*g^3*log((c + d*x)/(a + b*x)))/(12*b*d^4) - (B*(b*c - a*d)^2*g^3*(a + b*x)^2*(A + B*log((e*(c + d*x))/(a + b*x))))/(4*b*d^2) + (B*(b*c - a*d)*g^3*(a + b*x)^3*(A + B*log((e*(c + d*x))/(a + b*x))))/(6*b*d) + (B*(b*c - a*d)^3*g^3*(c + d*x)*(A + B*log((e*(c + d*x))/(a + b*x))))/(2*d^4) + (g^3*(a + b*x)^4*(A + B*log((e*(c + d*x))/(a + b*x)))^2)/(4*b) + (B*(b*c - a*d)^4*g^3*(A + B*log((e*(c + d*x))/(a + b*x)))*log(1 - (d*(a + b*x))/(b*(c + d*x))))/(2*b*d^4) - (B^2*(b*c - a*d)^4*g^3*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(2*b*d^4)]
    @test_int [(a*g + b*g*x)^2*(A + B*log((e*(c + d*x))/(a + b*x)))^2, x, 11, (B^2*(b*c - a*d)^2*g^2*x)/(3*d^2) - (B^2*(b*c - a*d)^3*g^2*log(a + b*x))/(b*d^3) - (B^2*(b*c - a*d)^3*g^2*log((c + d*x)/(a + b*x)))/(3*b*d^3) + (B*(b*c - a*d)*g^2*(a + b*x)^2*(A + B*log((e*(c + d*x))/(a + b*x))))/(3*b*d) - (2*B*(b*c - a*d)^2*g^2*(c + d*x)*(A + B*log((e*(c + d*x))/(a + b*x))))/(3*d^3) + (g^2*(a + b*x)^3*(A + B*log((e*(c + d*x))/(a + b*x)))^2)/(3*b) - (2*B*(b*c - a*d)^3*g^2*(A + B*log((e*(c + d*x))/(a + b*x)))*log(1 - (d*(a + b*x))/(b*(c + d*x))))/(3*b*d^3) + (2*B^2*(b*c - a*d)^3*g^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(3*b*d^3)]
    @test_int [(a*g + b*g*x)^1*(A + B*log((e*(c + d*x))/(a + b*x)))^2, x, 7, (B^2*(b*c - a*d)^2*g*log(a + b*x))/(b*d^2) + (B*(b*c - a*d)*g*(c + d*x)*(A + B*log((e*(c + d*x))/(a + b*x))))/d^2 + (g*(a + b*x)^2*(A + B*log((e*(c + d*x))/(a + b*x)))^2)/(2*b) + (B*(b*c - a*d)^2*g*(A + B*log((e*(c + d*x))/(a + b*x)))*log(1 - (d*(a + b*x))/(b*(c + d*x))))/(b*d^2) - (B^2*(b*c - a*d)^2*g*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^2)]
    @test_int [(A + B*log((e*(c + d*x))/(a + b*x)))^2/(a*g + b*g*x)^1, x, 4, -((log(-((b*c - a*d)/(d*(a + b*x))))*(A + B*log((e*(c + d*x))/(a + b*x)))^2)/(b*g)) - (2*B*(A + B*log((e*(c + d*x))/(a + b*x)))*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(b*g) + (2*B^2*PolyLog(3, (b*(c + d*x))/(d*(a + b*x))))/(b*g)]
    @test_int [(A + B*log((e*(c + d*x))/(a + b*x)))^2/(a*g + b*g*x)^2, x, 4, (2*A*B*(c + d*x))/((b*c - a*d)*g^2*(a + b*x)) - (2*B^2*(c + d*x))/((b*c - a*d)*g^2*(a + b*x)) + (2*B^2*(c + d*x)*log((e*(c + d*x))/(a + b*x)))/((b*c - a*d)*g^2*(a + b*x)) - ((c + d*x)*(A + B*log((e*(c + d*x))/(a + b*x)))^2)/((b*c - a*d)*g^2*(a + b*x))]
    @test_int [(A + B*log((e*(c + d*x))/(a + b*x)))^2/(a*g + b*g*x)^3, x, 8, (-2*A*B*d*(c + d*x))/((b*c - a*d)^2*g^3*(a + b*x)) + (2*B^2*d*(c + d*x))/((b*c - a*d)^2*g^3*(a + b*x)) - (b*B^2*(c + d*x)^2)/(4*(b*c - a*d)^2*g^3*(a + b*x)^2) - (2*B^2*d*(c + d*x)*log((e*(c + d*x))/(a + b*x)))/((b*c - a*d)^2*g^3*(a + b*x)) + (b*B*(c + d*x)^2*(A + B*log((e*(c + d*x))/(a + b*x))))/(2*(b*c - a*d)^2*g^3*(a + b*x)^2) + (d*(c + d*x)*(A + B*log((e*(c + d*x))/(a + b*x)))^2)/((b*c - a*d)^2*g^3*(a + b*x)) - (b*(c + d*x)^2*(A + B*log((e*(c + d*x))/(a + b*x)))^2)/(2*(b*c - a*d)^2*g^3*(a + b*x)^2)]
    @test_int [(A + B*log((e*(c + d*x))/(a + b*x)))^2/(a*g + b*g*x)^4, x, 6, -((2*B^2*d^2*(c + d*x))/((b*c - a*d)^3*g^4*(a + b*x))) + (b*B^2*d*(c + d*x)^2)/(2*(b*c - a*d)^3*g^4*(a + b*x)^2) - (2*b^2*B^2*(c + d*x)^3)/(27*(b*c - a*d)^3*g^4*(a + b*x)^3) + (B^2*d^3*log((c + d*x)/(a + b*x))^2)/(3*b*(b*c - a*d)^3*g^4) + (2*B*d^2*(c + d*x)*(A + B*log((e*(c + d*x))/(a + b*x))))/((b*c - a*d)^3*g^4*(a + b*x)) - (b*B*d*(c + d*x)^2*(A + B*log((e*(c + d*x))/(a + b*x))))/((b*c - a*d)^3*g^4*(a + b*x)^2) + (2*b^2*B*(c + d*x)^3*(A + B*log((e*(c + d*x))/(a + b*x))))/(9*(b*c - a*d)^3*g^4*(a + b*x)^3) - (2*B*d^3*log((c + d*x)/(a + b*x))*(A + B*log((e*(c + d*x))/(a + b*x))))/(3*b*(b*c - a*d)^3*g^4) - (A + B*log((e*(c + d*x))/(a + b*x)))^2/(3*b*g^4*(a + b*x)^3)]
    @test_int [(A + B*log((e*(c + d*x))/(a + b*x)))^2/(a*g + b*g*x)^5, x, 5, (2*B^2*d^3*(c + d*x))/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*B^2*d^2*(c + d*x)^2)/(4*(b*c - a*d)^4*g^5*(a + b*x)^2) + (2*b^2*B^2*d*(c + d*x)^3)/(9*(b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*B^2*(c + d*x)^4)/(32*(b*c - a*d)^4*g^5*(a + b*x)^4) - (B^2*d^4*log((c + d*x)/(a + b*x))^2)/(4*b*(b*c - a*d)^4*g^5) - (2*B*d^3*(c + d*x)*(A + B*log((e*(c + d*x))/(a + b*x))))/((b*c - a*d)^4*g^5*(a + b*x)) + (3*b*B*d^2*(c + d*x)^2*(A + B*log((e*(c + d*x))/(a + b*x))))/(2*(b*c - a*d)^4*g^5*(a + b*x)^2) - (2*b^2*B*d*(c + d*x)^3*(A + B*log((e*(c + d*x))/(a + b*x))))/(3*(b*c - a*d)^4*g^5*(a + b*x)^3) + (b^3*B*(c + d*x)^4*(A + B*log((e*(c + d*x))/(a + b*x))))/(8*(b*c - a*d)^4*g^5*(a + b*x)^4) + (B*d^4*log((c + d*x)/(a + b*x))*(A + B*log((e*(c + d*x))/(a + b*x))))/(2*b*(b*c - a*d)^4*g^5) - (A + B*log((e*(c + d*x))/(a + b*x)))^2/(4*b*g^5*(a + b*x)^4)]

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [(a*g + b*g*x)^2/(A + B*log((e*(c + d*x))/(a + b*x))), x, 0, Unintegrable((a*g + b*g*x)^2/(A + B*log((e*(c + d*x))/(a + b*x))), x)]
    @test_int [(a*g + b*g*x)^1/(A + B*log((e*(c + d*x))/(a + b*x))), x, 0, Unintegrable((a*g + b*g*x)/(A + B*log((e*(c + d*x))/(a + b*x))), x)]
    @test_int [1/((a*g + b*g*x)^1*(A + B*log((e*(c + d*x))/(a + b*x)))), x, 0, Unintegrable(1/((a*g + b*g*x)*(A + B*log((e*(c + d*x))/(a + b*x)))), x)]
    @test_int [1/((a*g + b*g*x)^2*(A + B*log((e*(c + d*x))/(a + b*x)))), x, 3, -(ExpIntegralEi((A + B*log((e*(c + d*x))/(a + b*x)))/B)/(B*(b*c - a*d)*e*ℯ^(A/B)*g^2))]
    @test_int [1/((a*g + b*g*x)^3*(A + B*log((e*(c + d*x))/(a + b*x)))), x, 7, (d*ExpIntegralEi((A + B*log((e*(c + d*x))/(a + b*x)))/B))/(B*(b*c - a*d)^2*e*ℯ^(A/B)*g^3) - (b*ExpIntegralEi((2*(A + B*log((e*(c + d*x))/(a + b*x))))/B))/(B*(b*c - a*d)^2*e^2*ℯ^((2*A)/B)*g^3)]

    @test_int [(a*g + b*g*x)^2/(A + B*log((e*(c + d*x))/(a + b*x)))^2, x, 0, Unintegrable((a*g + b*g*x)^2/(A + B*log((e*(c + d*x))/(a + b*x)))^2, x)]
    @test_int [(a*g + b*g*x)^1/(A + B*log((e*(c + d*x))/(a + b*x)))^2, x, 0, Unintegrable((a*g + b*g*x)/(A + B*log((e*(c + d*x))/(a + b*x)))^2, x)]
    @test_int [1/((a*g + b*g*x)^1*(A + B*log((e*(c + d*x))/(a + b*x)))^2), x, 0, Unintegrable(1/((a*g + b*g*x)*(A + B*log((e*(c + d*x))/(a + b*x)))^2), x)]
    @test_int [1/((a*g + b*g*x)^2*(A + B*log((e*(c + d*x))/(a + b*x)))^2), x, 4, -(ExpIntegralEi((A + B*log((e*(c + d*x))/(a + b*x)))/B)/(B^2*(b*c - a*d)*e*ℯ^(A/B)*g^2)) + (c + d*x)/(B*(b*c - a*d)*g^2*(a + b*x)*(A + B*log((e*(c + d*x))/(a + b*x))))]
    @test_int [1/((a*g + b*g*x)^3*(A + B*log((e*(c + d*x))/(a + b*x)))^2), x, 10, (d*ExpIntegralEi((A + B*log((e*(c + d*x))/(a + b*x)))/B))/(ℯ^(A/B)*(B^2*(b*c - a*d)^2*e*g^3)) - (2*b*ExpIntegralEi((2*(A + B*log((e*(c + d*x))/(a + b*x))))/B))/(ℯ^((2*A)/B)*(B^2*(b*c - a*d)^2*e^2*g^3)) + (c + d*x)/(B*(b*c - a*d)*g^3*(a + b*x)^2*(A + B*log((e*(c + d*x))/(a + b*x))))]

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^2/(c+d*x)^2))^p*when*d*f-c*g=0=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(a*g + b*g*x)^4*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)), x, 4, (-2*B*(b*c - a*d)^4*g^4*x)/(5*d^4) + (B*(b*c - a*d)^3*g^4*(a + b*x)^2)/(5*b*d^3) - (2*B*(b*c - a*d)^2*g^4*(a + b*x)^3)/(15*b*d^2) + (B*(b*c - a*d)*g^4*(a + b*x)^4)/(10*b*d) + (2*B*(b*c - a*d)^5*g^4*log(c + d*x))/(5*b*d^5) + (g^4*(a + b*x)^5*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(5*b)]
    @test_int [(a*g + b*g*x)^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)), x, 4, (B*(b*c - a*d)^3*g^3*x)/(2*d^3) - (B*(b*c - a*d)^2*g^3*(a + b*x)^2)/(4*b*d^2) + (B*(b*c - a*d)*g^3*(a + b*x)^3)/(6*b*d) - (B*(b*c - a*d)^4*g^3*log(c + d*x))/(2*b*d^4) + (g^3*(a + b*x)^4*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(4*b)]
    @test_int [(a*g + b*g*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)), x, 4, (-2*B*(b*c - a*d)^2*g^2*x)/(3*d^2) + (B*(b*c - a*d)*g^2*(a + b*x)^2)/(3*b*d) + (2*B*(b*c - a*d)^3*g^2*log(c + d*x))/(3*b*d^3) + (g^2*(a + b*x)^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(3*b)]
    @test_int [(a*g + b*g*x)^1*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)), x, 4, (B*(b*c - a*d)*g*x)/d - (B*(b*c - a*d)^2*g*log(c + d*x))/(b*d^2) + (g*(a + b*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(2*b)]
    @test_int [(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(a*g + b*g*x)^1, x, 5, -((log(-((b*c - a*d)/(d*(a + b*x))))*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(b*g)) - (2*B*PolyLog(2, 1 + (b*c - a*d)/(d*(a + b*x))))/(b*g)]
    @test_int [(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(a*g + b*g*x)^2, x, 3, -((A*(c + d*x))/((b*c - a*d)*g^2*(a + b*x))) + (2*B*(c + d*x))/((b*c - a*d)*g^2*(a + b*x)) - (B*(c + d*x)*log((e*(c + d*x)^2)/(a + b*x)^2))/((b*c - a*d)*g^2*(a + b*x))]
    @test_int [(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(a*g + b*g*x)^3, x, 4, B/(2*b*g^3*(a + b*x)^2) - (B*d)/(b*(b*c - a*d)*g^3*(a + b*x)) - (B*d^2*log(a + b*x))/(b*(b*c - a*d)^2*g^3) + (B*d^2*log(c + d*x))/(b*(b*c - a*d)^2*g^3) - (A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(2*b*g^3*(a + b*x)^2)]
    @test_int [(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(a*g + b*g*x)^4, x, 4, (2*B)/(9*b*g^4*(a + b*x)^3) - (B*d)/(3*b*(b*c - a*d)*g^4*(a + b*x)^2) + (2*B*d^2)/(3*b*(b*c - a*d)^2*g^4*(a + b*x)) + (2*B*d^3*log(a + b*x))/(3*b*(b*c - a*d)^3*g^4) - (2*B*d^3*log(c + d*x))/(3*b*(b*c - a*d)^3*g^4) - (A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(3*b*g^4*(a + b*x)^3)]
    @test_int [(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(a*g + b*g*x)^5, x, 4, B/(8*b*g^5*(a + b*x)^4) - (B*d)/(6*b*(b*c - a*d)*g^5*(a + b*x)^3) + (B*d^2)/(4*b*(b*c - a*d)^2*g^5*(a + b*x)^2) - (B*d^3)/(2*b*(b*c - a*d)^3*g^5*(a + b*x)) - (B*d^4*log(a + b*x))/(2*b*(b*c - a*d)^4*g^5) + (B*d^4*log(c + d*x))/(2*b*(b*c - a*d)^4*g^5) - (A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(4*b*g^5*(a + b*x)^4)]

    @test_int [(a*g + b*g*x)^4*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2, x, 19, (26*B^2*(b*c - a*d)^4*g^4*x)/(15*d^4) - (7*B^2*(b*c - a*d)^3*g^4*(a + b*x)^2)/(15*b*d^3) + (2*B^2*(b*c - a*d)^2*g^4*(a + b*x)^3)/(15*b*d^2) - (10*B^2*(b*c - a*d)^5*g^4*log(a + b*x))/(3*b*d^5) - (26*B^2*(b*c - a*d)^5*g^4*log((c + d*x)/(a + b*x)))/(15*b*d^5) + (2*B*(b*c - a*d)^3*g^4*(a + b*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(5*b*d^3) - (4*B*(b*c - a*d)^2*g^4*(a + b*x)^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(15*b*d^2) + (B*(b*c - a*d)*g^4*(a + b*x)^4*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(5*b*d) - (4*B*(b*c - a*d)^4*g^4*(c + d*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(5*d^5) + (g^4*(a + b*x)^5*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2)/(5*b) - (4*B*(b*c - a*d)^5*g^4*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))*log(1 - (d*(a + b*x))/(b*(c + d*x))))/(5*b*d^5) + (8*B^2*(b*c - a*d)^5*g^4*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(5*b*d^5)]
    @test_int [(a*g + b*g*x)^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2, x, 15, -((5*B^2*(b*c - a*d)^3*g^3*x)/(3*d^3)) + (B^2*(b*c - a*d)^2*g^3*(a + b*x)^2)/(3*b*d^2) + (11*B^2*(b*c - a*d)^4*g^3*log(a + b*x))/(3*b*d^4) + (5*B^2*(b*c - a*d)^4*g^3*log((c + d*x)/(a + b*x)))/(3*b*d^4) - (B*(b*c - a*d)^2*g^3*(a + b*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(2*b*d^2) + (B*(b*c - a*d)*g^3*(a + b*x)^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(3*b*d) + (B*(b*c - a*d)^3*g^3*(c + d*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/d^4 + (g^3*(a + b*x)^4*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2)/(4*b) + (B*(b*c - a*d)^4*g^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))*log(1 - (d*(a + b*x))/(b*(c + d*x))))/(b*d^4) - (2*B^2*(b*c - a*d)^4*g^3*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^4)]
    @test_int [(a*g + b*g*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2, x, 11, (4*B^2*(b*c - a*d)^2*g^2*x)/(3*d^2) - (4*B^2*(b*c - a*d)^3*g^2*log(a + b*x))/(b*d^3) - (4*B^2*(b*c - a*d)^3*g^2*log((c + d*x)/(a + b*x)))/(3*b*d^3) + (2*B*(b*c - a*d)*g^2*(a + b*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(3*b*d) - (4*B*(b*c - a*d)^2*g^2*(c + d*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(3*d^3) + (g^2*(a + b*x)^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2)/(3*b) - (4*B*(b*c - a*d)^3*g^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))*log(1 - (d*(a + b*x))/(b*(c + d*x))))/(3*b*d^3) + (8*B^2*(b*c - a*d)^3*g^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(3*b*d^3)]
    @test_int [(a*g + b*g*x)^1*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2, x, 7, (4*B^2*(b*c - a*d)^2*g*log(a + b*x))/(b*d^2) + (2*B*(b*c - a*d)*g*(c + d*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/d^2 + (g*(a + b*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2)/(2*b) + (2*B*(b*c - a*d)^2*g*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))*log(1 - (d*(a + b*x))/(b*(c + d*x))))/(b*d^2) - (4*B^2*(b*c - a*d)^2*g*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d^2)]
    @test_int [(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2/(a*g + b*g*x)^1, x, 4, -((log(-((b*c - a*d)/(d*(a + b*x))))*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2)/(b*g)) - (4*B*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(b*g) + (8*B^2*PolyLog(3, (b*(c + d*x))/(d*(a + b*x))))/(b*g)]
    @test_int [(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2/(a*g + b*g*x)^2, x, 4, (4*A*B*(c + d*x))/((b*c - a*d)*g^2*(a + b*x)) - (8*B^2*(c + d*x))/((b*c - a*d)*g^2*(a + b*x)) + (4*B^2*(c + d*x)*log((e*(c + d*x)^2)/(a + b*x)^2))/((b*c - a*d)*g^2*(a + b*x)) - ((c + d*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2)/((b*c - a*d)*g^2*(a + b*x))]
    @test_int [(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2/(a*g + b*g*x)^3, x, 8, (-4*A*B*d*(c + d*x))/((b*c - a*d)^2*g^3*(a + b*x)) + (8*B^2*d*(c + d*x))/((b*c - a*d)^2*g^3*(a + b*x)) - (b*B^2*(c + d*x)^2)/((b*c - a*d)^2*g^3*(a + b*x)^2) - (4*B^2*d*(c + d*x)*log((e*(c + d*x)^2)/(a + b*x)^2))/((b*c - a*d)^2*g^3*(a + b*x)) + (b*B*(c + d*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/((b*c - a*d)^2*g^3*(a + b*x)^2) + (d*(c + d*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2)/((b*c - a*d)^2*g^3*(a + b*x)) - (b*(c + d*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2)/(2*(b*c - a*d)^2*g^3*(a + b*x)^2)]
    @test_int [(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2/(a*g + b*g*x)^4, x, 6, -((8*B^2*d^2*(c + d*x))/((b*c - a*d)^3*g^4*(a + b*x))) + (2*b*B^2*d*(c + d*x)^2)/((b*c - a*d)^3*g^4*(a + b*x)^2) - (8*b^2*B^2*(c + d*x)^3)/(27*(b*c - a*d)^3*g^4*(a + b*x)^3) + (4*B^2*d^3*log((c + d*x)/(a + b*x))^2)/(3*b*(b*c - a*d)^3*g^4) + (4*B*d^2*(c + d*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/((b*c - a*d)^3*g^4*(a + b*x)) - (2*b*B*d*(c + d*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/((b*c - a*d)^3*g^4*(a + b*x)^2) + (4*b^2*B*(c + d*x)^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(9*(b*c - a*d)^3*g^4*(a + b*x)^3) - (4*B*d^3*log((c + d*x)/(a + b*x))*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(3*b*(b*c - a*d)^3*g^4) - (A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2/(3*b*g^4*(a + b*x)^3)]
    @test_int [(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2/(a*g + b*g*x)^5, x, 5, (8*B^2*d^3*(c + d*x))/((b*c - a*d)^4*g^5*(a + b*x)) - (3*b*B^2*d^2*(c + d*x)^2)/((b*c - a*d)^4*g^5*(a + b*x)^2) + (8*b^2*B^2*d*(c + d*x)^3)/(9*(b*c - a*d)^4*g^5*(a + b*x)^3) - (b^3*B^2*(c + d*x)^4)/(8*(b*c - a*d)^4*g^5*(a + b*x)^4) - (B^2*d^4*log((c + d*x)/(a + b*x))^2)/(b*(b*c - a*d)^4*g^5) - (4*B*d^3*(c + d*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/((b*c - a*d)^4*g^5*(a + b*x)) + (3*b*B*d^2*(c + d*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/((b*c - a*d)^4*g^5*(a + b*x)^2) - (4*b^2*B*d*(c + d*x)^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(3*(b*c - a*d)^4*g^5*(a + b*x)^3) + (b^3*B*(c + d*x)^4*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(4*(b*c - a*d)^4*g^5*(a + b*x)^4) + (B*d^4*log((c + d*x)/(a + b*x))*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))/(b*(b*c - a*d)^4*g^5) - (A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2/(4*b*g^5*(a + b*x)^4)]

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [(a*g + b*g*x)^2/(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)), x, 0, Unintegrable((a*g + b*g*x)^2/(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)), x)]
    @test_int [(a*g + b*g*x)^1/(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)), x, 0, Unintegrable((a*g + b*g*x)/(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)), x)]
    @test_int [1/((a*g + b*g*x)^1*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))), x, 0, Unintegrable(1/((a*g + b*g*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))), x)]
    @test_int [1/((a*g + b*g*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))), x, 3, -((c + d*x)*ExpIntegralEi((A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(2*B)))/(2*B*(b*c - a*d)*ℯ^(A/(2*B))*g^2*(a + b*x)*sqrt((e*(c + d*x)^2)/(a + b*x)^2))]
    @test_int [1/((a*g + b*g*x)^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))), x, 7, (d*(c + d*x)*ExpIntegralEi((A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(2*B)))/(2*B*(b*c - a*d)^2*ℯ^(A/(2*B))*g^3*(a + b*x)*sqrt((e*(c + d*x)^2)/(a + b*x)^2)) - (b*ExpIntegralEi((A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/B))/(2*B*(b*c - a*d)^2*e*ℯ^(A/B)*g^3)]

    @test_int [(a*g + b*g*x)^2/(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2, x, 0, Unintegrable((a*g + b*g*x)^2/(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2, x)]
    @test_int [(a*g + b*g*x)^1/(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2, x, 0, Unintegrable((a*g + b*g*x)/(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2, x)]
    @test_int [1/((a*g + b*g*x)^1*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2), x, 0, Unintegrable(1/((a*g + b*g*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2), x)]
    @test_int [1/((a*g + b*g*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2), x, 4, -((c + d*x)*ExpIntegralEi((A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(2*B)))/(4*B^2*(b*c - a*d)*ℯ^(A/(2*B))*g^2*(a + b*x)*sqrt((e*(c + d*x)^2)/(a + b*x)^2)) + (c + d*x)/(2*B*(b*c - a*d)*g^2*(a + b*x)*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))]
    @test_int [1/((a*g + b*g*x)^3*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2))^2), x, 10, (d*(c + d*x)*ExpIntegralEi((A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(2*B)))/(ℯ^(A/(2*B))*(4*B^2*(b*c - a*d)^2*g^3*(a + b*x)*sqrt((e*(c + d*x)^2)/(a + b*x)^2))) - (b*ExpIntegralEi((A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/B))/(ℯ^(A/B)*(2*B^2*(b*c - a*d)^2*e*g^3)) + (c + d*x)/(2*B*(b*c - a*d)*g^3*(a + b*x)^2*(A + B*log((e*(c + d*x)^2)/(a + b*x)^2)))]

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^n/(c+d*x)^n))^p*when*d*f-c*g=0=#

    #= ::Subsubsection:: =#
    #=p>0=#

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [1/((a*g + b*g*x)^2*(A + B*log(e*(a + b*x)^n/(c + d*x)^n))), x, 4, (ℯ^(A/(B*n))*(c + d*x)*((e*(a + b*x)^n)/(c + d*x)^n)^(1/n)*ExpIntegralEi(-((A + B*log((e*(a + b*x)^n)/(c + d*x)^n))/(B*n))))/(B*(b*c - a*d)*g^2*n*(a + b*x))]

    #= ::Section::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^n/(c+d*x)^n))^p=#

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^1/(c+d*x)^1))^p=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(f + g*x)^4*(A + B*log((e*(a + b*x))/(c + d*x))), x, 3, (B*(b*c - a*d)*g*(a^3*d^3*g^3 - a^2*b*d^2*g^2*(5*d*f - c*g) + a*b^2*d*g*(10*d^2*f^2 - 5*c*d*f*g + c^2*g^2) - b^3*(10*d^3*f^3 - 10*c*d^2*f^2*g + 5*c^2*d*f*g^2 - c^3*g^3))*x)/(5*b^4*d^4) - (B*(b*c - a*d)*g^2*(a^2*d^2*g^2 - a*b*d*g*(5*d*f - c*g) + b^2*(10*d^2*f^2 - 5*c*d*f*g + c^2*g^2))*x^2)/(10*b^3*d^3) - (B*(b*c - a*d)*g^3*(5*b*d*f - b*c*g - a*d*g)*x^3)/(15*b^2*d^2) - (B*(b*c - a*d)*g^4*x^4)/(20*b*d) - (B*(b*f - a*g)^5*log(a + b*x))/(5*b^5*g) + ((f + g*x)^5*(A + B*log((e*(a + b*x))/(c + d*x))))/(5*g) + (B*(d*f - c*g)^5*log(c + d*x))/(5*d^5*g)]
    @test_int [(f + g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x))), x, 3, -(B*(b*c - a*d)*g*(a^2*d^2*g^2 - a*b*d*g*(4*d*f - c*g) + b^2*(6*d^2*f^2 - 4*c*d*f*g + c^2*g^2))*x)/(4*b^3*d^3) - (B*(b*c - a*d)*g^2*(4*b*d*f - b*c*g - a*d*g)*x^2)/(8*b^2*d^2) - (B*(b*c - a*d)*g^3*x^3)/(12*b*d) - (B*(b*f - a*g)^4*log(a + b*x))/(4*b^4*g) + ((f + g*x)^4*(A + B*log((e*(a + b*x))/(c + d*x))))/(4*g) + (B*(d*f - c*g)^4*log(c + d*x))/(4*d^4*g)]
    @test_int [(f + g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))), x, 3, -(B*(b*c - a*d)*g*(3*b*d*f - b*c*g - a*d*g)*x)/(3*b^2*d^2) - (B*(b*c - a*d)*g^2*x^2)/(6*b*d) - (B*(b*f - a*g)^3*log(a + b*x))/(3*b^3*g) + ((f + g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x))))/(3*g) + (B*(d*f - c*g)^3*log(c + d*x))/(3*d^3*g)]
    @test_int [(f + g*x)^1*(A + B*log((e*(a + b*x))/(c + d*x))), x, 3, -(B*(b*c - a*d)*g*x)/(2*b*d) - (B*(b*f - a*g)^2*log(a + b*x))/(2*b^2*g) + ((f + g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))/(2*g) + (B*(d*f - c*g)^2*log(c + d*x))/(2*d^2*g)]
    @test_int [(f + g*x)^0*(A + B*log((e*(a + b*x))/(c + d*x))), x, 3, A*x + (B*(a + b*x)*log((e*(a + b*x))/(c + d*x)))/b - (B*(b*c - a*d)*log(c + d*x))/(b*d)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))/(f + g*x)^1, x, 7, -((B*log(-((g*(a + b*x))/(b*f - a*g)))*log(f + g*x))/g) + ((A + B*log((e*(a + b*x))/(c + d*x)))*log(f + g*x))/g + (B*log(-((g*(c + d*x))/(d*f - c*g)))*log(f + g*x))/g - (B*PolyLog(2, (b*(f + g*x))/(b*f - a*g)))/g + (B*PolyLog(2, (d*(f + g*x))/(d*f - c*g)))/g]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))/(f + g*x)^2, x, 3, ((a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/((b*f - a*g)*(f + g*x)) + (B*(b*c - a*d)*log((f + g*x)/(c + d*x)))/((b*f - a*g)*(d*f - c*g))]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))/(f + g*x)^3, x, 3, -(B*(b*c - a*d))/(2*(b*f - a*g)*(d*f - c*g)*(f + g*x)) + (b^2*B*log(a + b*x))/(2*g*(b*f - a*g)^2) - (A + B*log((e*(a + b*x))/(c + d*x)))/(2*g*(f + g*x)^2) - (B*d^2*log(c + d*x))/(2*g*(d*f - c*g)^2) + (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*log(f + g*x))/(2*(b*f - a*g)^2*(d*f - c*g)^2)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))/(f + g*x)^4, x, 3, -(B*(b*c - a*d))/(6*(b*f - a*g)*(d*f - c*g)*(f + g*x)^2) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g))/(3*(b*f - a*g)^2*(d*f - c*g)^2*(f + g*x)) + (b^3*B*log(a + b*x))/(3*g*(b*f - a*g)^3) - (A + B*log((e*(a + b*x))/(c + d*x)))/(3*g*(f + g*x)^3) - (B*d^3*log(c + d*x))/(3*g*(d*f - c*g)^3) + (B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*log(f + g*x))/(3*(b*f - a*g)^3*(d*f - c*g)^3)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))/(f + g*x)^5, x, 3, -(B*(b*c - a*d))/(12*(b*f - a*g)*(d*f - c*g)*(f + g*x)^3) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g))/(8*(b*f - a*g)^2*(d*f - c*g)^2*(f + g*x)^2) - (B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2)))/(4*(b*f - a*g)^3*(d*f - c*g)^3*(f + g*x)) + (b^4*B*log(a + b*x))/(4*g*(b*f - a*g)^4) - (A + B*log((e*(a + b*x))/(c + d*x)))/(4*g*(f + g*x)^4) - (B*d^4*log(c + d*x))/(4*g*(d*f - c*g)^4) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*log(f + g*x))/(4*(b*f - a*g)^4*(d*f - c*g)^4)]

    @test_int [(f + g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 15, (B^2*(b*c - a*d)^3*g^3*x)/(6*b^3*d^3) + (B^2*(b*c - a*d)^2*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*x)/(4*b^3*d^3) + (B^2*(b*c - a*d)^2*g^3*(c + d*x)^2)/(12*b^2*d^4) + (B^2*(b*c - a*d)^4*g^3*log((a + b*x)/(c + d*x)))/(6*b^4*d^4) + (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*log((a + b*x)/(c + d*x)))/(4*b^4*d^4) - (B*(b*c - a*d)*g*(a^2*d^2*g^2 - 2*a*b*d*g*(2*d*f - c*g) + b^2*(6*d^2*f^2 - 8*c*d*f*g + 3*c^2*g^2))*(a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/(2*b^4*d^3) - (B*(b*c - a*d)*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*(c + d*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))/(4*b^2*d^4) - (B*(b*c - a*d)*g^3*(c + d*x)^3*(A + B*log((e*(a + b*x))/(c + d*x))))/(6*b*d^4) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x))/(c + d*x))))/(2*b^4*d^4) - ((b*f - a*g)^4*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(4*b^4*g) + ((f + g*x)^4*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(4*g) + (B^2*(b*c - a*d)^4*g^3*log(c + d*x))/(6*b^4*d^4) + (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*log(c + d*x))/(4*b^4*d^4) + (B^2*(b*c - a*d)^2*g*(a^2*d^2*g^2 - 2*a*b*d*g*(2*d*f - c*g) + b^2*(6*d^2*f^2 - 8*c*d*f*g + 3*c^2*g^2))*log(c + d*x))/(2*b^4*d^4) - (B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(2*b^4*d^4)]
    @test_int [(f + g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 12, (B^2*(b*c - a*d)^2*g^2*x)/(3*b^2*d^2) + (B^2*(b*c - a*d)^3*g^2*log((a + b*x)/(c + d*x)))/(3*b^3*d^3) - (2*B*(b*c - a*d)*g*(3*b*d*f - 2*b*c*g - a*d*g)*(a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/(3*b^3*d^2) - (B*(b*c - a*d)*g^2*(c + d*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))/(3*b*d^3) + (2*B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x))/(c + d*x))))/(3*b^3*d^3) - ((b*f - a*g)^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(3*b^3*g) + ((f + g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(3*g) + (B^2*(b*c - a*d)^3*g^2*log(c + d*x))/(3*b^3*d^3) + (2*B^2*(b*c - a*d)^2*g*(3*b*d*f - 2*b*c*g - a*d*g)*log(c + d*x))/(3*b^3*d^3) + (2*B^2*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(3*b^3*d^3)]
    @test_int [(f + g*x)^1*(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 9, -((B*(b*c - a*d)*g*(a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/(b^2*d)) + (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x))/(c + d*x))))/(b^2*d^2) - ((b*f - a*g)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(2*b^2*g) + ((f + g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(2*g) + (B^2*(b*c - a*d)^2*g*log(c + d*x))/(b^2*d^2) + (B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b^2*d^2)]
    @test_int [(f + g*x)^0*(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 6, (2*B*(b*c - a*d)*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x))/(c + d*x))))/(b*d) + ((a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/b + (2*B^2*(b*c - a*d)*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))^2/(f + g*x)^1, x, 9, -((log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/g) + ((A + B*log((e*(a + b*x))/(c + d*x)))^2*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/g - (2*B*(A + B*log((e*(a + b*x))/(c + d*x)))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/g + (2*B*(A + B*log((e*(a + b*x))/(c + d*x)))*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/g + (2*B^2*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/g - (2*B^2*PolyLog(3, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/g]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))^2/(f + g*x)^2, x, 4, ((a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/((b*f - a*g)*(f + g*x)) + (2*B*(b*c - a*d)*(A + B*log((e*(a + b*x))/(c + d*x)))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)*(d*f - c*g)) + (2*B^2*(b*c - a*d)*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)*(d*f - c*g))]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))^2/(f + g*x)^3, x, 9, (B*(b*c - a*d)*g*(a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/((b*f - a*g)^2*(d*f - c*g)*(f + g*x)) + (b^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(2*g*(b*f - a*g)^2) - (A + B*log((e*(a + b*x))/(c + d*x)))^2/(2*g*(f + g*x)^2) + (B^2*(b*c - a*d)^2*g*log((f + g*x)/(c + d*x)))/((b*f - a*g)^2*(d*f - c*g)^2) + (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(A + B*log((e*(a + b*x))/(c + d*x)))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)^2*(d*f - c*g)^2) + (B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)^2*(d*f - c*g)^2)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))^2/(f + g*x)^4, x, 12, (B^2*(b*c - a*d)^2*g^2*(c + d*x))/(3*(b*f - a*g)^2*(d*f - c*g)^3*(f + g*x)) + (B^2*(b*c - a*d)^3*g^2*log((a + b*x)/(c + d*x)))/(3*(b*f - a*g)^3*(d*f - c*g)^3) - (B*(b*c - a*d)*g^2*(c + d*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))/(3*(b*f - a*g)*(d*f - c*g)^3*(f + g*x)^2) + (2*B*(b*c - a*d)*g*(3*b*d*f - b*c*g - 2*a*d*g)*(a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/(3*(b*f - a*g)^3*(d*f - c*g)^2*(f + g*x)) + (b^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(3*g*(b*f - a*g)^3) - (A + B*log((e*(a + b*x))/(c + d*x)))^2/(3*g*(f + g*x)^3) - (B^2*(b*c - a*d)^3*g^2*log((f + g*x)/(c + d*x)))/(3*(b*f - a*g)^3*(d*f - c*g)^3) + (2*B^2*(b*c - a*d)^2*g*(3*b*d*f - b*c*g - 2*a*d*g)*log((f + g*x)/(c + d*x)))/(3*(b*f - a*g)^3*(d*f - c*g)^3) + (2*B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*(A + B*log((e*(a + b*x))/(c + d*x)))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/(3*(b*f - a*g)^3*(d*f - c*g)^3) + (2*B^2*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/(3*(b*f - a*g)^3*(d*f - c*g)^3)]
    @test_int [(A + B*log((e*(a + b*x))/(c + d*x)))^2/(f + g*x)^5, x, 15, -((B^2*(b*c - a*d)^2*g^3*(c + d*x)^2)/(12*(b*f - a*g)^2*(d*f - c*g)^4*(f + g*x)^2)) - (B^2*(b*c - a*d)^3*g^3*(c + d*x))/(6*(b*f - a*g)^3*(d*f - c*g)^4*(f + g*x)) + (B^2*(b*c - a*d)^2*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*(c + d*x))/(4*(b*f - a*g)^3*(d*f - c*g)^4*(f + g*x)) - (B^2*(b*c - a*d)^4*g^3*log((a + b*x)/(c + d*x)))/(6*(b*f - a*g)^4*(d*f - c*g)^4) + (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*log((a + b*x)/(c + d*x)))/(4*(b*f - a*g)^4*(d*f - c*g)^4) + (B*(b*c - a*d)*g^3*(c + d*x)^3*(A + B*log((e*(a + b*x))/(c + d*x))))/(6*(b*f - a*g)*(d*f - c*g)^4*(f + g*x)^3) - (B*(b*c - a*d)*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*(c + d*x)^2*(A + B*log((e*(a + b*x))/(c + d*x))))/(4*(b*f - a*g)^2*(d*f - c*g)^4*(f + g*x)^2) + (B*(b*c - a*d)*g*(3*a^2*d^2*g^2 - 2*a*b*d*g*(4*d*f - c*g) + b^2*(6*d^2*f^2 - 4*c*d*f*g + c^2*g^2))*(a + b*x)*(A + B*log((e*(a + b*x))/(c + d*x))))/(2*(b*f - a*g)^4*(d*f - c*g)^3*(f + g*x)) + (b^4*(A + B*log((e*(a + b*x))/(c + d*x)))^2)/(4*g*(b*f - a*g)^4) - (A + B*log((e*(a + b*x))/(c + d*x)))^2/(4*g*(f + g*x)^4) + (B^2*(b*c - a*d)^4*g^3*log((f + g*x)/(c + d*x)))/(6*(b*f - a*g)^4*(d*f - c*g)^4) - (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*log((f + g*x)/(c + d*x)))/(4*(b*f - a*g)^4*(d*f - c*g)^4) + (B^2*(b*c - a*d)^2*g*(3*a^2*d^2*g^2 - 2*a*b*d*g*(4*d*f - c*g) + b^2*(6*d^2*f^2 - 4*c*d*f*g + c^2*g^2))*log((f + g*x)/(c + d*x)))/(2*(b*f - a*g)^4*(d*f - c*g)^4) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*(A + B*log((e*(a + b*x))/(c + d*x)))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/(2*(b*f - a*g)^4*(d*f - c*g)^4) - (B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/(2*(b*f - a*g)^4*(d*f - c*g)^4)]

    @test_int [log((1 + x)/(-1 + x))/x^2, x, 3, 2*log(-(x/(1 - x))) - ((1 + x)*log(-((1 + x)/(1 - x))))/x]

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [(f + g*x)^2/(A + B*log((e*(a + b*x))/(c + d*x))), x, 0, Unintegrable((f + g*x)^2/(A + B*log((e*(a + b*x))/(c + d*x))), x)]
    @test_int [(f + g*x)^1/(A + B*log((e*(a + b*x))/(c + d*x))), x, 0, Unintegrable((f + g*x)/(A + B*log((e*(a + b*x))/(c + d*x))), x)]
    @test_int [(f + g*x)^0/(A + B*log((e*(a + b*x))/(c + d*x))), x, 0, Unintegrable((A + B*log((e*(a + b*x))/(c + d*x)))^(-1), x)]
    @test_int [1/((f + g*x)^1*(A + B*log((e*(a + b*x))/(c + d*x)))), x, 0, Unintegrable(1/((f + g*x)*(A + B*log((e*(a + b*x))/(c + d*x)))), x)]
    @test_int [1/((f + g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))), x, 0, Unintegrable(1/((f + g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))), x)]
    @test_int [1/((f + g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))), x, 0, Unintegrable(1/((f + g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))), x)]

    @test_int [(f + g*x)^2/(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 0, Unintegrable((f + g*x)^2/(A + B*log((e*(a + b*x))/(c + d*x)))^2, x)]
    @test_int [(f + g*x)^1/(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 0, Unintegrable((f + g*x)/(A + B*log((e*(a + b*x))/(c + d*x)))^2, x)]
    @test_int [(f + g*x)^0/(A + B*log((e*(a + b*x))/(c + d*x)))^2, x, 0, Unintegrable((A + B*log((e*(a + b*x))/(c + d*x)))^(-2), x)]
    @test_int [1/((f + g*x)^1*(A + B*log((e*(a + b*x))/(c + d*x)))^2), x, 0, Unintegrable(1/((f + g*x)*(A + B*log((e*(a + b*x))/(c + d*x)))^2), x)]
    @test_int [1/((f + g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2), x, 0, Unintegrable(1/((f + g*x)^2*(A + B*log((e*(a + b*x))/(c + d*x)))^2), x)]
    @test_int [1/((f + g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2), x, 0, Unintegrable(1/((f + g*x)^3*(A + B*log((e*(a + b*x))/(c + d*x)))^2), x)]

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^2/(c+d*x)^2))^p=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(f + g*x)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 3, (2*B*(b*c - a*d)*g*(a^3*d^3*g^3 - a^2*b*d^2*g^2*(5*d*f - c*g) + a*b^2*d*g*(10*d^2*f^2 - 5*c*d*f*g + c^2*g^2) - b^3*(10*d^3*f^3 - 10*c*d^2*f^2*g + 5*c^2*d*f*g^2 - c^3*g^3))*x)/(5*b^4*d^4) - (B*(b*c - a*d)*g^2*(a^2*d^2*g^2 - a*b*d*g*(5*d*f - c*g) + b^2*(10*d^2*f^2 - 5*c*d*f*g + c^2*g^2))*x^2)/(5*b^3*d^3) - (2*B*(b*c - a*d)*g^3*(5*b*d*f - b*c*g - a*d*g)*x^3)/(15*b^2*d^2) - (B*(b*c - a*d)*g^4*x^4)/(10*b*d) - (2*B*(b*f - a*g)^5*log(a + b*x))/(5*b^5*g) + ((f + g*x)^5*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(5*g) + (2*B*(d*f - c*g)^5*log(c + d*x))/(5*d^5*g)]
    @test_int [(f + g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 3, -(B*(b*c - a*d)*g*(a^2*d^2*g^2 - a*b*d*g*(4*d*f - c*g) + b^2*(6*d^2*f^2 - 4*c*d*f*g + c^2*g^2))*x)/(2*b^3*d^3) - (B*(b*c - a*d)*g^2*(4*b*d*f - b*c*g - a*d*g)*x^2)/(4*b^2*d^2) - (B*(b*c - a*d)*g^3*x^3)/(6*b*d) - (B*(b*f - a*g)^4*log(a + b*x))/(2*b^4*g) + ((f + g*x)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(4*g) + (B*(d*f - c*g)^4*log(c + d*x))/(2*d^4*g)]
    @test_int [(f + g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 3, (-2*B*(b*c - a*d)*g*(3*b*d*f - b*c*g - a*d*g)*x)/(3*b^2*d^2) - (B*(b*c - a*d)*g^2*x^2)/(3*b*d) - (2*B*(b*f - a*g)^3*log(a + b*x))/(3*b^3*g) + ((f + g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*g) + (2*B*(d*f - c*g)^3*log(c + d*x))/(3*d^3*g)]
    @test_int [(f + g*x)^1*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 3, -((B*(b*c - a*d)*g*x)/(b*d)) - (B*(b*f - a*g)^2*log(a + b*x))/(b^2*g) + ((f + g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(2*g) + (B*(d*f - c*g)^2*log(c + d*x))/(d^2*g)]
    @test_int [(f + g*x)^0*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 3, A*x + (B*(a + b*x)*log((e*(a + b*x)^2)/(c + d*x)^2))/b - (2*B*(b*c - a*d)*log(c + d*x))/(b*d)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(f + g*x)^1, x, 7, (-2*B*log(-((g*(a + b*x))/(b*f - a*g)))*log(f + g*x))/g + ((A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log(f + g*x))/g + (2*B*log(-((g*(c + d*x))/(d*f - c*g)))*log(f + g*x))/g - (2*B*PolyLog(2, (b*(f + g*x))/(b*f - a*g)))/g + (2*B*PolyLog(2, (d*(f + g*x))/(d*f - c*g)))/g]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(f + g*x)^2, x, 3, ((a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*f - a*g)*(f + g*x)) + (2*B*(b*c - a*d)*log((f + g*x)/(c + d*x)))/((b*f - a*g)*(d*f - c*g))]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(f + g*x)^3, x, 3, -((B*(b*c - a*d))/((b*f - a*g)*(d*f - c*g)*(f + g*x))) + (b^2*B*log(a + b*x))/(g*(b*f - a*g)^2) - (A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(2*g*(f + g*x)^2) - (B*d^2*log(c + d*x))/(g*(d*f - c*g)^2) + (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*log(f + g*x))/((b*f - a*g)^2*(d*f - c*g)^2)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(f + g*x)^4, x, 3, -(B*(b*c - a*d))/(3*(b*f - a*g)*(d*f - c*g)*(f + g*x)^2) - (2*B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g))/(3*(b*f - a*g)^2*(d*f - c*g)^2*(f + g*x)) + (2*b^3*B*log(a + b*x))/(3*g*(b*f - a*g)^3) - (A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(3*g*(f + g*x)^3) - (2*B*d^3*log(c + d*x))/(3*g*(d*f - c*g)^3) + (2*B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*log(f + g*x))/(3*(b*f - a*g)^3*(d*f - c*g)^3)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(f + g*x)^5, x, 3, -(B*(b*c - a*d))/(6*(b*f - a*g)*(d*f - c*g)*(f + g*x)^3) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g))/(4*(b*f - a*g)^2*(d*f - c*g)^2*(f + g*x)^2) - (B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2)))/(2*(b*f - a*g)^3*(d*f - c*g)^3*(f + g*x)) + (b^4*B*log(a + b*x))/(2*g*(b*f - a*g)^4) - (A + B*log((e*(a + b*x)^2)/(c + d*x)^2))/(4*g*(f + g*x)^4) - (B*d^4*log(c + d*x))/(2*g*(d*f - c*g)^4) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*log(f + g*x))/(2*(b*f - a*g)^4*(d*f - c*g)^4)]

    @test_int [(f + g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 15, (2*B^2*(b*c - a*d)^3*g^3*x)/(3*b^3*d^3) + (B^2*(b*c - a*d)^2*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*x)/(b^3*d^3) + (B^2*(b*c - a*d)^2*g^3*(c + d*x)^2)/(3*b^2*d^4) - (B*(b*c - a*d)*g*(a^2*d^2*g^2 - 2*a*b*d*g*(2*d*f - c*g) + b^2*(6*d^2*f^2 - 8*c*d*f*g + 3*c^2*g^2))*(a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(b^4*d^3) - (B*(b*c - a*d)*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*(c + d*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(2*b^2*d^4) - (B*(b*c - a*d)*g^3*(c + d*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*b*d^4) - ((b*f - a*g)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(4*b^4*g) + ((f + g*x)^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(4*g) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log((b*c - a*d)/(b*(c + d*x))))/(b^4*d^4) + (2*B^2*(b*c - a*d)^4*g^3*log((a + b*x)/(c + d*x)))/(3*b^4*d^4) + (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*log((a + b*x)/(c + d*x)))/(b^4*d^4) + (2*B^2*(b*c - a*d)^4*g^3*log(c + d*x))/(3*b^4*d^4) + (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - 3*b*c*g - a*d*g)*log(c + d*x))/(b^4*d^4) + (2*B^2*(b*c - a*d)^2*g*(a^2*d^2*g^2 - 2*a*b*d*g*(2*d*f - c*g) + b^2*(6*d^2*f^2 - 8*c*d*f*g + 3*c^2*g^2))*log(c + d*x))/(b^4*d^4) - (2*B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b^4*d^4)]
    @test_int [(f + g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 12, (4*B^2*(b*c - a*d)^2*g^2*x)/(3*b^2*d^2) - (4*B*(b*c - a*d)*g*(3*b*d*f - 2*b*c*g - a*d*g)*(a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*b^3*d^2) - (2*B*(b*c - a*d)*g^2*(c + d*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*b*d^3) - ((b*f - a*g)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(3*b^3*g) + ((f + g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(3*g) + (4*B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log((b*c - a*d)/(b*(c + d*x))))/(3*b^3*d^3) + (4*B^2*(b*c - a*d)^3*g^2*log((a + b*x)/(c + d*x)))/(3*b^3*d^3) + (4*B^2*(b*c - a*d)^3*g^2*log(c + d*x))/(3*b^3*d^3) + (8*B^2*(b*c - a*d)^2*g*(3*b*d*f - 2*b*c*g - a*d*g)*log(c + d*x))/(3*b^3*d^3) + (8*B^2*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(3*b^3*d^3)]
    @test_int [(f + g*x)^1*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 9, -((2*B*(b*c - a*d)*g*(a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(b^2*d)) - ((b*f - a*g)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(2*b^2*g) + ((f + g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(2*g) + (2*B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log((b*c - a*d)/(b*(c + d*x))))/(b^2*d^2) + (4*B^2*(b*c - a*d)^2*g*log(c + d*x))/(b^2*d^2) + (4*B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b^2*d^2)]
    @test_int [(f + g*x)^0*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 6, ((a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/b + (4*B*(b*c - a*d)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log((b*c - a*d)/(b*(c + d*x))))/(b*d) + (8*B^2*(b*c - a*d)*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(f + g*x)^1, x, 9, -(((A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2*log((b*c - a*d)/(b*(c + d*x))))/g) + ((A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/g - (4*B*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/g + (4*B*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/g + (8*B^2*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/g - (8*B^2*PolyLog(3, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/g]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(f + g*x)^2, x, 4, ((a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/((b*f - a*g)*(f + g*x)) + (4*B*(b*c - a*d)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)*(d*f - c*g)) + (8*B^2*(b*c - a*d)*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)*(d*f - c*g))]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(f + g*x)^3, x, 9, (2*B*(b*c - a*d)*g*(a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*f - a*g)^2*(d*f - c*g)*(f + g*x)) + (b^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(2*g*(b*f - a*g)^2) - (A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(2*g*(f + g*x)^2) + (4*B^2*(b*c - a*d)^2*g*log((f + g*x)/(c + d*x)))/((b*f - a*g)^2*(d*f - c*g)^2) + (2*B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)^2*(d*f - c*g)^2) + (4*B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)^2*(d*f - c*g)^2)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(f + g*x)^4, x, 12, (4*B^2*(b*c - a*d)^2*g^2*(c + d*x))/(3*(b*f - a*g)^2*(d*f - c*g)^3*(f + g*x)) - (2*B*(b*c - a*d)*g^2*(c + d*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*(b*f - a*g)*(d*f - c*g)^3*(f + g*x)^2) + (4*B*(b*c - a*d)*g*(3*b*d*f - b*c*g - 2*a*d*g)*(a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*(b*f - a*g)^3*(d*f - c*g)^2*(f + g*x)) + (b^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(3*g*(b*f - a*g)^3) - (A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(3*g*(f + g*x)^3) + (4*B^2*(b*c - a*d)^3*g^2*log((a + b*x)/(c + d*x)))/(3*(b*f - a*g)^3*(d*f - c*g)^3) - (4*B^2*(b*c - a*d)^3*g^2*log((f + g*x)/(c + d*x)))/(3*(b*f - a*g)^3*(d*f - c*g)^3) + (8*B^2*(b*c - a*d)^2*g*(3*b*d*f - b*c*g - 2*a*d*g)*log((f + g*x)/(c + d*x)))/(3*(b*f - a*g)^3*(d*f - c*g)^3) + (4*B*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/(3*(b*f - a*g)^3*(d*f - c*g)^3) + (8*B^2*(b*c - a*d)*(a^2*d^2*g^2 - a*b*d*g*(3*d*f - c*g) + b^2*(3*d^2*f^2 - 3*c*d*f*g + c^2*g^2))*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/(3*(b*f - a*g)^3*(d*f - c*g)^3)]
    @test_int [(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(f + g*x)^5, x, 15, -((B^2*(b*c - a*d)^2*g^3*(c + d*x)^2)/(3*(b*f - a*g)^2*(d*f - c*g)^4*(f + g*x)^2)) - (2*B^2*(b*c - a*d)^3*g^3*(c + d*x))/(3*(b*f - a*g)^3*(d*f - c*g)^4*(f + g*x)) + (B^2*(b*c - a*d)^2*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*(c + d*x))/((b*f - a*g)^3*(d*f - c*g)^4*(f + g*x)) + (B*(b*c - a*d)*g^3*(c + d*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(3*(b*f - a*g)*(d*f - c*g)^4*(f + g*x)^3) - (B*(b*c - a*d)*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*(c + d*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/(2*(b*f - a*g)^2*(d*f - c*g)^4*(f + g*x)^2) + (B*(b*c - a*d)*g*(3*a^2*d^2*g^2 - 2*a*b*d*g*(4*d*f - c*g) + b^2*(6*d^2*f^2 - 4*c*d*f*g + c^2*g^2))*(a + b*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)))/((b*f - a*g)^4*(d*f - c*g)^3*(f + g*x)) + (b^4*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2)/(4*g*(b*f - a*g)^4) - (A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2/(4*g*(f + g*x)^4) - (2*B^2*(b*c - a*d)^4*g^3*log((a + b*x)/(c + d*x)))/(3*(b*f - a*g)^4*(d*f - c*g)^4) + (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*log((a + b*x)/(c + d*x)))/((b*f - a*g)^4*(d*f - c*g)^4) + (2*B^2*(b*c - a*d)^4*g^3*log((f + g*x)/(c + d*x)))/(3*(b*f - a*g)^4*(d*f - c*g)^4) - (B^2*(b*c - a*d)^3*g^2*(4*b*d*f - b*c*g - 3*a*d*g)*log((f + g*x)/(c + d*x)))/((b*f - a*g)^4*(d*f - c*g)^4) + (2*B^2*(b*c - a*d)^2*g*(3*a^2*d^2*g^2 - 2*a*b*d*g*(4*d*f - c*g) + b^2*(6*d^2*f^2 - 4*c*d*f*g + c^2*g^2))*log((f + g*x)/(c + d*x)))/((b*f - a*g)^4*(d*f - c*g)^4) - (B*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))*log(1 - ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)^4*(d*f - c*g)^4) - (2*B^2*(b*c - a*d)*(2*b*d*f - b*c*g - a*d*g)*(2*a*b*d^2*f*g - a^2*d^2*g^2 - b^2*(2*d^2*f^2 - 2*c*d*f*g + c^2*g^2))*PolyLog(2, ((d*f - c*g)*(a + b*x))/((b*f - a*g)*(c + d*x))))/((b*f - a*g)^4*(d*f - c*g)^4)]

    #= ::Subsubsection::Closed:: =#
    #=p<0=#

    @test_int [(f + g*x)^2/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 0, Unintegrable((f + g*x)^2/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x)]
    @test_int [(f + g*x)^1/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 0, Unintegrable((f + g*x)/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x)]
    @test_int [(f + g*x)^0/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2)), x, 0, Unintegrable((A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^(-1), x)]
    @test_int [1/((f + g*x)^1*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))), x, 0, Unintegrable(1/((f + g*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))), x)]
    @test_int [1/((f + g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))), x, 0, Unintegrable(1/((f + g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))), x)]
    @test_int [1/((f + g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))), x, 0, Unintegrable(1/((f + g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))), x)]

    @test_int [(f + g*x)^2/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 0, Unintegrable((f + g*x)^2/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x)]
    @test_int [(f + g*x)^1/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 0, Unintegrable((f + g*x)/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x)]
    @test_int [(f + g*x)^0/(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2, x, 0, Unintegrable((A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^(-2), x)]
    @test_int [1/((f + g*x)^1*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2), x, 0, Unintegrable(1/((f + g*x)*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2), x)]
    @test_int [1/((f + g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2), x, 0, Unintegrable(1/((f + g*x)^2*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2), x)]
    @test_int [1/((f + g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2), x, 0, Unintegrable(1/((f + g*x)^3*(A + B*log((e*(a + b*x)^2)/(c + d*x)^2))^2), x)]

    #= ::Subsection::Closed:: =#
    #=Integrands*of*the*form*(f+g*x)^m*(A+B*log(e*(a+b*x)^n/(c+d*x)^n))^p=#

    #= ::Subsubsection::Closed:: =#
    #=p>0=#

    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))*(g + h*x)^4, x, 3, (B*(b*c - a*d)*h*(a^3*d^3*h^3 - a^2*b*d^2*h^2*(5*d*g - c*h) + a*b^2*d*h*(10*d^2*g^2 - 5*c*d*g*h + c^2*h^2) - b^3*(10*d^3*g^3 - 10*c*d^2*g^2*h + 5*c^2*d*g*h^2 - c^3*h^3))*n*x)/(5*b^4*d^4) - (B*(b*c - a*d)*h^2*(a^2*d^2*h^2 - a*b*d*h*(5*d*g - c*h) + b^2*(10*d^2*g^2 - 5*c*d*g*h + c^2*h^2))*n*x^2)/(10*b^3*d^3) - (B*(b*c - a*d)*h^3*(5*b*d*g - b*c*h - a*d*h)*n*x^3)/(15*b^2*d^2) - (B*(b*c - a*d)*h^4*n*x^4)/(20*b*d) - (B*(b*g - a*h)^5*n*log(a + b*x))/(5*b^5*h) + (B*(d*g - c*h)^5*n*log(c + d*x))/(5*d^5*h) + ((g + h*x)^5*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(5*h)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))*(g + h*x)^3, x, 3, -((B*(b*c - a*d)*h*(a^2*d^2*h^2 - a*b*d*h*(4*d*g - c*h) + b^2*(6*d^2*g^2 - 4*c*d*g*h + c^2*h^2))*n*x)/(4*b^3*d^3)) - (B*(b*c - a*d)*h^2*(4*b*d*g - b*c*h - a*d*h)*n*x^2)/(8*b^2*d^2) - (B*(b*c - a*d)*h^3*n*x^3)/(12*b*d) - (B*(b*g - a*h)^4*n*log(a + b*x))/(4*b^4*h) + (B*(d*g - c*h)^4*n*log(c + d*x))/(4*d^4*h) + ((g + h*x)^4*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(4*h)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))*(g + h*x)^2, x, 3, -((B*(b*c - a*d)*h*(3*b*d*g - b*c*h - a*d*h)*n*x)/(3*b^2*d^2)) - (B*(b*c - a*d)*h^2*n*x^2)/(6*b*d) - (B*(b*g - a*h)^3*n*log(a + b*x))/(3*b^3*h) + (B*(d*g - c*h)^3*n*log(c + d*x))/(3*d^3*h) + ((g + h*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(3*h)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))*(g + h*x)^1, x, 3, -((B*(b*c - a*d)*h*n*x)/(2*b*d)) - (B*(b*g - a*h)^2*n*log(a + b*x))/(2*b^2*h) + (B*(d*g - c*h)^2*n*log(c + d*x))/(2*d^2*h) + ((g + h*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(2*h)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))*(g + h*x)^0, x, 3, A*x - (B*(b*c - a*d)*n*log(c + d*x))/(b*d) + (B*(a + b*x)*log((e*(a + b*x)^n)/(c + d*x)^n))/b]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))/(g + h*x)^1, x, 7, -((B*n*log(-((h*(a + b*x))/(b*g - a*h)))*log(g + h*x))/h) + (B*n*log(-((h*(c + d*x))/(d*g - c*h)))*log(g + h*x))/h + ((A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*log(g + h*x))/h - (B*n*PolyLog(2, (b*(g + h*x))/(b*g - a*h)))/h + (B*n*PolyLog(2, (d*(g + h*x))/(d*g - c*h)))/h]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))/(g + h*x)^2, x, 3, (b*B*n*log(a + b*x))/(h*(b*g - a*h)) - (B*d*n*log(c + d*x))/(h*(d*g - c*h)) - (A + B*log((e*(a + b*x)^n)/(c + d*x)^n))/(h*(g + h*x)) + (B*(b*c - a*d)*n*log(g + h*x))/((b*g - a*h)*(d*g - c*h))]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))/(g + h*x)^3, x, 3, -((B*(b*c - a*d)*n)/(2*(b*g - a*h)*(d*g - c*h)*(g + h*x))) + (b^2*B*n*log(a + b*x))/(2*h*(b*g - a*h)^2) - (B*d^2*n*log(c + d*x))/(2*h*(d*g - c*h)^2) - (A + B*log((e*(a + b*x)^n)/(c + d*x)^n))/(2*h*(g + h*x)^2) + (B*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n*log(g + h*x))/(2*(b*g - a*h)^2*(d*g - c*h)^2)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))/(g + h*x)^4, x, 3, -((B*(b*c - a*d)*n)/(6*(b*g - a*h)*(d*g - c*h)*(g + h*x)^2)) - (B*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n)/(3*(b*g - a*h)^2*(d*g - c*h)^2*(g + h*x)) + (b^3*B*n*log(a + b*x))/(3*h*(b*g - a*h)^3) - (B*d^3*n*log(c + d*x))/(3*h*(d*g - c*h)^3) - (A + B*log((e*(a + b*x)^n)/(c + d*x)^n))/(3*h*(g + h*x)^3) + (B*(b*c - a*d)*(a^2*d^2*h^2 - a*b*d*h*(3*d*g - c*h) + b^2*(3*d^2*g^2 - 3*c*d*g*h + c^2*h^2))*n*log(g + h*x))/(3*(b*g - a*h)^3*(d*g - c*h)^3)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))/(g + h*x)^5, x, 3, -((B*(b*c - a*d)*n)/(12*(b*g - a*h)*(d*g - c*h)*(g + h*x)^3)) - (B*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n)/(8*(b*g - a*h)^2*(d*g - c*h)^2*(g + h*x)^2) - (B*(b*c - a*d)*(a^2*d^2*h^2 - a*b*d*h*(3*d*g - c*h) + b^2*(3*d^2*g^2 - 3*c*d*g*h + c^2*h^2))*n)/(4*(b*g - a*h)^3*(d*g - c*h)^3*(g + h*x)) + (b^4*B*n*log(a + b*x))/(4*h*(b*g - a*h)^4) - (B*d^4*n*log(c + d*x))/(4*h*(d*g - c*h)^4) - (A + B*log((e*(a + b*x)^n)/(c + d*x)^n))/(4*h*(g + h*x)^4) - (B*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*(2*a*b*d^2*g*h - a^2*d^2*h^2 - b^2*(2*d^2*g^2 - 2*c*d*g*h + c^2*h^2))*n*log(g + h*x))/(4*(b*g - a*h)^4*(d*g - c*h)^4)]

    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2*(g + h*x)^2, x, 13, (B^2*(b*c - a*d)^2*h^2*n^2*x)/(3*b^2*d^2) + (B^2*(b*c - a*d)^3*h^2*n^2*log((a + b*x)/(c + d*x)))/(3*b^3*d^3) + (B^2*(b*c - a*d)^3*h^2*n^2*log(c + d*x))/(3*b^3*d^3) + (2*B^2*(b*c - a*d)^2*h*(3*b*d*g - 2*b*c*h - a*d*h)*n^2*log(c + d*x))/(3*b^3*d^3) - (2*B*(b*c - a*d)*h*(3*b*d*g - 2*b*c*h - a*d*h)*n*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(3*b^3*d^2) - (B*(b*c - a*d)*h^2*n*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(3*b*d^3) + (2*B*(b*c - a*d)*(a^2*d^2*h^2 - a*b*d*h*(3*d*g - c*h) + b^2*(3*d^2*g^2 - 3*c*d*g*h + c^2*h^2))*n*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(3*b^3*d^3) - ((b*g - a*h)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(3*b^3*h) + ((g + h*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(3*h) + (2*B^2*(b*c - a*d)*(a^2*d^2*h^2 - a*b*d*h*(3*d*g - c*h) + b^2*(3*d^2*g^2 - 3*c*d*g*h + c^2*h^2))*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(3*b^3*d^3)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2*(g + h*x)^1, x, 10, (B^2*(b*c - a*d)^2*h*n^2*log(c + d*x))/(b^2*d^2) - (B*(b*c - a*d)*h*n*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b^2*d) + (B*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b^2*d^2) - ((b*g - a*h)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*b^2*h) + ((g + h*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*h) + (B^2*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b^2*d^2)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2*(g + h*x)^0, x, 6, (2*B*(b*c - a*d)*n*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b*d) + ((a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/b + (2*B^2*(b*c - a*d)*n^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2/(g + h*x)^1, x, 10, -((log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/h) + ((A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2*log(1 - ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/h - (2*B*n*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/h + (2*B*n*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/h + (2*B^2*n^2*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/h - (2*B^2*n^2*PolyLog(3, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/h]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2/(g + h*x)^2, x, 5, ((a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/((b*g - a*h)*(g + h*x)) + (2*B*(b*c - a*d)*n*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*log(1 - ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)*(d*g - c*h)) + (2*B^2*(b*c - a*d)*n^2*PolyLog(2, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)*(d*g - c*h))]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^2/(g + h*x)^3, x, 10, (B*(b*c - a*d)*h*n*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/((b*g - a*h)^2*(d*g - c*h)*(g + h*x)) + (b^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*h*(b*g - a*h)^2) - (A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2/(2*h*(g + h*x)^2) + (B^2*(b*c - a*d)^2*h*n^2*log((g + h*x)/(c + d*x)))/((b*g - a*h)^2*(d*g - c*h)^2) + (B*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*log(1 - ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)^2*(d*g - c*h)^2) + (B^2*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n^2*PolyLog(2, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)^2*(d*g - c*h)^2)]

    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3*(g + h*x)^2, x, 19, -((B^3*(b*c - a*d)^3*h^2*n^3*log(c + d*x))/(b^3*d^3)) + (B^2*(b*c - a*d)^2*h^2*n^2*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b^3*d^2) - (2*B^2*(b*c - a*d)^2*h*(3*b*d*g - 2*b*c*h - a*d*h)*n^2*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b^3*d^3) - (B*(b*c - a*d)*h*(3*b*d*g - 2*b*c*h - a*d*h)*n*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(b^3*d^2) - (B*(b*c - a*d)*h^2*n*(c + d*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*b*d^3) + (B*(b*c - a*d)*(a^2*d^2*h^2 - a*b*d*h*(3*d*g - c*h) + b^2*(3*d^2*g^2 - 3*c*d*g*h + c^2*h^2))*n*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(b^3*d^3) - ((b*g - a*h)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(3*b^3*h) + ((g + h*x)^3*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(3*h) - (B^2*(b*c - a*d)^3*h^2*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*log(1 - (b*(c + d*x))/(d*(a + b*x))))/(b^3*d^3) - (2*B^3*(b*c - a*d)^2*h*(3*b*d*g - 2*b*c*h - a*d*h)*n^3*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b^3*d^3) + (2*B^2*(b*c - a*d)*(a^2*d^2*h^2 - a*b*d*h*(3*d*g - c*h) + b^2*(3*d^2*g^2 - 3*c*d*g*h + c^2*h^2))*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b^3*d^3) + (B^3*(b*c - a*d)^3*h^2*n^3*PolyLog(2, (b*(c + d*x))/(d*(a + b*x))))/(b^3*d^3) - (2*B^3*(b*c - a*d)*(a^2*d^2*h^2 - a*b*d*h*(3*d*g - c*h) + b^2*(3*d^2*g^2 - 3*c*d*g*h + c^2*h^2))*n^3*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/(b^3*d^3)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3*(g + h*x)^1, x, 13, -((3*B^2*(b*c - a*d)^2*h*n^2*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n)))/(b^2*d^2)) - (3*B*(b*c - a*d)*h*n*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*b^2*d) + (3*B*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*b^2*d^2) - ((b*g - a*h)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(2*b^2*h) + ((g + h*x)^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(2*h) - (3*B^3*(b*c - a*d)^2*h*n^3*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b^2*d^2) + (3*B^2*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b^2*d^2) - (3*B^3*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n^3*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/(b^2*d^2)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3*(g + h*x)^0, x, 6, (3*B*(b*c - a*d)*n*log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(b*d) + ((a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/b + (6*B^2*(b*c - a*d)*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/(b*d) - (6*B^3*(b*c - a*d)*n^3*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/(b*d)]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3/(g + h*x)^1, x, 12, -((log((b*c - a*d)/(b*(c + d*x)))*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/h) + ((A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3*log(1 - ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/h - (3*B*n*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2*PolyLog(2, (d*(a + b*x))/(b*(c + d*x))))/h + (3*B*n*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2*PolyLog(2, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/h + (6*B^2*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(3, (d*(a + b*x))/(b*(c + d*x))))/h - (6*B^2*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(3, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/h - (6*B^3*n^3*PolyLog(4, (d*(a + b*x))/(b*(c + d*x))))/h + (6*B^3*n^3*PolyLog(4, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/h]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3/(g + h*x)^2, x, 6, ((a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/((b*g - a*h)*(g + h*x)) + (3*B*(b*c - a*d)*n*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2*log(1 - ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)*(d*g - c*h)) + (6*B^2*(b*c - a*d)*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)*(d*g - c*h)) - (6*B^3*(b*c - a*d)*n^3*PolyLog(3, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)*(d*g - c*h))]
    @test_int [(A + B*log(e*(a + b*x)^n/(c + d*x)^n))^3/(g + h*x)^3, x, 13, (3*B*(b*c - a*d)*h*n*(a + b*x)*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2)/(2*(b*g - a*h)^2*(d*g - c*h)*(g + h*x)) + (b^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3)/(2*h*(b*g - a*h)^2) - (A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^3/(2*h*(g + h*x)^2) + (3*B^2*(b*c - a*d)^2*h*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*log(1 - ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)^2*(d*g - c*h)^2) + (3*B*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2*log(1 - ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/(2*(b*g - a*h)^2*(d*g - c*h)^2) + (3*B^3*(b*c - a*d)^2*h*n^3*PolyLog(2, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)^2*(d*g - c*h)^2) + (3*B^2*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n^2*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))*PolyLog(2, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)^2*(d*g - c*h)^2) - (3*B^3*(b*c - a*d)*(2*b*d*g - b*c*h - a*d*h)*n^3*PolyLog(3, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))))/((b*g - a*h)^2*(d*g - c*h)^2)]

    #= ::Subsubsection:: =#
    #=p<0=#
    end

max_stars_repo_path: test/3 Logarithms/3.2.1 (f+g x)^m (A+B log(e ((a+b x) over (c+d x))^n))^p.jl