Ibn al-Haytham and the Science of Light
Optics & the Scientific Method

Ibn al-Haytham and the Science of Light

The father of optics — how one scholar in 11th-century Cairo invented the scientific method and explained how we see.

Optics & the Scientific Method12-Month Curriculum 12h

The Story

The Madman of Cairo

In the year 1011, the Fatimid Caliph al-Hakim summoned a scholar named Ibn al-Haytham (known in the West as Alhazen) to Cairo with a grand commission: build a dam on the Nile to control its annual flooding.

Ibn al-Haytham traveled south to study the river. He quickly realized the project was impossible — the engineering required was beyond anything the 11th century could achieve (the Aswan Dam would not be built for another 900 years). But telling the Caliph that his project was impossible was dangerous — al-Hakim was known for executing people who disappointed him.

Ibn al-Haytham did something remarkable: he pretended to be insane. The Caliph, rather than executing a madman, placed him under house arrest. For the next ten years, confined to a room in Cairo, Ibn al-Haytham conducted the experiments that would make him the most important scientist of the medieval world.

The Revolution

Before Ibn al-Haytham, the dominant theory of vision — held by Euclid, Ptolemy, and most Greek thinkers — was the emission theory: the eye sends out rays that touch objects and return with information about their shape and colour. This is intuitive (you "look at" things, directing your gaze like a searchlight) but completely wrong.

Ibn al-Haytham proposed the opposite: intromission theory. Objects are illuminated by an external light source (the Sun, a candle). Light bounces off the object in all directions. Some of that reflected light enters the eye, where it forms an image. We see because light comes IN to the eye, not because something goes OUT.

This seems obvious today. It was revolutionary in 1011. And Ibn al-Haytham didn't just assert it — he proved it through a series of experiments that established the foundations of the scientific method.

The Dark Room

Ibn al-Haytham's most famous experiment used a dark room — a chamber with a single small hole in one wall. He placed candles at various positions outside the hole and observed the light that entered.

He discovered that light from each candle traveled in a straight line through the hole and projected an inverted image on the opposite wall. When he blocked one candle, its corresponding spot of light disappeared, proving that each light source produced its own independent rays.

This was the camera obscura — literally "dark room" in Latin. It is the ancestor of every camera ever built, and it demonstrated three fundamental principles of optics:

1. Light travels in straight lines (rectilinear propagation) 2. Light from different sources does not interact (the rays cross at the hole without interfering) 3. An image is formed by the convergence of many individual light rays, each carrying information from a different point on the source

Refraction

Ibn al-Haytham then turned to refraction — the bending of light as it passes from one medium to another (from air to water, or air to glass).

He built apparatus to measure the angle of refraction precisely — observing how light bent as it entered water or glass at different angles of incidence. He discovered that the relationship between the angle of incidence and the angle of refraction was not linear (as earlier scholars had assumed) but followed a more complex pattern.

He didn't derive Snell's Law (the exact mathematical relationship, sin θ₁ / sin θ₂ = n₂ / n₁), but his measurements were precise enough that the law could have been extracted from his data. Snell independently discovered it 600 years later, in 1621.

Ibn al-Haytham also studied atmospheric refraction — the bending of light by the atmosphere, which makes the Sun appear to be above the horizon when it has actually already set. He calculated the height of the atmosphere from the duration of twilight — an estimate that, while not exact, demonstrated a sophisticated understanding of the atmosphere as a refracting medium.

The Method

What made Ibn al-Haytham truly revolutionary was not any single discovery but his method. In his masterwork, Kitab al-Manazir (Book of Optics), he laid out a systematic approach to investigating nature:

1. State the problem clearly 2. Form a hypothesis (a tentative explanation) 3. Design an experiment to test the hypothesis 4. Observe the results and record them accurately 5. Draw conclusions — and if the results contradict the hypothesis, abandon the hypothesis, not the results

This is the scientific method — and Ibn al-Haytham described it explicitly, six hundred years before Francis Bacon (often credited as the father of the scientific method in Western tradition) wrote Novum Organum in 1620.

Ibn al-Haytham was especially insistent on the importance of skepticism — even skepticism toward established authorities. He wrote: "The seeker after truth is not one who studies the writings of the ancients and, following his natural disposition, puts his trust in them, but rather the one who suspects his faith in them and questions what he gathers from them."

The Legacy

The Book of Optics was translated into Latin in the late 12th century and became the standard textbook on light and vision in European universities for the next 400 years. It influenced Roger Bacon, Kepler, Descartes, and Newton — all of whom built on Ibn al-Haytham's foundations.

The camera obscura that Ibn al-Haytham described became a tool for artists (Vermeer likely used one), astronomers (for safely observing solar eclipses), and eventually, in the 19th century, the basis of photography — when someone figured out how to make the image on the back wall permanent.

From a dark room in Cairo, under house arrest, pretending to be insane, one man built the foundations of optics, established the scientific method, and changed how humanity understands light, vision, and the pursuit of truth.

The end.

Try It Yourself

Choose your level. Everyone starts with the story — the code gets deeper as you go.

Story Progress

0%

Ready to Start Coding?

Here is a taste of what Level 1 looks like for this lesson:

Level 1: Explorer — Python
import numpy as np
import matplotlib.pyplot as plt

# Your first data analysis with Python
data = [45, 52, 38, 67, 41, 55, 48]  # measurements
mean = np.mean(data)

plt.bar(range(len(data)), data)
plt.axhline(mean, color='red', linestyle='--', label=f'Mean: {mean:.1f}')
plt.xlabel("Sample")
plt.ylabel("Value")
plt.title("Optics & the Scientific Method — Sample Data")
plt.legend()
plt.show()

This is just the first of 6 coding exercises in Level 1. By Level 4, you will build: Build an Optics Simulator.

Free

Level 0: Listener

Stories, science concepts, diagrams, quizzes. No coding.

You are here

Enrolled

Levels 1-4

Python, NumPy, Matplotlib, real projects, mentorship.

Sign Up Free

Stay Updated

Join Waitlist

Get notified when enrollment opens for your area.

Notify Me

Level 0 is always free. Coding levels (1-4) are part of our 12-Month Curriculum.