Manuals/calci/ENFORCEPOSITIVEINTEGER
ENFORCEPOSITIVEINTEGER(Number)
- is any real number.
Description
- This function converts or enforces the given number or set of numbers to a 'positive integer value'.
- Integer is the number without any decimal or fractional part but it can be the natural number with positive or negative sign.
- If the is negative decimal number, it is converted to positive number and rounded off to nearest integer.
- If the is positive decimal number, it is retained as positive number and rounded off to nearest integer.
- Number 'zero' is natural number, neither positive nor negative.
- The argument can also be a result of any function.
Examples
- ENFORCEPOSITIVEINTEGER(10) = 10
- ENFORCEPOSITIVEINTEGER(-2.45) = 2
- ENFORCEPOSITIVEINTEGER(14/9) = 1
- ENFORCEPOSITIVEINTEGER(-20/6) = 3
- ENFORCEPOSITIVEINTEGER(SUM([-5,-30])) = 35
For a set of numbers, the function displays a table as follows -
- ENFORCEPOSITIVEINTEGER(-5.5..5.5)=
Nature | Number | ENFORCETYPE |
---|---|---|
positiveinteger | -5.5 | 5 |
positiveinteger | -4.5 | 4 |
positiveinteger | -3.5 | 3 |
positiveinteger | -2.5 | 2 |
positiveinteger | -1.5 | 1 |
positiveinteger | -0.5 | 0 |
positiveinteger | 0.5 | 0 |
positiveinteger | 1.5 | 1 |
positiveinteger | 2.5 | 2 |
positiveinteger | 3.5 | 3 |
positiveinteger | 4.5 | 4 |
positiveinteger | 5.5 | 5 |
Related Videos
See Also
References