# Equipment Health Assessment: Time Series Analysis for Wind Turbine Performance
## 2 Data and Methods
### Methods
#### 2.2.1 Long Short-Term Memory (LSTM)  
Recently, deep learning methods, especially recurrent neural networks (RNNs) and long short-term memory networks (LSTMs) [18], have revolutionized the time series prediction landscape [31; 33]. When applied to power function prediction, these DL methods can capture intricate dependencies and nonlinearities inherent in the data. Additionally, convolutional neural networks (CNNs) can be employed to capture spatial patterns within the data [32]. Deep learning models, while computationally intensive, offer the advantage of automatic feature extraction, enabling them to discern complex relationships, and making them highly effective in accurately predicting power functions even in dynamic and intricate scenarios. Their ability to handle vast amounts of data and learn hierarchical representations often leads to superior performance in power function prediction tasks [34].  
LSTM is a type of RNN architecture, specifically designed to capture long-term dependencies in sequential data, making them ideal for predicting power functions over time as seen in Figure 3. Traditional RNNs often struggle with learning patterns in data sequences that are separated by many time steps. LSTMs were introduced to address this issue by incorporating memory cells and sophisticated gating mechanisms. LSTMs are widely used in various applications such as natural language processing, speech recognition, and time  
Figure 2: Actual power output of the 13 wind turbines (black: bad performance, orange: good performance).  
series prediction due to their ability to capture long-term dependencies in sequential data. LSTM components are as follows:  
1. Hidden state & new inputs--hidden state from a previous timestep (\(h_{t-1}\)) and the input at a current timestep (\(x_{t}\)) are combined before passing copies of it through various gates.
2. Forget gate--this gate controls what information should be forgotten. Since the sigmoid function ranges between 0 and 1, it sets which values in the cell state should be discarded (multiplied by 0), remembered (multiplied by 1), or partially remembered (multiplied by some value between 0 and 1).
3. Input gate helps to identify important elements that need to be added to the cell state. Note that the results of the input gate get multiplied by the cell state candidate, with only the information deemed important by the input gate being added to the cell state.
4. Update cell state--first, the previous cell state (\(c_{t-1}\)) gets multiplied by the results of the forget gate. Then we add new information from [input gate \(\times\) cell state candidate] to get the latest cell state (\(c_{t}\)).
5. Update hidden state--the last part is to update the hidden state. The latest cell state (\(c_{t}\)) is passed through the tanh activation function and multiplied by the results of the output gate.
6. Finally, the latest cell state (\(c_{t}\)) and the hidden state (\(h_{t}\)) go back into the recurrent unit, and the process repeats at timestep \(t+1\). The loop continues until we reach the end of the sequence.