Introduction
- Some sets are used so often in mathematics that they are given their own names.
- This article will cover two of them:
- Z: The set of all integers.
- R: The set of all real numbers.
Integers
- The set of all integers contains all the whole numbers, including negative numbers and 0.
- It is represented by an uppercase bold (or blackboard bold) Z:
LaTeX:
\mathbb{Z} = \{ ..., -3, -2, -1, 0, 1, 2, 3, ... \}
code (Python)
i = 1
print(type(i)) # prints <class 'int'>
Real Numbers
- The set of all real numbers contains every number that is not imaginary. This includes:
- Integers: e.g. 0, 1, 2
- Rational Numbers: Those which can be represented as a fraction, e.g. 0.5, 1.1
- Irrational Numbers: Those which cannot be represented by a fraction, e.g.
- It is represented by an uppercase bold (or blackboard bold) R:
LaTeX:
\mathbb{R} = \{ -1, 1.4, \pi \}
code (Python)
Unfortunately we cannot represent irrational numbers using code. Instead we can approximate them as floating point numbers:r = 1.41421356237
print(type(r)) # prints <class 'float'>