## 2 Principle
Finally, by putting \(\mathbf{d}_{\mathbf{U}}\) into the state update equations, the new state vector in the next time slot is updated. The state update equations are listed as follows [15]:  
\[\mathbf{S}_{k}-\mathbf{A}\mathbf{S}_{k-1}, \tag{7}\]  
\[\mathbf{P}_{k}^{-}=\mathbf{A}\mathbf{P}_{k-1}\mathbf{A}^{T}+\mathbf{Q}, \tag{8}\]  
\[\mathbf{K}=\mathbf{P}_{k}^{-}\mathbf{M}^{T}(\mathbf{M}\mathbf{P}_{k}^{-}\mathbf{M}^{T}+\mathbf{R})^{-1}, \tag{9}\]  
\[\mathbf{P}_{k}=(\mathbf{I}-\mathbf{K}\mathbf{M})\mathbf{P}_{k}^{-}, \tag{10}\]  
\[\mathbf{S}_{k}=\mathbf{S}_{k}-\mathbf{K}\mathbf{d}\mathbf{z}. \tag{11}\]  
The matrices \(\mathbf{A},\mathbf{Q},\mathbf{R},\mathbf{P}_{n}\) and \(\mathbf{K}\) describe the process equation, process noise covariance, measurement noise covariance, error covariance, and Kalman gain, respectively. \(\mathbf{M}\) and \(\mathbf{S}_{k}\) represent the Jacobian matrix and innovation vector, respectively. In addition, the process noise covariance of carrier phase noise and polarization rotation can be expressed as \(\mathbf{Q}=[\text{Qpol}\cdot\mathbf{I}_{4\leftrightarrow 4},0;0;\text{QPhase} \cdot\mathbf{I}_{1\leftrightarrow 1}]\). Qpol is the Q value related to polarization, and Qphase is the Q value related to the laser linewidth. \(\mathbf{Q}\) in EKF always plays an important role. For example, with the larger laser linewidth, which means a larger phase variation, the larger Qphase value is required to achieve better performance. A similar rule applies to polarization rotation along the fiber. Therefore, conventional EKF is difficult to ensure optimal performance with dynamic signals or time-varying fiber channel conditions. Additionally, an EKF is unstable if the initial noise covariance is not properly configured. Therefore,an adaptive approach is necessary to adjust the \(\mathbf{Q}\) in an intelligent manner for dealing with dynamic conditions. This adaptation can be introduced with the following expression [20]:  
\[\mathbf{Q}_{k}=\mathbf{E}(\mathbf{K}(\mathbf{d}\mathbf{u}\times\mathbf{d}\mathbf{u}^{T})\mathbf{K}^{T})=\mathbf{K} \mathbf{E}(\mathbf{d}\mathbf{u}\times\mathbf{d}\mathbf{u}^{T})\mathbf{K}^{T}.\]  
Generally, the forgetting factor \(\alpha\) can be introduced in the following update equation to calculate \(\mathbf{Q}_{k}\). This operation can decrease the computational complexity. The forgetting factor \(\alpha\) is usually set to be 0.975. \[\mathbf{Q}_{k}=\alpha\mathbf{Q}_{k-1}+(1-\alpha)\mathbf{Q}_{k}. \tag{13}\]  
As shown in Equation (12), \(\mathbf{Q}_{k}\) is dependent on \(\mathbf{d}\mathbf{u}\) The corresponding Q value, including Qpol and Qphase is also depending on it. With a larger \(\mathbf{d}\mathbf{u}\), the higher Q value is led. In the initial stage of EKF, the residual measurement is large, and a high Q value is led. In the convergence stage of EKF, the residual measurement becomes small, and the Q value is small. In a dynamic network condition, the residual measurement will vary along with operating conditions. This means that the Q can respond to changing network conditions. A switch mode is also employed for enhancing this response mechanism and it is shown in Figure 2. We define a threshold value \(\beta\). The average of measurement residual is calculated and compared with the threshold value. If the average of measurement residual is smaller than the threshold value, the Q value will be updated. If not, the Q value is set to the previous value. The above scheme can be schematically presented in the following diagram: