Chapter 3: Problem 9
When a ray of light passes from a region with an index of refraction \(n_{1}\) into a region with a different index of refraction \(n_{2}\), the light ray is bent (see Figure 3.16). The angle at which the light is bent is given by Snell's law. $$ n_{1} \sin \theta_{1}=n_{2} \sin \theta_{2} $$ where \(\theta_{1}\) is the angle of incidence of the light in the first region, and \(\theta_{2}\) is the angle of incidence of the light in the second region. Using Snell's law, it is possible to predict the angle of incidence of a light ray in Region 2 if the angle of incidence \(\theta_{1}\) in Region \(I\) and the indices of refraction \(n_{1}\) and \(n_{2}\) are known. The equation to perform this calculation is $$ \theta_{2}=\sin ^{-1}\left(\frac{n_{1}}{n_{2}} \sin \theta_{1}\right) $$ Write a program to calculate the angle of incidence (in degrees) of a light ray in Region 2 given the angle of incidence \(\theta_{1}\) in Region \(I\) and the indices of refraction \(n_{1}\) and \(n_{2}\). (Note: If \(n_{1}>n_{2}\), then for some angles \(\theta_{1}\). Equation \(3.8\) will have no real solution because the absolute value of the quantity \(\left(\frac{n_{1}}{n_{2}} \sin \theta_{1}\right)\) will be greater than 1.0. When this occurs, all light is reflected back into Region 1, and no light passes into Region 2 at all. Your program must be able to recognize and properly handle this condition.) The program should also create a plot showing the incident ray, the boundary between the two regions, and the refracted ray on the other side of the boundary. Test your program by running it for the following two cases: \((a) n_{1}=\) 1. \(0, n_{2}=1.7\), and \(\theta_{1}=45^{\circ},(b) n_{1}=1.7, n_{2}=1.0\), and \(\theta_{1}=45^{\circ}\).
Short Answer
Step by step solution
Key Concepts
These are the key concepts you need to understand to accurately answer the question.