# Integer

Integers are the natural numbers, their negative values (opposite integers), and zero. Essentially, integers are numbers that can be written without a fractional component, such as 0, 1, -1, 2, -2, 3, -3 and so on.

Example

1. Which of the following are positive integers?

1, 2, -1, 4.5, 7, -3.2, 4¼

The positive integers in this list are: 1, 2, and 7.

The rest of the numbers in the list are not positive integers; -1 is a negative integer, 4.5 and -3.2 are not integers because they have a decimal component, and 4¼ has a fractional component.

2. Which of the following are integers?

-1.5, -76, 1,000,000, 15¾, 0, 48.27, -5,700, 12

-76, 1,000,000, 0, -5700, and 12 are all integers. The remaining numbers contain either a fractional or decimal component, and therefore are not integers.

## Arithmetic properties of integers

Below is a table of some of the properties of integers undergoing arithmetic operations. The properties in the table are dependent on a and b being integers.

Closure a + b is an integer a × b is an integer
Commutativity a + b = b + a a × b = b × a
Associativity a + (b + c) = (a + b) + c a × (b × c) = (a × b) × c
Existence of an identity a + 0 = a a × 1 = a
Existence of an inverse a + (-a) = 0 only -1 and 1 are invertible
Distributivity a × (b + c) = a × b + a × c

## Integers and other number sets

There are many different sets of numbers with many different names, and sometimes different definitions. Many of the sets also have a significant amount of overlap. It is important to understand the various differences between number sets since they are often discussed in mathematical contexts. Below are some of the most common number sets, specifically in terms of their relationship to the set of integers, typically denoted Z.

### Natural numbers

Natural numbers, typically denoted N (also referred to as counting numbers or sometimes whole numbers), are the set of numbers from 1 to infinity. There is a lot of overlap between natural numbers and integers. Like integers, natural numbers do not have a fractional component. The set of integers, Z, includes all the natural numbers. The only real difference is that Z includes negative values. As such, natural numbers can be described as the set of non-negative integers, which includes 0, since 0 is an integer.

It is worth noting that in some definitions, the natural numbers do not include 0. Certain texts distinguish natural numbers and whole numbers based on their inclusion of 0. In these definitions the natural numbers do not include 0 while the set of whole numbers does.

### Rational and real numbers

In the same way that the natural numbers are a subset of the set of integers, Z is also a subset of two larger number sets, namely the set of rational (Q) and real numbers (R).

Rational numbers are numbers that can be written in the form of a fraction comprised of integers. Any integer can be written in the form of a fraction as that integer over 1 (ex. ), so all integers are rational numbers, but not all rational numbers are integers.

Rational numbers, in turn, are a subset of real numbers. A real number is a quantity that can represent a distance along a line, such as a number line. Real numbers are contrasted with imaginary numbers. Imaginary numbers are numbers composed of a real number multiplied by an imaginary unit, i. Despite the name "imaginary," they have many uses in mathematical and scientific contexts, and are used to calculate things in the real world.