I've been reading about Fermats last principle in Feynmans lectures on physics, and he sort of goes through the derivation of Snell's law by considering a simple refraction and applying a bit of trigonometry (see photo). What I'm having trouble with is this. He states that if you take a two paths separated by the distance XC when hitting the 2nd medium, and introduce the assumption that XC is very small, then AC - EC ≈ AX. But what if the distance of XC is not small enough to make this assumption valid? Surely then the trigonometry would not work and you would end up with a different equation for Snell's law?