Loading editor...

Snell's law of refraction

Snell's Law describes how light bends when passing between media:

We'll visualize this using the ratio and animate the incident angle.

Define the refractive index ratio and fixed height:

Convert angle to radians:

Draw the interface and normal:

Set line colors to be different:

Calculate incident ray start point: (-y tan θ₁, y)

Calculate refraction angle using Snell's Law:

Calculate refracted ray end point: (y tan \theta_2, -y)


Draw the light rays:

  • and
  • and

Highlight the two rays:


Experiment with different scenarios

Case 1: Light entering denser medium (n₁/n₂ < 1)

Notice how the refracted ray bends toward the normal.

Case 2: Light entering less dense medium (n₁/n₂ > 1)

Notice how the refracted ray bends away from the normal.


The Critical Angle

When , there exists a critical angle θc beyond which refraction cannot occur. At the critical angle, the refracted ray travels along the interface (θ₂ = 90°).

- For glass to air (n₁/n₂ = 1.5), ≈ 41.8°.

Try angles approaching the critical angle:

At the critical angle, the refracted ray becomes parallel to the interface. Beyond this angle, total internal reflection occurs (not shown here).

Try other material combinations:

  • - θc ≈ 48.6°
  • - θc ≈ 24.4°