FloatingPointUtils Library Documentation ¶ Company System Title FloatingPointUtils Version 3.5.17.0 Categories Intern|Utils Namespace FPU Author None Placeholder FloatingPointUtils Description 1 ¶ Helper functions for REAL and LREAL numbers. Contents: ¶ ESpecial_FP_Value (Enum) Functions Ceil (Function) CeilF (Function) Floor (Function) FloorF (Function) Truncate (Function) TruncateF (Function) HexReal DeserializeHexReal (Function) SerializeHexReal (Function) LREAL GetLRealSpecialVal (Function) IsLRealNaN (Function) IsLRealNegInfinity (Function) IsLRealNumber (Function) IsLRealPosInfinity (Function) REAL GetRealSpecialVal (Function) IsRealNaN (Function) IsRealNegInfinity (Function) IsRealNumber (Function) IsRealPosInfinity (Function) StringFunctions HexStrToLReal (Function) HexStrToReal (Function) LRealToHexStr (Function) LRealToStr (Function) RealToHexStr (Function) RealToStr (Function) StrToLReal (Function) StrToReal (Function) Indices and tables ¶ 1 Based on FloatingPointUtils.library, last modified 20.04.2021, 15:17:29. LibDoc 4.4.0.0-b.27 The content file FloatingPointUtils.clean.json was generated with CODESYS V3.5 SP16 Patch 3 on 20.04.2021, 15:17:29.
ESpecial_FP_Value (ENUM) ¶ TYPE ESpecial_FP_Value : Enumeration of special floating point values InOut: Name Initial Comment NaN 0 A (quiet) NaN PosInf 1 Positive infinity NegInf 2 Negative infinity Eps 3 Smallest positive number MaxVal 4 The maximum representable value MinVal 5 The minimum representable value
Functions ¶ Ceil (Function) CeilF (Function) Floor (Function) FloorF (Function) Truncate (Function) TruncateF (Function)
Ceil (FUN) ¶ FUNCTION Ceil : LREAL Returns the smallest integral value that is not less than f. If f is +0, -0, infinity, or NaN, then f is returned. Note This function also handles the case LREAL = REAL. InOut: Scope Name Type Input f LREAL Return Ceil LREAL
CeilF (FUN) ¶ FUNCTION CeilF : REAL Returns the smallest integral value that is not less than f. If f is +0, -0, infinity, or NaN, then f is returned. InOut: Scope Name Type Input f REAL Return CeilF REAL
Floor (FUN) ¶ FUNCTION Floor : LREAL Returns the greatest integral value that is not greater than f. if f is +0, -0, infinity, or NaN, then f is returned. Note This function also handles the case LREAL = REAL. InOut: Scope Name Type Input f LREAL Return Floor LREAL
FloorF (FUN) ¶ FUNCTION FloorF : REAL Returns the greatest integral value that is not greater than f. If f is +0, -0, infinity, or NaN, then f is returned. InOut: Scope Name Type Input f REAL Return FloorF REAL
Truncate (FUN) ¶ FUNCTION Truncate : LREAL Round to the next integral value, towards zero. if f is integral, infinity, or NaN, then f is returned. Note This function also handles the case LREAL = REAL. InOut: Scope Name Type Input f LREAL Return Truncate LREAL
TruncateF (FUN) ¶ FUNCTION TruncateF : REAL Round to the next integral value, towards zero. If f is integral, infinity, or NaN, then f is returned. InOut: Scope Name Type Input f REAL Return TruncateF REAL
HexReal ¶ DeserializeHexReal (Function) SerializeHexReal (Function)