# Real-Time Sea State Estimation for Wave Energy Converter Control via Machine Learning
## 7 Conclusions  
This study presented an LSTM-based approach for predicting sea states by utilizing features extracted from a WEC device's physical measurements. Later, a MATLAB-Python co-design architecture is used to integrate wave predictions with a PID controller to obtain optimal control actions that maximize energy extraction. The results show that the proposed control approach significantly enhances power capture in both fixed and variable sea conditions. For the fixed sea state case, the proposed method captures the same amount of power as the traditional fixed \(T_{p}\) approach, which is optimally tuned for that particular \(T_{p}\). In the variable sea state scenario, the model was able to tune PID controller gains based on the real-time wave conditions. This adaptation improved power capture by  
\begin{table}
\begin{tabular}{l c c c c c c} \hline \hline \multirow{2}{*}{**Model**} & \multicolumn{3}{c}{**Fixed \(T_{p}\)**} & \multicolumn{3}{c}{**Variable \(T_{p}\)**} \\ \cline{2-7}  & \(R^{2}\)**-Score** & **RMSE** & **Pavg (W)** & \(R^{2}\)**-Score** & **RMSE** & **Pavg (W)** \\ \hline ANN & 0.95 & 0.02 & 35.6 & 0.92 & 0.04 & 33.11 \\ SVR & 0.89 & 0.09 & 34.21 & 0.87 & 0.15 & 31.86 \\ LSTM & 0.98 & 0.005 & 36.65 & 0.96 & 0.03 & 34.09 \\ Baseline (PI) & - & - & 35.26 & - & - & 27.13 \\ \hline \hline \end{tabular}
\end{table}
Table 4: Comparison of different models for fixed and variable \(T_{p}\).  
25.6%, demonstrating the effectiveness of the real-time tuning of \(K_{p}\) and \(K_{i}\) using the LSTM-predicted sea states. By leveraging these improvements, our proposed method can offer a practical, resilient solution for WEC control by focusing on device measurements, thereby reducing the need for complex and costly wave predictions.  
Conceptualization, T.A.S. and T.B.; methodology, T.B. and R.C.; software, T.A.S.; validation, R.C., G.B. and T.B.; formal analysis, T.A.S.; investigation, T.B.; resources, T.B. and R.C.; data curation, T.A.S.; writing--original draft preparation, T.A.S.; writing--review and editing, T.B. and R.C.; visualization, T.A.S.; supervision, T.B.; project administration, R.C. and G.B.; funding acquisition, T.B. All authors have read and agreed to the published version of the manuscript.  
This research was funded by Sandia National Laboratory under DOE Water Power Technologies Office DE-NA0003525.  
Not applicable.  
The data presented in this study are available on request from the corresponding author. The data are not publicly available due to privacy.  
The authors declare no conflicts of interest.  
The following abbreviations are used in this manuscript:  
\begin{tabular}{l l} ANN & Artificial Neural Network \\ AWGN & Additive White Gaussian Noise \\ CF & Crest Factor \\ CCC & Complex Conjugate Control \\ CWT & Continuous Wavelet Transform \\ DNN & Deep Neural Network \\ FBR & Feedback Resonating Control \\ LSTM & Long Short-Term Memory \\ MPC & Model Predictive Control \\ PI & Proportional--Integral \\ PTO & Power Take-Off \\ RNN & Recurrent Neural Network \\ SHAP & SHapley Additive exPlanations \\ SVR & Support Vector Regression \\ Tp & Peak Wave Period \\ WEC & Wave Energy Converter \\ \end{tabular}