The integers form the smallest group and the smallest ring containing the natural numbers. In algebraic number theory, the integers are sometimes qualified as rational integers to distinguish them from the more general algebraic integers. In fact, (rational) integers are algebraic integers that are also rational numbers.
The word integer comes from the Latin integer meaning "whole" or (literally) "untouched", from in ("not") plus tangere ("to touch"). "Entire" derives from the same origin via the French word entier, which means both entire and integer.[9] Historically the term was used for a number that was a multiple of 1,[10][11] or to the whole part of a mixed number.[12][13] Only positive integers were considered, making the term synonymous with the natural numbers. The definition of integer expanded over time to include negative numbers as their usefulness was recognized.[14] For example Leonhard Euler in his 1765 Elements of Algebra defined integers to include both positive and negative numbers.[15] However, European mathematicians, for the most part, resisted the concept of negative numbers until the middle of the 19th century.[14]
The use of the letter Z to denote the set of integers comes from the German word Zahlen ("numbers")[3][4] and has been attributed to David Hilbert.[16] The earliest known use of the notation in a textbook occurs in Algébre written by the collective Nicolas Bourbaki, dating to 1947.[3][17] The notation was not adopted immediately, for example another textbook used the letter J[18] and a 1960 paper used Z to denote the non-negative integers.[19] But by 1961, Z was generally used by modern algebra texts to denote the positive and negative integers.[20]
The whole numbers were synonymous with the integers up until the early 1950s.[23][24][25] In the late 1950s, as part of the New Math movement,[26] American elementary school teachers began teaching that "whole numbers" referred to the natural numbers, excluding negative numbers, while "integer" included the negative numbers.[27][28] "Whole number" remains ambiguous to the present day.[29]
Like the natural numbers, Z \displaystyle \mathbb Z is closed under the operations of addition and multiplication, that is, the sum and product of any two integers is an integer. However, with the inclusion of the negative natural numbers (and importantly, 0), Z \displaystyle \mathbb Z , unlike the natural numbers, is also closed under subtraction.[30]
The integers form a unital ring which is the most basic one, in the following sense: for any unital ring, there is a unique ring homomorphism from the integers into this ring. This universal property, namely to be an initial object in the category of rings, characterizes the ring Z \displaystyle \mathbb Z .
Z \displaystyle \mathbb Z is not closed under division, since the quotient of two integers (e.g., 1 divided by 2) need not be an integer. Although the natural numbers are closed under exponentiation, the integers are not (since the result can be a fraction when the exponent is negative).
The first four properties listed above for multiplication say that Z \displaystyle \mathbb Z under multiplication is a commutative monoid. However, not every integer has a multiplicative inverse (as is the case of the number 2), which means that Z \displaystyle \mathbb Z under multiplication is not a group.
All the rules from the above property table (except for the last), when taken together, say that Z \displaystyle \mathbb Z together with addition and multiplication is a commutative ring with unity. It is the prototype of all objects of such algebraic structure. Only those equalities of expressions are true in Z \displaystyle \mathbb Z for all values of variables, which are true in any unital commutative ring. Certain non-zero integers map to zero in certain rings.
The lack of multiplicative inverses, which is equivalent to the fact that Z \displaystyle \mathbb Z is not closed under division, means that Z \displaystyle \mathbb Z is not a field. The smallest field containing the integers as a subring is the field of rational numbers. The process of constructing the rationals from the integers can be mimicked to form the field of fractions of any integral domain. And back, starting from an algebraic number field (an extension of rational numbers), its ring of integers can be extracted, which includes Z \displaystyle \mathbb Z as its subring.
The above says that Z \displaystyle \mathbb Z is a Euclidean domain. This implies that Z \displaystyle \mathbb Z is a principal ideal domain, and any positive integer can be written as the products of primes in an essentially unique way.[31] This is the fundamental theorem of arithmetic.
The traditional style of definition leads to many different cases (each arithmetic operation needs to be defined on each combination of types of integer) and makes it tedious to prove that integers obey the various laws of arithmetic.[34]
In modern set-theoretic mathematics, a more abstract construction[35][36] allowing one to define arithmetical operations without any case distinction is often used instead.[37] The integers can thus be formally constructed as the equivalence classes of ordered pairs of natural numbers (a,b).[38]
Addition and multiplication of integers can be defined in terms of the equivalent operations on the natural numbers;[38] by using [(a,b)] to denote the equivalence class having (a,b) as a member, one has:
In theoretical computer science, other approaches for the construction of integers are used by automated theorem provers and term rewrite engines.Integers are represented as algebraic terms built using a few basic operations (e.g., zero, succ, pred) and, possibly, using natural numbers, which are assumed to be already constructed (using, say, the Peano approach).
There exist at least ten such constructions of signed integers.[39] These constructions differ in several ways: the number of basic operations used for the construction, the number (usually, between 0 and 2) and the types of arguments accepted by these operations; the presence or absence of natural numbers as arguments of some of these operations, and the fact that these operations are free constructors or not, i.e., that the same integer can be represented using only one or many algebraic terms.
An integer is often a primitive data type in computer languages. However, integer data types can only represent a subset of all integers, since practical computers are of finite capacity. Also, in the common two's complement representation, the inherent definition of sign distinguishes between "negative" and "non-negative" rather than "negative, positive, and 0". (It is, however, certainly possible for a computer to determine whether an integer value is truly positive.) Fixed length integer approximation data types (or subsets) are denoted int or Integer in several programming languages (such as Algol68, C, Java, Delphi, etc.).
Variable-length representations of integers, such as bignums, can store any integer that fits in the computer's memory. Other integer data types are implemented with a fixed size, usually a number of bits which is a power of 2 (4, 8, 16, etc.) or a memorable number of decimal digits (e.g., 9 or 10).
The set Z is a denumerable set. Denumerability refers to the fact that, even though there might be an infinite number of elements in a set, those elements can be denoted by a list that implies the identity of every element in the set. For example, it is intuitive from the list ..., -3, -2, -1, 0, 1, 2, 3, ... that 356,804,251 and -67,332 are integers, but 356,804,251.5, -67,332.89, -4/3, and 0.232323 ... are not.
The unsigned integer value is the argument plus 232 if the argument is negative; otherwise, it is equal to the argument. This value is converted to a string of ASCII digits in hexadecimal (base 16) with no extra leading 0s.
The unsigned integer value is the argument plus 232 if the argument is negative; otherwise, it is equal to the argument. This value is converted to a string of ASCII digits in octal (base 8) with no extra leading 0s.
The unsigned integer value is the argument plus 232 if the argument is negative; otherwise it is equal to the argument. This value is converted to a string of ASCII digits in binary (base 2) with no extra leading 0s.
The first argument is treated as the name of a system property. System properties are accessible through the System.getProperty(java.lang.String) method. The string value of this property is then interpreted as an integer value using the grammar supported by decode and an Integer object representing this value is returned.
aa06259810