summaryrefslogtreecommitdiff
path: root/2183/CH4/EX4.1.b/Ex_4_1_b.sce
blob: 674377df3ee85b9cae69eccbb05d6f8c2aeb850c (plain)
1
2
3
4
5
6
7
8
9
10
// Example 4.1.b:signal attenuation per km
clc;
clear;
close;
L=8;// Length of fiber in km
Pi=120*10^-6;// input power in Watt
Po=4*10^-6;//Output power in Watt
alpha=(10*(log10(Pi/Po)));//Loss in dB
alphal=alpha/L
disp(alphal,"signal attenuation per km in dB/km is")