Open ojnas opened 5 years ago
Thank you for this feedback! @jeanluc-auge is putting together some comments and will provide feedback after the TIP Summit.
Hi, thank you for your comments and taking the time to check the code. This is not a bug, and I stand by this implementation.
@jeanluc-auge, thinking a bit more about this, I have larger issues with the EDFA model. Your reasoning above applies to variable gain EDFAs (with internal VOA). I think an "advanced model" should be able to model any type of EDFA. For example, fixed gain EDFAs (without internal VOA) typically specifies a gain range as well as an optimal flat gain between gain_max and gain_min. So three gain parameters would be needed instead of the two (gain_min and gain_flatmax) that are currently allowed. For such an EDFA, the tilt is a function of the gain (e.g. represented by the dgt - dynamic gain tilt) and it is not possible to set a tilt target independently of the gain.
In the current code, distinction between fixed_gain
, variable_gain
and "advanced model" is only done when calculating NF, not when calculating gain profile. I think this is confusing since it does not represent what is normally meant with fixed vs. variable gain EDFAs.
Two more questions related to this:
There is a hard-coded parameter TARGET_EXTENDED_GAIN
in the select_edfa
function. Shouldn't the extended gain range rather be specified per type_variety
in eqpt_config.json
?
The fact that the gain starts to tilt when entering the extended gain range does not seem to be implemented in the code, or do I miss something?
In the
_calc_nf
method in the EDFA class, for the advanced model, the average NF is evaluated from target gain and polynomial coefficients like this:nf_avg = polyval(self.params.nf_fit_coeff, -dg)
where
dg
should be the difference between target gain and (average) design-flat gain but is calculated like this:dg = max(self.params.gain_flatmax - gain_target, 0)
So for target gain > design-flat gain
dg
will be 0 and average NF will be constant. It this really a correct model? I think the polynomial fit should be valid for any target gain anddg
should simply be calculated as:dg = self.params.gain_flatmax - gain_target