In AQA Computer Science, you need to understand different categories of numbers and how they relate to computing.
| Number set | Symbol | Definition | Examples |
|---|---|---|---|
| Natural numbers | ℕ | Non-negative integers (whole numbers ≥ 0) | 0, 1, 2, 3, 100 |
| Integer numbers | ℤ | All whole numbers, including negatives | -3, -1, 0, 5, 100 |
| Rational numbers | ℚ | Numbers expressible as p/q where p,q ∈ ℤ and q ≠ 0 | ½, -¾, 0.25, 3 |
| Irrational numbers | — | Cannot be expressed as a fraction; non-terminating non-repeating decimals | π, √2, e |
| Real numbers | ℝ | All rational and irrational numbers | Any point on the number line |
Natural numbers are the counting numbers starting from 0 (or 1 in some definitions). In computing, natural numbers are used for counting items, array indices, and loop counters.
Integers extend natural numbers to include negative whole numbers. In computing, integers are fundamental — all CPUs natively process integers.
A rational number is any number that can be expressed as a fraction p/q where p and q are integers and q ≠ 0.
Irrational numbers cannot be expressed as a fraction and have non-terminating, non-repeating decimal expansions.
Computers cannot represent irrational numbers (or most real numbers) exactly — they use floating-point approximations. This introduces rounding errors.
Real numbers include all rational and irrational numbers — every point on the number line. The number hierarchy is:
ℕ ⊂ ℤ ⊂ ℚ ⊂ ℝ
(Natural numbers are a subset of integers, which are a subset of rationals, which are a subset of reals.)
Ordinal numbers describe position or order: 1st, 2nd, 3rd, 4th. They are used in computing to describe order of execution, priority queues, and ranking.
| Number type | How stored in computers |
|---|---|
| Natural / Integer | Binary integers (unsigned / two's complement) |
| Rational / Real | Floating-point (IEEE 754 standard) — an approximation |
| Irrational | Cannot be stored exactly — approximated by floating-point |
This distinction matters because floating-point arithmetic can introduce small rounding errors — critical in scientific computing, financial calculations, and graphics.
8 questions · instantly marked · AQA 7517 standard
| Term | Definition |
|---|
10 questions · 10 minutes