blob: 7957f39b5df05c8c3ee7625783de57b6c867637c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
// Example 5.2.1 page 5.2
clc;
clear;
n1=1.47; //refractive index of fiber
n=1; //refractive index of air
r=((n1-n)/(n1+n))^2; //computing fraction of light reflected
loss=-10*log10(1-r); //loss
total_loss=2*loss;
printf("r = %.3f, which means %.1f percent of the transimitted light is reflected at one interface",r,r*100);
printf("\nTotal loss is %.3f dB",total_loss);
//answer in the book for total loss of fiber is 0.318 dB, deviation of 0.002
|