# Real-Time Eye Diagram Monitoring for Optical Signals Based on Optical Sampling
## 2 Theory of Optical Sampling and Eye Diagram Recovery  
Figure 1 shows the schematic diagram of the proposed eye diagram monitoring method for an optical signal. As can be seen, the eye diagram monitoring system can be divided into three parts: optical signal input module (Part 1), sampling and quantizing module (Part 2), and eye diagram recovery and time-domain parameter extraction module (Part 3). In the optical signal input module, the optical signal under test, which is coupled output from an optical transmission link or source, is injected into a polarization controller (PC), where the polarization of the optical signal under test is adjusted to be consistent with that of the MZM in Part 2. In the sampling and quantizing module, the signal from part 1 is injected into an MZM, which is intensity modulated by a gating on-off sampling pulse from an electrical pulse generator (EPG). The modulation pulse has a repetition rate of \(1/T_{S}\) and a pulse width of \(T_{P}=1/(NT_{S})\), where \(T_{S}\) is the period of the sampling pulse, and \(N\) is a positive integer. Then, the optical signal under test is optically sampled by the pulse with a repetition rate of \(1/T_{S}\) and a pulse width of \(T_{P}\). It should be noted that the repetition rate and the pulse width can be tuned by tuning the EPG. Then, a sampled signal is generated from the MZM, and the sampled signal is transmitted into a pulse broadening module, in which the pulse is broadened to match the sample rate of a low-speed electrical  
ADC. The broadened sampling pulse is quantified at the same rate as the sampling pulse in the ADC. In addition, a clock generator is used to synchronize the ADC and the EPG, ensuring the quantization rate of the ADC matches the sampling rate of the sampling pulse train. Note that the ADC quantizing efficiency can be increased due to the excellent match between the hold time of the sample-and-hold circuit in the ADC and the pulse width of the broadened sampling pulse. In the eye diagram recovery and time-domain parameters extraction module, the quantified data from the low-speed ADC is used to recover the eye diagram. Figure 2 shows the principle of random equivalent sampling to recover the eye diagram using the ADC data. The optical pulse is sampled with a repetition rate of \(1/T_{S}\) and a pulse width of \(T_{P}=1/(NT_{S})\). Then, the sampling rate of the ADC is chosen to be \(f_{S}=1/T_{S}\). The random equivalent sampling is achieved when the sampling rate \(f_{S}\
eq(1/T_{S})\times n\), where \(n=1/2\), \(1,2,3\cdot\cdots\cdots\). Assuming the period of the optical signal under test is \(T_{X}\) and moving the sampled and quantified data within \(2T_{X}\) with the specific time relations between the periods of the optical signal under test and the sampling pulse, the eye diagram is obtained with an equivalent sampling rate of \(f_{ES}=M/T_{S}\), where \(M=T_{X}/(T_{S}-T_{X})\). For example, when the period of the optical signal is \(T_{X}=400\) ps (2.5-Gb/s rate) and the period of the sampling pulse is \(T_{X}=420\) ps (2.38-GS/s sampling rate), an equivalent sampling rate of \(f_{ES}=50\) GS/s can be achieved. Generally, the frequency or the period \(T_{X}\) of the optical signal under test can be achieved using a fast Fourier transform (FFT). However, a huge amount of data and computation are necessary to realize the FFT. Here, an algorithm based on the infinitesimal calculus is proposed to directly obtain the period \(T_{X}\) of the optical signal under test and recover the eye diagram. According to the eye diagram in Figure 3, the eye area can be calculated based on the concept of infinitesimal calculus. \[S=sum(w_{i}\times h_{i}),i=1,2,3,\cdots,m, \tag{1}\]  
where the eye area is divided into \(m\) rectangles, and \(w_{i}\) and \(h_{i}\) are the width and height of the \(i\)-th rectangle, respectively. Figure 4 shows the eye diagram recovery algorithm, and the eye diagram recovery can be realized by the six steps shown below.