math.is_subnormal()

Determines whether a floating point value is subnormal. See floating point classifications for more information.

Format

BOOL
math.is_subnormal(FLOAT x)

Examples

1
2
3
4
5
6
7
8
9
10
declare local var.f FLOAT;

set var.f = math.FLOAT_MIN; # minimum finite value
if (!math.is_subnormal(var.f)) {
  log "not subnormal";
}
set var.f /= 2;
if (math.is_subnormal(var.f)) {
  log "subnormal";
}