MATH function in 5.7 vs in 5.4.1

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf MATH function in 5.7 vs in 5.4.1

  • Creator
    Topic
  • #51961
    TorfinnK
    Participant

      Hello Clovertechers

      I have a problem with the MATH function on 5.7 and it doesn’t seem to be a problem in 5.4.1. I have tried it on 5.7 and 5.7 Rev2 and the OS is Windows2003.

      To remove any unnecessary code I made a frl with 3 field (A,B,C) each on 6 bytes. I made a Xlate wich have this frl both as inbound and outbound. I copy the value in A –> A, B –> B, MATH ADD A B –> C

      The Xlate looks like this

      Code:


      { { OP COPY }
         { ERR 0 }
         { IN {{AField.[0]}} }
         { OUT {{AField.[0]}} }
      }
      { { OP COPY }
         { ERR 0 }
         { IN {{BField.[0]}} }
         { OUT {{BField.[0]}} }
      }
      { { OP ADD }
         { ERR 0 }
         { IN {{AField.[0]} {BField.[0]}} }
         { OUT {{CField.[0]}} }
         { FUNCTION ADD }
      }

      I have a test input file like this:

      Code:


        3.3   6.6      

      When I run this Xlate in the Testing Tool it works fine, except from the trailing zeros, but that a minor problem.

      Code:


      MESSAGE 1
      AField: >   3.3< BField: >   6.6< CField: >9.9000<

      When I run it through the engine, just one IB thread, one OB thread, no Tcl code just the Xlate.  It won’t copy anything to the CField.

      When I do the same thing in 5.4.1 it works fine

      Does anyone have any idea.

      I have attached the .frl, .xlt and input data so if someone would test this I would appreciate it

      /Torfinn

    Viewing 1 reply thread
    • Author
      Replies
      • #72509
        Robert Kersemakers
        Participant

          Hi Torfinn,

          I have tried this in 5.5 (testing tool) and in 5.7 rev2 (testing tool and in/out-threads), but all works fine for me. I just had to remove the last line in the xlate: I don’t have the ‘xlt_echo’ proc.

          I even tried to add your last line COPY -> CField, but it still gives me 9.900 in the outbound field.

          So I can’t replicate this in 5.7. We are on HP-UX Itanium though.

          Zuyderland Medisch Centrum; Heerlen/Sittard; The Netherlands

        • #72510
          TorfinnK
          Participant

            I found the cause to this weird behavor. If there, for the hciuser in  Control Panel -> Regional and Language Option -> Regional Options -> Standards and Formats says Danish, the engine can’t use neither  the Math function in Xlate nor the expr in tcl, if I change that to English it works fine. The strange thing is why it works in Testing Tools and on 5.4.1.

            I can make a demonstration at the User Conference

            /Torfinn

        Viewing 1 reply thread
        • The forum ‘Cloverleaf’ is closed to new topics and replies.