## 2 Methodology  
### Rain Flow Counting Method  
Load cycle counting is the central part of statistical processing of random load-time history. The essence of counting is to study the load characteristic value and frequency of random load-time history from the perspective of fatigue damage. There are three most commonly used cycle counting methods in engineering [18]: horizontal cross method, peak cycle method and rain flow counting method. [PERSON] and [PERSON] [19] confirmed through a large amount of data analysis and research that the fatigue life predicted by the rain flow cycle counting method is the most consistent with the actual fatigue life of the mechanical structure. The counting method is divided into single parameter counting method and double parameter counting method. Because the single parameter counting method only considers the single variable of peak and valley value, it cannot accurately describe the characteristics of the load cycle. As a counting method based on the two-parameter method, the rain flow counting method has become a widely accepted method for processing random signals and performing fatigue analysis. The rain flow counting method was proposed by [PERSON] [20] in 1968, and then [PERSON] [21] gave the mathematical definition of rain flow counting method. The rain flow counting method can directly extract the load cycles in the load sequence, and obtain the two parameters of load mean and amplitude. The load mean and amplitude represent the static strength and dynamic strength of the mechanical structure respectively. The rain flow counting method can obtain more complete load information that affects the strength of the mechanical structure, which lays the foundation for the load spectrum design and fatigue life prediction of the mechanical structure. In addition, this method can not only count the trend of load changes but also relate the fatigue characteristics of materials, so it is widely used in the field of fatigue life prediction.  
Figure 1a is the strain-time history generated under the action of alternating load, and the corresponding stress-strain response of the mechanical structure is shown in Figure 1b. Figure 1c shows that the load cycles obtained by counting rain flow is consistent with this. Therefore, the load cycles extracted by the rain flow counting method can represent the stress-strain response of the mechanical structure.  
Place the obtained load time history as shown in Figure 2, which is similar to a multilayer roof. Assuming that raindrops flow down the multi-layer roof from point O, the counting result and the rain flow counting rule corresponding to the stress-strain response are as follows:  
1. In the process of raindrops flowing down the roof, if there is no roof blocking, the raindrops will continue to flow down until it stops;
2. Raindrops that start at the peak load point will end when they encounter a peak load point higher than it;
3. Raindrops that start at the load valley will also end when they encounter a load valley lower than it;
4. When raindrops flow, they stop when they encounter the rain stream from the roof above.  
The path that the raindrops flow from the starting point to the ending point represents the load cycles. The from-to data sets in all load cycles can be calculated to obtain the amplitude and mean value data sets. The amplitude and the mean value can respectively represent the load cycles extracted from the rain flow count. The amplitude \((S_{a})\) and mean \((S_{m})\) value of the load cycle can be expressed as:  
\[S_{a}=\frac{S_{max}-S_{min}}{2} \tag{1}\]  
\[S_{m}=\frac{S_{max}+S_{min}}{2} \tag{2}\]  
Figure 1: Principle of rain flow counting method ((a) strain-time history, (b) stress-strain response, (c) cyclic extraction).