1
$\begingroup$

I tried to run the following code:

FullSimplify[(4*
     Pi*(-(r*(1 + r)^2*
          Sqrt[-(((1 + r)^4 + (-1 + r^2)^2 - 
                2*(1 + r)^2*(1 + r^2))/(r^2*(1 + r)^2))]) + 
       3*(1 + r)^3*ArcCos[(-1 + r^2 + (1 + r)^2)/(2*r*(1 + r))]))/
   9 - (4*Pi*(-((1 - r)^2*r*
          Sqrt[-(((1 - r)^4 + (-1 + r^2)^2 - 
                2*(1 - r)^2*(1 + r^2))/((1 - r)^2*r^2))]) + 
       3*(1 - r)^3*
        ArcCos[(-1 + (1 - r)^2 + r^2)/(2*(1 - r)*r)] + (r*
           Sqrt[(1 - r)^2/(1 + r)^2]*
           Sqrt[-(((-(1 - r)^2 + (-1 + r)^2)*(-(1 - r)^2 + (1 + 
                    r)^2))/r^2)]*
           EllipticF[
            ArcSin[Sqrt[2 + (1 - (1 - r)^2)/r + r]/
              2], (4*r)/(1 + r)^2] - 
          2*r^3*Sqrt[(1 - r)^2/(1 + r)^2]*
           Sqrt[-(((-(1 - r)^2 + (-1 + r)^2)*(-(1 - r)^2 + (1 + 
                    r)^2))/r^2)]*
           EllipticF[
            ArcSin[Sqrt[2 + (1 - (1 - r)^2)/r + r]/
              2], (4*r)/(1 + r)^2] + 
          r^5*Sqrt[(1 - r)^2/(1 + r)^2]*
           Sqrt[-(((-(1 - r)^2 + (-1 + r)^2)*(-(1 - r)^2 + (1 + 
                    r)^2))/r^2)]*
           EllipticF[
            ArcSin[Sqrt[2 + (1 - (1 - r)^2)/r + r]/
              2], (4*r)/(1 + r)^2] + ((7*I)*
             Sqrt[1 - (1 - r)^2/(-1 + r)^2]*(1 - r)*(1 + r)^2*
             Sqrt[1 - (1 - r)^2/(1 + r)^2]*(EllipticE[

                I*ArcSinh[(1 - r)*
                   Sqrt[-(-1 + r)^(-2)]], (-1 + r)^2/(1 + r)^2] - 
               EllipticF[
                I*ArcSinh[(1 - r)*
                   Sqrt[-(-1 + r)^(-2)]], (-1 + r)^2/(1 + r)^2]))/
           Sqrt[-(-1 + r)^(-2)] + (I*
             Sqrt[1 - (1 - r)^2/(-1 + r)^2]*(1 - r)*r^2*(1 + r)^2*
             Sqrt[1 - (1 - r)^2/(1 + r)^2]*(EllipticE[
                I*ArcSinh[(1 - r)*
                   Sqrt[-(-1 + r)^(-2)]], (-1 + r)^2/(1 + r)^2] - 
               EllipticF[
                I*ArcSinh[(1 - r)*
                   Sqrt[-(-1 + r)^(-2)]], (-1 + r)^2/(1 + r)^2]))/
           Sqrt[-(-1 + r)^(-2)])/((1 - r)^2*r*
          Sqrt[-(((1 - r)^4 + (-1 + r^2)^2 - 
                2*(1 - r)^2*(1 + r^2))/((1 - r)^2*r^2))])))/9, 
 0 < r < 1 && r \[Element] Reals]

I cannot figure out what is wrong here. All the denominator pose no problems. Square root and Elliptic functions and Arc trig functions should not be able to produce complex infinity. Yet every time I run it will produce a warning and result in ComplexInfinity.

The warning look like this:

FullSimplify::infd:Expression 4/9 π (-r (1+r)^2 
Sqrt[-((Power[<<2>>]+Power[<<2>>]+Times[<<3>>])/(r^2 Plus[<<2>>]^2))]+3 (1+r)^3 
ArcCos[(-1+Power[<<2>>]+Power[<<2>>])/(2 r Plus[<<2>>])])-4/9 π (-(1-r)^2 r 
Sqrt[-((Power[<<2>>]+Power[<<2>>]+Times[<<3>>])/(Plus[<<2>>]^2 r^2))]+3 (1-r)^3 
ArcCos[(-1+Power[<<2>>]+Power[<<2>>])/(2 Plus[<<2>>] r)]+<<1>>/((1-r)^2 r 
Sqrt[-((Power[<<2>>]+<<1>>+<<1>>)/(<<1>>^2 r^2))])) simplified to ComplexInfinity. >>

(I got an error if I try to convert to input form, so I have to paste that as plain text; but in any case, all the <<1>> and <<2>> seriously obscure where the error are occurring)

I am unable to simplify this on my own. I hope you can help. Thank you very much.

$\endgroup$
4
$\begingroup$

Assuming there's not a typo in your question, it's doing exactly what it should, meaning perhaps your equation or its entry is incorrect.

Using a simplify wrapper:

fs[a_] := FullSimplify[a, 0 < r < 1 && r ∈ Reals]

I applied it to the blocks of your equation as follows:

s1 = fs[4*
   Pi*(-(r*(1 + r)^2*
        Sqrt[-(((1 + r)^4 + (-1 + r^2)^2 - 
              2*(1 + r)^2*(1 + r^2))/(r^2*(1 + r)^2))]) + 
     3*(1 + r)^3*ArcCos[(-1 + r^2 + (1 + r)^2)/(2*r*(1 + r))])]

s2 = fs[((1 - r)^2*r*
    Sqrt[-(((1 - r)^4 + (-1 + r^2)^2 - 
          2*(1 - r)^2*(1 + r^2))/((1 - r)^2*r^2))])]

s3 = fs[3*(1 - r)^3*ArcCos[(-1 + (1 - r)^2 + r^2)/(2*(1 - r)*r)]]

s4 = fs[r*Sqrt[(1 - r)^2/(1 + r)^2]*
   Sqrt[-(((-(1 - r)^2 + (-1 + r)^2)*(-(1 - r)^2 + (1 + r)^2))/r^2)]*
   EllipticF[
    ArcSin[Sqrt[2 + (1 - (1 - r)^2)/r + r]/2], (4*r)/(1 + r)^2]]

s5 = fs[2*r^3*Sqrt[(1 - r)^2/(1 + r)^2]*
   Sqrt[-(((-(1 - r)^2 + (-1 + r)^2)*(-(1 - r)^2 + (1 + r)^2))/r^2)]*
   EllipticF[
    ArcSin[Sqrt[2 + (1 - (1 - r)^2)/r + r]/2], (4*r)/(1 + r)^2]]

s6 = fs[r^5*Sqrt[(1 - r)^2/(1 + r)^2]*
   Sqrt[-(((-(1 - r)^2 + (-1 + r)^2)*(-(1 - r)^2 + (1 + r)^2))/r^2)]*
   EllipticF[
    ArcSin[Sqrt[2 + (1 - (1 - r)^2)/r + r]/2], (4*r)/(1 + r)^2]]

s7 = fs[(7*I)*Sqrt[1 - (1 - r)^2/(-1 + r)^2]*(1 - r)*(1 + r)^2*
   Sqrt[1 - (1 - r)^2/(1 + r)^2]*(EllipticE[
      I*ArcSinh[(1 - r)*Sqrt[-(-1 + r)^(-2)]], (-1 + r)^2/(1 + r)^2] -
      EllipticF[
      I*ArcSinh[(1 - r)*Sqrt[-(-1 + r)^(-2)]], (-1 + r)^2/(1 + r)^2])]

s8 = fs[Sqrt[-(-1 + r)^(-2)]]

s9 = fs[I*Sqrt[1 - (1 - r)^2/(-1 + r)^2]*(1 - r)*r^2*(1 + r)^2*
   Sqrt[1 - (1 - r)^2/(1 + r)^2]*(EllipticE[
      I*ArcSinh[(1 - r)*Sqrt[-(-1 + r)^(-2)]], (-1 + r)^2/(1 + r)^2] -
      EllipticF[
      I*ArcSinh[(1 - r)*Sqrt[-(-1 + r)^(-2)]], (-1 + r)^2/(1 + r)^2])]

s10 = fs[Sqrt[-(-1 + r)^(-2)]]

s11 = fs[(1 - r)^2*r*
   Sqrt[-(((1 - r)^4 + (-1 + r^2)^2 - 
         2*(1 - r)^2*(1 + r^2))/((1 - r)^2*r^2))]]

{s1, s2, s3, s4, s5, s6, s7, s8, s9, s10, s11}

(* {0, 0, -3 π (-1 + r)^3, 0, 0, 0, 0, -(I/(-1 + r)), 0, -(I/(-1 + r)), 0} *)

Note that only s3, s8, and s10 simplify to other than zero.

Substituting these simplifications back into the original equation:

(s1)/9 - (4*Pi*(-s2 + s3 + (s4 - s5 + s6 + (s7)/s8 + (s9)/s10)/(s11)))/9

Replacing the zeros:

(0)/9 - (4*Pi*(-0 + s3 + (0 - 0 + 0 + (0)/s8 + (0)/s10)/(0)))/9

And simplifying that:

-(4*Pi*(s3/0))/9

Division by zero -> Complex Infinity...

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.