## 2 Materials and Methods
Although the promising results for the classification and clustering tasks in the data science domain, few works use GP-based feature construction for diagnostics. [PERSON] et al. [30] use GP to construct artificial features for fault detection using the Fisher rate as the fitness metric. [PERSON] et al. [31] propose a fault diagnosis approach based on the extraction, construction, and combination of features through GP that uses classification results of the k-NN algorithm in the fitness function. On the contrary, feature construction through GP is mainly investigated for prognostics to identify degradation indicators that reveal the failure progression [32]. Unlike features for diagnostics, which have to be as much different as possible for distinct health conditions, an optimal HI should have peculiar characteristics. [PERSON] et al. [33] provide an overview of the HI evaluation criteria for prognostics, divided into two categories: the first looks at the performance of the HI construction phase, and the second focuses on prognostic results. Many existing works use the evaluation criteria of the first category and, in particular, the intrinsic characteristic of the HI, such as monotonicity, trendability, and failure consistency. [PERSON] [34] proposes a GP-based HI construction approach for automatically identifying prognostics features for RUL prediction. They extract statistical features in the time domain first. Then a single-objective fitness function, including monotonicity, is introduced to construct an optimal HI. Similarly, [PERSON] et al. [32] adopt monotonicity as the fitness function for prognostics of rotating machinery. [PERSON] et al. [24] use a GP-based HI construction for rolling bearings prognostics. In this case, the original feature set includes features in the time, frequency, and time-frequency domains, and the fitness function is equal to the arithmetic mean of three terms, i.e., monotonicity, trendability, and deviation. [PERSON] et al. [33] propose a multi-criteria GP-based HI construction methodology, in which the input feature set consists of 11 time-domain features, and the fitness function is represented by a combination of eight different HI evaluation criteria. [PERSON] et al. [35] include GP in the stochastic process for RUL prediction. In particular, considering the characteristics of the degradation models, \begin{table}
\begin{tabular}{c c} \hline
**Kind of Primitives** & **Example(s)** \\ \hline Arithmetic & Add, Multiplication, Division \\ Mathematical & Sin, Cos, Exp \\ Boolean & AND, OR, NOT \\ Conditional & IF-THEN-ELSE \\ Looping & FOR, REPEAT \\ \hline \end{tabular}
\end{table} 
Table 1: Function set. two properties of the HI are identified, i.e., consistency and the average range of HI, and considered in the fitness function. Similar to the works mentioned above, this paper uses a GP for HI construction based on three metrics, i.e., monotonicity, trendability, and prognosability. In addition, GP is also used for constructing system-level features and classifying the system setting. Table 2 summarizes the main approaches adopted in the related literature for feature extraction, feature construction, and HI construction through Genetic Programming. The first difference of the present study with respect to related works lies in the use of GP for two distinct purposes, i.e., features construction and HI construction, which allow realizing a simultaneous analysis at a system level and a component level. Indeed, features with different trends are built from the same feature set consisting of time-domain features extracted from raw signals depending on the fitness function included in the GP training. In particular, a classification- or cluster-based fitness function addresses the machinery setting recognition issue, while a fitness function based on typical metrics for RUL prediction address the component-level prognostics issue. In addition, because the working conditions are not always known, both classification- and clustering-based fitness functions for the setting recognition.