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

    EXPT -0.05^0.78 produces NaN (Exception InvalidOperands)

    Scheduled Pinned Locked Moved Mervis
    3 Posts 2 Posters 1.1k Views
    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
          • A AVsetula locked this topic on

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • First post
            Last post