Suppose light ray passing through a medium with refractive index $n=n(y)$. In the case of an inhomogeneous medium in which $n$ varies continuously in the $y$-direction, We have curved rays that satisfy Snell's law in the form:

$$n\cos\psi=\mathrm{constant}$$ where the angle $\psi$ is the slope of the tangent to the path.

Fermat's principle states that

The actual path taken by a light ray between two fixed points makes the travel time of the ray stationary.

So that $$T[\mathcal{P}]=c^{-1}\int_{\mathcal{P}}nds$$ which reduce to (in present case) $$T[y]=c^{-1}\int_{x_0}^{x_1}dx \ n(1+\dot{y}^2)^{1/2}$$ with the help of Euler-Lagrange's Equation $$\frac{n}{(1+\dot{y}^2)^{1/2}}=\mathrm{constant}$$

And on writing $\dot{y}=\tan\psi$, this gives snell's law.

Question: If I put $\dot{y}=0 \Rightarrow y=$ constant that is not extremals and therefore not rays. But since such a ray would experience a constant value of $n$, How does the ray know that it must bend?

  • 1
    $\begingroup$ Please correct your equation -- you are missing a $dx$ -- and define your notation, $\dot y = dy/dx$. I know it seams obvious to you, but for most physicists a dot means time derivative. $\endgroup$
    – Semoi
    Dec 15, 2020 at 12:49

1 Answer 1


Fermats principle becomes clear, if you start from Huygens description of light. Huygen assumes that

light is a wave, which propagates in such a way that each disturbance generates a 
secondary spherical wave. These secondary waves interfere with each another

Using this picture we don't have a directed light beam. Instead we have a superposition of all possible paths. Thus, your original question "how does the light know which path is shortest" disappears, because now the light does not have to choose a path a priori: It just takes all the possible path and the superposition principle makes sure that correct path is dominant/enhanced.

  • $\begingroup$ I'm not concerned with the Huygens description, Can you explain it with the principle that I have given. $\endgroup$ Dec 15, 2020 at 17:02
  • $\begingroup$ The answer I gave is the best I can do. If this does not help you I am sorry. Maybe somebody else is able to. $\endgroup$
    – Semoi
    Dec 15, 2020 at 20:45
  • $\begingroup$ Thank you for your answer though. $\endgroup$ Dec 15, 2020 at 20:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.