Button for 1977 Button for 1984 Button for 1990 Button for 1995 Button for MDC Button for notes Button for examples

Numeric Data Values

Draft MDC Standard

7.1.4.3 Numeric data values

The set of numeric values is a subset of the set of all values of data type MVAL. Only numbers that may be represented with a finite number of decimal digits are representable as numeric values. A data value of data type MVAL has the form of a number if it satisfies the following restrictions.

  1. It shall contain only digits and the characters "" and ".".
  2. At least one digit must be present.
  3. "." occurs at most once.
  4. The number zero is represented by the one-character string "0".
  5. The representation of each positive number contains no "".
  6. The representation of each negative number contains the character "" followed by the representation of the positive number which is the absolute value of the negative number. (Thus, the following restrictions describe positive numbers only.)
  7. The representation of each positive integer contains only digits and no leading zero.
  8. The representation of each positive number less than 1 consists of a "." followed by a non-empty digit string with no trailing zero. (This is called a fraction.)
  9. The representation of each positive non-integer greater than 1 consists of the representation of a positive integer (called the integer part of the number) followed by a fraction (called the fraction part of the number).

Note that the mapping between representable numbers and representations is one-to-one. An important result of this is that string equality of numeric values is a necessary and sufficient condition of numeric equality.

Button for 1977 Button for 1984 Button for 1990 Button for 1995 Button for MDC Button for notes Button for examples

Copyright © Standard Documents; 1977-2024 MUMPS Development Committee;
Copyright © Examples: 1995-2024 Ed de Moel;
Copyright © Annotations: 2003-2008 Jacquard Systems Research
Copyright © Annotations: 2008-2024 Ed de Moel.

Some specifications are "approved for inclusion in a future standard". Note that the MUMPS Development Committee cannot guarantee that such future standards will indeed be published.

This page most recently updated on 28-Nov-2011, 21:03:45.

For comments, contact Ed de Moel (demoel@jacquardsystems.com)