• Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    EXPT -0.05^0.78 produces NaN (Exception InvalidOperands)

    Mervis
    2
    3
    107
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • G
      greatlama last edited by

      EXPT -0.05^0.78 produces NaN (Exception InvalidOperands)

      Hello,

      In Mervis 2.4.1 EXPT block produces NaN (Exception InvalidOperands) for IN1 = -0.05 and IN2 = 0.78.

      I think that this behavior is not correct -0.05^0.75 = -0.097.

      NaN.png

      Have a nice day
      Jan

      1 Reply Last reply Reply Quote 0
      • H
        HPC last edited by HPC

        (-0.05)^(0.75) is equal to the "4th root of (-0.05)^3"=2th root of (2th root of (-0.000125))=2rd root of (0.011*i) where "i" is a complex number operand. The 2th root for a complex number is not defined in mathematics and as such, not in Mervis. That's why you get NAN.

        G 1 Reply Last reply Reply Quote 0
        • G
          greatlama @HPC last edited by

          @HPC
          Ok, you are right. My fault... I checked -(0.05)^0.78 instead of (-0.05)^0.78

          The Mervis behavior is correct.

          Thank you
          Jan

          P.S. Maybe it will be great to add this information into documentation. Now there is IN1 ANY_REAL which seems to me that also negative numbers are accepted.

          1 Reply Last reply Reply Quote 0
          • Locked by  A AVsetula 
          • First post
            Last post