SAP ABAP Class CL_ABAP_MATH (ABAP Mathematics Library)
Hierarchy
☛
SAP_BASIS (Software Component) SAP Basis Component
⤷
BC-ABA-LA (Application Component) Syntax, Compiler, Runtime
⤷
SABP_CORE (Package) Kernel-Level Objects
⤷
⤷
Properties
| Class | CL_ABAP_MATH | |
| Short Description | ABAP Mathematics Library | |
| Super Class | ||
| Instantiability of a Class | 0 | Private |
| Final |
General Data
| Message Class | ||
| Program status | S | System Program |
| Category | 0 | |
| Package | SABP_CORE | Kernel-Level Objects |
| Created | 20000114 | SAP |
| Last change | 20110908 | SAP |
| Shared Memory-enabled | ||
| Fixed point arithmetic | ||
| Unicode checks active |
Forward declarations
| # | Type group / Object type | Type | Type Description |
|---|---|---|---|
| 1 | Type group use (TYPE-POOLS tp) | Type group use (TYPE-POOLS tp) |
Interfaces
Class CL_ABAP_MATH has no interface implemented.
Friends
Class CL_ABAP_MATH has no friend class.
Attributes
| # | Attribute | Level | Visibility | Read only | Typing | Associated Type | Initial Value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | Constant | Public | Type reference (TYPE) | OUTPUTSTYLE | 06 | Output: Technical | 20060202 | ||
| 2 | Constant | Public | Type reference (TYPE) | DECFLOAT16 | '9.999999999999999E+384' | Maximum Possible Value | 20060215 | ||
| 3 | Constant | Public | Type reference (TYPE) | DECFLOAT34 | '9.999999999999999999999999999999999E+6144' | Maximum Possible Value | 20060215 | ||
| 4 | Constant | Public | Type reference (TYPE) | I | 2147483647 | Biggest Possible Value for Type 1 | 20060803 | ||
| 5 | Constant | Public | Type reference (TYPE) | DECFLOAT16 | '1E-383' | Smallest Positive (not Subnormal) Value | 20060606 | ||
| 6 | Constant | Public | Type reference (TYPE) | DECFLOAT34 | '1E-6143' | Smallest Positive (not Subnormal) Value | 20060606 | ||
| 7 | Constant | Public | Type reference (TYPE) | I | -2147483648 | Smallest Possible Value for Type 1 | 20060803 | ||
| 8 | Constant | Public | Type reference (TYPE) | I | 0 | Round to Positive Infinity | 20051212 | ||
| 9 | Constant | Public | Type reference (TYPE) | I | 5 | Round to Zero | 20051212 | ||
| 10 | Constant | Public | Type reference (TYPE) | I | 6 | Round to Negative Infinity | 20051212 | ||
| 11 | Constant | Public | Type reference (TYPE) | I | 4 | Round to zero if value is exactly half | 20051212 | ||
| 12 | Constant | Public | Type reference (TYPE) | I | 3 | Round so last digit is an even no. if value is exactly half | 20051212 | ||
| 13 | Constant | Public | Type reference (TYPE) | I | 2 | Round away from zero if value is exactly half | 20051212 | ||
| 14 | Constant | Public | Type reference (TYPE) | I | 1 | Round away from zero | 20051212 | ||
| 15 | Constant | Public | Type reference (TYPE) | OUTPUTSTYLE | 02 | Output: Scale Preserving | 20060127 | ||
| 16 | Constant | Public | Type reference (TYPE) | OUTPUTSTYLE | 05 | Output: Scale Preserving Scientific | 20060202 | ||
| 17 | Constant | Public | Type reference (TYPE) | OUTPUTSTYLE | 03 | Output: Scientific | 20060202 | ||
| 18 | Constant | Public | Type reference (TYPE) | OUTPUTSTYLE | 04 | Output: Scientific with Leading Zero | 20060202 | ||
| 19 | Constant | Public | Type reference (TYPE) | OUTPUTSTYLE | 01 | Output: +/- Sign Right | 20060127 | ||
| 20 | Constant | Public | Type reference (TYPE) | OUTPUTSTYLE | 00 | Output: Simple | 20060127 |
Methods
| # | Method | Level | Visibility | Method type | Description | Created on |
|---|---|---|---|---|---|---|
| 1 | Static method | Public | Method | DF16_DEC/DF34_DEC: Length and Decimal Places in DB | 20080125 | |
| 2 | Static method | Public | Method | Exponent of DECFLOAT Number or floor( log10( x ) ) | 20110504 | |
| 3 | Static method | Public | Method | Maximum Possible Value In Database | 20080114 | |
| 4 | Static method | Public | Method | Number of Significant Places in a DECFLOAT Number | 20060321 | |
| 5 | Static method | Public | Method | Returns Scale of a DECFLOAT Number | 20060321 | |
| 6 | Static method | Public | Method | Number of Significant Places Without Following Zeros | 20060608 | |
| 7 | Static method | Public | Method | Normalization of a DECFLOAT Number | 20060321 | |
| 8 | Static method | Public | Method | Variable of ABAP Type F Rounded to 15 Decimal Places | 20000114 |
Events
Class CL_ABAP_MATH has no event.
Types
Class CL_ABAP_MATH has no local type.
Method Signatures
Method GET_DB_LENGTH_DECS Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | DECIMALS | Call by reference | Type reference (TYPE) | I | Nachkommastellen auf der Datenbank | 20080125 | |||
| 2 | IN | Call by reference | Type reference (TYPE) | DECFLOAT | Input-Variable | 20080125 | |||
| 3 | LENGTH | Call by reference | Type reference (TYPE) | I | Länge auf der Datenbank | 20080125 |
| # | Exception | Resumable | Description | Created on |
|---|---|---|---|---|
| 1 | Input-Variable nicht vom Typ DF34_DEC oder DF16_DEC | 20080125 |
Method GET_EXPONENT Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | EXPONENT | Value transfer | Type reference (TYPE) | I | Exponent | 20110504 | |||
| 2 | VAL | Call by reference | Type reference (TYPE) | DECFLOAT | Zahl deren Exponent ermittelt wird | 20110504 |
Method GET_EXPONENT on class CL_ABAP_MATH has no exception.
Method GET_MAX_DB_VALUE Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | IN | Call by reference | Type reference (TYPE) | DECFLOAT | Input-Variable | 20080114 | |||
| 2 | MAX_VALUE | Value transfer | Type reference (TYPE) | DECFLOAT34 | Maximalwert auf der Datenbank | 20080114 |
Method GET_MAX_DB_VALUE on class CL_ABAP_MATH has no exception.
Method GET_NUMBER_OF_DIGITS Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | NUM_OF_DIGITS | Value transfer | Type reference (TYPE) | I | Zahl der signifikanten Stellen | 20060322 | |||
| 2 | VAL | Call by reference | Type reference (TYPE) | DECFLOAT | Zu analysierende Zahl | 20060322 |
Method GET_NUMBER_OF_DIGITS on class CL_ABAP_MATH has no exception.
Method GET_SCALE Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | SCALE | Value transfer | Type reference (TYPE) | I | Scale | 20060322 | |||
| 2 | VAL | Call by reference | Type reference (TYPE) | DECFLOAT | Zahl deren scale ermittelt wird | 20060322 |
Method GET_SCALE on class CL_ABAP_MATH has no exception.
Method GET_SCALE_NORMALIZED Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | SCALE | Value transfer | Type reference (TYPE) | I | Scale | 20060608 | |||
| 2 | VAL | Call by reference | Type reference (TYPE) | DECFLOAT | Zahl deren Scale ermittelt wird | 20060608 |
Method GET_SCALE_NORMALIZED on class CL_ABAP_MATH has no exception.
Method NORMALIZE Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | NORM_VAL | Value transfer | Type reference (TYPE) | DECFLOAT34 | Normalisierte DECFLOAT Zahl | 20060322 | |||
| 2 | VAL | Call by reference | Type reference (TYPE) | DECFLOAT | Zu normalisierende DECFLOAT Zahl | 20060322 |
Method NORMALIZE on class CL_ABAP_MATH has no exception.
Method ROUND_F_TO_15_DECS Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | F_IN | Value transfer | Type reference (TYPE) | F | Zu rundender Wert | 20000114 | |||
| 2 | F_OUT | Value transfer | Type reference (TYPE) | F | Auf 15 Dezimalstellen gerundeter Wert | 20000114 |
Method ROUND_F_TO_15_DECS on class CL_ABAP_MATH has no exception.
History
| Last changed by/on | SAP | 20110908 |
| SAP Release Created in | 50A |