RoundDown (FPScript)

21.09.2021

Rounds down to a number of decimal places that you can specify.

Syntax

RoundDown(Number, Places)

 

The syntax of the RoundDown function consists of the following parts:

Part

Description

Number

The real or complex number that is to be rounded down.

All data structures are allowed. All numeric data types are permitted.

If the argument is a list, then the function is executed for each element of the list and the result is also a list.

Places

Specifies the number of places to which to round down.

Permitted data structures are scalar value. All numeric data types are permitted.

The value must be greater or equal to 1.

For complex data types the absolute value is formed.

If the argument is a list, then the first element in the list is taken. If this is also a list, then the process is repeated.

Remarks

The result has the same structure and unit as the argument Number.

For signals, only the Y component is considered. For complex numbers, real and imaginary parts are rounded down separately.

Available in

FlexPro Basic, Professional, Developer Suite

Examples

RoundDown(1.2345, 2)

Results in 1.200.

RoundDown(1.253 V, 2)

Results in 1.200 V.

RoundDown(12745, 2)

Results in 12000.

RoundDown(-1.234, 2)

Results in -1.300.

See Also

RoundUp Function

Round Function

Share article or send as email:

You might be interested in these articles