## 2 Formulation for Modeling
### Main Formulas for Inverse Wave Estimation
Thus, it is practical to specify \(R\). On the other hand, \(Q\) is generally more difficult to determine, because \(Q\) is sometimes dynamically varying during filtering and it cannot be directly observed in the process of estimation. In a simple process, satisfactory estimation can sometimes be obtained by setting the appropriate \(Q\). The tuning of \(Q\) and \(R\) can provide excellent filter performance, regardless of whether there is a reasonable basis for choosing the parameters [15]. Thus, [16] described \(R\) and \(Q\) as model-specific \"tuning knobs\" that determine filter performance and expressed choosing them as \"spirit of observer design\". First, \(P_{\overline{1}}\) was set large enough to make the initial convergence fast, as Equation (18). This is because the initial state is uncertain. In the long run, this initial value does not make much difference in the filter performance [13]. Subsequently, to design the proper fixed value of \(Q\), it is assumed that there is no measurement error, which means that \(R\) is 0. From a number of tests, the appropriate \(Q\) value was set as Equation (19), so that the estimation is good enough and P does not diverge. \[P_{\overline{1}}=\left[ \begin{array}{cc}50_{l\times i}&0\\ 0&50_{\times i}\end{array} \right] \tag{18}\]  
\[Q=\left[ \begin{array}{cc}10^{-5}_{\times i}&0\\ 0&10^{-5}_{\times i}\end{array} \right] \tag{19}\]  
where  
\(i\): half the length of \(x\)  
Only heave motion is considered to simplify the case. R was calculated by Equation (20) and it remains as the fixed value while the filter is running. The standard deviation of heave motion sensor error is set to be 2.3 cm, referring to the test result of a commercial product [17]. Thus, when only heave is considered, R is \(5.29\times 10^{-4}\), which is the square of 0.023 m.  
\[R=diag\left( \begin{array}{c}\sigma_{1}{}^{2}\\ \sigma_{2}{}^{2}\\ \vdots\\ \sigma_{l-1}{}^{2}\\ \sigma_{l}{}^{2}\end{array} \right) \tag{20}\]  
where  
\(\sigma\): sensor noise (error) standard deviation  
\(l\): \(l\)th response or mode  
A freely floating FPSO (Floating Production Storage and Offloading) in Figure 4 was selected as the vessel. The total number of 1831 quadrilateral panels was used after the convergence test. The details of the vessel are given in [18]. Figure 5 is the RAO of the FPSO. The vessel's transfer function (or RAO) was numerically computed while using a three-dimensional (3D) diffraction/radiation panel program, WAMIT software. Figure 4: Floating Production Storage and Offloading (FPSO) mesh (LPP (length between perpendiculars): 310 m, B: 47 m, Draft: 15 m). A uni-directional JONSWAP wave spectrum with Hs = 2 m, Tp = 7 s, and enhancement parameter = 2.2 is considered. The significant wave height, Hs is defined as the average of the 1/3 largest waves. It can be calculated from either wave spectrum or wave time series. Tp is the spectral peak period. Hs and Tp are used as key index parameters since the purpose of the Kalman filtering is to inversely estimate the overall shape of the spectrum. Subsequently, the corresponding heave motion spectrum was calculated while using the calculated RAO. Afterwards, the corresponding irregular-motion time series were generated by Equation (29). Subsequently, a white noise that was equivalent to the standard deviation of sensor error 2.3 cm was artificially added (Figure 6). Afterwards, the motion-time-series data, including the sensor error, was inputted to the present Kalman filter process. The frequency range of the white noise is set to be the same as that of input wave spectrum. The previous equations and conditions were applied. First, the frequency range was limited to 0.1-1.15 rad/s, as in [8]. The Kalman filter was run for 1000 s. The real-time spectra were calculated during that time. The spectral estimation was good after the initial transient stage, as indicated in Figure 7. This shows that the Kalman filter is well designed up to this point.