Introduction

Welcome back to The Real Number System and Irrationality! In the first lesson of this course, you learned that irrational numbers are those that cannot be written as a ratio of integers, and that their decimals neither terminate nor repeat. With that foundation in place, we are ready to move forward.

In this second lesson, we turn from the general definition to two specific and celebrated examples: the constants π and e. These are arguably the most famous irrational numbers in all of mathematics, and every math and science student is expected to recognize them on sight. We will learn where each one comes from, commit their standard approximate values to memory, and examine exactly why their decimal behavior marks them as irrational.

Why Some Irrationals Are Famous

Not all irrational numbers are created equal. A number like 0.1010010001000010.101001000100001\ldots is irrational, but it was invented just to illustrate a concept. Nobody uses it to design a bridge, model a bank account, or calculate the area of a park.

π and e are different. They emerge naturally from real-world phenomena — circles and continuous growth, respectively — and they appear in formulas across geometry, physics, engineering, finance, and statistics. Their importance is why mathematicians spent centuries studying their properties and ultimately proved that both are irrational. Because these constants show up so frequently, knowing their approximate values and understanding why they are irrational is practical knowledge you will use again and again.

The Number π

The constant π (spelled "pi") arises from one of the simplest shapes in geometry: the circle. If we take any circle and divide its circumference by its diameter, we always get the same number:

π=circumferencediameter\pi = \frac{\text{circumference}}{\text{diameter}} A circle with labeled circumference and diameter illustrating the ratio that defines π

No matter how large or small the circle is, this ratio is always π. Its decimal expansion begins:

π=3.14159265358979\pi = 3.14159265358979\ldots
The Number e

The constant e is sometimes called Euler's number, after the Swiss mathematician Leonhard Euler. While π comes from circles, e emerges from the study of continuous growth and appears naturally when we model compound interest, population growth, and radioactive decay.

One intuitive way to see where e comes from is to imagine investing $1 at 100% annual interest and compounding more and more frequently. As the number of compounding periods grows without bound, the total amount approaches a fixed limit — and that limit is e:

e=limn(1+1n)n=2.71828182845904e = \lim_{n \to \infty}\left(1 + \frac{1}{n}\right)^n = 2.71828182845904\ldots
Approximations Are Not Exact Values

Now that we know the approximate values of both constants, it is important to address a widespread misconception: many people believe that π equals 227\frac{22}{7}. The fraction 227\frac{22}{7} is a handy approximation, but it is exact. We can check by dividing:

Contrasting with a Rational Decimal

To sharpen our understanding, let's place π alongside a rational number that also has many decimal digits. Consider 17\frac{1}{7}:

17=0.142857=0.142857142857142857\frac{1}{7} = 0.\overline{142857} = 0.142857142857142857\ldots
Conclusion and Next Steps

In this lesson, we met two of the most important irrational constants in mathematics. π is the ratio of a circle's circumference to its diameter, approximately 3.143.14 (or 3.14163.1416 to four decimal places). e is Euler's number, tied to continuous growth, approximately 2.722.72 (or 2.71832.7183 to four decimal places). Both have decimal expansions that go on forever without repeating, and no fraction of integers can represent either one exactly.

Now it's time to put these ideas to work! In the upcoming practice exercises, you will recall the standard approximations, tackle common true-or-false misconceptions, and explain in your own words why π and e are irrational by contrasting their decimal behavior with that of a repeating decimal like 17\frac{1}{7}.

Sign up
Join the 1M+ learners on CodeSignal
Be a part of our community of 1M+ users who develop and demonstrate their skills on CodeSignal