## 2 Problem Description  
A flexible production line is considered in current research, which is composed of several machines in series to process multiple types of products. Customer orders arrivedin the workshop with a variety of demand of products with different due dates. Moreover, each customer can give a distinct amount of profit on different product models and have different penalty costs on delay. In addition, due to the capacity constrained resources (CCR), there is a storage buffer of the semi-finished parts associated with different product models in the buffer near CCR. Different buffer sizes are assigned to each product model to complete the uncertain demand of product models from customers. The problem is concerned to decide the production sequence of different product models on the CCR resource so that the buffer of each product models can be utilized efficiently and the company can earn more profit to fulfill customer demand in each planning horizon. Figure 1 illustrates a schematic of the proposed DBR based rolling horizon concept for order scheduling and mixed model sequencing in the production line.  
The objective of the planning and scheduling problem is to maximize the net profit earned from different customers in a planning horizon as indicated in Equation (1):  
\[\max\,NP=\sum_{\tau=1}^{T}\sum_{i=1}^{I}\sum_{\tau=1}^{Z}\left[\sum_{q=1}^{d_{ \tau\tau}}UP_{x}^{i}X_{xq\tau}^{i}-PC_{x}^{i}\left(d_{\tau\tau}^{i}-\sum_{q=1}^ {d_{\tau\tau}^{i}}X_{xq\tau}^{i}\right)\right] \tag{1}\]  
\[X_{xq\tau}^{i}=\left\{\begin{array}{ll}1,\,\,if\,\,Com_{xq\tau}^{i}\leq DD_{ xq\tau}^{i}\\ 0,\,\,otherwise\end{array}\right. \tag{2}\]  
\[Com_{xq\tau}^{i,m}=\sum_{q=1}^{Q_{\tau}}i_{xmq\tau}^{i},\,\,\,\forall m=1,\, \,\forall q \tag{3}\]  
\[Com_{xq\tau}^{i,m}=Com_{xq\tau}^{i,(m-1)}+i_{xmq\tau}^{i},\,\,\forall q=1,\, \,\forall m\in(2,M) \tag{4}\]  
\[Com_{xq\tau}^{i,m}=max\left\{Com_{xq\tau}^{i,(m-1)},\,\,Com_{x(q-1)\tau}^{i,m} \right\}+t_{xmq\tau}^{i},\,\,\forall q>1,\,\,\forall m\in(2,M) \tag{5}\]  
\[S_{\tau\tau}>0,\,\,\forall\kappa=1,2,\cdots,\text{models},\,\,\forall\tau=1,2,\cdots\Gamma \tag{6}\]  
\[S_{\tau\tau}\leq SC_{x},\,\,\,\forall\tau=1,2,\cdots\Gamma \tag{7}\]  
Equation (1) indicates maximizing the objective of total net profit that can be earned from customer orders from all customers and all planning horizons. The objective function includes unit profit that can be earned from a product model from different customers on the basis of their urgency, etc., and it also includes the penalty cost that the company has to pay to the customer if the demands of the customer are not met before their due date. The penalty cost for each product model is also different for different customers. Equation (2) indicates a binary variable to know if the completion time of the product model is within its due date. Equation (3) to Equation (5) indicate the completion time of any product model on CCR and other downstream machines. Equation (6) indicates that, for any planning horizon, there is always some storage of material related to any product model in the product model buffer of CCR exits. Equation (7) indicates the buffer size constraint of product model \(x\) in planning horizon \(\tau\).  
Figure 1: Order releasing and scheduling for a multi-item MTO industry in the production line.