# Polynomial Modeling of Noise Figure in Erbium-Doped Fiber Amplifiers
## 3 Materials and Methods
### Test Setup  
Figure 3 illustrates the setup used to obtain the measurement datasets. This configuration enables the measurement of the input and output Power Spectral Densities (PSD) of the signal passing through the amplifier. The signal is fed to the amplifier using a Variable Optical Attenuator (VOA) to achieve the desired input power, while the target gain and tilt are set programmatically on the EDFA. Devices from different vendors--and even different device types from the same vendor--require individual characterization and distinct models due to variations in internal EDFA architecture, which result in performance differences across devices. However, devices of the same type from the same vendor are treated as a single group, as the primary differences among them stem from manufacturing tolerances. Most of these devices support both high- and low-gain operation modes, which must be considered separately when developing models. Manufacturers typically optimize the noise figure independently for each mode, leading to uncorrelated performance characteristics. The characterization process is influenced by the spectral load used during measurements. These measurements were conducted under an even spectral load, with the number of active channels varying between 38 and 48 depending on the device model. The input power profile followed a flat Wavelength Division Multiplexing (WDM) comb distribution. The channels were spaced at 100 GHz, each with a bandwidth of 32 GHz. All measurements were performed using an OSA with a Resolution Bandwidth (RBW) of 10 GHz. To construct the datasets, it is essential to define appropriate step sizes for the input parameters. This strategy ensures a comprehensive understanding of their influence on the noise figure while maintaining dataset size within practical limits. Accordingly, the parameters are selected as follows:  
Figure 3: Diagram of the test setup for measuring input (blue) and output (red) power spectral densities. 1. **Total input power**: For the low-gain range, values span from \(-10\,\mathrm{dBm}\) to \(6\,\mathrm{dBm}\), while, for the high-gain range, they range from \(-18\,\mathrm{dBm}\) to \(2\,\mathrm{dBm}\), both with a step size of \(2\,\mathrm{dB}\). 2. **Gain**: Depending on the specific EDFA model and gain range, values are selected within the \(10\,\mathrm{dB}\) to \(35\,\mathrm{dB}\) range, with a step size of \(1\,\mathrm{dB}\). 3. **Tilt**: Defined within either \(-5\,\mathrm{dB}\) to \(5\,\mathrm{dB}\) or \(-3\,\mathrm{dB}\) to \(3\,\mathrm{dB}\), depending on the EDFA model, with a step size of \(1\,\mathrm{dB}\). Subsequent sections assess whether or not these initial step size choices are appropriate. This analysis will determine whether finer steps are necessary to maintain the desired accuracy or if larger steps could be sufficient, potentially reducing the required dataset size. The datasets collected from OSA measurements are stored in MATLAB (.mat) files. Each file corresponds to a specific device and input power configuration and follows the structure outlined below:  
1. **Gain_target**: A 1D array containing the target gain values set on the device, in dB. 2. **Gain_real:** A 1D array containing the actual gain values achieved by the device, in dB, serving as feedback relative to the target gain. 3. **Tilt_target:** A 1D array containing the target tilt values set on the device, in dB. 4. **Tilt_real:** A 2D array (one row per gain value) containing the actual tilt values achieved by the device, in dB, serving as feedback relative to the target tilt. 5. **spectrum_freq:** A 1D array listing all frequency points at which the OSA evaluated signal power, in THz. 6. **spectrum_TX_power:** A 1D array containing signal power measurements at the amplifier input across the entire frequency range, in dBm. 7. **spectrum_RX_power:** A 3D array (one row per target gain and tilt pair) containing signal power measurements at the amplifier output across the frequency range, in dBm. 8.