## 2 Materials and Methods
### Pseudocode
Simultaneously optimising production and maintenance tasks is very computationally intensive, especially when there are many machines and jobs. The CBC solver is suitable for medium-sized problems but reaches its limits as complexity increases. Strong solvers such as CPLEX or Gurobi, heuristic methods, or learning methods can reduce the computational effort [11]. Solvers can also be made more efficient by dynamically adapting to previous optimisation runs, thus reducing computation time. Alternatively, heuristic or metaheuristic methods can reduce computational time by providing an approximate solution of acceptable quality in a shorter period. This is particularly relevant in highly variable production scenarios, where fast decision-making is essential. A further challenge lies in the modelling assumptions. The quality of the results depends heavily on the reliability of the input data, especially when predicting machine wear and failure probabilities [30]. Inaccurate or incomplete data can lead to maintenance measures being scheduled too early or too late, which impairs the efficiency of the model. Therefore, accurate data collection and regular updates are essential for reliable planning. The current model calculates machine wear based on task-specific load factors and task-specific utilisation patterns. Although no real-time sensor data are used, this approach is a condition-based strategy. The maintenance timing is dynamically adjusted as soon as certain thresholds are exceeded. Future research could investigate the integration of real-time monitoring to further improve maintenance decisions. The model does not contain any formal stochastic elements or interruption scenarios, so it supports limited responsiveness through iterative replanning. Rescheduling can be triggered by updated machine conditions, e.g., progressive wear or the occurrence of free capacity. This allows the model to respond to changing production conditions within short-term planning horizons, which it is designed to do. To further evaluate the robustness of the model, a sensitivity analysis can be conducted by systematically varying key input parameters such as machine availability, maintenance thresholds or production order priorities. This provides insights into how stable the optimisation results remain under changing conditions and whether specific parameter ranges significantly impact scheduling efficiency. Analysing how variations in job sequencing affect machine utilisation and maintenance scheduling is particularly relevant, as fluctuations in incoming orders are common in real-world production environments. Future research should integrate such an analysis to strengthen the empirical validation of the approach and assess its adaptability to dynamic production scenarios. In addition, the model requires interlinking between production and maintenance planners, as they are responsible for data maintenance, the validation of data, and the integration of empirical values. Acceptance and utilisation of the model by planners is crucial to fully exploit its potential. ### Implications for Practice

Parallel to the model analysis, an expert interview was conducted to assess the practical applicability and possible challenges in implementation. The expert interviewed comes from a one-off production company with a batch size of 1 and has in-depth knowledge of production planning and dealing with unplanned maintenance measures. His assessments are based on many years of experience in a diverse production environment with a large number of critical machines and a machine park with varying production requirements. The results show that although machine runtimes and maintenance data are available in many companies, they are not systematically used for optimised maintenance planning, and that there is often a lack of structured data evaluation and the ability to dynamically adapt maintenance decisions to current machine conditions. The model offers the option of utilising unused production time windows to carry out preventative maintenance measures.