CLEANUP - changes to folder structure
This commit is contained in:
11
Functions/propagation_time.m
Normal file
11
Functions/propagation_time.m
Normal file
@@ -0,0 +1,11 @@
|
||||
function prop_time = propagation_time(fiber_len_m)
|
||||
|
||||
c = physconst('lightspeed'); % Speed of light in vacuum (m/s)
|
||||
n = 1.46; % Refractive index of the fiber
|
||||
|
||||
% Calculate the propagation speed in the fiber
|
||||
propagation_speed = c / n;
|
||||
|
||||
% Calculate the propagation time
|
||||
prop_time = fiber_len_m ./ propagation_speed;
|
||||
end
|
||||
Reference in New Issue
Block a user