If formula_38 is negative, then formula_34 points to the side without the light, so start over with formula_34 replaced by its negative. This reflected direction vector points back toward the side of the surface where the light came from. Now apply Snell's law to the ratio of sines to derive the formula for the refracted ray's direction vector:  The formula may appear simpler in terms of renamed simple values formula_48 and formula_49, avoiding any appearance of trig function names or angle names:  Example:  The cosine values may be saved and used in the Fresnel equations for working out the intensity of the resulting rays. Total internal reflection is indicated by a negative radicand in the equation for formula_54, which can only happen for rays crossing into a less-dense medium (formula_55). When light travels from a medium with a higher refractive index to one with a lower refractive index, Snell's law seems to require in some cases (whenever the angle of incidence is large enough) that the sine of the angle of refraction be greater than one. This of course is impossible, and the light in such cases is completely reflected by the boundary, a phenomenon known as total internal reflection. The largest possible angle of incidence which still results in a refracted ray is called the critical angle; in this case the refracted ray travels along the boundary between the two media. For example, consider a ray of light moving from water to air with an angle of incidence of 50°. The refractive indices of water and air are approximately 1.333 and 1, respectively, so Snell's law gives us the relation  which is impossible to satisfy. The critical angle θcrit is the value of θ1 for which θ2 equals 90°:  In many wave-propagation media, wave velocity changes with frequency or wavelength of the waves; this is true of light propagation in most transparent substances other than a vacuum. These media are called dispersive. The result is that the angles determined by Snell's law also depend on frequency or wavelength, so that a ray of mixed wavelengths, such as white light, will spread or disperse. Such dispersion of light in glass or water underlies the origin of rainbows and other optical phenomena, in which different wavelengths appear as different colors. In optical instruments, dispersion leads to chromatic aberration; a color-dependent blurring that sometimes is the resolution-limiting effect. This was especially true in refracting telescopes, before the invention of achromatic objective lenses.