## 2 Principle of the FOG-Based MWD  
In order to fit the narrow and slim downhole environment, the FOG-based MWD structure should be designed to be slender. A schematic diagram of FOG-based MWD is shown in Figure 1. The FOG-based MWD is mounted in the downhole drilling tools closed to the bit. We just need to install these directional sensors onto a stable platform, which connected with the drilling string by bearings which could separate the motion of directional sensors from the drilling string. It realizes the FOGs-based MWD does not rotate with the drilling string. The FOG-based MWD mainly consists of three FOGs, three ACCs and circuit boards. These FOGs are perpendicular to each other as well as the ACCs. FOG is composed of an optic fiber coil and signal-processing circuit board. The FOG-based MWD has a length of 1 m and its diameter is 35 mm. Its power consumption is 10.4 W. Its supply voltage range is from 18 V to 36 V, and its rated supply voltage is 26 V.  
The flow chart of the FOG-based MWD measurement algorithm is represented in Figure 2[6]. The FOG-based MWD are installed into the bottom hole, assembled with their sensitive axes aligned toward the forward direction (Z), the transverse direction (\(\Upsilon\)) and the vertical direction (X). These three axes form the body frame (b-frame). The local level frame (l-frame), which is the East-North-Up frame with axes along the east, north, and vertical directions, is used as the common reference frame. The earth frame (e-frame) is defined with its \(Z\)-axis parallel to and aligned with the direction of the Earth's rotation. In the equatorial plane, the \(X\)-axis locates the Greenwich meridian, and the \(Y\)-axis completes the right-hand system. The inertial frame (i-frame) has the common definition that the \(Z\)-axis is aligned with the direction of the Earth's rotation, the \(X\)-axis is aligned with the direction of the Earth's rotation spring equinox in inertial space and the \(Y\)-axis completes the right-hand system. Coordinate systems are established to allow information to be exchanged between interfacing systems in a consistent manner and help readers to understand the survey algorithm of the FOG-based MWD. Firstly, the carrier angular velocity \(\widetilde{\mathbf{\omega}}_{ib}^{b}\) is measured by the FOGs in b-frame. The carrier acceleration \(\widetilde{\mathbf{f}}_{ib}^{b}\) is measured by the ACCs in b-frame. Secondly, the errors in the original sensor data should be compensated. \(\mathbf{\omega}_{ib}^{b}\) and \(\widetilde{\mathbf{f}}_{ib}^{b}\) stands for the data whose error has been compensated. Thirdly, the attitude matrix \(\mathbf{C}_{b}^{l}\) is updated by using angular velocity \(\mathbf{\omega}_{ib}^{b}\). Fourthly, \(\mathbf{\omega}_{ib}^{b}\) and \(\widetilde{\mathbf{f}}_{ib}^{b}\) are transferred from b-frame into the l-frame by the updated attitude matrix \(\mathbf{C}_{b}^{l}\). The \(\mathbf{C}_{b}^{l}\) is described in (1) [22]. Figure 1: Schematic diagram of a FOG-based MWD. Figure 2: Flow chart of the FOG-based MWD measurement algorithm. \[\mathbf{C}_{b}^{l}=\left[ \begin{array}{ccc}\cos A\cos T+\sin A\sin I\sin T&\sin A\cos T &\cos A\sin I-\sin A\sin I\cos T\\ -\sin A\cos T+\cos A\sin I\sin T&\cos A\cos I&-\sin A\sin I-\cos A\sin I\cos T \\ -\cos I\sin T&\sin I&\cos I\cos T\end{array} \right] \tag{1}\]  
Whereas, the \(A\) is azimuth, \(T\) is tool face angle and \(I\) is inclination. In the l-frame, the real-time position, velocity and attitude which describe the 3D borehole trajectory could be calculated by the inertial navigation algorithm. The inertial navigation algorithm has a defect wherein its results could be accumulated over time because of the sensors' error items. Thus, before using the sensors, we need to calibrate their error items and compensate them. However, there are still residual errors in the sensors' data. The Kalman filter method could estimate and compensate the sensors' residual error online by fusing a piece of external information.