Decimal
The decimal numeral system (also called the base-ten positional numeral system and denary /ˈdiːnəri/[1] or decanary) is the standard system for denoting integer and non-integer numbers. It is the extension to non-integer numbers (decimal fractions) of the Hindu–Arabic numeral system. The way of denoting numbers in the decimal system is often referred to as decimal notation.[2]
For other uses, see Decimal (disambiguation).
A decimal numeral (also often just decimal or, less correctly, decimal number), refers generally to the notation of a number in the decimal numeral system. Decimals may sometimes be identified by a decimal separator (usually "." or "," as in 25.9703 or 3,1415).[3]
Decimal may also refer specifically to the digits after the decimal separator, such as in "3.14 is the approximation of π to two decimals". Zero-digits after a decimal separator serve the purpose of signifying the precision of a value.
The numbers that may be represented in the decimal system are the decimal fractions. That is, fractions of the form a/10n, where a is an integer, and n is a non-negative integer. Decimal fractions also result from the addition of an integer and a fractional part; the resulting sum sometimes is called a fractional number.
Decimals are commonly used to approximate real numbers. By increasing the number of digits after the decimal separator, one can make the approximation errors as small as one wants, when one has a method for computing the new digits.
Originally and in most uses, a decimal has only a finite number of digits after the decimal seperator. However, the decimal system has been extended to infinite decimals for representing any real number, by using an infinite sequence of digits after the decimal separator (see decimal representation). In this context, the usual decimals, with a finite number of non-zero digits after the decimal separator, are sometimes called terminating decimals. A repeating decimal is an infinite decimal that, after some place, repeats indefinitely the same sequence of digits (e.g., 5.123144144144144... = 5.123144).[4] An infinite decimal represents a rational number, the quotient of two integers, if and only if it is a repeating decimal or has a finite number of non-zero digits.
For writing numbers, the decimal system uses ten decimal digits, a decimal mark, and, for negative numbers, a minus sign "−". The decimal digits are 0, 1, 2, 3, 4, 5, 6, 7, 8, 9;[5] the decimal separator is the dot "." in many countries (mostly English-speaking),[6] and a comma "," in other countries.[3]
For representing a non-negative number, a decimal numeral consists of
If m > 0, that is, if the first sequence contains at least two digits, it is generally assumed that the first digit am is not zero. In some circumstances it may be useful to have one or more 0's on the left; this does not change the value represented by the decimal: for example, 3.14 = 03.14 = 003.14. Similarly, if the final digit on the right of the decimal mark is zero—that is, if bn = 0—it may be removed; conversely, trailing zeros may be added after the decimal mark without changing the represented number; [note 1] for example, 15 = 15.0 = 15.00 and 5.2 = 5.20 = 5.200.
For representing a negative number, a minus sign is placed before am.
The numeral represents the number
The integer part or integral part of a decimal numeral is the integer written to the left of the decimal separator (see also truncation). For a non-negative decimal numeral, it is the largest integer that is not greater than the decimal. The part from the decimal separator to the right is the fractional part, which equals the difference between the numeral and its integer part.
When the integral part of a numeral is zero, it may occur, typically in computing, that the integer part is not written (for example, .1234, instead of 0.1234). In normal writing, this is generally avoided, because of the risk of confusion between the decimal mark and other punctuation.
In brief, the contribution of each digit to the value of a number depends on its position in the numeral. That is, the decimal system is a positional numeral system.