PROPOSED PROCEDURE FOR OPTIMAL MAINTENANCE SCHEDULING UNDER EMERGENT FAILURES

Production lines are usually subjected to emergent machine failures. Such emergent failures disrupt pre-established 
 maintenance schedules, which challenge maintenance engineers to react to those failures in real time. This research proposes an optimization 
 procedure for optimizing scheduling repairs of emergent failures. Three optimization models are developed. Model I schedules failures in newly 
 idle repair shops with the objective of maximizing the number of scheduled repairs. Model II maximizes the number of assigned repairs to 
 untapped ranges. Model III maximizes both the number of assigned failure repairs and satisfaction on regular and emergency repairs by 
 resequencing regular and emergent failures in the shop that contains the largest free margin. A real case study is provided to illustrate 
 the proposed optimization procedure. Results reveal that the proposed models efficiently scheduled and sequenced emergent failures in the idle 
 maintenance shops, the untapped ranges between repairs of regular failures, and in the maintenance shop with the largest free margin. In 
 conclusions, the proposed models can greatly support maintenance engineers in planning repairs under unexpected failures.


Introduction
Maintenance activities are generally divided into preventive, corrective, and predictive maintenance (Murthy et al., 2002;Yang et al., 2017). For any company, maintenance department (MD) is one of the most critical facilities that prone to bottlenecking and require resources associated with high costs (Ben-Daya et al., 2009;Salmasnia & Mirabadi-Dastjerd, 2017). In many MDs, the shop capacity is shared between two competing failure categories; emergent failures and regular failures. Scheduling and sequencing of the repairs of regular failures, which can be easily handled by maintenance planning engineers. While, emergent failures, which happen due to the occurrence of emergency events need immediate repairs due to avoid failure consequences; severity or production losses (Seif et al., 2018;Tonke & Grunow, 2018). In previous literature, maintenance scheduling problem has been extensively studied (Irawan et al., 2017;Kiefer et al., 2018;Chansombat et al., 2019). However, maintenance engineers are still challenged to handle repairs scheduling of emergent failures. This research, therefore, proposes mathematical optimization models for maintenance scheduling under emergency. The remaining of this paper including the introduction is outlined as follows. Section 1 reviews relevant studies on maintenance scheduling. Section 2 develops optimization models. Section 3 provides a real case study to illustrate the proposed models. Last section summarizes conclusions.

Literature review
Recently, the maintenance scheduling problem has received significant research attention. For example, El-Sharkh and El-Keib (2003) used fuzzy evolutionary programming for maintenance scheduling of generation and transmission systems. Cassady and Kutanoglu (2003) minimized job tardiness using integrated preventive maintenance planning and production scheduling. Cassady and Kutanoglu (2005) integrated preventive maintenance planning and production scheduling for a single machine. Ruiz et al. (2007) considered scheduling and preventive maintenance in the flowshop sequencing problem. Nourelfath et al. (2010) proposed an integrated model for production and preventive maintenance planning in multi-state systems. Lu et al. (2014) developed integrated production and preventive maintenance scheduling for a single machine with failure uncertainty. Jian and Tianyuan (2015) proposed LS-SVM based substation circuit breakers maintenance scheduling optimization. Squires and Hoffman (2015) considered military maintenance planning and scheduling problem. Xiao et al. (2016) conducted joint optimization of production scheduling and machine group preventive maintenance. Wu et al. (2017) proposed a computational method for optimal machine scheduling problem with maintenance and production. Yin et al. (2017) solved a multi-objective scheduling optimization model considering product blockage and machine faults. Grigoriu and Briskorn (2017) considered scheduling jobs and maintenance activities subject to job-dependent machine deteriorations. Irawan et al. (2017) optimize maintenance routing and scheduling for offshore wind farms. Liao et al. (2017) conducted multi-objective group scheduling optimization integrated with preventive maintenance. Lu and Zhou (2017) considered opportunistic preventive maintenance scheduling for serial-parallel multistage manufacturing systems with multiple streams of deterioration. Gholami and Hafezalkotob (2018) performed maintenance scheduling using data mining techniques and time series models. Alayo and Paucar (2018) employed A MILP model for maintenance scheduling in transmission systems application to Peruvian system. Kiefer et al. (2018) performed scheduling of maintenance work of a large-scale tramway network. Rasiulis et al. (2016) proposed the decision model for selection of optimal combinations of modernization measures. Bertolini et al. (2019) conducted comparison of new metaheuristics, for the solution of an integrated jobs-maintenance scheduling problem. Chansombat et al. (2019) proposed a mixed-integer linear programming model for integrated production and preventive maintenance scheduling in the capital goods industry. Miyata et al. (2019a) incorporated preventive maintenance into the m-machine no-wait flow-shop scheduling problem with total flow-time minimization. Miyata et al. (2019b) incorporated preventive maintenance operations as a constraint to the m-machine no-wait flow shop problem with dependent-sequence setup times and makespan minimization scheduling problem. Miyata and Nagano (2019) fulfilled a deep literature review (in total 139 papers are reviewed and classified) on the m-machine flow shop scheduling problem with blocking conditions. Rossit et al. (2019) studied the permutation flow shop and the non-permutation flow shop scheduling problems in the case of two jobs, when makespan is the objective function and processing times are not known. Hedjazi et al. (2019) presented the methodology to schedule the maintenance activities of geo-distributed assets. The authors proposed a multi-agent system based approach to enable the decision-making for the subcontractors in a distributed industrial environment under uncertainty. Yang et al. (2019) investigated an advanced group and opportunistic maintenance policy for a two-component system with failure interaction. Authors provided a case study on an electrical distribution system to validate the applicability of the adopted policy. Abed et al. (2019) analyzed scheduling maintenance jobs in networks. Ustinovichius et al. (2018) developed a conceptual model of BIM-based design and refurbishment, based on pre-built indicators and allowing the assessment of the building energy demand and eco-building parameters. Analysing the literature, few approaches can be found to describe the parameters (e.g. maintenance time) of the system. The first involves using fuzzy logic to estimate stochastic parameters and calculate the probability of disturbance (Duenas & Petrovic, 2008). The second approach is applying the theory of probability (Liu et al., 2018;Paprocka, 2019) to describe the maintenance time. The third approach is using numerical ranges (Kalinowski & Zemczak, 2015) determined by a decisionmaker arbitrarily.
This research proposes an extension of ongoing research by proposing three models for optimizing maintenance scheduling and sequencing under the occurrence of emergent failures while considering the maximization of satisfaction on the repairs of regular and emergent failures and the number of assigned emergent failures and satisfaction.

Proposed optimization models
Typically, scheduling repairs of regular failures is established in maintenance shops before an emergent failure, k, occurs (at t < t k ). However, this schedule is disturbed once emergent failures have occurred (at t = t k ). To handle repairs of such failures, the three consecutive cases, as shown in Figure 1, will be considered; Case I considers the scheduling of the repair of the emergent failures in the MD's idle shops. Case II assigns emergent failures in the untapped ranges of shops, which is the idle time between the assigned repair times of the regular failures. Case III selects the shop with the largest free margin to be re-sequenced for both emergent and regular failures.

Scheduling repairs of the emergent failures in the idle shops (CASE I)
Let k be the index of emergent failure; k ∈ [1, ..., K], and s denotes shop index; s ∈ [1,.., S]. The model assumptions include: (1) each technician crew (w) is responsible for a certain shop s during shops working hours and (2) the regular opening duration of shops, R s , includes the maximum allowed overtime. Let the binary decision variable, y ks , indicates that shop s is assigned to repair emergent failure k, where y ks equals one if failure k is assigned to shop s, and zero otherwise. During the occurrence of the emergent failures, the maintenance department (MD) normally aims to maximize the number of repaired failures in the idle maintenance shops at any cost. The objective function is thus expressed as shown in Eqn (1): The objective function is subjected to the following constraints: (i) For shop s, the total of repair durations must not exceed the regular working hours. Let Dtot k denotes repair duration of an emergent failure k (in hours) and R s denotes the regular working hours of shop s (hours). Then, respecting shop availability is expressed mathematically as follows: ( ) (v) When the failure repair has repair duration equal to or larger that SRD (Dtot k ≥ SRD), then it can be delayed. That is: Solving Model I, the assigned shop to each emergent failure, y ks , are obtained.

Sequencing repairs of the emergent failures in the idle shops
This model aims to sequence the scheduled emergent failures in their assigned maintenance shop s. Let st ks and ft ks denote the repair start and finish times for failure k in shop s, respectively. The repair time priority depends on the arrival time, AT k , for failure k; that is, first arrived failure shall be repaired first. To repair emergent failures as soon as possible, the start repair times shall be minimized. That is: (c) If emergent failures k and k' were both assigned to be repaired in shop s and failure k arrives after failure k',

Insertion of repairs of the emergent failures in untapped ranges (CASE II)
Let Dtot f denotes the repair duration of regular failure f. This model attempts to insert repair of emergent failure k between the scheduled repairs of regular failures as illustrated in Figure 2. Before constructing the model, the following assumptions have been made: (1) the number technician crew (W) is equal to the number of shops (S); that is, each crew w is assigned to make repairs in a specific shop s, and (2) the repair equipment are available in all shops. Further, the main model parameters include: (i) disruption time, t k , number of shops, S, number of emergent failures, K, and number of regular failures, F, (ii) the repair durations, Dtot f , and Dtot k , of the of regular failure f and emergent failure k, respectively, (iii) the repair start time, st fs , of each regular failure in maintenance shop s, and (iii) the precedence matrix, ε fjs , between regular failures f and j in shop s.
Let ρ kfjs be a binary variable that denotes the repair assignment of the emergent failure k between regular failures f and j in shop s; which ρ kfjs is equal to one if the repair of the emergent failure k is assigned and zero otherwise. The objective function is then formulated to maximize the total number of emergent failure repairs inserted in the untapped ranges over all maintenance shops as stated in Eqn (13). The imposed constraints on the objective function follows: (i) Let ut fjs and t k denote duration of the untapped range between failures f and j in shop s, and disruption time, respectively. The interest is to calculate the untapped range in which emergent failure repairs can be inserted following the disruption time, t k . Figure  3 shows the situation in which the untapped range is equal to zero. Mathematically: In contrast, the untapped range between the repairs of failures f and j as shown in Figure 4 and stated in Eqn (15) can be utilized to insert the repair of emergent failure k is shop s.
Another untapped range situation is considered when the disruption time occurs in idle time as illustrated in Figure 5, the untapped range is then estimated using Eqn (16): (ii) The ut fjs is sufficient to insert emergent failure repair(s). That is: (iv) The ρ kfjs is a binary variable; or:  The optimization results of this model identify the maintenance shop in which the repair of emergent failure k will take place and between which failure repairs, ρ kfjs , and untapped ranges, ut fjs , values.

Re-sequencing shop of the largest free margin (CASE III)
Model III re-sequences the prescheduled repairs of the regular failures in the maintenance shop of the largest free margin in order to assign the repairs of the remaining emergent failures. Initially, the free margin, is calculated as the summation of all the untapped ranges between regular failures repairs as illustrated in Figure 6.  (21) to (24).
Let the repairs of regular failures j and l be sequenced after and before the repair of failure f, respectively. Then, the fs LF ' and fs EF ' are respectively calculated as: Model III is composed of three sub-models (III-A, III-B and III-C), which are presented as follows. Model III decision variables and parameters are listed in Table 1.

Model III-A: maximize the total number of repaired failures
Suppose that the repairs of E emergent failures are still unassigned. Let P ft and P kt be binary variables which determine the repair assignment of the regular and emergent failures, respectively; where P ft and P kt equal to one if failure f is repaired at hour t and zero otherwise. Let s' denotes the maintenance shop of the largest free margin. CT s' denotes the closing time for shop s'. Given the precedence matrix, ε fjs' , that determines whether failure f should be repaired before or after failure j at maintenance shop s', which equals one if the repair of failure f should be repaired before failure j and zero otherwise. The objective functions then are maximizing the total number The objective functions are subject to the following constraints: (i) Repair of emergent failures shall be assigned in maintenance shop s', whereas the repair of regular failures can be delayed as stated by inequality (27) and Eqn (28), respectively.
(ii) At most one repair of regular or emergent failure can be assigned at each time t. Thus, the following inequalities are formulated: (iv) Let rt f denotes the readiness time of failure f. The repairs of regular and emergent failures should not be realized before failure f is ready (setup procedure ended) and arrival time, At k , respectively, as expressed in Eqns (33) and (34) (v) The repairs of regular or emergent failure should end at most at the closing time, CT s' , for shop s' as stated in Eqns (35) and (36), respectively: (vi) Let ε fjs' be a binary variable that denotes repairs precedence between failures f and j in maintenance shop s', which equals one if the repair of failure f should be repaired before failure j and zero otherwise. That is: Then, the precedence between the repairs of any two regular failures in shop s' is respected as stated in inequality (38) (1 ), (vii) The repair start times of the regular and unassigned emergent failures are respectively expressed using Eqns (39) and (40) (1 ),

Model III-B: maximizing satisfaction on emergent failure repairs
This sub-model seeks maximizing the satisfaction on repairs of emergent failures, which is calculated by considering the positive delay, st ks ' + δ , which the time delay between the time of failure repair and its readiness time. Because the smaller delay leads to better satisfaction, the proper membership function is the smaller-the-better (STB) re-sponse type. Let The decision variables are ( ) ks st ' + µ and st ks ' + δ . The objective function is then to maximize sum of satisfaction functions. Mathematically: (45) The model parameters include minimum acceptable satisfaction, q k , failure readiness time, rt k , the maximum delay, st ks 1 ' + υ , and repair start time, st ks' . The constraints of maximizing total satisfaction on the repair of the emergent failures are as follows: (i) The value of ( ) should be at least q k as formulated in inequality (46): (ii) Satisfaction on emergent failure's repair is determined with consideration of the delay occurred in assigning the failure's repair after rt k , where the target is to assign the failure's repair once it is ready (setup procedure ended), as given in Eqn (47) can be formulated as shown in Eqn (50) , , , , Finally, the following constraints are formulated:   after which satisfaction will be one.
Typically, larger satisfaction indicated better performance. Thus, the objective function is formulated to maximize the total satisfaction, ( ) fs st ' µ , on repairs of regular failures; mathematically: ( ) This objective is subjected to the following constraints: (i) The satisfaction shall achieve at least minimal satisfaction level, q f , on each failure's repair; or (ii) Failure satisfaction is determined with consideration to the delay occurred in failures' appointment where the target is to prohibit appointment changing, as expressed in Eqn (59): where: functions are respectively formulated as shown in Eqns (62) and (63) γ be binary variables given respectively by Eqns (64) and (65):

Application of the proposed optimization procedure
The optimization models were applied on a real case study for a maintenance department, which consists of six maintenance shops. The maintenance department consists of four active maintenance shops; s = 1, ..., 4; where 23 regular failures (f = f 1 , ..., f 23 ) were already scheduled to these four shops. Assuming that at 9:00 am on the schedule date, twenty emergent failures (k = k 1 , ..., k 20 ) have been occurred.

Case I: scheduling and sequencing of emergent failure repairs in idle maintenance shops
Firstly, Model I will be used to schedule and sequence the emergent failures in the idle maintenance shops (shops 5 and 6). The input data for model I are summarized in Table 2. The relevant data for the emergent failures are represented in Table 3. Model I was solving to schedule and sequence the repairs of the twenty emergent failures in the idle maintenance shops 5 and 6 as illustrated in Table 4. However, repairs of the emergent failures k 2 , k 6 , k 8 , k 10 , k 13 and k 15 remain unassigned. Next, the sequencing of the 14 scheduled emergent failures is conducted as shown in Table 5 and Figure 8.

Case II: repair of unscheduled emergent failures in the untapped ranges between repairs of regular failures
Model II will be utilized to assign the repairs of failures k 2 , k 6 , k 8 , k 10 , k 13 and k 15 in the untapped ranges between the repairs of regular failures. General inputs of model II are listed in Table 6, where 23 repairs of regular failures have already been scheduled in operating maintenance shops one to four. The pre-established repair assignment of these regular failures on the day of emergent failure is shown in Table 7. The untapped ranges are calculated and then depicted in Figure 9. t k 0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5 5.5 6 6.5 7 7.5 8 8.5 9 k 4 k 9 k 1 k 18 k 19 k 17 k 12 k 20 After solving Model II, 5 out of 6 the remaining repairs of emergent failures are scheduled in the untapped ranges between regular failures as shown in Figure 10.
However, failure k 13 is still not assigned because its repair time is larger than the sum of all untapped ranges. Thus, Model III will be used in sequence emergent failure k 13 in the active maintenance shop of the largest free margin. As shown in Table 8, the largest free margin corresponds to shop 4.the general inputs for Model III are displayed in Table 9 and the precedence of regular failures, ε fjs' , and the readiness times are shown in Table 10. Moreover, Model III maximizes the satisfactions of the regular failures.
Note that shop 4 has the highest free margin, which is larger than the repair durations for the remaining unscheduled emergent failure. In order to insert the repair of emergent failure k 13 in shop 4, the six scheduled repairs of the regular failures including one inserted emergent failure will be re-sequenced. After solving Model III, the resulted repairs' sequencing in shop 4 are shown in Figure 11. The obtained start times are presented in Table 11. Finally, utilization values for the six maintenance shops before and after adopting the optimization models are presented in Table 12 and Figure 12.

Conclusions
This research proposed three models for optimal scheduling and sequencing repairs of emergent and regular failures in maintenance shops under the occurrence of unexpected events. The models were implemented on schedule and sequence 20 emergent failures and pre-sequenced 23 regular failures in six maintenance shops in a real case study. The results revealed that the proposed models effectively scheduled and sequenced emergent failures while maximizing satisfaction on the repairs of emergent and regular failures and enhanced the utilization of maintenance shops, which saves significant maintenance and production costs. In conclusion, the proposed optimization procedure is found valuable in maintenance planning activities and can be utilized for maintenance scheduling and sequencing repair of emergent failure in a wide range of business applications.

Author contributions
Abbas Al-Refaie and Heba Al-shalaldeh conceived the study and were responsible for the mathematical modelling of optimization models, data collection and analysis, and results interpretation. Natalija Lepkova was respon- Shop 5 --6 88% Shop 6 --8 88% Figure 11. The obtained repairs sequence by using Model III Figure 12. Utilization of the shops before and after using the model t k 0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5 5.5 6 6.5 7 7.5 8 8. Before After sible for review of the presented literature, data analysis, and models' validation on real industrial application in the article.

Disclosure statement
Authors do not have any competing financial, professional, or personal interests from other parties. The authors declare no conflict of interest.