DSF Core: Integrated Decision Support for Optimal Scheduling of Lifetime Extension Strategies for Industrial Equipment

This paper proposes a generic algorithm for industries with degrading and/or failing equipment with significant consequences. Based on the specifications and the real-time status of the production line, the algorithm provides decision support to machinery operators and manufacturers about the appropriate lifetime extension strategies to apply, the optimal time-frame for the implementation of each and the relevant machine components. The relevant recommendations of the algorithm are selected by comparing smartly chosen alternatives after simulation-based life cycle evaluation of Key Performance Indicators (KPIs), considering the short-term and long-term impact of decisions on these economic and environmental KPIs. This algorithm requires various inputs, some of which may be calculated by third-party algorithms, so it may be viewed as the ultimate algorithm of an overall Decision Support Framework (DSF). Thus, it is called “DSF Core”. The algorithm was applied successfully to three heterogeneous industrial pilots. The results indicate that compared to the lightest possible corrective strategy application policy, following the optimal preventive strategy application policy proposed by this algorithm can reduce the KPI penalties due to stops (i.e., failures and strategies) and production inefficiency by 30–40%.


Introduction
The European remanufacturing industry is estimated to have a total turnover of EUR 29.8 billion with 190,000 employees. Provided adequate support from public authorities, remanufacturing could reach up to EUR 90 billion and an associated employment of 600,000 by 2030 [1]. According to [2], the Europe Maintenance, Repair and Overhaul (MRO) distribution market size was estimated at USD 202.88 billion in 2021 and is expected to grow at a compound annual growth rate (CAGR) of 2.8% from 2022 to 2030. In addition, the manufacturing of machinery and equipment is one of the most competitive and largest manufacturing segments in Europe. Furthermore, based on [1], remanufacturing and refurbishment can contribute significantly to the well-being in Europe, as they are important lifetime extension strategies of resource-efficient manufacturing. By keeping components and their embodied material in use longer, significant environmental benefits can emerge. Less energy and fewer material resources are used, and less waste is created when products and components are used again instead of only recycling the materials. Opportunities for highly skilled jobs and economic growth would also arise; according to a recent study conducted by the European Remanufacturing Network Project, remanufacturing in Europe was assessed to reach about EUR 30 billion in 2015 and has been expected to triple up to about EUR 100 billion in Europe until 2030, employing over 500,000 people.
An electromechanical machine near its end of life (EoL) can no longer perform its required functions under the stated conditions, thus EoL decisions should be made well in advance in order to minimize the impact on production capacity [3]. One cost-effective decision is to extend the life of the machine via refurbishment or remanufacturing. However, so far there was no standard solution or even an established decision-making strategy for the refurbishing of manufacturing assets [4]. This raises the need for a Decision Support Framework (DSF) for a timely and accurate machine health forecast. There are three main challenges that need to be addressed during the decision-making process concerning the refurbishment of a machine. First, is the machine worth refurbishing? Second, what is the best time to perform refurbishment at the least cost? Finally, how should the machine be refurbished?
This paper deals with an algorithm responsible for providing recommendations to industrial end users (machinery operators and manufacturers) about the optimal lifetime extension strategy application policy for the analysed industrial equipment of the production line. This policy includes the selection of the strategies, the time of application of each and the relevant machine components. The application of this algorithm requires heterogeneous raw (sensorial or manually defined) or processed input data (past stops and downtime, degradation levels, failure probabilities, production efficiency, failure metrics, cost elements, etc.). Since many of these data may have been processed by third-party algorithms, this algorithm, which gathers all these inputs to provide integrated decision support, will be called "DSF Core" for simplicity. The DSF Core requires first training a DSF Core model based on (mainly manually defined) specifications of the production line to learn the optimal policy. Then, this model can be used (run) in order to simulate the status of the production line at every timestamp of a future time interval in terms of Key Performance Indicators (KPIs), numbers and time intervals of stops (failures and strategies) and production time percentage of each machine component under the optimal policy. It can also run real-time only to recommend strategies that should be used immediately. In both run scenarios, an initial (present) condition of the production line should be assumed. The actual condition may be inferred by information provided by the raw sensorial data and the data processed by third-party algorithms.
In particular, this algorithm may receive the following kinds of inputs. Unavailable processed inputs from third-party algorithms should be manually defined, be assigned some default values or be simulated using random generators.

•
The direct sensorial input needed is the historical and real-time information about analysed stops (failures, strategies), i.e., start-end time, related machine component and reason for each instance. Usually, the aforementioned stop information cannot be recorded directly thanks to sensorial data, may be only manually registered, may have not been performed at all or performed incompletely or inaccurately. In these cases, the stop intervals should be identified based on the behaviour of other sensorial time series (e.g., based on zero or absent values), whereas failure diagnosis algorithms should infer the related component and stop reason, especially in the case of failures accompanied by some anomaly. Failure diagnosis may be performed, e.g., using failure mode and effects analysis [5] or probabilistic graphical models [6] [such as Bayesian methods [7] in general or the time-dependent dynamic Bayesian networks [8]]. • From predictive maintenance algorithms, such as those described in [9,10], the DSF Core needs the real-time failure probabilities for each failure type for a particular forecasting horizon, computed based on sensorial data. • From degradation models, the DSF Core may receive the parameters of the Weibull distributions characterizing the lifetime of machine components with respect to various failure types. In relation to this, it may also receive real-time equivalent age and load information, which assess the respective degradation levels and degradation speeds, in accordance with the generic references [11,12]. There are also references about the reliability of specific common machine components considered in this work, such as bearing [13] and sample-detector [14].
• Thanks to extensive cost information, directly provided as input or computed based on [15] or by the DSF Core itself, the algorithm is able to perform short-term as well as long-term (using Monte Carlo simulation) assessment of the economic KPI, considering costs and profit both during production and during voluntary (strategies) and involuntary stops (failures).
The DSF Core, as well as third-party algorithms which may provide potential useful input to it from each of the above kinds, have been developed within the context of the RECLAIM project (see Funding section). The algorithm was successfully applied to three pilot industries involved in this project: GORENJE (white goods manufacturer, the white enamelling line of which is studied in this paper), HWH (producer of control systems in the welding sector) and ZORLUTEKS (cotton textile manufacturer). A couple of indicative useful DSF Core models from each pilot will be discussed in this paper.
Particularly, the remainder of the paper is organized as follows. The rest of Section 1 presents the related work found in the bibliography and the contribution of this work, Section 2 describes the generic methodology of the algorithm, and Section 3 deals with the implementation of the algorithm per pilot for various machinery components. More especially, Section 3 includes the input and results related to the trained DSF Core models, as well as execution examples of these models with simulation of the production line life cycle under the optimal strategy application policy and the relevant impact on KPIs. The results are also discussed in the same section. The deliverable is concluded in Section 4.
The lifetime extension (circular economy) and conventional (linear economy) strategies applied during the machinery life cycle which are considered by the DSF Core were defined in [16], andwere also instantiated per pilot during workshops. References [3,[17][18][19][20] include figures that mention such machinery as product and show the flow among states of the machinery during its life cycle based on the applied strategies. Table 1 summarizes the bibliographic findings about the candidate decisions proposed by decision support frameworks in manufacturing, the KPIs evaluating decision support optimization criteria, the methods used and the required input data to the optimization algorithm. A particularly systematic classification of KPIs appears in [21,22], based on which the KPIs of this work were coarsely classified as economic and environmental, as explained later in detail. In the former work, the KPIs are first scaled in the range 0-100 and then weighted based on factors defined by stakeholders, and it is asserted that they should also be determined with the help of historical data when possible. Unlike other available methodologies, the latter paper considers all the interests of the stakeholders involved in the product life cycle, who also define the KPI weighting factors based on their objectives, which generally vary and may even be conflicting. productiondistribution planning, inventory management multi-criteria decision methodology (MCDM) [analytic hierarchy process (AHP), analytic network process, decision-making trial and evaluation laboratory, elimination and choice expressing reality, preference ranking organization method for enrichment of evaluations, technique for order of preference by similarity to ideal solution, utility additive, -constraint, goal programming, weighting method] (+interpretive structural modelling) [23,24] product performance, historical product design, customer demands, assembly requirements, environment impacts,. . .

Related Work on Cost Analysis and Cost Modelling Tools
Since the economic KPI is the most important one, a cost modelling and financial analysis methodology should definitely be embedded into a decision support framework for sustainable refurbishment and remanufacturing of used industrial equipment. The DSF Core relies on [15] to estimate the costs during stops and calculates on its own the cost and profit during production. Based on the above, using a Monte Carlo simulation including discrete event simulation, it is able to further estimate economic KPI. Table 2 summarizes the information in indicative bibliographic references about the types of estimated costs, the methods used and the required input data. Most of these references are related to additive manufacturing. A more extensive bibliographic study on cost modelling and analysis is included in [15]. Table 2. Relation among data, cost types and methods based on bibliography about cost analysis and cost modelling tools.

Input Data
Cost Types Methods Reference(s) • three-dimensional model and related information (materials, tolerances, surface finish,. . . ) • geometry, manufacturing process, materials, other non-geometric information manufacturing predictive analytics modelling, least absolute shrinkage and selection operator and elastic net modelling 1 , process-oriented feature extraction [62] raw material price, initial investment labor, part material, energy, support material, overheads fixed values of parameters [63] few primary user parameters, optional secondary user parameters to increase estimation accuracy machine, material, labor, post-processing break-down (build time estimated by considering activities undergone by machine for preparation of a layer and multiplying it by total number of layers) [64] module dimensions and format, factory assumptions and cost inputs, production equipment assumptions, materials manufacturing (sum of tool and facility, spare parts, footprint, electricity, material cost-usage) Monte Carlo analysis to estimate cost distribution [65] product type, design method, machining condition parameters (tool diameter/tip, cutting/free movement feed rate, cut depth, step over) machining, printing (process), material, labor, postprocessing calculating parameters affecting air manifold production price (cost types) (machining simulations performed with "Power mill 2018 software") [66] vendor's/buyer's holding cost, cost of replacing imperfect goods, cumulative distribution function, mean/variance of lead time, buyer's ordering cost, backorder cost, coefficient of variance per time period, batch size, initial probability of shifting out-of-control from in-control state, vendor's initial setup cost, demand scaling parameter, scaling/shape parameters related to advertising demand function, annual fractional cost of capital investment, variation constant of product tool/die cost, machine running cost, scaling parameters related to PQI/SCR, reorder point for buyer, expected backorder quantity/on-hand inventory, mean lead time demand vendor [holding, setup, variable production, defective, process quality improvement (PQI), setup cost reduction (SCR), advertisement] exact computations also considering assumptions based on bibliography [67] 1 These two are regularization and are dimensionality reduction techniques for linear regression.
The above studies consider cost only during specific stages of products life cycle. However, insightful decision making requires cost evaluation during the whole life cycle. The review in [68] examines life cycle cost (LCC) studies, along with the complementary life cycle assessment (LCA), which corresponds to the environmental factors, and the integration between the two. According to that review, there is no general standard for the application of LCC; there is just ISO 15686-5 for buildings and built assets. Although summing up costs per functional unit is a common practice, the detailed cost elements depend on the objectives of each study. LCA, along with its integration with LCC, is discussed in the next heading.

Related Work on Life Cycle Assessment and Integration with Life Cycle Cost
As mentioned above, LCA is the evaluation of environmental KPIs throughout a product's life cycle. Thus, this subsection complements the previous one, which examined the economic KPI.
LCA is performed at three system boundary levels with corresponding considered impacts as mentioned below [69]: • Cradle-to-gate: raw material extraction and material production until the exit of the product from the factory; • Cradle-to-grave: raw material extraction, material production, exit of the final product from the factory, as well as the use, demolition and waste phases; • Cradle-to-cradle: raw material extraction, material production, exit of the final product from the factory, as well as the phases of use, demolition, waste, recycling and extensive reuse of the waste.
Our work evaluates the economic and environmental KPIs from the viewpoint of the user of the industrial machinery throughout a representative period of production with intermediate failures and lifetime extension strategies regarding this machinery.
The particular challenge posed by the environmental factors is the diversity of their measurement units. According to [70], environmental factors generally concern resource consumption and greenhouse gas emissions. A finer classification of the environmental factors follows below: As admitted in this reference, although there are standards for the application of LCA, they are too general, giving much freedom regarding the definition of scopes, boundaries and functional units.
Examples of methods for integrating the environmental factors within a common environmental indicator are mentioned in [69,70]  (applied, e.g., in the industry-related paper [71]), LIME, LUCAS, Swiss Ecoscarcity and the Methodology Study for Ecodesign of Energy-using Products. However, the comparison of the environmental factors with the economic KPI is another issue. For this reason, a good practice is the monetization of environmental impacts [68], which was adopted in our paper. Another alternative is the use of fuzzy logic and the Likert scale [68,72] to qualify the heterogeneous factors in a common scale for comparison. However, such an approach has the drawback that the qualitative evaluation is subjective, and the evaluation accuracy is partly lost due to discretization. What is more, in our paper, the upper limits of the original individual KPIs are highly dependent on the lifetime extension strategy application policy, which would make the mapping to the Likert scale even more questionable and subjective. Finally, there are some hybrid approaches combining LCA with exergetic analysis with the use of the second law of thermodynamics, but they also suffer from the lack of appropriate indicators and a well-established set of calculations, as well as the lack of complete and updated data to overcome the uncertainty [73].
According to [69], many input data are needed to apply LCA. In the RECLAIM project, most sensorial data became available recently, and a systematic LCA has not been performed within the context of the DSF Core, but it will be conducted by another tool afterwards. Instead, the DSF Core at this stage relies on static specifications, assumptions and simulations to evaluate the environmental impacts within a sufficiently large future interval.
As is easily observable from the literature review conducted on LCA, the detailed environmental elements which are worth considering are use-case-specific. The aforementioned work in [70] examines textile production, so it is comparable and quite in line with the evaluation of environmental KPIs in our paper for the ZORLUTEKS pilot. However, related work on LCA for white goods manufacturing (GORENJE pilot) and friction welding (HWH pilot) was not found. There is just related work on welding [74]. In our work, each pilot selected for itself the most important environmental elements and the desired improvements in them to be achieved during the RECLAIM project. These were classified for the DSF Core based on [21] and according to their measurement units. LCA has also been applied to other industrial use cases, such as mass timber [75] and silicon photovoltaic modules [76] production, as well as in other settings.

Contributions of This Work beyond the State of the Art
The mathematical formulation of the optimization problem to be solved by the DSF Core algorithm in RECLAIM was inspired mainly by the MCDA approach of [21], which was also taken into account by the authors in their previous work on demand-side management [77] and is suitable for integrating economic and environmental KPIs [68]. However, this method in those papers is not combined with life cycle evaluation of KPIs, which enables decision support considering the strategy application policy impact on their values both during the application of strategies and in the long run. In general, as mentioned in the review of [25], big data analysis for smart decision making for the whole life cycle of a production line considering multiple objectives is rarely performed, so the current work may support progress in this research direction. In contrast to the other relevant methods found in the literature [23], which balance heterogeneous KPIs subjectively, this work introduces a method for automatic objective balancing of KPIs measured in different units by converting all environmental units to economic units. In addition, this paper demonstrates that, thanks to life cycle evaluation of KPIs and Monte Carlo simulation, decision support may be provided not only for the present, but for any timestamp of the simulation interval by estimating when each strategy will be favorable in the future under a specific optimal application policy. Since the evaluation of the objective function in this work is time-consuming and the value of the function depends on its arguments only within a subset of its domain, a typical optimization method, such as MINLP [58,59], is inappropriate and intractable. Thus, a technique for smarter selection and updating of the decision variables is introduced, so that the function is optimized with the fewest possible evaluations. The DSF Core supports health-based recovery planning at the component, machine and production line level while considering economic and environmental effects. Instead, other studies, such as [57], disregard the environmental factors and only consider the economic KPI or vice versa [56]. The DSF Core aims at helping the machinery operators and manufacturers make efficient EoL decisions at different service and life periods. More especially, it considers failure probabilities estimated based on both real-time sensorial data and the degradation level of components, as well as detailed cost modelling and financial analysis computations. In all cases, it considers dependencies among different machine components in terms of failures and operational efficiency in contrast to related references considering a single component, such as [27]. Furthermore, the quantitative optimization method used in this paper seems to be more suitable for the problem solved than qualitative approaches [18,28,30,61], since the latter involve some information loss due to uncertainty.
The cost modelling and analysis method of this paper also goes beyond the state of the art because apart from the static specifications it also supports the consideration of the (near-)real-time condition of the production line, expressed by stops and the degradation level of components. Furthermore, as mentioned, the Monte Carlo simulation method developed in this work enables a relatively accurate cost estimation for every timestamp of a future time interval as well, and by extension a life cycle estimation of the economic KPI. This also applies to the other KPIs when considered. The other KPIs are generally simpler and more straightforward to compute, both during stops and during production, as shown later. Previous similar studies generally do not consider life cycle cost dependent on the health status of the production line, only some constant costs during production [63,64,66] or during lifetime extension strategies, such as manufacturing [62,65].
Finally, it needs to be clarified that some of the above papers are not fully comparable with the current one because they solve a somehow different problem. More especially, [23,24,58,59,67] make decisions based on supply and demand rather than the health of the equipment, whereas other references [17,60] consider a single phase of the life cycle, namely design and disassembly.

Materials and Methods
The optimization of the DSF Core algorithm surrounding strategies recommended for machines and machine components of a production line, as explained in Section 1, is based on a mathematical programming problem of minimizing a non-linear scalar objective function. This function quantifies a mean (average) total KPI over a sufficiently large simulation interval. At every timestamp of this interval, obtained using a constant sampling rate, the total KPI is the weighted sum of independent individual KPIs with different measurement units. In the following, the mean individual KPIs and the mean total KPI will be scaled so that they correspond to average yearly values. Coarsely, based on [21,70] and the RECLAIM pilot goals, the individual KPIs in this project may be categorized as economic (including several cost elements all measured in Euros) and environmental (including the sub-categories about resource use and emissions). As described later in detail, every individual KPI at a particular timestamp is computed based on the condition of the production line at that moment, considering whether production is active or not, potential stops (failures or strategies) occurring and the production inefficiency due to degradation of machine components. Failures are simulated using discrete event simulation, considering short-term failure probabilities based on degradation of the respective components or other reasons. The failure probabilities within the simulation interval are randomly generated from particular probability distributions, and, usually, consecutive failure probability values for the same failure type are correlated. The evolution of the production line condition (and thus the KPIs) is estimated iteratively.
Every machine is assumed to consist of at least one component, particularly, at most one static component and potential movable components in the sense that a movable component can be changed without replacing the rest of the machine, whereas the change of the static component signifies the change of the machine. For the static component, refurbishment is the only candidate circular economy strategy that will be discussed in this paper. The definition of refurbishment is mentioned in [16] as follows: "Refurbishment means restoring an old product and bringing it up to date. In general, refurbished products are upgraded and brought back to specified quality standards or satisfactory working and/or cosmetic conditions and have to fulfill extensive testing. Occasionally, refurbishing is combined with technology upgrading by replacing outdated modules and parts with technologically superior ones". For a movable component, replacement should always be a candidate strategy, whereas maintenance is also a possible lighter strategy, with one or more alternatives. In the following, wherever it is mentioned that the machine fails or is refurbished, it will be implied that this happens to the static component. Refurbishment of the static component can be combined with strategies to the movable components in multiple ways. More concretely, a strategy in a component generally does not imply the (in)ability to simultaneously apply a strategy in other component(s), with the following exceptions, stemming from the definition of refurbishment: • During refurbishment of a static component, maintenance of movable components of the same machine is impossible. In this case, the movable components may either be replaced or remain as they are. For some movable components, replacement may be compulsory in this case. • The reverse is true. During maintenance of a movable component, refurbishment of the same machine is impossible.
The optimization consists of two main phases: 1.
Pre-optimization for corrective strategies σ: Assuming initially that a strategy is always applied to a component and only as soon as possible after the component has failed, this phase finds the optimal strategy for each component after its failure. The initial solution considers the lightest compulsory corrective strategy for each failure type. The lightest compulsory corrective strategy to be applied after a failure is defined by the user, as explained later. For every failure type, the possible corrective strategies are the possible preventive ones which are not lighter than the above.

2.
Main optimization for decision variables θ related to: •

Short-interval average modified KPI threshold per component and strategy applicable to it:
The strategy is recommended and applied when the average total modified KPI (based on a modification described later) exceeds the threshold. If the threshold is exceeded for multiple strategies for the same component simultaneously, the heaviest one is selected. (If this happens for multiple maintenance alternatives simultaneously, the one defined first by the user is selected.) If strategies and failure fixations may take place only during working hours or the present time is non-working time, the strategy is assigned the status "urgent" and is applied as soon as possible. Otherwise, it is assigned the status "non-urgent" and is also applied as soon as possible, but only during non-working hours in order not to interrupt the production, which would cause indirect economic loss, since fewer parts would be produced due to the additional downtime. Exceptionally, if refurbishment for the static component has been chosen, any proposed strategy for movable components is assigned the same urgency status as refurbishment. • Failure probability threshold per component and failure type: The lightest strategy applicable to the component is recommended and applied when the probability of any failure in this component exceeds the threshold. If strategies and failure fixations may take place only during working hours or the present time is nonworking time, the strategy is considered "urgent". Otherwise, it is considered "urgent" (instead of "non-urgent") if and only if the failure probability until the next non-working timestamp is much higher than the failure probability at the next timestamp, also considering the impact of the strategy on the downtime of components and the time distance until the next non-working timestamp, based on the formula P long ≥ 10 ∆p nP short , according to the following notation: -P short : probability for failure of the component in question to happen at the next timestamp, according to the considered (constant) sampling step; -P long : probability for failure of the component in question to happen at the next non-working timestamp; -n: number of time steps until the next non-working timestamp; -∆p: difference in percentage of non-working machine components if the strategy is applied and not.
For a particular component and failure type combination, due to high time complexity, the relevant computations take place only at the first consecutive working timestamp for which the computation of urgency makes sense. For the other timestamps among the above, the same urgency is defined. In addition, when the status "non-urgent" is assigned to the recommended strategy at the last working timestamp of a working interval, the strategy is recommended with status "urgent" at the next timestamp (i.e., the first of the next non-working interval). This happens even if the respective failure probability threshold with respect to the load during non-working hours at that timestamp is also exceeded. Exceptionally, if refurbishment of the static component has been chosen, any simultaneously proposed strategy for movable components is assigned the same urgency status as refurbishment. • Corrective strategies "actuators" per component and failure type: Binary variables determining if the optimal corrective strategy for the component as found during the pre-optimization phase will indeed be applied as soon as possible (with status "urgent") after the component fails.
The objective function quantifying the mean yearly total KPI is defined as with the following notation: . Complex assumptions about the behavior of the KPIs under various circumstances (e.g., regarding their dependence on the degradation level of machine components) need to be taken into account, as will be explained further below. Thus, the objective function of this optimization is difficult to define as an analytic function, which would enable its optimization with the help of its derivatives with respect to its continuous input variables. Moreover, the computation of an exact solution using dynamic programming has too high a time complexity. Furthermore, since some stop periods have relatively short duration and some stops rarely occur, to reliably estimate individual KPIs, a long simulation time interval with many timestamps is needed, which would require many operations for iterative calculations. In this work, we perform a Monte Carlo simulation including discrete event simulation to evaluate and optimize g first with respect to σ (pre-optimization) and then with respect to θ (main optimization), thus finding the optimal corrective and preventive policy for applying lifetime extension strategies. To decrease computational complexity as much as possible, a specific greedy optimization algorithm was introduced, thanks to which the number of objective function evaluations is much lowith respect toan if a common non-linear optimization method was applied. The optimization of g with respect to σ and θ, shown in Algorithm 1 and Algorithm 2, respectively, will be called "training".
The inputs of Algorithm 1 follow below. Those with an asterisk are directly defined by the user, and thus they are discussed in detail in Section 2.1. The rest are computed by or included in the DSF Core itself.
• Number of strategy types; • *Failure types; • *Lightest compulsory corrective strategies; • Objective function g evaluated based on simulation; • *Stop types corresponding to decision variables to be excluded from the optimization (these are not considered in Algorithm 1); • Function sorting strategy types based on their effect (for comparisons with the lightest compulsory strategies to determine which strategies are applicable after each failure).
The outputs of Algorithm 1 are the optimal σ and corresponding g value.
Algorithm 1 Algorithm for pre-optimization for corrective strategies σ 1: compute g without applying strategies in preventive way, for σ corresponding to applying the lightest compulsory corrective strategy corresponding to every failure 2: epoch ← 0 3: while no termination criterion applies (epoch number/no improvement within 1 epoch) do 4: for every combination of component and failure type do 5: for every corrective strategy applicable to the component after such failure do 6: compute g if not computed with same arguments yet 7: if the value of g is better than the optimal found so far then 8: update optimal σ and optimal g value 9: end if 10: end for 11: end for 12: Strategies are never recommended in a preventive way when the KPI and failure probability thresholds are high enough so they are never exceeded. Therefore, high values are initially chosen. For probabilities, values equal to 1.1 are set. For KPIs, a single maximum KPI value of 10 4 is considered in this paper. In addition, initially, all corrective strategies "actuators" are active, i.e.,strategies are always applied after relevant failure instances. This is important because if the optimization starts from a really bad solution some component will never undergo any strategy.
The maximum number of optimization epochs will always be set to 10 but will never be reached, as discussed later.
The main inputs of Algorithm 2 follow below. Those with an asterisk are directly defined by the user; thus, they are discussed in detail in Section 2.1. The rest are computed by or included in the DSF Core itself.
• *Strategy types; • *Failure types; • *Lightest compulsory corrective strategies; • Objective function g evaluated based on simulation; • *Stop types corresponding to decision variables to be excluded from the optimization (these are not considered in Algorithm 2); • Function finding every time the next θ for which g is to be evaluated; The main outputs of Algorithm 2 are the optimal θ and corresponding g value. The use of percentiles also plays an important role in the reduction of function evaluations because the KPI and failure probability thresholds are updated in such a way that the numbers of instances from some stop types are significantly affected, also considering that the objective function is independent of the decision variables in some regions. The percentiles are updated every time a new solution is found because the distribution of KPIs and failure probabilities have been affected by the updated policy. Algorithm 2 Algorithm for main optimization for decision variables θ 1: initialize σ as the optimal one found during pre-optimization 2: for every KPI time series (each corresponding to a component-strategy type combination) and failure probability time series (each corresponding to a component-failure type combination) do 3: compute the 100(1 − nr)% percentiles of its instant values observed during the computation of g for the optimal pre-optimization solution, with resolution r [n ∈ N, 1 − nr ∈ [0, 1]] 4: end for 5: while no termination criterion (maximum epochs reached or g not improved within 1 epoch) applies do 6: for every decision variable do 7: if the decision variable corresponds to KPI threshold or failure probability threshold then 8: compute g for the closest lower and higher values for this threshold corresponding to respective percentiles if not computed with same arguments yet 9: else(decision variable corresponds to corrective strategy "actuator") 10: compute g for the other value of this binary "actuator" if not computed with same arguments yet 11: if the value of g is better than the optimal found so far then 12: update optimal θ and optimal g value 13: update KPI and probability percentiles based on new optimal solution, keeping also the initial thresholds as candidate values 14: end if 15: end if 16: end for 17 Machines of the production line studied by the DSF Core model, components of each machine, as well as potential stop (strategy and failure) types corresponding to each component: Only the names of machines and components considered by the DSF Core model in question should be defined. If other machines and components are considered by other DSF Core models (which should be considered in the case of many independent or similar machines/components, to reduce computation time, since time complexity is quadratic with respect to the number of stop types, and to avoid multiple trainings for similar components), just their number needs to be mentioned. In this paper, it is assumed that when a component stops, this causes the stop of production of the whole production line. However, the other components do not fail, i.e., they are not damaged. When the originally stopped component is restored, the others are also assumed as operational. Furthermore, no strategy is applicable to a failed component until it is fixed, even if the strategy is proposed by the DSF Core. Production is quantified per component and may stop due to the aforementioned reasons. Finally, it needs to be noted that no multiple failures may occur simultaneously in the same component. Even when mentioned that a failure of one type immediately causes a failure of another type (as discussed later), the latter starts at the next timestamp after the end of the former.
Components to be always replaced along with refurbishment: These should be defined for every machine for which refurbishment has been selected as a candidate strategy. Selected components must always be replaced along with refurbishment, but they may also be replaced at other times.
Stop types corresponding to decision variables to be excluded from the optimization; It makes sense to exclude failures which never happen (i.e., never cause downtime) but lead to degradation-based inefficiency during production, as expressed with some KPI(s). It also makes sense to exclude strategies that should be applied due to failure or high failure probability, but not due to KPI-expressed inefficiency.
Lightest compulsory corrective strategies: For every failure type, the lightest compulsory corrective strategy to make the component work again should be defined. It is possible not to select any strategy for some failure type. In this case, it is assumed that there is also the option just to fix the failure without improving the respective equivalent age (which quantifies the degradation level of the component with respect to this failure type, as discussed below). Maintenance alternatives belonging to the same high-level strategy type are assumed as sorted previously by the user in ascending order of effect.
Failure type dependencies: Based on prior pilot knowledge, the dependent failure types are considered by the DSF Core. In this paper, a failure type f 2 is dependent on another failure type f 1 if a failure of type f 2 occurs immediately after a failure of type f 1 .
Sampling step: The selected value is usually close to the minimum stop duration, as defined later, to ensure both sufficient time granularity and tractable time and memory complexities.
Working hours (from which the gross profit rate is computed): These are assumed as dependent on the day of week.
Indication if strategies and failure fixations may take place only during working hours: Yes/no. Simulation interval length: The selected value is close to 30 times the maximum Mean Equivalent Time To Failure (METTF), discussed later, to ensure both that enough instances from each stop type occur within the simulation interval and that the time and memory complexities are not too high.
Remaining equivalent age after strategy compared to before (percentage): Each simulation for training starts assuming that the production line is new. As the time passes, the components are gradually aging with respect to their various failure types. Depending on the component and the failure type, aging speed generally (which will be called "load" to follow the degradation modelling terminology) depends on whether the component is working, and it is also generally affected by the way in which it is working, as described by available process variables. The ages of components with respect to their failure types consider these factors, so they are called "equivalent ages". The equivalent age of a component with respect to a particular failure type partly affects the occurrence probability of a failure of this type, based on Weibull distributions, as explained later. The percentage of equivalent age that a component has with respect to each of its failure types after a strategy compared to before is assumed as dependent on the component, the strategy type and the failure type.
Load specifications: The load specifications follow below: • Range: The range is per component and failure type during periods with and without production. The load starts from a random number within the range and evolves according to the maximum absolute first-order difference within 1 day defined below. • Maximum absolute first-order difference within 1 day: This is a single value divided by the average number of timestamps per day to compute the maximum absolute change between two consecutive timestamps, based on the considered sampling step. • Multiplier during production due to high failure probability until the next timestamp: This is a per ordered pair of possibly equal failure types, where the first corresponds to the multiplier and the second to the failure probability. The probability is considered as high (resulting in the multiplication of load by the multiplier) when it exceeds the corresponding degradation-based probability of failure until the next timestamp at 90% of the respective METTF (discussed later).
KPI types considered: The economic KPI is mandatory because it is the only one related to benefit, and it is measured in some currency unit.
Measurement units of KPIs: A measurement unit should be defined per KPI type.
KPI weighting coefficients: The environmental KPIs are monetized based on unit prices of environmental elements, but the user may define any other possible weights.
Ideal average yearly values of KPIs: "Ideal" means that the equipment always works as efficiently as when it was new, and all failures always have probability of 0, so there is no need for strategies. The yearly values within a certain year are computed by summing up the instant values within this year. All KPIs are assumed to have a neutral value of 0, while the respective components are not producing. The ideal average yearly values of KPIs are assumed to depend only on the KPI type k. The values to be defined should correspond to the whole production line, including potential machine components absent from the current DSF Core model but considered by other DSF Core models.
KPIs evolution and dependencies: During production, the component individual KPI K k c (i, σ, θ), present in the objective function, is defined as the mean of failure-type-specific KPI sub-values K k c, f (i, σ, θ) for all failure types f of the component c. During production, each such sub-value is assumed to equal an equivalent-age-based exponential inefficiency penalty for the respective KPI type k, component c and failure type f , i.e., In the above formula, s c, f (i, σ, θ) stands for the equivalent age of component c with respect to failure type f at time i given policies σ and θ. In addition, v k is the ideal value of KPI k divided by the average yearly working timestamps (i.e., within the potential working hours of the production line, whether or not there are any irregular stops among the aforementioned) and the number of machine components (with ∑ k∈K w k v k < 0, since the production of the production line is profitable only for negative g) and b k,c > 1.
Because it is not straightforward to define b k,c directly, the user defines the inefficiency (b l , where s * c (equivalent age of component c corresponding to the inefficiency) is either manually defined by the user or automatically selected as 90% of METTF of component c. The METTF of a component is defined as the harmonic mean of METTF values of its failure types, with respect to either the time-to-failure distributions based on equivalent age or the failure probability distributions due to process-data-related reasons (see later).
Then, the auxiliary KPIsK k c, f (i, σ, θ), aiming at distributing the KPI sub-values K k c, f (i, σ, θ) among the failure types of the respective component, are computed aŝ where F c is the set of possible failure types of component c.
If a failure f starts at time i in component c, its direct impact on each KPI as defined by the user (see later) is . If a strategy s starts at time i in component c, its user-defined direct impact on each KPI as defined by the user is added initially to K k c, f (i, σ, θ). [The fact that it is not added toK k c, f (i, σ, θ) is compensated later, as will be explained right after.] Apart from the above, at the other timestamps without production from component c, it is LetK c,s (i, σ, θ) be the instant total modified KPIs for every component c and strategy s, based on which the average values compared to the respective thresholds are computed according to the short interval lengths of 1D, 7D and 30D for maintenance, replacement and refurbishment, respectively. If strategy s does not start at time i in component c, these are defined as where q c,h(s), f is the remaining equivalent age percentage with respect to failure of type f after the application of a strategy belonging to the high-level group h(s), including s to c.
The rationale for considering the factors 1 − q c,h(s), f is that the more a strategy reduces in percentage the equivalent age of a component with respect to some of its failure types, the higher the importance of reducing inefficiency, as quantified by theK k c, f (i, σ, θ) values for every k. This way, the inefficiency is mapped from the failures to the strategies, and there is no need to consider combinations of strategies and failure types in the thresholds, which would significantly increase the number of decision variables.
If strategy s starts at time i in component c, the above value is increased by the weighted sum of direct impacts of the strategy on the KPIs, which had previously been added only to K k c, f (i, σ, θ) and not to anyK k c, f (i, σ, θ), for every k. If strategy s ends in component c at time i, the values ofK c,s * (i, σ, θ) for every equivalent or lighter strategy s * and every j ≤ i are not considered afterwards in the average values compared to the respective thresholds, based on the assumption that strategy s addressed successfully, and better than s * could do, any problem observed before through the above KPIs.
As mentioned above, some machine components may not be considered by the DSF Core model in question but may be considered by other DSF Core models. Then, the downtime impact of stops of considered components on out-of-model ones is taken into account by uniformly charging the potential KPI differences in the out-of-model components (comparing with the ideal values) due to stops of considered ones to the respective KPIs of all considered components at the same timestamps.
Stop duration Weibull distribution parameters: The duration of each stop type is assumed to follow the 2-parameter Weibull distribution with user-defined scale η and shape β parameters dependent on the stop type. These can be selected based on the coefficient of variation (CV) and mean (MSD) of stop duration, since theoretically they depend on each other based on the following well-known 1-1 functions: where Γ denotes the gamma function. The parameter values may rely on prior domain expertise or analysis of historical data. Given that duration S = s has already passed, the probability distribution of the remaining duration U is computed as follows, considering that V := S + U follows the Weibull distribution with scale η and shape β: where in every case P denotes the probability of the event in the brackets, and u ≥ 0. For the purpose of simulation, the probability P(U < l|S = s) (i.e., for the next time step, which has length l) is computed. Usually, the sampling step is selected as comparable to (rather than negligible with respect to) the minimum MSD to balance time granularity and computational (or also memory) complexity. Thus, to avoid bias in the estimated downtime, when U < l given that S = s based on the above probability and the random number generator, it is assumed that and the relevant effects on KPIs apply accordingly, based on the above.
Equivalent Time To Failure (ETTF) distribution parameters based on equivalent age: As mentioned above, the equivalent age of a component partly determines the probability of future failures in this component. Like stop duration, ETTF follows the 2-parameter Weibull distribution for the purpose of simulation, but it applies only to failures and also considers load depending on the usage of the equipment during working hours apart from the working hours themselves for the measurement of time passed (hence the term "equivalent time"). Mathematically, equivalent time t eq passed within a regular time interval [0, t] is defined, as mentioned in [11,12], as where a denotes load, expressed as a function of the timestamp τ. Within short intervals, load can be assumed as nearly constant, so equivalent time may be approximated as This approximation is taken into account in the computation of the failure probability of each component within the next time step for each of its failure types given the component's equivalent age similar to the remaining stop duration case. In cases of dependent failure types, according to the failure type dependencies discussed above, after a strategy happens, the Weibull parameters along with the equivalent age remain the same as those that would apply without considering the stop correlation. Mean Time To Failure (MTTF) values for process-data-related component failures and frequency of their probabilities' change during production: Apart from equivalent aging, component failures may also occur for other reasons, which may be captured by anomaly detection and predictive maintenance algorithms. For the purpose of simulation during training, depending on the failure type, the failure probability within the next time step is considered as a random variable from the Beta probability distribution β(α, β) (so that it ranges from 0 to 1), with probability density function . For a particular failure type of a component, this probability is not updated at every timestamp; it is always updated right after the end of a strategy applied to the same component, otherwise it is updated with a probability based on a user-defined frequency. The failure probabilities are considered only for working components, since it is assumed that a component may fail due to a process-data-related reason only while working (even if aged equivalently with respect to some failure types during periods without production by this component). The Beta distribution parameters are related with the MTTF, as well as the mean (MP) and coefficient of variation of the random variable (in this case, failure probability) (CV P ) based on the well-known formulas where MTTF is measured in number of time steps based on the considered sampling step. The Beta distribution parameters may be defined as a function of MP and CV P by solving the above system: In the following, it will always be realistically assumed that α = 0.1.
Cost input: This stop-related input must be either defined manually or computed by a third-party algorithm. The detailed methodology of estimating the various cost elements during stops is described in [15]. The cost elements required by the DSF Core are the following: • One-off strategy costs: These costs are defined per machine, component and strategy combination. When multiple strategies start simultaneously to be applied to components of a particular machine, only the maximum one-off strategy cost of the started strategies instead of the sum of all of them is paid and is added to the net costs described later. • Net costs: The stop-type-dependent costs per component are paid during the stop interval. (The DSF Core assumes that they are paid at the beginning of the interval.) They do not include indirect costs, such as cost due to downtime and long-term economic impact, which are taken into account separately.
Direct impacts of stops on other KPIs: These are defined by the user and behave like the net costs.
KPI and failure probability percentiles resolution: This is defined as r as it appears in Algorithm 2.

Scenarios of Running a Trained DSF Core Model
The following two run scenarios have been envisioned: • Real-time recommendations scenario: The trained model runs (near-) real-time (automatically, and periodically, based on the sampling step considered for training) for the next timestamp (based on the sampling step). When a strategy is needed, relevant recommendation is shown. This requires the following real-time input: -Stops (production line failures, strategies); -Predictions from other DSF algorithms (failure probabilities, degradation levels); -Process data related to the KPIs (unless already used directly by other DSF algorithms instead).
• Simulation scenario: The trained model runs (manually) for a future time interval, thus simulating (under the trained optimal strategy selection policy and considering the current status of the production line) the following: -When-what failures will happen; -When-what strategies will be recommended; -Future independent KPIs; -Future production time percentage.

DSF Core Internal Architecture (Information Flow)
The architecture of the DSF Core corresponding to the overall methodology discussed above is outlined in Figure 1. It consists of the following elements: • Database: data repository where sensorial data and outputs of algorithms may be stored for future use by the same or other algorithms within the DSF; • User Interface: helps the end user interact with the DSF Core by inserting inputs and visualizing outputs; • Processed arguments calculator: computes additional training input arguments based on those defined by the user or on output of third-party algorithms; • Pre-optimizer: optimizes the corrective strategies based on Algorithm 1; • Main optimizer: optimizes the preventive strategy application policy based on Algorithm 2; • Simulator: simulates the evolution of the production line condition to evaluate the objective function; • Model repository: working directory where files including the input, processed and trained parameters related to the trained DSF Core models are stored so that the models can run in the future; • Run function: runs trained DSF Core models based on the aforementioned run scenarios.

Results and Discussion
This section includes the training results from the application of the DSF Core to the three aforementioned pilots, as well as examples of running the respective trained models based on the simulation scenario assuming a new production line in the beginning. For GORENJE and HWH, an indicative DSF Core model is discussed in this paper. For ZORLUTEKS, two representative models are discussed in detail, whereas high-level results for the other trained models for this pilot are also presented in the end.

Application to GORENJE
The spraying cabin is the only machine from the white enameling line of this pilot which is studied by the DSF Core because it involves the most important failures in terms of average yearly impact. The following 48  The components from the different types are in 1-1 correspondence, i.e., there are 12 power supply unit-pump-hose-spraying gun quartets, working in parallel for production.
Due to the high number of components, as well as the assumed independence among components of different quartets in terms of stops, it was decided to train the DSF Core algorithm for only one representative quartet, so that the trained model is used for all of them. Due to the independence of model execution for different quartets, the stop duration corresponding to each quartet is unavoidably charged separately, even in cases when strategies are applied simultaneously to multiple quartets.

Training Input for GORENJE
Machines of the production line studied by the DSF Core model, components of each machine, as well as potential strategies and failure types corresponding to each component: According to the above, the model includes one power supply unit, one pump, one hose and one spraying gun. A single failure type has been considered for each such movable component.
Maintenance and replacement are the candidate strategies for each component, except for the hose, which may only be replaced.
Components to be always replaced along with refurbishment: None.
Stop types corresponding to decision variables to be excluded from the optimization: These are the power supply unit and pump strategies, because they are not part of preventive strategies. (The failures of these components are not excluded in order for the DSF Core to select between corrective maintenance and replacement.) Lightest compulsory corrective strategies: • Power supply unit/pump: maintenance; • Hose/spraying gun: none.
Failure type dependencies: Failures of different types are assumed as independent.
Sampling step: 15 min. Working hours (from which the gross profit rate is computed): Working time lasts 8 h per business day (where the working hours have been considered as 9:00-17:00 from Monday to Friday), i.e., 40 h/week, i.e., 2087 h/year (23.81% of total time). Every working hour (woh), 380 parts are produced on average. (This rate corresponds to parts with a width of 50 cm, which is almost always the case. In the following, it will be assumed that all parts have this width). Thus, the ideal production rate is 793,114 parts/year. Under normal conditions, every part is good within the first two processing attempts with 99.6% probability. If it is bad, with the remaining 0.4% probability, it is discarded as scrap. From this percentage and under the assumption that normally each of the two processing attempts has equal probability to produce a good part, it is concluded that this probability is √ 0.4% = 6.3%. Then, 0.996/(1 + 0.063) = 1 − 0.063 = 93.7% of the produced parts (356 parts/woh) yield profit. The indicative selling price is EUR 7.5/part. Therefore, the estimated ideal gross profit rate is EUR 2669.750/woh = 5,572,150 EUR/year. This is uniformly distributed among all working timestamps based on the relevant sampling step.
Indication if strategies and failure fixations may take place only during working hours: Preventive strategies may also take place during non-working time by workers who are in charge during that time; this does not lead to extra labor cost.
Load specifications: The load specifications follow below: • Range: Load is assumed to equal one during production andzero during intervals without production for any analyzed failure type. • Maximum absolute first-order difference within 1 day: Load is sectionally constant; • Multiplier during production due to high failure probability until the next timestamp: One in all cases (no effect assumed); KPI types considered: Economic, scrap.
KPI weighting coefficients: Based on the rate EUR/part during production, the following weighting coefficients of the KPIs are proposed: • Economic: one; • Scrap: 7.5.

Ideal average yearly values of KPIs:
The production costs of non-degraded equipment follow below: (The equipment production efficiency is always assumed as perfect, since no impact of degradation on the KPIs during production has been defined for this pilot.) Regarding the scrap KPI, as mentioned above, it is known that under normal conditions every part is good within the first two processing attempts with 99.6% probability. If it is bad, with the remaining 0.4% probability, it is discarded as scrap. From this percentage, and under the assumption that normally each of the two processing attempts has equal probability to produce a good part, it is concluded that this probability is √ 0.4% = 6.3%. Then, 0.004/(1 + 0.063) = 0.38% of the produced parts (1.4 parts/woh = 2984 parts/year) are discarded.
KPIs evolution and dependencies: As mentioned above, no impact of degradation on the KPIs during production has been defined for this pilot.

Stop duration Weibull distribution parameters:
In contrast to the other DSF Core models, the one-off cost coincides with the durationdependent cost, as explained later, so the gross duration of simultaneous application of strategies has not been analysed. The gross durations of the individual strategies follow below: ETTF distribution parameters based on equivalent age: These are shown in Table 3. Table 3. ETTF distribution parameters and METTF for the spraying cabin (GORENJE), ignoring the already occurring lifetime extension thanks to time-based inspection. MTTF values for process-data-related component failures, and frequency of their probabilities' change during production: Failure occurrences at the components of this machine due to reasons irrelevant to degradation have not been considered.

Component Scale (η) Shape (β) METTF
Cost input: The direct costs during application of strategies are split into duration-dependent (only costs for labor time, since no machines are involved in the application of strategies for this pilot) and duration-independent (costs to buy new components, consumables costs and other costs to apply a strategy which do not depend on its duration). The durationdependent costs are proportional to the durations of strategies mentioned above. However, usually workers do not work overtime to apply the analysed strategies and are not paid extra for them compared to their fixed reward. The total labor rate is independent of the production and stop time percentages and is defined as 7.5 h/(business day) · 10.5 persons · EUR 12.6/Ph · 5(business days)/week = EUR 4961.25/week = 258,871 EUR/year = 124.03125 EUR/woh (Ph = person hour). During stops, this rate remains constant, but the relevant cost corresponding to the strategy duration is characterized as one-off strategy cost instead. Thus, when multiple strategies are applied simultaneously, the one-off cost corresponding to the strategy that takes longer applies, and the whole duration-dependent cost is considered as one-off. Therefore, the one-off costs, which coincide with the gross duration-dependent costs, are defined as follows: From the above, it also follows that the duration-independent costs coincide with the total net costs. Table 4 summarizes the direct costs during strategies. Any failure, depending on its duration, is assumed to have additional cost for labor time (which would be paid also in case of production, as happens with strategies). This means EUR 31.0078125 for a hose and a spraying gun and 0 for the other components. The additional advantage of preventing hose and spraying gun failures is to avoid downtime during working intervals.
Direct impacts of stops on other KPIs: When some component fails, this is recognized quickly, so the extra scrap rate applies for a negligible duration. Thus, the extra scrap may be considered as negligible.

Training Results for GORENJE Optimal Solution
Corrective strategies and actuators: In this case, the initial and corrective solutions coincide. That is, the corrective strategies after failures are the lightest compulsory ones. However, the actuators remained active only for the compulsory maintenance of the power supply unit and the pump after the failure of the corresponding component. A simple fix instead of a strategy is proposed after hose and spraying gun failure.
Preventive strategies: • Preventive replacement is proposed for the hose when its failure probability within the next time step (15 min) exceeds 0.001510. • Preventive maintenance is proposed for the spraying gun when its failure probability within the next time step (15 min) exceeds 0.001557.
The original training had also proposed preventive maintenance of the power supply unit based on its failure probability, but this was not considered because of the pilot information that preventive maintenance of the power supply unit is impossible.

Evaluation Metrics
These are shown in Tables 5-7.   Figure 2 presents the time series of the total KPI per component within an interval of 8 years, and the subsequent ones (Figures 3-6) show how each KPI is decomposed into individual KPIs. Every perpendicular line corresponds to a stop. The lower-length lines correspond to stop instances of lower impact. When applicable, the downtime impact of stops on the considered components of the production line which are out of this DSF Core model is incorporated in the perpendicular lines. Apparently, during production, the economic and the total KPI per component are negative because overall the production is advantageous. In Figure 2, the values for some components are almost not visible. The first reason for this is that hose replacement and spraying gun maintenance (almost) coincide in time, as also discussed later. Secondly, the pump theoretically fails (and is maintained in a corrective way) only every 4.3 years, based on Table 3, so it is reasonable not to see many pump stops in the 8-year run simulation interval. (A larger simulation interval for the run results was not chosen in this case because stops from other types are very frequent and would hinder the visibility of figures.) Mainly, the downtime impact of stops of other components on the pump is depicted in Figure 4, and this downtime impact coincides in time for all components. As shown in these figures, as well as in Table 5, in this pilot, the total KPI is almost exclusively affected by the economic one.

Discussion of the Training Results for GORENJE
The conclusion from training the model for this pilot is that the lightest possible preventive strategies in the hoses and the spraying guns considerably help to improve the total KPI since they prevent numerous failures and the respective bad consequences. In addition, it was concluded that no corrective strategy should be applied to these components, but the temporary repair solutions should be preferred instead. A hose and a spraying gun have the same lifetime and almost equal failure probability thresholds triggering the preventive strategies on them, and since no corrective strategies are proposed for them, it is preferable to perform preventive strategies for multiple such components simultaneously. In relation to this, it should be noted that the same number of preventive strategies happened in the hose and the spraying gun during the simulation interval under the strategy application policy of the final solution, as shown in Table 6. What is more, regarding the components included in the DSF Core model, preventive replacement of the hose and preventive maintenance of the spraying gun (almost) coincide in time, as shown in Figure 2. Table 8 contains the total KPIs with respect to components obtained from the above trained model and their total in the last row of each sub-table. The scrap penalty is slightly negative (due to downtime), as expected, because no inefficiency during production has been defined for it. Thus, the extra total KPI values, which appear in the bottom right cell of each sub-table and refer to the whole production line, depend almost only on the economic factor. These values indicate that the application of the optimal strategy application policy proposed above may reduce the yearly unnecessary total KPI penalty by 99,467 (40%) compared to the lightest compulsory corrective strategy application policy without preventive strategies.
However, as mentioned above, time-based inspection is already taking place at the plant, and based on it, preventive maintenance helps to avoid most failures. In the future, the cost of the time-based inspection policy will be evaluated, thus enabling its comparison with the policy proposed by the DSF Core.

Application to HWH
A friction welding machine from HWH is studied by the DSF.

Training Input for HWH
Machines of the production line studied by the DSF Core model, components of each machine, as well as potential strategies and failure types corresponding to each component: Table 9 shows the components of the friction welding machine (one static and four movable), as well as the failure and strategy types considered for each component. Components to be always replaced along with refurbishment: The replacement of the motor and the spindle in case of refurbishment is compulsory.
Stop types corresponding to decision variables to be excluded from the optimization: None. Lightest compulsory corrective strategies: Idle time also includes time to repair failures and time to perform strategies, but it is not increased due to these stops, since the lost time is compensated with faster production later. There is no need to produce more than 50,000 parts per year, so this is not calculated, since human work is needed for production. Therefore, the gross profit rate is EUR 500,000/year (from the production of 50,000 parts with a selling price of EUR 10 each). Based on the above, during working time, the average time between welding activities is 0.5·1565/416.67 = 1.878 min (0.5 min welding + 1.378 min idle). The DSF Core does not need such fine time granularity, so welding and idle time will not be distinguished from now on.
During working time, the average gross profit rate from production is EUR 10/ (1.878 min) = 319.4 EUR/h. This verifies that the average gross profit rate is EUR 500,000/year (EUR 10 · 50,000 welding activities).
Indication if strategies and failure fixations may take place only during working hours: The restoration of production may also be completed during non-working intervals.
Remaining equivalent age after strategy compared to before (percentage): Load specifications: The load specifications follow below: • Range: In most cases, it is assumed that normal usage corresponds to average load of 1, ranging from 0.5 to 1.5, as it depends on the way the equipment is used, expressed by potential sensorial data relevant to load calculation throughout working (instead of welding) time. Exceptionally, the load during working time for the static component is assumed by the pilot to range from 0.9 to 1.1. Furthermore, for the sample-detector failure type, load is assumed to exactly equal one during working time (and zero otherwise) only for the purpose of economic penalty evaluation as a function of equivalent age, because the sample-detector failures may be better forecast based on process data anomalies rather than equivalent age. In addition, for the lubricant failure type of the motor and the spindle, load is assumed to exactly equal one during the whole time, including non-working intervals. • Maximum absolute first-order difference within 1 day: 0.72. • Multiplier during production due to high failure probability until the next timestamp: one in all cases (no effect assumed). Replacement of sample-holder: TTR sh,replacement + TTR fwm = 1 woh; 5.
TTR fwm stands for the one-off duration required during every group of simultaneous strategies applied to the friction welding machine. Solving the above system of six equations with six unknown variables with respect to these variables (independent net durations and TTR fwm ) yields negative values for TTR sh,replacement and TTR sd,replacement , so this solution should be rejected. To face this issue, TTR fwm is removed from the fourth and fifth problematic equations, which yields the following acceptable solution: • One-off duration: TTR fwm = 7 woh; • Refurbishment of static component (excluding the compulsory simultaneous replacement of the motor and the spindle): TTR static,refurbishment = 9 woh; • Replacement of any movable component: TTR motor,replacement = TTR spindle,replacement = TTR sh,replacement = TTR sd,replacement = 1 woh.
Thus, it seems that the one-off duration appears if and only if at least one component among the static ones, the motor and the spindle undergo some strategy, i.e., it does not apply when only the sample-holder and/or the sample-detector is replaced. Therefore, the gross duration of refurbishment, including the compulsory simultaneous replacement of the motor and the spindle, is 18 woh.
In addition, it has been assumed that maintenance of motor and spindle has the same duration as replacement of these components, respectively.
Based on the above, the downtime does not cause indirect cost due to lost production profit because the lost time is compensated. Thus, no downtime is modelled. The durations were computed only to evaluate the costs of strategies on the movable components, including the duration-dependent costs, which have been explicitly provided by the pilot only for refurbishment.
Since the lost time is compensated, the duration of failures has not been modelled. No duration-dependent failure costs have been analyzed.
To conclude, the duration of every stop from the downtime viewpoint has been assumed as 0.
ETTF distribution parameters based on equivalent age: These are shown in Table 10. MTTF values for process-data-related component failures, and frequency of their probabilities' change during production: The relevant failure is the remaining sample-holder failure. The MTTF related to process-data-related reasons for this failure type has been assumed as 1.5Γ(1 + 1/2) years = 1.33 years = 86.68 working days = 553.89 weh (weh = welding hours). Apart from the cases of strategies, the probability obtained from the above distribution changes with a new random value every 5 woDon average.
Cost input: The direct costs during application of strategies are split into duration-dependent (costs for machine time and labor time) and duration-independent (costs to buy new components, consumables costs and other costs to apply a strategy which do not depend on its duration). Since the machine time always equals the labor time in the case of this pilot, the duration-dependent costs are proportional to the durations of strategies mentioned above, according to the sum of the defined labor rate (EUR 27.4/h) and machine rate (0.5 EUR/h), so EUR 27.9/h. The one-off cost, corresponding to the one-off duration, is EUR 195.3, so this is the difference between gross and net costs. This is paid only once for every group of strategies applied simultaneously to the machine, unless only the sample-holder and/or sample detector are/is involved, where this cost is not paid. Table 11 summarizes the direct costs during strategies. Fixing of any failure without application of some strategy is assumed to have a direct cost of EUR 2000.
Direct impacts of stops on other KPIs: No other KPIs have been considered for this model. KPI and failure probability percentiles resolution: 5% (10% proved to be too high).

Training Results for HWH Optimal Solution
Corrective strategies and actuators: In this case, the initial and corrective solution coincide. That is, the corrective strategies after failures are the lightest compulsory ones. However, the actuators remained active only for the compulsory strategies after failures. A simple fixing instead of a strategy is proposed after motor and spindle lubricant failure, which is reasonable because mechanical fatigue always follows lubricant failure, which necessitates replacement of the component anyway.

Evaluation Metrics
These are shown in Tables 12 and 13.  Apparently, since no downtime has been modelled for this pilot, the production time percentage for every component equals the ideal (17.8572%) in every case.

Discussion of the Training Results for HWH
The conclusion from training the above model for this pilot is that the lightest possible preventive strategies in the movable components considerably help to improve the KPI, since they prevent numerous failures and the respective bad consequences. Based on the simulations, the number of replacement strategies in the sample-detector under the optimal strategy application policy is much higher than the number of replacement strategies in the sample-holder. This happens not only because the sample-detector has about half lifetime, but also because the sample-detector failure probabilities have been modelled as process-data-related instead of equivalent-age-based (which is the case for the other components), and as a result, the prevention thanks to the strategy has more short-term effect; 5 working days on average, based on the input.
The results indicate that the application of the optimal strategy application policy proposed above may reduce the yearly unnecessary total KPI penalty by EUR 2168/year (27%) compared to the lightest compulsory corrective strategy application policy without preventive strategies.

Application to ZORLUTEKS
The bleaching machine of the production line is studied in this work. The following 51 important components have been selected for analysis: Due to the high number of components and the similarity among many of them, it was decided to train the DSF Core algorithm separately for different components, except for those with correlated failures and load. While strategies are applied simultaneously to components which belong to the same DSF Core model, the corresponding duration and the one-off strategy cost related to the waiting time to insert fabric into the machine are considered only once. In all other cases, due to the independence of the models, unavoidably the duration corresponding to each component and the one-off strategy cost are charged separately.
To keep its content concise, this paper will only discuss two indicative DSF Core models for ZORLUTEKS. The first is related with one of the seven motors with two associated paired coated rollers each. The other models for motors with two rollers are not presented in detail, since they only differ in the METTF of some components. The second model for this pilot discussed in this paper is related with any of the two motors with one associated roller each. These two rollers are the uncoated ones. The model for motors without associated rollers and the models for inverters are also not discussed in detail because they are simpler, and in these cases the benefit from applying preventive strategies is less significant.

Training Input for ZORLUTEKS
Machines of the production line studied by the DSF Core model, components of each machine, as well as potential strategies and failure types corresponding to each component: Table 14 shows the types of movable components of the bleaching machine considered by the two DSF Core models, as well as the failure and strategy types considered for each component. Based on the above, the first model considers five components; two roller coatings, two double bearing-lubricant pairs (each corresponding to one roller) and one motor connected to the two rollers. The second model considers two components; one double bearing-lubricant pair of a uncoated roller and one associated motor. Although there are several other stop types, they have not been modelled because they have been considered as non-controllable or of insignificant impact on the KPIs, and according to a preliminary statistical stop correlation analysis based on [78], there was no (reliable) conclusion about their dependence with the important failure types mentioned above. Thus, for simulation purposes, the production time is uniformly distributed outside intervals of important failures and application of strategies. (As discussed later, all hours of the week are considered as working hours.) Components to be always replaced along with refurbishment: None.
Stop types corresponding to decision variables to be excluded from the optimization: None. Lightest compulsory corrective strategies: maintenance of the failed component (winding for complete motor failure, and lubrication for motor lubricant failure).
Failure type dependencies: Based on prior knowledge of the domain experts, any bearing lubricant failure immediately causes also mechanical fatigue in the bearing-lubricant pair. There are also load-related dependencies, as explained later.
Sampling step: 30 min. Working hours (from which the gross profit rate is computed): Based on the cost modelling template, about 3 Mm 2 of fabric are produced per month. More accurately, based on a preliminary analysis of a production dataset from 2020 and 2021, the time and average yearly output area of fabric are distributed as shown in Table 15. The bleaching route operation is the only one considered as related to profit. Its time percentage may be improved thanks to third quality optimization algorithms with respect to process parameters by up to 7.55 percentage units (from 54.28% to 61.83%), i.e., the percentage of the bleaching repair operation timestamps, which can be avoided thanks to improvement of the initial quality of products (i.e., after the first process and before any potential reprocess). Since, based on the above table, the average bleaching speed during route operation is 27.72 Mm 2 /year, there is potential to increase the yearly production rate of profitable bleached fabric to 31.58 Mm 2 /year (33.55 Mm 2 /year including washing), which corresponds to gross profit rate of EUR 25.90 M/year, since the unit gross profit is 0.82 EUR/m 2 . No fixed non-working hours within the week exist, and the DSF Core is generally impossible to know a priori the intervals without bleaching route operation, so, for the simulations, it uniformly distributes the profitable production rate (considering gross profit) as 60 Load specifications: The load specifications follow below: • Range: Normally, load is assumed to equal one during production and zero during intervals without production for any mechanical fatigue of bearing and complete motor failure. For the other failure types, load is assumed asone all the time. The only exceptions which apply are related to the multipliers discussed below. • Maximum absolute first-order difference within 1 day: load is sectionally constant. • Multiplier during production due to high failure probability until the next timestamp: According to the orange arrows in Figure 13, load with respect to a particular failure type (arrow end) is assumed to be multiplied by the respective number when the probability of failure of another type (arrow start) within the next elementary time interval (i.e., interval with length equal to the sampling step) is relatively high (i.e., higher than the theoretical degradation-based probability corresponding to 90% of METTF). The red arrows indicate the aforementioned failure correlations.  KPIs evolution and dependencies: As mentioned above, no impact of degradation on the KPIs during production has been defined for this pilot.
Stop duration Weibull distribution parameters: The gross durations of strategies (replacement/maintenance) for the involved components are: Unless stated that a strategy is applied in parallel to the production, in which case the strategy duration is considered as 0 in the sense that it does not imply downtime, the fabric should have been removed from the machine so that it takes place. This results in additional waiting time of 23 min, which is the time needed for the fabric to go through the machine.
The above durations are assumed to have coefficient of variation CV = 0.1. The Weibull distribution parameters are computed from the above as mentioned in the methodology. Particularly, CV = 0.1 corresponds to shape β = 12.153434. The scale (η) values for strategies not applied in parallel to the production prove to be as follows: • Replacement/maintenance of roller coating: 7.5620232 woh = 0.31508430 woD; • Replacement of double bearing-lubricant pair: 1.3907169 woh = 0.057946538 woD; • Replacement/maintenance (winding) of motor: 3.6506319 woh = 0.15210967 woD.
Based on the analysis of stop data from 2016 to 2021 for the mechanical, electrical and power failures, the mean and CV statistics were computed for the involved component types. Based on them, the most appropriate scale and shape of two-parameter Weibull distribution parameters were computed, as shown in Table 16, so these distributions are used for the simulation of failure intervals for the evaluation of the objective function of the optimization algorithm. Table 16. Time to recover from roller coating (appeared as "roller and shaft" in the stop dataset), double bearing-lubricant pair (appeared as "bearing and mounting guide" in the stop dataset) and motor failures in the bleaching machine (ZORLUTEKS).

Component
Mean ( As discussed below more extensively, each failure causes bad fabric whiteness with a probability dependent on its type. If bad whiteness is detected at the exit of the production line, the same fabric is re-inserted into the machine and reprocessed, which is supposed to require another 23 min. However, when the failure happens, the fabric does not need to be removed from the machine to fix the failure. This may be required only by the strategy applied after the failure, according to the above.
ETTF distribution parameters based on equivalent age: These are shown in Table 17. In the respective degradation model β = 3 was defined, but since it is assumed that lubricant failure in a particular bearing-lubricant pair may be well-forecast thanks to vibration anomalies detection, the value was increased to reduce the variance of the distribution.
MTTF values for process-data-related component failures and frequency of their probabilities' change during production: Failure occurrences at the components of this machine due to reasons irrelevant to degradation have not been considered. As mentioned above, it is assumed that lubricant failure in a particular bearing-lubricant pair may be well-forecast thanks to vibration anomalies detection, but this is already considered by the respective modified degradation model, since it is considered as degradation-related.
Cost input: No costs for machine time and consumables costs have been defined for this pilot, and the costs for labor time should not be considered, because the total payment for the staff is constant. Thus, all in all, there are no direct duration-dependent costs during application of strategies, and all direct costs are duration-independent (costs to buy new components and other costs to apply a strategy which do not depend on its duration). The one-off cost, corresponding to the waiting time to insert fabric into the machine after its removal for the purpose of application of a strategy, leads to economic impact equal to the respective gross profit loss, i.e., 23 min · EUR 49.23/min = EUR 1132, i.e., EUR 22.20 for each of the 51 components. This is the difference between gross and net costs when applicable, i.e., for strategies for which the removal of the fabric is necessary. Table 18 summarizes the direct costs during strategies for the involved components. On average, any failure, no matter the strategy to be applied afterwards, is assumed to have additional cost because it involves a probability that whiteness becomes bad, defined by the pilot experts as shown in Table 19, in which case the fabric needs to be reprocessed. Thus, the average gross profit lost during the waiting time for the fabric of bad whiteness to exit the machine (assumed as 23 min) should be considered extra. The aforementioned bad whiteness probabilities should be multiplied by this duration to compute probabilistically the expected additional waiting time shown in the column "Expected waiting time due to bad whiteness" of the table and the respective additional cost based on the rate EUR 49.23/min. The additional advantages of preventing failures is to avoid the downtime during the failure and the negative impact of anomalies and failures on the lifetime of neighboring components, according to the above.
Direct impacts of stops on other KPIs: The assumptions about the average waste per discarded component follow below: • Initially, the optimal strategy application policy for the double bearing-lubricant pair of the bottom roller was different from the policy for that of the top one, but the latter proved to be better and more stable across simulations, so it was selected for both double bearing-lubricant pairs.
Corrective strategies and actuators: The corrective strategies are mentioned in Table 20. All actuators are active because there is always some compulsory strategy after any failure, according to the above. Although the increase of KPI inefficiency due to equivalent aging has been defined as negligible for this pilot, KPI thresholds are still proposed, as shown above. Thus, the effective run of the model without surprising results requires precise evaluation of KPIs and definition of their thresholds. Otherwise, the optimal policy found after training the model with standalone uncoated rollers (Section 3.3.4) should be considered instead for the double bearing-lubricant pairs and the motor, because it depends only on failure probabilities (which increase much faster in absolute values due to degradation) and not on KPIs.

Evaluation Metrics
These are shown in Tables 21-23.    Figure 14 presents the time series of the total KPI per component within an interval of same length as the simulation interval during training, and the subsequent ones (Figures 15-19) show how each KPI is decomposed into individual KPIs. Every perpendicular line corresponds to a stop. The lower-length lines correspond to stop instances of lower impact. When applicable, the downtime impact of stops on the considered components of the production line which are out of this DSF Core model is incorporated in the perpendicular lines, which explains the negative values of the other environmental KPI.

Training Results for ZORLUTEKS-Model with Standalone Uncoated Roller Optimal Solution
The solution below, which was found from the original training, proved to be comparable with the solution based on the optimal strategy application policy for double bearing-lubricant pairs and motors as selected for models for motors with two rollers.
Corrective strategies and actuators: The corrective strategies are mentioned in Table 24. All actuators are active because there is always some compulsory strategy after any failure, based on the above. -Its left bearing lubricant failure probability within the next time step (30 min) exceeds 9.113753 · 10 −9 ; -Its right bearing lubricant failure probability within the next time step (30 min) exceeds 3.796748 · 10 −8 . • Motor when its lubricant failure probability within the next time step (30 min) exceeds 3.840225 · 10 −5 (in which case the maintenance is lubrication).

Evaluation Metrics
These are shown in Tables 25-27. Similar to before, Figure 20 presents the time series of the total KPI per component within an interval of the same length as the simulation interval during training, and the subsequent ones (Figures 21 and 22) show how each KPI is decomposed into individual KPIs. Every perpendicular line corresponds to a stop. The lower-length lines correspond to stop instances of lower impact. When applicable, the downtime impact of stops on the considered components of the production line which are out of this DSF Core model is incorporated in the perpendicular lines, which explains the negative values of the other environmental KPI.

Discussion of the Training Results for ZORLUTEKS
The conclusion from training the above models for this pilot is that the fast and economic preventive maintenance strategies, which usually may happen in parallel to production, help to considerably improve the total KPI, since they prevent numerous failures and the respective bad consequences. In addition, the fact that replacement instead of maintenance is preferred for a double bearing-lubricant pair after bearing mechanical fatigue for one of its bearings is because maintenance does not decrease at all the equivalent age with respect to mechanical fatigue. Table 28 contains the total KPIs with respect to components obtained from all seven trained models and their sum in the last row of each sub-table. (As mentioned above, the details about the extra five models are omitted in this paper to avoid extending its content too much.) As shown in the table, all but the last model correspond to solutions better than the respective initial ones; thus these models improve the total KPI. The models discussed above in detail correspond to the names "Motor of type 2_3_7" (for paired coated rollers) and "Motor of type 1" (for a standalone uncoated roller). Similar to GORENJE, the multipliers in the second column indicate the number of identical (groups of) components, to all of which the respective models apply. The energy and other environmental penalties are slightly negative (due to downtime), as expected, because no inefficiency during production has been defined for them, whereas the only defined non-economic penalty during stops is waste, which is almost negligible for the selected KPI weighting. Thus, the extra total KPI values, which appear in the bottom right cell of each sub-table and refer to the whole production line, depend almost only on the economic factor. These values indicate that the application of the optimal strategy application policies proposed above may reduce the yearly unnecessary total KPI penalty by 88,000 (33%) compared to the lightest compulsory corrective strategy application policy without preventive strategies. For the models discussed in this paper, this percentage is 32% (for the model with paired coated rollers) and 39% (for the model with a standalone uncoated roller).
linear with respect to the number of timestamps. Between the two optimization phases, the most time-consuming is the second one because the candidate values per variable to be optimized are more, and the number of variables is higher. The algorithm can find a near-optimal solution with few function evaluations in each of the two optimization phases (about 2MJ with respect to the case during the second phase, where M is the number of variables to be optimized and J is the number of epochs during that phase, and M ≤ 23, J ≤ 4 for the models trained). However, each individual function evaluation corresponds to a simulation of the production line operation during an interval large enough to include tens of instances for (almost) each stop type and with a sampling step not much higher than the shortest modelled mean stop duration of the specific stop type. These two conditions should be met so the numbers of stops and their downtime impact may be estimated accurately enough. Since about 1000 timestamps were processed per second during the simulation, the whole training usually takes hours or a few days. The memory complexity is linear with respect to both the number of components and the number of timestamps. Most of the trained models do not involve memory concerns, but the most complex models for ZORLUTEKS, that is, those involving motors with two rollers, consume significant memory. Although memory could be reduced with a small adaptation of the algorithm, this would lead to a further increase of execution time, so this idea was not implemented. The simulation approach may be more time-and memory-complex than an analytic solution in a simple case, but it is more generic and easily scalable.
The DSF Core is going to be deployed at the above pilot locations. The integration with the other relevant algorithms is ongoing as well. After deployment, the benefit offered by the DSF Core to the pilots will be evaluated. As future research work, the plan is to find the fastest but equally generic KPI evaluation methods that will avoid a significant part of the calculations during a normal simulation.
Author Contributions: Conceptualization and project administration, D.I. and D.T.; methodology, software, validation, formal analysis, investigation, data curation, writing-original draft preparation, writing-review and editing, visualization, supervision and funding acquisition, N.K.; resources, non-applicable. All authors have read and agreed to the published version of the manuscript. Data Availability Statement: All input parameters and specifications needed to train the DSF Core models discussed in this paper have already been provided within the main part of the manuscript with the permission of the pilots.

Acknowledgments:
The authors would like to thank the RECLAIM pilot partners, and more especially Jiří Balhar, Michael Peschl and Murat Yıldırım from the GORENJE, HWH and ZORLUTEKS pilots respectively, for communicating specifications.

Conflicts of Interest:
The authors declare no conflict of interest.

Abbreviations
The following abbreviations are used in this manuscript: