SAP CL_ABAP_MATH OO Class - ABAP Mathematics Library









CL_ABAP_MATH is a standard SAP object class available within R/3 SAP systems depending on your version and release level. You can view/maintain the class details by entering its name into the relevant SAP transactions such as SE24, SE80 or even SE84. Below is the documentation available for class CL_ABAP_MATH including details of:

  • Interface class implementations
  • Inheritance details
  • Methods defined within class ( including link to full details )
  • Attributes ( including initial values )
  • Class Events



Method list of CL_ABAP_MATH SAP class


A method is a coding block that performs a certain procedure (i.e. ABAP functionality) on an object within the overall SAP class. In simple terms if the object is an SAP database table a method could be the procedure to add a record or to delete a record. If you are new to OO in many respects, the implementation of a method is similar to a function module and can be called in a very similar way using CALL METHOD. Instead of "CALL FUNCTION", Methods are referenced using the following syntax: CALL METHOD =>methodname EXPORTING/IMPORTING...


Method NameDescriptionVisability
GET_DB_LENGTH_DECSDF16_DEC/DF34_DEC: Length and Decimal Places in DBPublic
CALL METHOD cl_abap_math=>GET_DB_LENGTH_DECS...more details

GET_EXPONENTExponent of DECFLOAT Number or floor( log10( x ) )Public
CALL METHOD cl_abap_math=>GET_EXPONENT...more details

GET_MAX_DB_VALUEMaximum Possible Value In DatabasePublic
CALL METHOD cl_abap_math=>GET_MAX_DB_VALUE...more details

GET_NUMBER_OF_DIGITSNumber of Significant Places in a DECFLOAT NumberPublic
CALL METHOD cl_abap_math=>GET_NUMBER_OF_DIGITS...more details

GET_SCALEReturns Scale of a DECFLOAT NumberPublic
CALL METHOD cl_abap_math=>GET_SCALE...more details

GET_SCALE_NORMALIZEDNumber of Significant Places Without Following ZerosPublic
CALL METHOD cl_abap_math=>GET_SCALE_NORMALIZED...more details

NORMALIZENormalization of a DECFLOAT NumberPublic
CALL METHOD cl_abap_math=>NORMALIZE...more details

ROUND_F_TO_15_DECSVariable of ABAP Type F Rounded to 15 Decimal PlacesPublic
CALL METHOD cl_abap_math=>ROUND_F_TO_15_DECS...more details



CL_ABAP_MATH attributes

List of attributes within class CL_ABAP_CHAR_UTILITIES. These can be referenced using the following syntax CL_ABAP_CHAR_UTILITIES=>. Although depending on where you are inserting the ABAP code you do need to check if the attribute is public or private.

NameLevelDescriptionInitial ValueTypeVisability
ENGINEERINGConstantOutput: Technical06LIKE
OUTPUTSTYLE
Public
MAX_DECFLOAT16ConstantMaximum Possible Value'9.999999999999999E+384'LIKE
DECFLOAT16
Public
MAX_DECFLOAT34ConstantMaximum Possible Value'9.999999999999999999999999999999999E+6144'LIKE
DECFLOAT34
Public
MAX_INT4ConstantBiggest Possible Value for Type 12147483647LIKE
I
Public
MAX_INT8Instance AttributeLIKE
Private
MIN_DECFLOAT16ConstantSmallest Positive (not Subnormal) Value'1E-383'LIKE
DECFLOAT16
Public
MIN_DECFLOAT34ConstantSmallest Positive (not Subnormal) Value'1E-6143'LIKE
DECFLOAT34
Public
MIN_INT4ConstantSmallest Possible Value for Type 1-2147483648LIKE
I
Public
MIN_INT8Instance AttributeLIKE
Private
ROUND_CEILINGConstantRound to Positive Infinity0LIKE
I
Public
ROUND_DOWNConstantRound to Zero5LIKE
I
Public
ROUND_FLOORConstantRound to Negative Infinity6LIKE
I
Public
ROUND_HALF_DOWNConstantRound to zero if value is exactly half4LIKE
I
Public
ROUND_HALF_EVENConstantRound so last digit is an even no. if value is exactly half3LIKE
I
Public
ROUND_HALF_UPConstantRound away from zero if value is exactly half2LIKE
I
Public
ROUND_UPConstantRound away from zero1LIKE
I
Public
SCALE_PRESERVINGConstantOutput: Scale Preserving02LIKE
OUTPUTSTYLE
Public
SCALE_PRESERVING_SCIENTIFICConstantOutput: Scale Preserving Scientific05LIKE
OUTPUTSTYLE
Public
SCIENTIFICConstantOutput: Scientific03LIKE
OUTPUTSTYLE
Public
SCIENTIFIC_WITH_LEADING_ZEROConstantOutput: Scientific with Leading Zero04LIKE
OUTPUTSTYLE
Public
SIGN_AS_POSTFIXConstantOutput: +/- Sign Right01LIKE
OUTPUTSTYLE
Public
SIMPLEConstantOutput: Simple00LIKE
OUTPUTSTYLE
Public


Links to Related Class(s)

CL_ABAP_...
Full list of available SAP object classes

Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!