Simple maths function

Hi,
I'm wanting to divide 2 ints but strugling with it for some reason.
my code is below:
          int datasize;
          int MemPoolsize;     
          double reduction;
          datasize = dataNormalised.size();
          MemPoolsize = MemoryPool.size();
          reduction = (MemPoolsize/datasize);//both datasie and Mempoolsie have int values assigned to them.
it works when i divide MemPoolsie with 2 but doesn't work when i divide it with datasie. i can't see why this would be.
can anyone help?
cheers

jverd wrote:
flounder wrote:
Jeff, check date.D'oh!
Idiot.Don't worry. Got me in one of his/her many other zombie revivals.

Similar Messages

  • Eval formula node vi cannot work with simple math functions

    Hi I have problem using eval formula node.
    And it produces error.
    The formula is AI0=AI0-AI6; AI1=AI1-AI6; AI2=AI2-AI6; AI3=AI3-AI6; AI4=AI4-AI6; AI5=AI5-AI6;
    Pls see the attached. I am using LV 7.1
    Pls help. Will be grateful for your help
    Clement
    Solved!
    Go to Solution.
    Attachments:
    eval_formula_test.vi ‏29 KB

    Yes, the problem are your variable names.
    Can you give us a bit of background why you want to do such a complicated and inefficient method for such a simple operation. The same could be done trivally with exactly three primitives (index array, array subset, subtract) and no purple at all.
    LabVIEW Champion . Do more with less code and in less time .

  • Creating a form with a field that contains a simple math problem.

    I am creating a form in Acrobat 9 Standard that contains a field that requires a simple math function (divide).
    if (QuantityRow1 > 0)
    ExtensionRow1 / QuantityRow1
    Take the value input in ExtensionRow1 and divide it by the value in QuantityRow1. I have included an IF statement to prevent an error that occur if QuantityRow1 were equal to zero.
    After inputting the data into the two fields I tab past the field where I expect to see my result and the field remains blank. I don't receive any error messages.
    Any ideas? Thanks - jb

    This is a duplicate of your question on Acrobatusers.com (
    http://answers.acrobatusers.com/Need-simple-math-operation-function-Acrobat-9-Standard-cre ating-form-q142800.aspx
    Did the information provided there not help you with your problem?
    Karl Heinz Kremer
    PDF Acrobatics Without a Net
    PDF Software Development, Training and More...
    [email protected]
    http://www.khkonsulting.com

  • Using advanced math functions in plugins

    I have an application built in LabVIEW 8.5 that calls external VIs as PlugIns. Normally adding any subVIs of these PlugIns in the same directory as the plugin is located in (or a sub-directory of that) will enable the plugin to execute (I have several such plugins that do run properly).
    The problem now however is that one of these PlugIns use a few math functions (linear fit etc.) and, although all the subVIs and dlls (including the ones from the vi.lib etc.) are located in the same directory - and the application is run on a machine that actually has the full professional LV 8.5 installed on it, it is still not executable (I've built a source distribution to get all the code it depends on out, with no exclusions). If I hit the broken run-button it says the full development system is required to resolve the issue.
    The same plugin works fine in LV 7.1.1 (although then it is distributed as a top level VI in an llb with the support-VIs in it instead).
    Is there still a way in LV 8.5 to distribute a plugin that uses the math functions without having to include the functions in the built application that will launch the plugin?
    MTO

    Hi, Mads,
    My "Quick and Dirty" test shows that it should be no any problems. Just deselect "Exclude vi.lib" Vis in the Distribution, and select that dependecies should be deployed with PlugIn. See attachment, hopefully its will be helpful for you. Such distribution way produced huge llb (because not only linear fit embedded into library, but all math library), but at least it works.
    best regards,
    Andrey.
    Attachments:
    PlugInWithMathDistributionTest.zip ‏21 KB

  • Simple mail functionality

    Hi,
    I am testing the simple mail functionality in transaction VA01.
    In customizing (output determination – processing routines) for simple mail is being used a program and a smartform. It was not me who developed them.
    The problem is that when I try to test this through VA01 (I choose simple mail, etc), I get a dump saying: ‘Invalid commit work in an update function module. Termination occurred in the ABAP program ‘SAPLSOI1’ – in “SO_DOCUMENT_SEND_API1”. The main program was “RSM13000’’.
    My problem now is how can I try to debug this when I am in transaction VA02? I am not able to execute the program I have in customizing…
    How can I found more information about this?
    Thanks a lot

    Weird..
    I am working with SAP ECC 6.0 - release 700
    In version history no one has modified the program...
    function so_document_send_api1.
    ""Lokale Schnittstelle:
    *"  IMPORTING
    *"     VALUE(DOCUMENT_DATA) LIKE  SODOCCHGI1 STRUCTURE  SODOCCHGI1
    *"     VALUE(PUT_IN_OUTBOX) LIKE  SONV-FLAG DEFAULT SPACE
    *"     VALUE(SENDER_ADDRESS) LIKE  SOEXTRECI1-RECEIVER DEFAULT SY-UNAME
    *"     VALUE(SENDER_ADDRESS_TYPE) LIKE  SOEXTRECI1-ADR_TYP DEFAULT 'B'
    *"     VALUE(COMMIT_WORK) LIKE  SONV-FLAG DEFAULT SPACE
    *"  EXPORTING
    *"     VALUE(SENT_TO_ALL) LIKE  SONV-FLAG
    *"     VALUE(NEW_OBJECT_ID) LIKE  SOFOLENTI1-OBJECT_ID
    *"     VALUE(SENDER_ID) LIKE  SOUDK STRUCTURE  SOUDK
    *"  TABLES
    *"      PACKING_LIST STRUCTURE  SOPCKLSTI1
    *"      OBJECT_HEADER STRUCTURE  SOLISTI1 OPTIONAL
    *"      CONTENTS_BIN STRUCTURE  SOLISTI1 OPTIONAL
    *"      CONTENTS_TXT STRUCTURE  SOLISTI1 OPTIONAL
    *"      CONTENTS_HEX STRUCTURE  SOLIX OPTIONAL
    *"      OBJECT_PARA STRUCTURE  SOPARAI1 OPTIONAL
    *"      OBJECT_PARB STRUCTURE  SOPARBI1 OPTIONAL
    *"      RECEIVERS STRUCTURE  SOMLRECI1
    *"  EXCEPTIONS
    *"      TOO_MANY_RECEIVERS
    *"      DOCUMENT_NOT_SENT
    *"      DOCUMENT_TYPE_NOT_EXIST
    *"      OPERATION_NO_AUTHORIZATION
    *"      PARAMETER_ERROR
    *"      X_ERROR
    *"      ENQUEUE_ERROR
    data begin of object_hd_change.
            include structure sood1.
    data end of object_hd_change.
    data begin of attach_hd_change.
            include structure sood1.
    data end of attach_hd_change.
    data begin of object_data.
            include structure soodd.
    data end of object_data.
    data begin of objhead occurs 1.
            include structure soli.
    data end of objhead.
    data begin of objcont occurs 100.
            include structure soli.
    data end of objcont.
    data begin of atthead_tab occurs 1.
            include structure soli.
    data end of atthead_tab.
    data begin of attcont_tab occurs 10.
            include structure soli.
    data end of attcont_tab.
    data begin of atthead occurs 1.
            include structure soli.
    data end of atthead.
    data begin of attcont occurs 10.
            include structure soli.
    data end of attcont.
    data begin of new_pack_list occurs 10.
            include structure soxpl.
    data end of new_pack_list.
    data begin of rec_table occurs 10.
            include structure soos1.
    data end of rec_table.
    data begin of object_fl_change.
            include structure sofm1.
    data end of object_fl_change.
    data rcode like sonv-rcode.
    data object_type like sood-objtp.
    data object_id_new like soodk.
    data file_format(3).
    data: originator      like soos1-recextnam,
          originator_type like soos1-recesc.
    data: hex_size like sy-tabix.
    data: old_object like swotobjid,
        * sh070900 5.0A reconvert R30 into OBJ Docs is possible.
          sood_id like soodk.
    data: old_folder_id like soodk,
          old_object_id like soodk,
          old_forwarder like soud-usrnam,
          old_object_data like sood2.
    data hex_mode type sonv-flag value space.
    data dummy_hex type solix_tab.
    **data i.
    **if sy-uname = ''
    while i ne 1.
    endwhile.
    **endif.
    describe table contents_bin lines hex_size.
    if hex_size gt 0.
       call function 'SO_CONVERT_CONTENTS_BIN'
        exporting
          it_contents_bin = contents_bin[]
        importing
          et_contents_bin = contents_bin[].
       data l_new_size     type i.
       data l_line_size    type i.
       data l_new_doc_size type i.
       describe table contents_bin lines l_new_size.
       if l_new_size <> hex_size.
         describe field contents_bin-line length l_line_size in character mode.
         loop at packing_list where transf_bin = on.
           packing_list-body_start = packing_list-body_start * 2 - 1.
           packing_list-body_num = packing_list-body_num * 2.
           l_new_doc_size = packing_list-body_num * l_line_size / 2.
           if packing_list-doc_size <= l_new_doc_size.
             packing_list-doc_size = l_new_doc_size * 2.
           endif.
           modify packing_list.
         endloop.
       endif.
    endif.
    describe table contents_hex lines hex_size.
    if hex_size gt 0.
       refresh contents_bin.
      MOVE CONTENTS_HEX[] TO CONTENTS_BIN[].
       hex_to_cont contents_hex contents_bin.
    endif.
    * transfer document data
      perform transfer_objdat_to_obj using document_data
                                           object_hd_change
                                           object_fl_change.
      perform set_default_object_data using object_hd_change.
    * read object out of table
    * take API1, so no receiver conversion is necessary here
      read table packing_list index 1.   "first object is document
      if sy-subrc ne ok.   "no packing list
        raise parameter_error.
      endif.
      perform read_object_out_of_tables tables object_header
                                               contents_txt
                                               contents_bin
                                               objhead
                                               objcont
                                      using    packing_list
                                               object_data
                                               rcode.
    * parameters    for tracing
      LOOP AT OBJHEAD.
        PERFORM  TRACE(RSSOEXTR) USING 'OBJHEAD'  OBJHEAD-LINE.
      ENDLOOP.
      if rcode ne ok.   "no object found
        raise parameter_error.
      endif.
    * out of object data use only extern content flag and perhaps the size
      move object_data-extct to object_hd_change-extct.
      if object_hd_change-objlen = 0       or
         object_hd_change-objlen is initial.
        move object_data-objlen to object_hd_change-objlen.
      endif.
      perform format_prepare_for_insert in program sapfssoa          "873845
           using packing_list-transf_bin
                 dummy_hex
        changing objhead[]
                 objcont[]
                 packing_list-doc_type
                 object_hd_change-file_ext
                 rcode.
      move packing_list-doc_type to object_type.
    * for old types move size to header
      perform size_to_header tables objhead
                             using  object_type
                                    document_data-doc_size.
    get    now all attachments, decreibed in packing list
      refresh new_pack_list.
      refresh atthead_tab.
      refresh attcont_tab.
      loop at packing_list from 2.
        clear new_pack_list.
        perform read_object_out_of_tables tables object_header
                                                 contents_txt
                                                 contents_bin
                                                 atthead
                                                 attcont
                                        using    packing_list
                                                 object_data
                                                 rcode.
        check rcode = ok.
      * sh240899 46C check for executable mail attachment (MAPI)
        if packing_list-doc_type = 'R3O'.
          read table attcont index 21 into old_object.
          if old_object-objtype = 'SOFM'.
            read table attcont index 22.
            if attcont = 'PROCESS'.
            * it's an attachment created by MAPI because of an executable
            * mail
            * read old mail and fill new one with process parameters
              move: old_object-objkey(17) to old_folder_id,
                    old_object-objkey+17(17) to old_object_id,
                    old_object-objkey+34(12) to old_forwarder.
              call function 'SO_OBJECT_READ'
                   exporting
                        folder_id                  = old_folder_id
                        forwarder                  = old_forwarder
                        object_id                  = old_object_id
                   importing
                        object_hd_display          = old_object_data
                   tables
                        objpara                    = object_para
                        objparb                    = object_parb
                   exceptions
                        folder_not_exist           = 4
                        folder_no_authorization    = 5
                        object_not_exist           = 6
                        object_no_authorization    = 7
                        operation_no_authorization = 8
                        owner_not_exist            = 9
                        parameter_error            = 10
                        others                     = 15.
              if sy-subrc = 0.
                move: old_object_data-vmtyp to object_hd_change-vmtyp,
                      old_object_data-skips to object_hd_change-skips,
                      old_object_data-acnam to object_hd_change-acnam,
                      old_object_data-acmem to object_hd_change-acmem.
              endif.
              continue.
            elseif attcont = 'DISPLAYATTACHMENT'.
            * sh070900 5.0A reconvert R30 into OBJ Docs is possible.
            * get object instance and method into attachment body
              refresh: attcont, atthead.
              move old_object-objkey+17(17) to sood_id.
              perform socx_select(sapfsso0) tables atthead
                                                   attcont
                                                   object_para
                                                   object_parb
                                            using  sood_id
                                                   hex_mode
                                                   rcode.
              move atthead[] to attcont[].
            * fill new packing list parameter
              describe table atthead lines packing_list-head_num.
              describe table attcont lines packing_list-body_num.
              packing_list-doc_size = '255'.
              packing_list-doc_type = obj.
            endif.
          endif.
        endif.
        move-corresponding packing_list to new_pack_list.
        move: packing_list-obj_descr     to new_pack_list-objdes,
              packing_list-obj_name      to new_pack_list-objnam,
              packing_list-doc_size      to new_pack_list-objlen,
              packing_list-obj_langu     to new_pack_list-objla,
              packing_list-mess_type     to new_pack_list-extct,
              packing_list-doc_type      to new_pack_list-objtp,
              packing_list-transf_bin    to new_pack_list-transf_bin."873845
        describe table atthead_tab lines new_pack_list-head_start.
        add 1 to new_pack_list-head_start.
        describe table attcont_tab lines new_pack_list-body_start.
        add 1 to new_pack_list-body_start.
        perform format_prepare_for_insert in program sapfssoa        "873845
             using packing_list-transf_bin
                   dummy_hex
          changing atthead[]
                   attcont[]
                   new_pack_list-objtp
                   new_pack_list-file_ext
                   rcode.
      get new sizes (also for attcont, someone forgot this...)
        describe table atthead lines new_pack_list-head_num.
        describe table attcont lines new_pack_list-body_num.
        loop at atthead.
          clear atthead_tab.
          move atthead to atthead_tab.
          append atthead_tab.
        endloop.
        loop at attcont.
          clear attcont_tab.
          move attcont to attcont_tab.
          append attcont_tab.
        endloop.
        append new_pack_list.
      endloop.
    * transfer receiver data
      perform transfer_rec_to_tab tables receivers
                                         rec_table.
    * sender in right format
      move sender_address to originator.
      perform convert_sndart_esc using sender_address_type
                                       originator_type.
      call function 'SO_OBJECT_SEND'
           exporting
              EXTERN_ADDRESS             = ' '
              FOLDER_ID                  = ' '
              FORWARDER                  = ' '
                object_fl_change           = object_fl_change
                object_hd_change           = object_hd_change
              OBJECT_ID                  = ' '
                object_type                = object_type
                outbox_flag                = put_in_outbox
                originator                 = originator
                originator_type            = originator_type
              OWNER                      = ' '
              STORE_FLAG                 = ' '
           importing
                object_id_new              = object_id_new
                sent_to_all                = sent_to_all
                originator_id              = sender_id
           tables
                objcont                    = objcont
                objhead                    = objhead
                objpara                    = object_para
                objparb                    = object_parb
                packing_list               = new_pack_list
                att_head                   = atthead_tab
                att_cont                   = attcont_tab
                receivers                  = rec_table
           exceptions
                object_not_sent            = 15
                object_type_not_exist      = 17
                operation_no_authorization = 21
                parameter_error            = 23
                too_much_receivers         = 73
                others                     = 1000.
      case sy-subrc.
        when ok.
          move object_id_new to new_object_id.
        when object_not_sent.
          perform transfer_tab_to_rec tables rec_table
                                             receivers.
          raise document_not_sent.
        when too_much_receivers.
          raise too_many_receivers.
        when object_type_not_exist.
          raise document_type_not_exist.
        when operation_no_authorization.
          raise operation_no_authorization.
        when parameter_error.
          raise parameter_error.
        when others.
          raise x_error.
      endcase.
    MOVE OBJECT_ID TO NEW_OBJECT_ID.
      perform transfer_tab_to_rec tables rec_table
                                         receivers.
    set commit work
      if commit_work = on.
        commit work.
      endif.
    endfunction.

  • How to invoke math functions from dbx?

    Is there an easy way to invoke math functions from dbx? If I try, for example, to call sqrt I get meaningless results:
    (dbx) print sqrt(4.0)
    sqrt(4) = 1074790400
    (dbx)
    This is from code which uses sqrt, so sqrt should be accessible. Does this need some kind of cast?

    It turns out that this is a bit different than it looks: dbx is indeed able to invoke functions invoked in this way correctly; dbx just fails to print a sensible return value.
    I tried with the following small function:
    #include <stdio.h>
    int printme(double x) {
    printf("This is %g\n",x);
    return (int)2*x;
    Compiling this without -g, linking this with some hello world program and invoking the function from dbx gives
    (dbx) print ((int (*)(double))printme)(4.0)
    This is 4
    ((int (*)(double)) printme)(4) = &(noname)(double) at 0x8
    (dbx)
    The line "This is 4" clearly indicates that the function has been invoked correctly. Just the printed return value is meaningless. In this case, it is even possible to construct expressions with the return value:
    (dbx) print 5 + ((int (*)(double))printme)(4.0)
    This is 4
    5+((int (*)(double)) printme)(4) = 13
    i.e. dbx "knows" the correct return value 8. This does, however, apparently not work with return values of type double (i.e. in the original sqrt-Example).
    I have therefore submitted a bug report with bugs.sun.com; I will post the BugID when (and if) this has been accepted.

  • Simple exit function

    Hi All,
    I am new BPS planning functions, I am trying to write a simple exit function to manipulate amount.
    Example: For value type as Plan i.e. '020' , I want to added constant to existing values say '100'.
    like price = price + 100 (for all value types as '020').
    I know this can be done by formula function as well , I know that i need to build a function inorder to create a exit function. I need help in building the ABAP code.
    Any help greatly appreicated.
    Regards,
    Reddy.

    Hi Vachan,
    Thanks for the reply, you mentioned that XXX-value type.
    What XXX stand for? As i am new to SAP please can you be of more specific.
    Regards,
    Reddy.

  • What advantage does HiQ provide over LabView Math Functions

    I'm evaluating how HiQ can help me to solve engineering modeling problems. I have used LabView to write several DAQ programs and a few programs to numerically solve modeling and simulation problems. What advantage are there to using HiQ compared to the math functions provided in LabView.

    There aren't really any advantages. There are some visualization options that are available in HiQ that would be very difficult in LabVIEW. HiQ is just another option to use, for a different type of interface and programming than is available in LabVIEW.
    Best Regards,
    Chris Matthews
    National Instruments

  • Advanced math functions/libraries

    Are there any more advanced math functions/libraries available for Java (other than in the normal Math class)? Right now I'm looking for something that will rapidly return all the factors of an integer, but I am likely to be interested in other features in the future as well. Thanks.

    Kramis wrote:
    Are there any more advanced math functions/libraries available for Java (other than in the normal Math class)? Right now I'm looking for something that will rapidly return all the factors of an integer, but I am likely to be interested in other features in the future as well. Thanks.Not in the standard classes.
    You could look at the Apache Math library:
    [http://commons.apache.org/math/]
    perhaps it has some number theory methods.
    Or you could look into a Java bridge/interface between existing computer algebra systems (CAS) like Maple, Mathcad (both commercial) or the excellent opensource alternative: Octave. All these CAS have a bridge/interface to Java.

  • Math functions for dates

    Hello,
    Have you ever used a math function for dates (MMDDYYYY) not just a number? I'm looking to send an email out based on date field. For example, if someone's contract expires on 1/1/2016, I'd like to send them out emails 30, 152, 212 and 335 days before that date. Right now, we have fields set up for those 30, 152, 212 and 335 days and would like to know if there's a math function that would automatically fill them in dynamically based on their contract exp. date.
    Thanks for your help and suggestions.

    rmabrey wrote:
    I have the calculator working but I am having trouble figuring out thow to do a square root function, nth factorial, absolute value, and Fibonacci. java.lang.Math.sqrt()
    nothing for factorial - write your own.
    java.lang.Math.abs()
    nothing for Fibonacci - write your own.
    %

  • C99 math functions

    Hello all yet again,
    I'm trying to use the C99 math functions: nearbyint, round, exp2, cbrt, etc... But they don't seem to be defined in the CVI2013 header file.
    I previously would compile them (with gcc) only if __STDC_HOSTED__ was defined, but it appears that, although it doesn't appear in the predefined options listed in the build options, this macro is now defined in CVI2013...
    So if CVI is now C99 compliant, where are those functions ? And if not, how do I know if they are present or not, short of doing #ifdef _CVI_ ?
    Note, the official test seems to be:
    #if _XOPEN_SOURCE >= 600 || _ISOC99_SOURCE || _POSIX_C_SOURCE >= 200112L
    // C99 math functions present
    #endif
    Solved!
    Go to Solution.

    gdargaud wrote:
    So if CVI is now C99 compliant, where are those functions ? And if not, how do I know if they are present or not, short of doing #ifdef _CVI_ ?
    Nobody said so..., see here

  • TestStand math functions completely explained

    Is there a reference that has complete explanations to math functions used in TestStand?
    Many functions have options that are not explained under help.
    BenH

    Hi BenH,
    Just to make sure I am on the same page as you, are you referring to the Operators/Functions found in the expression browser or something within the API? Most of the math type functions within the expression browser have their operations and parameters explained within the Description box. I am not quite sure what other options you are seeing. Could you give some examples of some of the Math functions you have questions about and the options that are not defined?
    Regards,
    James W.
    Applications Engineer
    National Instruments

  • Specialized math functions?

    Hi,
    I'm quite knew here and I would like to know if there are more specialized math functions than in class Math.
    For example, I would like to work with complex numbers, integrate, differentiate, cartesian to spheric (or polar) transforms and vice versa, Fourier transforms, Matrix operations like: inverse, determinant, multiplication, size of a matrix, etc...
    I'm trying to rewrite in Java a program I had in Matlab so I can put it in an applet. If someone knows where I can find this information I'll be very grateful. Thanks in advance
    Mauricio

    JMSL is not free. Here is some packages for some of the things you said:
    http://math.nist.gov/javanumerics/

  • Math functions with error in/out

    Please refer to the attached picture. Where do you get these math functions with the error in/out? I saw these in responding to a post.
    Richard
    Solved!
    Go to Solution.
    Attachments:
    them_things.jpg ‏2 KB

    No wonder I've never seen it, I never use the waveform datatype. Thanks Lynn and Smerc.
    Richard

  • Math Functions in SAP

    What are the math functions in SAP?

    Hi,
    This is what u want may be
    Mathematical Functions
    ABAP contains a range of built-in functions that you can use as mathematical expressions, or as part of a mathematical expression:
    [COMPUTE] <n> = <func>( <m> ).
    The blanks between the parentheses and the argument <m> are obligatory. The result of calling the function <func> with the argument <m> is assigned to <n>.
    Functions for all Numeric Data Types
    The following built-in functions work with all three numeric data types (F, I, and P) as arguments.
    Functions for all numeric data types
    Function
    Result
    ABS
    Absolute value of argument.
    SIGN
    Sign of argument:                      1 X > 0
                                                  SIGN( X) = 0 if X = 0
                                                                   -1 X < 0
    CEIL
    Smallest integer value not smaller than the argument.
    FLOOR
    Largest integer value not larger than the argument.
    TRUNC
    Integer part of argument.
    FRAC
    Fraction part of argument.
    The argument of these functions does not have to be a numeric data type. If you choose another type, it is converted to a numeric type. For performance reasons, however, you should use the correct type whenever possible. The functions itself do not have a data type of their own. They do not change the numerical precision of a numerical operation.
    DATA N TYPE P DECIMALS 2.
    DATA M TYPE P DECIMALS 2 VALUE '-5.55'.
    N = ABS( M ).   WRITE:   'ABS:  ', N.
    N = SIGN( M ).  WRITE: / 'SIGN: ', N.
    N = CEIL( M ).  WRITE: / 'CEIL: ', N.
    N = FLOOR( M ). WRITE: / 'FLOOR:', N.
    N = TRUNC( M ). WRITE: / 'TRUNC:', N.
    N = FRAC( M ).  WRITE: / 'FRAC: ', N.
    The output appears as follows:
    ABS:              5.55
    SIGN:             1.00-
    CEIL:             5.00-
    FLOOR:            6.00-
    TRUNC:            5.00-
    FRAC:             0.55-
    DATA: T1(10),
    T2(10) VALUE '-100'.
    T1 = ABS( T2 ).
    WRITE T1.
    This produces the following output:
    100
    Two conversions are performed. First, the contents of field T2 (type C) are converted to type P. Then the system processes the ABS function using the results of the conversion. Then, during the assignment to the type C field T1, the result of the function is converted back to type C.
    Floating-Point Functions
    The following built-in functions work with floating point numbers (data type F) as an argument.
    Functions for floating point data types
    Function
    Meaning
    ACOS, ASIN, ATAN; COS, SIN, TAN
    Trigonometric functions.
    COSH, SINH, TANH
    Hyperbolic functions.
    EXP
    Exponential function with base e (e=2.7182818285).
    LOG
    Natural logarithm with base e.
    LOG10
    Logarithm with base 10.
    SQRT
    Square root.
    For all functions, the normal mathematical constraints apply (for example, square root is only possible for positive numbers). If you fail to observe them, a runtime error occurs.
    The argument of these functions does not have to be a floating point field. If you choose another type, it is converted to type F. The functions themselves have the data type F. This can change the numerical precision of a numerical operation.
    Regards

Maybe you are looking for

  • Customer written Request Handler at Webdynpro SICF Node

    Hi, We tried to activate our own request handler in the handler list of the SICF node of our ABAP webdynpro application. However, the handler is not called, i.e. the method IF_HTTP_EXTENSION~HANDLE_REQUEST of my own handler class is not executed.  Wh

  • Refresh Planning application using batch client

    Hi All, I'm trying to refresh the planning application using batch client and I'm not winning so far. This is what I have in my script. Execute Deploy Parameters(ApplicationName, InstanceName, Refresh Outline) Values('MyAppName', 'MyInstanceName', 'T

  • ThinkPad Yoga Synaptics TouchPad Error msg on Windows 7 startup and loss of gesture functions

    I fresh installed Windows 7 Ultimate on my ThinkPad Yoga after getting fed up with windows 8.1. I now get the following error msg on each startup and the trakpad features do not work: "synaptics touchpad 64-bit enhancements has stopped working"   I c

  • Photoshop Komplett langsam und After Effects gehen schon gar nicht!?

    Hallo liebe User, frohes Fest miteinander (: ich habe mir die 30 Tägige Testversion heruntergeladen und wollte mit voller Motivation nach dem Download mich einarbeiten. Doch bereits nach 0 Sekunden der erste Dämpfer.. AE funktioniert nicht "After Eff

  • How to recover the last sync at iCloud

    Yesterday I had sync my iphone 4 as usal and today I erase one picture from the Iphone 4 so I want to recover my Iphone with the last sync but in my computer the last sync is one week ago so when i restore my Iphone seem as that day, but i already kn