Fermat's principle (biography on p. 275 ) in optics states that light traveling from one point to another follows
that path for which the total travel time is minimum. In a uniform medium, the paths of “minimum time” and
“shortest distance” turn out to be the same, so that light,
if unobstructed, travels along a straight line. Assume
that we have a light source, a flat mirror, and an ob-
server in a uniform medium. If a light ray leaves the
source, bounces off the mirror, and travels on to the observer, then its path will consist of two line segments,
as shown in Figure Ex-62. According to Fermat’s principle, the path will be such that the total travel time t is
minimum or, since the medium is uniform, the path will
be such that the total distance traveled from $A$ to $P$ to $B$is as small as possible. Assuming the minimum occurs
when $d t / d x=0$ show that the light ray will strike the
mirror at the point $P$ where the where the “angle of incidence” $\theta_{1}$ equals the the “angle of reflection” $\theta_{2}$