Scheduling using max-plus algebra. M.D. van den Muijsenberg

Size: px
Start display at page:

Download "Scheduling using max-plus algebra. M.D. van den Muijsenberg"

Transcription

1 Scheduling using max-plus algebra General framework and application to a baggage handling system Delft Center for Systems and Control

2

3 Scheduling using max-plus algebra General framework and application to a baggage handling system For the degree of Master of Science in Mechanical Engineering at Delft University of Technology July 15, 2015 Faculty of Mechanical, Maritime and Materials Engineering (3mE) Delft University of Technology

4 Copyright c Delft Center for Systems and Control (DCSC) All rights reserved

5 Abstract In industry, discrete models can be used to describe and analyze a class of event driven systems These so called discrete event systems (DESs) contain a finite number of resources that are shared by different users called jobs All of these resources and jobs contribute to the achievement of some common goal Deciding on how to allocate a set of jobs to limited resources over time in an optimal way is called scheduling, where the basic types of control decisions are routing, ordering and synchronization The scheduling of DESs is crucial in many applications, such as railway networks, production systems, baggage handling, legged locomotion, container handling and paper handling in printers Most of the models that describe the behavior of DESs are nonlinear in the conventional algebra that uses addition and multiplication operators There is however a class of DESs that can be described by a model that is linear in the max-plus algebra, which uses maximization ( ) and addition ( ) as its main operators In such a max-plus linear (MPL) system the model structure is fixed, whereby changes in the structure of the system cannot be modeled However, the model dynamics can be influenced by allowing switching between different modes An MPL system where switching is allowed is called a switching max-plus linear (SMPL) system By switching to another mode, the route, order and/or synchronization is changed A general framework on how to model these SMPL systems is obtained, where the topology graph is used A topology graph of a system describes all possible connections between resources but does not tell which route or order is chosen The routes can all be constructed by assigning max-plus binary control variables to each arc By looking at the number of incoming arcs specific ordering constraints for each node are obtained A problem that remains are circuits where a job can re-enter multiple times These circuits result in duplicated nodes whereby the ordering constraints change The method on how to model such circuits is described Once the model is obtained, the scheduling problem always results in finding the optimal max-plus binary variables related to routing and ordering This control problem is solved by using a Model Predictive Control (MPC) strategy, which is recast as a Mixed Integer Linear Programming problem Using the general framework, a simple and more complex baggage handling system is modeled and controlled Adding a due date reference for the complex baggage handling system shows that the bags arrive in time Also the switching between different cycles can clearly be seen

6 ii

7 Table of Contents Acknowledgements vii 1 Introduction Background Problem statement Contribution Outline 3 2 Max-Plus Linear systems Maximization and addition Basic elements and matrices in the max-plus algebra Graphs Solving linear equations Max-plus linear systems Switching max-plus linear systems Routing Ordering Synchronization Overall SMPL system Parameterization Converting max-plus binary equations to conventional equations 18 3 General modeling framework using topology graphs Defining the elements in a system Variable routing Ordering Nodes with one incoming arc 32

8 iv Table of Contents Nodes with more than one incoming arc Ordering between duplicated nodes Exceptions Overall ordering decision constraints Overall SMPL system Using the eigenvalues and eigenvectors 44 4 Control for SMPL systems Model Predictive Control for SMPL systems Prediction model Cost function Constraints Overall Model Predictive Control problem Tuning Solving the optimization problem Recast MPC problem into MILP problem 51 5 Case studies: three discrete event systems modeled using the general framework Legged locomotion Scheduling of multiple sheets in a printer Railway network Concepts and definitions in a railway network Modeling a railway network using the topology graph 66 6 Case study: baggage handling system Baggage handling without circuits Routing Ordering Control Complex baggage handling system Routing complex baggage handling without circuits Ordering complex baggage handling system without circuits Control complex baggage handling system Modeling the circuits in a baggage handling system 87 7 Conclusions and recommendations Conclusions Recommendations Parameterization of the control variables Ordering between duplicated nodes Extend general Matlab code to multiple jobs 93

9 Table of Contents v A General framework for routing constraints in Matlab 95 A-1 Matlab file 95 A-2 Routing file 100 B General framework for ordering constraints in Matlab 103 B-1 Matlab file 103 B-2 Ordering file 111 C General framework for scheduling in Matlab 113 C-1 Matlab file 113 C-2 Scheduling file 120 C-3 Structure of the vectors used in the MILP formulation 122 D Adjustments in Matlab file for case study simple baggage handling system 127 E Reference file for scheduling complex baggage handling system 129 E-1 Matlab file 129 Bibliography 135 Glossary 137

10 vi Table of Contents

11 Acknowledgements I would like to thank my supervisor drir Ton van den Boom for the time he invested in me while working on this thesis The meetings where he answered my questions and where we came up with more ideas were very helpful Furthermore, I want to thank the other members of the exam committee, prof dr ir Bart De Schutter and drir Gabriel Lopes, for evaluating my thesis Finally I thank my friends and especially my parents for the support they gave me through the years of college Without them I would have never made it this far Delft, University of Technology July 15, 2015

12 viii Acknowledgements

13 Chapter 1 Introduction 1-1 Background Within our ever-expanding society the need for complex automated systems in fields like transport, logistics and manufacturing continues to grow We have come to rely so naturally on streamlined regulation of such systems that the general population often does not even notice they exist; trains run in time, printers operate in the fastest way possible and luggage is optimally distributed However, it is when these automated systems are disrupted that we experience discomfort and our dependencies become truly apparent In highly complex automated systems even the tiniest disruption can result in a complete failure of all subsequent processes Therefore a great amount of effort is being invested in the creation of fail-safe mechanisms that ensure the proper functioning of a total system if one of its parts does not function properly Generally, the approach for the creation of fail-safe mechanisms is to first identify and understand all of the system properties through mathematical modeling The evolution of these dynamic systems depends on the interactions of various events, such as the arrival or departure of a train or the completion of printing a paper Such a dynamic system is referred to as a discrete event system (DES) The state of a DES is defined as the set of time instants the events occur and therefore the state changes at various time instants as opposed to discrete time systems A DES contains a finite number of resources, such as machines, that are shared by different users called jobs Each job consists of a chain of operations, where every operation needs to be performed on a specific resource After all jobs in a system have been completed, the cycle is complete and a new cycle begins All of these resources and jobs contribute to the achievement of some common goal Deciding on how to allocate a set of jobs to limited resources over time in such a way that one or more objectives are optimized is called scheduling The scheduling of a DES consists of routing, ordering and synchronization Most of the mathematical models that describe the behavior of DESs are nonlinear in the conventional algebra that uses multiplication and addition as its main operators There is however a class of DESs that can be described by a model that is linear in the max-plus algebra Max-plus algebra is a

14 2 Introduction so called dioid algebra The study of dioid algebras has been described in literature since the 1970 s However, it was not until the mids 1980 s that their use in the modeling and analysis of DESs was pioneered by Cohen et al Modeling a DES using max-plus algebra has as advantage that the resulting MPL system can be considered as a linear system which has a strong analogy to conventional linear system theory A disadvantage is that in such an MPL system the model structure is fixed, whereby change in the structure of the system cannot be modeled However, the model dynamics can be influenced by allowing switching between different modes Therefore, the optimal schedule can be calculated for each cycle if the route, order and/or synchronization can change Furthermore, if a disruption occurs the model can be updated with new information and the system can be rescheduled An MPL system where switching is allowed is called a switching max-plus linear (SMPL) system [1], [2] The mathematical modeling of such an SMPL system if often time consuming Therefore, it would be convenient if there is a general modeling method that one can follow, whereby all DESs can be modeled Moreover, when an adjustment must be made in the obtained model, such as adding a resource, it is desirable that not the whole system needs to be remodeled It would be time saving if then only that specific part can be added whereby automatically a new model is obtained Finally, a systematic way of modeling results in a structured control method to obtain the optimal schedule 1-2 Problem statement For a variety of DESs a (switching) max-plus linear model is already obtained These systems have similarities, but also contain differences Some systems have an external given input, such as a baggage handling system, while others have a controllable input, this may occur in production systems It also may happen no input is present at all, this is the case in for example paper handling in printers Furthermore, systems may have multiple jobs each cycle (railway network, where the jobs are the trains) or only one job per cycle (printers, since then a job is one sheet) The routes of the jobs can vary every cycle or can be fixed and ordering and synchronization may or may not occur The main research question for this thesis is: Is there a generic way of modeling for these type of systems based on the similarities while taking the differences into account? If this is possible, the goal is to obtain a general framework whereafter another goal is to model a baggage handling system using this framework, since this particular system is not yet described as an (S)MPL system in literature To achieve these goals, several steps need to be taken A structured way to build up the system matrices should be defined An option is the use of graphs which can be used to model DES Combining these graphs with max-plus algebra may result in a systematic way to build up the system matrices for an (S)MPL system After the general modeling framework is obtained, this is tested by modeling some systems already modeled as an (S)MPL system in literature Thereafter, the baggage handling system will be modeled Once the (S)MPL model is obtained, the optimal operating schedule for the system needs to be found, where the control strategy Model Predictive Control (MPC) is used This MPC problem needs to

15 1-3 Contribution 3 be recast as a Mixed Integer Linear Programming (MILP) problem, in which modeling using max-plus algebra will contribute to a structured way to do this 1-3 Contribution The main contributions of this thesis are the general modeling framework using topology graphs described in chapter 3 and the initial modeling and control of a baggage handling system in chapter 6 In the general modeling framework the routing and ordering constraints for SMPL systems are described in a general way The MPC problem is adjusted in chapter 4 to fit the general modeling framework from chapter 3 Three DESs that already have been modeled as an (S)MPL system are modeled in a different way by using the general framework in chapter Outline Chapter 2 will introduce max-plus algebra by defining its basic operators and basic elements and matrices Furthermore, the concept of using graphs to model the system will be explained Then the eigenvalues and eigenvectors in max-plus algebra will be defined and the method of solving linear equations in the max-plus algebra will be explained Finally, an introduction to MPL systems is given, after which an extension is made to SMPL systems and the three basic types of scheduling decisions are explained The general modeling framework for SMPL systems is explained in chapter 3 In chapter 4 a Model Predictive Control method is explained for SMPL systems Furthermore, methods to solve the eventually obtained optimization problem are defined The modeling framework is used in chapter 5, where different case studies of systems already modeled as (S)MPL systems are given The general framework is used for the modeling and control of the baggage handling system in chapter 6 Finally, chapter 7 gives some conclusions and recommendations for future research

16 4 Introduction

17 Chapter 2 Max-Plus Linear systems As explained in section 1-1, a class of discrete event systems (DESs) that is nonlinear in conventional algebra that uses multiplication and addition as its main operators can be described by a model that is linear in the max-plus algebra Max-plus algebra has maximization and addition as its basic operations In this chapter the basics of max-plus algebra are described, which is mainly based on [3] Hereafter Max-Plus Linear (MPL) systems are described and then this is extended to Switching Max-Plus Linear (SMPL) systems 2-1 Maximization and addition Where in the conventional plus-times algebra the main operators are addition (+) and multiplication ( ), in the max-plus algebra the main operators are maximization (max-plus addition) and addition (max-plus multiplication) and are represented by and respectively The max-plus multiplication can be compared to the addition in conventional algebra, as will be shown below First consider max-plus multiplication of scalars: = = 10, which shows that for scalars max-plus multiplication is the same as addition in conventional algebra For matrices however, A B A + B For matrices A R 4 4 max and B Rmax 4 4 the max-plus multiplication works in the following way: [ ] [ ] a11 a A B = 12 b11 b 12 = a 21 a 22 b 21 b 22 [ ] max(a11 + b 11, a 12 + b 21 ) max(a 11 + b 12, a 12 + b 22 ) max(a 21 + b 11, a 22 + b 21 ) max(a 21 + b 12, a 22 + b 22 ) Writing this in max-plus algebra results in:

18 6 Max-Plus Linear systems A B = [ ] (a11 b 11 ) (a 12 b 21 ) (a 11 b 12 ) (a 12 b 22 ) (a 21 b 11 ) (a 22 b 21 ) (a 21 b 12 ) (a 22 b 22 ) As can be seen from the previous, matrix multiplication in the max-plus algebra is similar to matrix multiplication in conventional algebra The difference is that the and + are replaced by the max-plus operators and respectively This also holds for non-square matrices As long as the number of columns of A are equal to the number of rows of B, A B is defined So for matrices A R n l max and B R max l m, A B is defined as: [ l A B ]ik = a ij b jk = max{a ij + b jk } (2-1) j=1 Next the max-plus addition will be explained scalars: = max(1, 4, 5) = 5, Again, first consider max-plus addition of where the max-plus addition is defined as taking the maximum For matrices it works similar Again take A R 4 4 max and B R 4 4 max, then the max-plus matrix addition will result in: [ ] [ ] [ ] [ ] a11 a A B = 12 b11 b 12 a11 b = 11 a 12 b 12 max(a11, b = 11 ) max(a 12, b 12 ) a 21 a 22 b 21 b 22 a 21 b 21 a 22 b 22 max(a 21, b 21 ) max(a 22, b 22 ) Here it also holds that matrix addition in the max-plus algebra is similar to the matrix addition in conventional algebra, the + is replaced by the operator For A B to exist, A and B must be the same size This gives the following result The sum of matrices A, B R n m max, denoted by A B is defined by: [ ] A B = a ij b ij = max(a ij, b ij ) for i n and j m (2-2) ij Further it is important to know that has priority over the operation, as can be seen in the following example using scalars: = (5 6) (8 2) = 1 10 = max( 1, 10) = 10 So in general this leads to: x (y z) = x max(y, z) = x + max(y, z) = max(x + y, x + z) = (x y) (x z) Now that the basic operations are described, the powers of scalars and matrices can be defined The nth power of a scalar x is defined as follows: x n = x x x x = nx (2-3) }{{} n times

19 2-2 Basic elements and matrices in the max-plus algebra 7 The same holds for max-plus roots: = = 3 = 3 1 For matrix A R n n max, the kth power of A is defined by: A k = A A A A }{{} k times (2-4) Lastly, a max-plus Schur product can occur which is denoted by the operation and is defined as: [ ] A B = a ij + b ij, for i n and j m (2-5) ij 2-2 Basic elements and matrices in the max-plus algebra The max-plus algebra is defined by all real numbers (R) and ε, denoted by the set R max = R {ε}, and the operations and Here ε def = This is often called the max-plus zero and below can be seen why In conventional algebra the following equality rule holds: 0 a = a 0 = 0 This equality rule is valid in max-plus algebra using ε: ε a = a ε = ε Another difference between max-plus algebra and conventional algebra is the replacement of 1 by e, where e def = 0 Again lets consider the following equality in conventional algebra: 1 a = a 1 = a By replacing 1 with e the equality rule holds using the max-plus multiplication: e a = a e = a The definitions described above result in different zero and identity matrices compared to the ones in conventional algebra These max-plus standard matrices are given below [ ] E = ε for all i, j (2-6) ij { [ ] e, if i = j E = (2-7) ij ε, otherwise where E is the max-plus zero matrix and E is the max-plus identity matrix Lastly, let u B ε = {e, ε} be a max-plus binary variable Then the adjoint variable ū B ε is defined as: { e, if u = ε ū = (2-8) ε, if u = e

20 8 Max-Plus Linear systems 2-3 Graphs To any n n matrix A a graph can be associated This graph is called the communication graph of A and is denoted by G(A) A graph G(A) consists of a finite set of nodes, denoted by N (A) and a set of arcs, denoted by D(A) N (A) N (A) If G(A) contains an arc from i to j then (i, j) D The arc (i, j) is called an incoming arc at j and an outgoing arc at i Now suppose that (i, j) D but (j, i) / D Then an arc from node i to j exists but an arc from j to i does not exist Since there is a distinction in the direction of the arcs, a graph with an ordered set of arcs is called a directed graph If all the arcs of such a graph have a weight w(i, j) G is called a weighted directed graph However, they will be referred to as graphs because there will only be dealt with weighted directed graphs Now consider a matrix A R n n max and define the following: { w(i, j), if (i, j) N (A) N (A) a ji = ε, otherwise (2-9) Figure 2-1: Graph G(A) Take as an example the graph G(A) shown in Figure 2-1 The matrix belonging to this graph is: ε ε 2 A = 5 e ε For any two nodes i, j, a sequence of arcs denoted by p = (i k, j k ) D(A) with k {1,, m} and i = i 1, j k = i k+1 for k < m and j m = j is called a path from i to j The path has length m, denoted as p l = m A path is called a circuit if i = j and such a circuit is called elementary if all nodes of that circuit only have one ingoing and one outgoing arc The weight of a path in G(A) is defined by the sum of the weights of all arcs that form the path So for p = ((i 1, i 2 ), (i 2, i 3 ),, (i m, i m+1 )) P (i, j; m) with i = i 1, j = i m+1 and P (i, j; m) the set of all paths from i to j of length m 1, the weight of p, denoted by p w, is defined as: m p w = a ik+1 i k (2-10) k=1

21 2-3 Graphs 9 The average weight of a path p is now defined as p w / p l The weight, length and average weight of circuits are defined similarly as for paths The powers of A can be used to find the maximal weight of a path in the communication graph G(A) This relation is defined by the following definition: [ A k] ji = max{ p w : p P (i, j; k)} (2-11) [ where A k] = ε if P (i, j; k) is empty (no path of length k from i to j exists in G(A)) In ji [ words equation (2-11) means that A k] yields the maximal weight of a path of length k ji from node i to j, provided that such a path exists In a similar fashion, the maximum weight of any path from node i to j can be defined as: A + def = A k, (2-12) k=1 for A R n n max Furthermore, if A R n n max is such that any circuit in G(A) has average circuit weight less than or equal to e, it holds that: A + = k=1 A k = A A 2 A 3 A n R n n max A circuit p with the maximal average circuit weight of the circuits in G(A) is called the critical circuit The critical graph of A is the graph consisting of those nodes and arcs that belong to the critical circuit and is denoted by G c (A) = (N c (A), D c (A)) A graph G can either be strongly connected or not strongly connected If there is a path from node i to node j for i, j N, then node j is reachable from node i which is denoted by irj If for any two nodes i, j N, node j is reachable from node i, a graph G is said to be strongly connected A matrix A is called irreducible if its communication graph G(A) is strongly connected On the other hand, if the communication graph of A is not strongly connected, A is called reducible Using the previously defined concepts, the cyclicity σ G of a graph G can be defined For a strongly connected graph G, the cyclicity is defined as the greatest common divisor of the lengths of all elementary circuits in G If G only consists of one node without a self-loop, then its cyclicity is equal to one The cyclicity of not strongly connected graphs equals the least common multiple of the cyclicities of all mscs s of G Finally, consider a node i in graph G The nodes that are connected to node i can be divided into a set of (direct) predecessors and (direct) successors The set of direct predecessors of node i is denoted by π(i) and the set of all predecessors is denoted by π + (i), which are formally defined as: π(i) def = {j {1,, n} : (j, i) D} π + (i) def = {j {1,, n} : jri}

22 10 Max-Plus Linear systems Denote the set of direct successors by σ(i) and the set of all successors of node i by σ + (i), with formal definitions: σ(i) def = {j {1,, n} : (i, j) D} σ + (i) def = {j {1,, n} : irj} 2-4 Solving linear equations Consider any matrix A R n n max, then the Kleene star product A can be defined as follows: A def = E A + = A k (2-13) A exists for any square matrix A with a communication graph G(A) having only nonpositive circuit weights The entries of A k are the maximal weights of paths of length k Furthermore, in [3] is proven that if the maximum circuit mean is less than or equal to e, A can be determined as: n 1 A = A k (2-14) k=0 This matrix A can be used to solve the linear max-plus equation x = A x b, with A R n n max and vector b R n max, namely the equation x = A x b has the solution x = A b This solution is unique if the circuit weights in G(A) are negative Another type of linear equation is A x = b, where A can also be a non square matrix A solution to this equation does not always exist There is however always a greatest solution to the max-plus inequality A x b, with A Rmax n m and b R m max This greatest solution is called the principal solution and is denoted as x (A, b), which is defined by: for j {1,, n} k=0 [x (A, b)] j = min{b i a ij : i {1,, m}} (2-15) 2-5 Max-plus linear systems As explained before, max-plus algebra can be used to model a class of discrete event systems (DESs) A DES is a dynamic event driven system where the state changes at various time instants Scheduling events in a DES is the process of deciding how to allocate a set of jobs to limited resources over time in an optimal way The processing of a job on a resource is called an operation Within each job, the operations must be performed in a specified order In general, the system has internal events x(k), input events u(k) and output events y(k) However, often the output events are stacked in the state vector x(k) The objective is often to determine the set of starting times for each operation which preserves the specified orders of operations while minimizing the time required to complete all the operations of the jobs [4], [5]

23 2-5 Max-plus linear systems 11 In order to understand the concept of switching max-plus linear (SMPL) systems, first maxplus linear (MPL) systems of which the model structure is fixed will be explained A DES with fixed schedule can be described by an MPL model MPL systems are DESs where synchronization but no concurrency or choice takes place No concurrency means there are no operations executed simultaneously Furthermore, no choices need to be made to determine the order of operations [1], [2] A typical example is a production system with a fixed routing schedule This type of systems can be described by a model of the form x(k) = A(k) x(k 1) B(k) u(k) y(k) = C(k) x(k) (2-16) with A(k) R n n max, B(k) R n m max and C(k) R p n max, where n is the number of states, m is the number of inputs, p is the number of outputs and k is an event counter For this type of systems x(k) usually contains the time instants at which internal events occur for the kth time, the input u(k) contains time instants at which the input events occur for the kth time and y(k) contains time instants at which the output events happen for the kth time Note that the input event u(k) can take different forms It can be predefined, like in a railway system since then it represents the predefined timeschedule, or it can be variable like in a production system since then it may represent the time instant raw material is fed to the system However, it is also possible u(k) is not present in the system like in legged locomotion A selection of these systems will be explained in chapter 5 The sums or maximizations of for example process times and transportation times are generally stacked in the matrices A, B and C [1] As mentioned, often the state-vector is the output in these systems, which means that y(k) = x(k) The output is therefore often left out of equation (2-16) and the following state equation is left: x(k) = A(k) x(k 1) B(k) u(k) (2-17) Sometimes events do not only depend on the events from the previous cycle, but may also depend on events in cycle (k µ), for some µ {2,, µ max } Then the state equation can be written as: x(k) = ( µmax µ=1 ) A µ (k) x(k µ) B(k) u(k) (2-18) Equations (2-17) and (2-18) are explicit models since they only depend on the known values x(k µ) for µ = 1,, µ max and u(k) However, often the implicit model is obtained after modeling a system This implicit model has the following form: x(k) = A 0 (k) x(k) A 1 (k) x(k 1) B 0 (k) u(k) (2-19) or x(k) = ( µmax µ=0 ) A µ (k) x(k µ) B 0 (k) u(k) (2-20)

24 12 Max-Plus Linear systems Following the same idea as given in section 2-4, the implicit form (2-19) can be solved for x(k) Define A 1 (k) x(k 1) B 0 (k) u(k) = b Then, if A 0 (k) exists, the solution is: x(k) = A 0(k) (A 1 (k)) x(k 1) B 0 (k) u(k) = A 0(k) A 1 (k) x(k 1) A }{{} 0(k) B 0 (k) u(k) }{{} A(k) B(k) and equation (2-19) can be rewritten as equation (2-16) For the implicit model (2-20), x(k) ( µmax ) can be solved by defining A µ (k) x(k µ) B 0 (k) u(k) = b and the solution is given by x(k) = A 0(k) given that A 0 (k) exists µ=0 ( µmax µ=1 ) A µ (k) x(k µ) A 0(k) B 0 (k) u(k), However, only a limited number of DESs can be described as MPL systems Limitations of such an MPL system is that the model structure is fixed Therefore the model dynamics cannot be influenced, whereby a change in the structure of the system, such as breaking a synchronization or changing the order of events, cannot be modeled A possible solution is to allow switching between different modes of operation Thereby each of the possible modes can be described as a separate MPL system A system where switching between different modes takes place is called an SMPL system [1], [2] 2-6 Switching max-plus linear systems In this section a general approach for modeling a SMPL system is described Three basic types of control decisions that play an important role in scheduling are routing ( 2-6-1), ordering ( 2-6-2) and synchronization ( 2-6-3) [2], which not necessarily occur in every system As mentioned before, an SMPL system is a DES that can switch between different modes of operation Now let the system be in mode l(k) {1,, n m } for event step k, with n m the number of possible modes Then the system is described by a max-plus linear state space model of the form: x(k) = A l(k) x(k 1) B l(k) u(k) (2-21) or x(k) = µ max µ=1 A l(k) µ x(k µ) B l(k) u(k) (2-22) in which the matrices A l(k) and B l(k) are the system matrices for mode l(k) The switching makes it possible to model a change in the structure of the system Each mode l corresponds to a specific route, a set of required synchronizations and an event order schedule, which leads to a model (2-21) or (2-22) The switching between different modes is controlled by a switching mechanism Therefore the switching variable z(k) is introduced Consider model (2-21), then this switching variable may depend on the previous state x(k 1), the previous mode l(k 1), the input variable u(k) and a control variable v(k): z(k) = φ(x(k 1), l(k 1), u(k), v(k)) R nz max (2-23)

25 2-6 Switching max-plus linear systems 13 Here R nz max is partitioned in n m subsets (with n m the number of modes) Z (i), with i = 1,, n m The set in which z(k) is for event step k now determines the mode l(k) (ie if z(k) Z (i), then l(k) = i) [1] A special case is when z(k) = v(k), where v(k) can either be a max-plus binary variable (v(k) B ε ) or an integer (v(k) Z ε ) Furthermore, z(k) can consist of both control variables v c (k) and uncontrollable decisions (decisions that are fixed), [ T denoted by v u (k) This results in z(k) = v c (k) v u (k)] In [2] a modeling framework for the three basic types of control decisions that play a role in a scheduling problem is defined The structure of the system matrices is studied, where the input variable u(k) is not taken into account Furthermore, the authors derived a method to manipulate routing, ordering and synchronization by a set of control variables This proposed framework will be discussed in the next subsections Routing The first type of control decision is routing A job generally consists of a number of operations that have to be performed using different resources Deciding on how a job follows a sequence of resources is routing The routing for each job has to be determined since often alternative routes are possible Consider a system that has to operate J jobs For each job a specific route through the system has to be scheduled and resources have to be ordered accordingly Let job j {1,, J} consist of p j operations on the sequence of resources R j = (r j,1,, r j,pj ) in processing order, with r j,i {1,, N} for all j, i and N being the number of resources Furthermore, let T j (k) = (τ j,1 (k),, τ j,pj (k)) be the corresponding processing times in cycle k with τ j,i (k) 0 for all j, i with i {1,, p j } Important is to set the condition that every operation is assigned to a unique resource and is not interruptible Let x j (k) = x j,1 (k) x j,pj (k)] [ T be the vector with all starting times of the operations of job j This results in the following inequalities for all j = 1,, J: x j,m (k) x j,l (k) + τ j,l (k), with m > l, m, l {1,, p j } This inequality means operation m of job j can only start when operation l of job j is finished, ie the starting time of operation l plus the process time of operation l For the whole vector with starting times (x j (k)) and all corresponding processing times, this results in the following max-plus matrix notation: x j,1 (k) ε ε ε x j,1 (k) x j,2 (k) τ j,1 (k) ε ε x j,2 (k) x j,pj (k) ε τ j,pj 1 (k) ε x j,pj (k) Which can be written as x j (k) A job,j (k) x j (k) For J jobs all starting times can be written in one state vector x(k) and the following equation is obtained:

26 14 Max-Plus Linear systems x 1 (k) A job,1 (k) E E x 1 (k) x 2 (k) x(k) = E A job,2 (k) E x 2 (k) x J (k) E A job,j (k) x J (k) Or shortly written as x(k) A job (k) x(k) The method described above does not allow alternative routes for the jobs However, often these alternative routes are available In for example a production system, the alternative routes can result in the same product or the route may be changed to make another product Consider L alternative sets of routes, then for each set the matrix A l job can be defined for l = 1,, L Hereafter, a set of max-plus binary variables can be defined such that if in cycle k the lth set of alternative routes is considered w l (k) = e and w l (k) = ε for all l l The job matrices can now be written as: A job (w(k), k) L l=1 w l (k) A l(k) job (2-24) For large complex systems, a reduction in the number of variables can be achieved by parameterizing (w 1, w 2,, w L ), which will be explained in section Ordering The next type of control decision that will be explained is ordering After the routing of the jobs have been done, conflicts may arise while jobs need to be operated at the same resource Therefore the ordering of concurring jobs in resources need to be determined Consider a system with n operations These n operations are divided over N resources and assume the system has L sets of alternative routes Then let P l Bε n n, l {1,, L}, be a matrix with: [P l] i,j = { e, if operation i and operation j are executed on the same resource ε, if operation i and operation j are executed on different resources Now the matrix for selection of the resources can be expressed as P (w(k)) = L w l (k) P l Further, let H(k) be a separation matrix, such that: { [ ] H(k) = hij (k), if operation i and operation j may be scheduled on the same resource i,j ε, if operation i and operation j can never be scheduled on the same resource where h ij (k) is the separation time between operations i and j in cycle k Finally let Q µ (k) be order decision matrices with max-plus binary entries, such that: { [ ] e, if operation i in cycle k is scheduled after operation j in cycle k + µ Q µ (k) = i,j ε, if operation i in cycle k is scheduled before operation j in cycle k + µ and denote q µ (k) = vec(q µ (k)) Now define the total ordering matrices: A ord,µ (w(k), q µ (k), k) = P (w(k)) Q µ (k) H(k) (2-25) l=1

27 2-7 Overall SMPL system 15 and formulate the operation ordering constraints as follows: µ max x(k) A ord,µ (w(k), q µ (k), k) x(k µ) (2-26) µ=µ min where µ min and µ max are the minimum and maximum value for µ, respectively Note that µ can also be smaller than zero, which is due to the fact that it may be desirable that an operation in cycle k is scheduled behind an operation in a cycle that comes after cycle k, so cycle k µ, with µ < Synchronization Some jobs running on different resources may need synchronization Synchronization occurs when an operation of a job can only start when a specific operation of another job has finished Take for example a railway network, there passengers may need time to change trains Now if there is a connection between train i and train j, train i has to wait for train j and vice versa Now a number of synchronization modes can be defined: l = 1,, L syn, where for every mode a system matrix is obtained: { [ ] e, if operation j in cycle k is to be scheduled behind operation i in cycle k + µ A l(k) syn,µ = ij ε, elsewhere (2-27) Define s(k) Bε Lsyn which are max-plus binary variables for scheduling the synchronizations Now the operation synchronization constraints in the system can be formulated as follows: µ max x(k) A syn,µ (s(k), k) x(k µ), (2-28) µ=µ min where A syn,µ (s(k), k) = L syn l=1 s l (k) A l(k) syn,µ (2-29) Synchronizations can be an isolated phenomenon like the synchronization of two trains on a platform to give passengers the chance to change trains However, synchronizations can also be coupled and appear in groups like the synchronization of legs in a legged robot 2-7 Overall SMPL system Now that conditions have been derived for x(k) belonging to different control decisions and a set of scheduling decision variables is made, namely Routing: w(k) Ordering: q µ (k), µ = µ min,, µ max

28 16 Max-Plus Linear systems Synchronization: s(k), the decision variables can be stacked into one vector w(k) q µmin (k) v(k) = (B ε ) Ltot q µmax (k) s(k) with L tot the total number of scheduling variables Now the scheduling model can be written as: where µ max x(k) = A µ (v(k), k) x(k µ) r(k) (2-30) µ=µ min A µ (v(k), k) = A job,µ (w(k), k) A ord,µ (w(k), q µ (k), k) A syn,µ (s(k)) = L tot l=1 v l (k) A l(k) tot,µ and r(k) is a reference signal This because some DESs work with a predefined schedule that gives a lower bound for the starting time of the operations in the system If r i (k) is the starting time for operation i according to a given time schedule, then the constraint x i (k) r i (k) guarantees a lower bound r i (k) on operation i By choosing a specific control vector v(k) the system switches between different modes of operation, it is thereby an SMPL system As a concluding remark it is important to note there are different types of control variables The control variables can directly represent mode l(k), for which predefined system matrices for every mode are required For small systems this is managable For large complex systems however, the generation of these system matrices in advance would result in a huge amount of data if all hypothetical combinations of possible actions are taken into account If there are for example 5 possible routes, 10 possible orders and 2 options for synchronization decisions, the number of predefined system matrices for cycle k already becomes = 100 This also results in 100 control variables to select the optimal MPL system Therefore, in such a case it is recommended to use max-plus binary control variables v(k), where each control variable corresponds to a specific control action In general this results in less predefined A-matrices for larger systems since then all control variables are stacked in matrices related to routing, ordering and synchronization The only disadvantage is that chances are that much more constraints related to the control variables are needed to eliminate infeasible combinations Another possibility is integer parameterization where the control variable v(k) represents a vector consisting of integers Since this method is almost never used, it is not taken into account To clarify the other two methods, consider the ordering of 3 operations performed on the same resource, where there are 3! = 6 feasible combinations In this example the minimum separation time between operations is neglected Mode l(k)

29 2-8 Parameterization 17 Modeling it by using control variables that directly correspond to mode l(k), 6 modes are possible, so l(k) {1,, 6} This also means 6 system matrices are obtained where each matrix stands for the specific order in which the operations occur Binary control variables For very large systems, it is impossible to model all possible combinations of all scheduling decisions Therefore, binary decision variables are used For the ordering of 3 operations, v 1 (k), v 2 (k) and v 3 (k) can be defined as: v 1 (k) represents the ordering between operations 1 and 2 v 2 (k) represents the ordering between operations 2 and 3 v 3 (k) represents the ordering between operations 1 and 3 Hereafter the matrix A ord (k) can be defined: ε v 1 (k) v 3 (k) A ord (k) = v 1 (k) ε v 2 (k) v 3 (k) v 2 (k) ε where v i (k) for i = 1, 2, 3 is defined as in (2-8) Now the ordering constraints can be written as x(k) A ord (k) x(k) and then by selecting the optimal control vector v(k) = [ T v 1 (k) v 2 (k) v 3 (k)], the optimal order for cycle k is obtained The adjoint control variables v i (k) for i = 1, 2, 3 follow directly from the vector v(k) Note that for ordering n operations, n(n 1)/2 control variables are added to the model The number of possible combinations of control actions is then 2 n(n 1)/2 However, the number of possible orders is only n!, which means that for n 3 there are more combinations of control variables than there are possible orders Therefore, the combinations that do not respond to possible orders describe infeasible orders [6] It is important to add constraints to eliminate these infeasible combinations Finally note that using mode l(k) as control variable can be rewritten in the form of (2-24), where w(k) is again a binary decision variable where w l (k) = e if the system is in mode l and w l (k) = ε for l l Therefore the scheduling problem always results in finding the optimal max-plus binary variables relating to optimal route, order and synchronization 2-8 Parameterization A problem may arise if there are too many control variables to try in the optimization The problem needs to be solved in a limited amount of time and therefore reduction of the control variables is recommended Furthermore, there is only a limited number of feasible combinations of the control variables and all infeasible combinations should be eliminated from the solution space Both problems can be addressed by parameterizing the control variables In [2] this is explained for routing and ordering, where the case for routing is elaborated next Take the routing control variables (w 1, w 2,, w L ) from section Let 2 m 1 < L 2 m,

30 18 Max-Plus Linear systems where w l is e if route set l is chosen and w l (k) = ε for all l l Then the variables (w 1, w 2,, w L ) can be parameterized by m max-plus binary variables (ω 1, ω 2,, ω m ) and its adjoint values ( ω 1, ω 2,, ω m ) as defined in equation (2-8) Take for example L = 4, then (w 1, w 4 ) can be parameterized as: w 1 (k) = ω 1 (k) ω 2 (k) (2-31) w 2 (k) = ω 1 (k) ω 2 (k) (2-32) w 3 (k) = ω 1 (k) ω 2 (k) (2-33) w 4 (k) = ω 1 (k) ω 2 (k) (2-34) where the values of ω 1 and ω 2 for each alternative set of routes l = 1,, 4 can be seen in Table 2-1 By substitution of the multiplicative function w(k) = f(ω(k)) in equation (2-24) Table 2-1: Parameterization routing l ω 1 ω 2 1 ε ε 2 ε e 3 e ε 4 e e the number of variables can be reduced By finding the optimal values for ω 1 and ω 2, f(ω(k)) corresponding to the optimal route is e and the other multiplicative function f(ω(k)) are equal to ε It is important to note that if the number of possible routes is not an exact power of 2, more permutations of ω l (k) and ω l (k) are possible than necessary In such a case, constraints on ω l (k) are introduced to describe the allowed set For an example on the parameterization of ordering control variables, referred is to [2] Important is to note that for large systems, the parameterization may result in functions for the control variables where not only the addition operator is used, but also the maximization operator is needed Then although the number of control variables is reduced, more constraints are added with respect to the system dynamics 2-9 Converting max-plus binary equations to conventional equations In many problems that are described in the max-plus algebra, constraints on max-plus binary variables cannot be used in the actual problem solving Therefore a method will be addressed to transform max-plus binary constraints to conventional constraints First, define the conventional binary variable δ i as in (2-35), where δ i is a max-plus binary variable δ i = { 0, if δi = e 1, if δ i = ε (2-35)

31 2-9 Converting max-plus binary equations to conventional equations 19 Consider the max-plus multiplication of max-plus binary variables δ i δ 0 = δ 1 δ 2 δ m (2-36) Then equation (2-36) can be written as a set of constraints of conventional binary variables δ i δ 0 δ 1 δ 0 δ 2 (2-37) δ 0 δ m δ 1 + δ δ m δ 0 0 Now, only if all δ i, for i = 1,, m, are equal to e, δ 0 is also e In all other cases δ 0 is equal to ε In the conventional constraints, if all δ i = e, all binary variables δ i are equal to 0 and δ 0 is also 0 For all other cases δ 0 is equal to 1 Next, consider the max-plus addition of different terms δ 0 = ( δ 11 δ 12 δ 1n1 ) ( δ m1 δ m2 δ mnm ) (2-38) }{{}}{{} δ 01 δ 0m The terms that consist of max-plus multiplication, so δ 01,, δ 0m are handled in the same manner as equation (2-36) whereby the set of constraints for the conventional binary variables are as shown in (2-39) δ 01 δ 11 δ 01 δ 1n1 δ 0m δ m1 (2-39) δ 0m δ mnm δ δ 1n1 δ 01 0 δ m1 + + δ mnm δ 0m 0 The next step is to take care of the max-plus addition Therefore, consider equation (2-40) δ 0 = δ 01 δ 02 δ 0m (2-40) If one or more δ 0i, for i = 1, m, is equal to e, then δ 0 = e If all δ 0i are ε, δ 0 is also ε In the conventional case this means that δ 0 is only equal to 1 if all δ 0i are 1 In all other cases

32 20 Max-Plus Linear systems δ 0 = 0 This can be written as the set of constraints (2-41) δ 0 δ 01 δ 0 δ 02 (2-41) δ 0 δ 0m δ 0 δ 01 + δ δ 0m (m 1)

33 Chapter 3 General modeling framework using topology graphs In the general modeling framework explained in section 2-6, the assumption was made that a system consists of multiple jobs However, some systems only have one job per cycle The routes of the jobs can vary every cycle or can be fixed and ordering and synchronization may or may not occur Ordering can be necessary between jobs in the same cycle or between jobs from different cycles Ordering between jobs in the same cycle only occurs in systems with more than one job in a cycle Also, synchronization only occurs in systems with more than one job each cycle Figure 3-1 shows the different possibilities in DESs that can be modeled as an SMPL system Figure 3-1: Possible combinations

34 22 General modeling framework using topology graphs For this general framework the topology graph is used to model the routing and ordering constraints A topology graph shows which connections exist between resources, but does not specify which route and order is chosen every cycle In many cases the original topology graph cannot directly be used to model and control the system, but must be extended first Before continuing describing how a topology graph is used for modeling purposes, it is necessary to define the meaning of all elements in such a graph and thus in the system 3-1 Defining the elements in a system In order to model a system it is necessary to define the jobs, operations and events of the system within one cycle Therefore it is also important to determine the start and end of one cycle Furthermore, it has to be decided if an input vector u(k) is used and if so, what it represents Jobs A job is a physical object that is subjected to some operations before it is finished It is important to note that a job can change its appearance during a cycle, take for example a production system There the job may start as raw material and ends as a finished product As mentioned, the number of jobs per cycle depends on the system Natural cycle A natural cycle can be seen as a sequence of events whereafter the behavior of the system repeats itself What is meant is that after one natural cycle, all different types of jobs enter the system again Thereby it is not said that all events in a new cycle appear in the same order or appear at all When there are different jobs, it is recommended to choose the natural cycle as the cycle when all different jobs are completed So after one natural cycle, no new events are introduced At the start of each new natural cycle, the global event counter k counts one step further If there is only one job in each cycle, the job in cycle k is denoted as job k For multiple jobs in cycle k, the jobs are denoted by job j in cycle k To clarify some of the previous, some examples are discussed In a railway network there are different jobs since every train is a job and therefore the natural cycle is the cycle when all trains finished their route and start over with the same schedule Legged locomotion has as many jobs as there are sets of legs Therefore, in legged locomotion the natural cycle is defined as the cycle when all legs have lifted off and touched down again In a printer on the other hand, there is only one type of job, namely a sheet (denoted by sheet k) and thus the natural cycle is the completion of one sheet Events Based on the natural cycle, the events should be defined The events are usually the starting times of the operations or processes within a natural cycle Sometimes it is desired to define the events as the starting and completion times of an operation This can occur when operations are performed at a resource and the time spend in this resource can deviate Furthermore, synchronization constraints between the arrival time of one job and the departure time of another job may be present in these systems In this case the completion time of an

35 3-2 Variable routing 23 operation is also the start of the next operation The events are the nodes for the topology graph and the starting (and ending) times are stacked in the state vector Moreover, all these events have a resource associated with them Operations The operations of a job are defined as the different processes a job needs to follow within the natural cycle from start to finish These processes are modeled by arcs which have a weight assigned to them This weight represents the process time to get from one event to another An event can only occur if the processes represented by incoming arcs are completed Input u(k) As mentioned before, u(k) can take different forms It can represent a reference under which the system needs to be operated, this is the case in a railway network where trains can never leave earlier than indicated by the reference (timetable) Furthermore u(k) can be a given external variable, which specifies when a job enters the system The latter is the case in a baggage handling system since there the input of a new bag cannot be controlled and thus the time a new bag enters the system is given In a printer the time paper is fed to the system can be chosen by the user and therefore in such a case the input will be included in the state vector x(k) Another possibility is that the input can be controlled This is the case in a production system However, this type of input will not be considered Due date reference For some systems there may be due dates that define when a job should be finished This can be seen as a reference, but can exist next to the input u(k) described previously So for example, there can be a given external variable u(k) and a due date signal 3-2 Variable routing When the routes of the jobs can differ every cycle, there is no nominal and perturbed case The optimization algorithm decides which route is the optimal route for a job at a certain time instant The starting point in this general framework is the topology graph An example of such a graph is shown in Figure 3-2, where node 4 represents the output From this graph Figure 3-2: Example of a topology graph

36 24 General modeling framework using topology graphs the topology matrix T can easily be determined by defining the following: [T ] ji = { τij, if (i, j) N (T ) N (T ) ε, otherwise (3-1) where τ ij represents the process time to get from node i to node j The number of nodes in a topology graph is equal to the dimension of the square topology matrix T Each arc corresponds to an entry of the matrix and the weight of that arc specifies that entry Therefore, the topology matrix T corresponding to Figure 3-2 is: ε ε ε ε τ T = 12 ε τ 23 ε τ 13 ε ε ε ε τ 24 ε ε From the matrix T, the transpose adjacency matrix A d should be obtained shows the relation between two nodes in a graph: { 1, if (i, j) N (T ) N (T ) and thus [T ]ji = τ ij [A d ] ji = 0, otherwise, so if [T ] ji = ε This matrix (3-2) So in words, if [A d ] ji = 1 there is a directed arc from node i to node j in the topology graph This matrix contains a lot of information about the system which can be used in obtaining a general framework for SMPL systems The first problem for which this matrix is used is the problem of re-entrancy Every closed loop in the topology graph forms a circuit where re-entrance can occur Re-entrancy occurs when a job can enter some resources more than once in one natural cycle If the system is re-entrant, the system matrix that describes the original topology graph cannot be used in the final scheduling problem This because then it is not determined how many times a job can re-enter a specific resource and the job can be caught infinitely in the circuit, whereby an optimal schedule will not be found If a job can pass some resources more than once, more event times are needed such that every sequence of events can be described Translated to a topology graph this means that every event must have there own node such that every path can be described To solve this problem, every possible route should be elementary, ie for every possible route, every node should have one incoming and one outgoing arc Therefore the topology graph should be extended by duplicating some nodes that are part of the circuit Note that the number of times a job can use the circuit must be finite, since otherwise the nodes should be duplicated infinitely The first important step is to define if and where circuits occur in the system This can be seen by looking at the powers of A d For systems where the number of nodes included in the circuit is not larger than 2, the circuit can be detected only by looking at A d, namely if [A d ] ij + [A d ] ji = 2 (or [T ] ij [T ] ji = ε), then node i and j are included in the circuit However, for systems with more than 2 nodes included in the circuit, this is not as easy to see As explained in section 2-3, entries of T n denote the weights of paths with length n in the corresponding graph If T does not have paths of length greater than m, then T n = E for n m However, when circuits are present in the system, [T n ] E, for all n Still the max-plus powers of T provide information about

37 3-2 Variable routing 25 the possible circuit in a system This can be translated to the transpose adjacency matrix related to T Therefore A i d, for i = 1,, n should be determined, with n being the number of nodes in the graph Then if in one of these powers 1 s appear on the diagonal it is an indication that circuits are present in the system and that nodes included in the circuit correspond to the diagonal entries showing a 1 Furthermore, the power of A d for which these diagonal entries appear tells how many arcs are included in the loop For more than one circuit in a system, more than one of the matrix powers shows 1 s on the diagonal 1 s on the diagonals in different powers represent different circuits Now it is important to detect which nodes need to be duplicated how many times This depends on the structure of the circuit and the number of circuit loops allowed, represented by N The number of times a node should be duplicated can be seen by looking at the possible sequence of nodes in the graph This can best be explained by means of examples Consider the three example topology graphs with circuits in Figure 3-3 For example 1, Figure 3-3: Graphs with different loops there are two possible sequences since node 1 has two outgoing arcs The first sequence is 1-2-(3-2) N -4 and the second 1-3-(2-3) N -2-4 Now if 1 loop is allowed, the sequences become and There can be seen node 2 appears 4 times in total in the sequences and therefore node 2 should be divided into 2i, with i = 1,, 4 Node 3 appears 3 times, which means node 3 should be divided in 3i, for i = 1,, 3 Note that only the nodes that are included in the circuit are duplicated In the second example only one sequence is possible, namely 1-2-(3-2) N -3-4 Now if N = 2, the sequence becomes The third example shows 2 sequences, 1-2-(4-3-2) N -5 and 1-3-(2-4-3) N -2-5 For N = 1, these become and Node 2 appears four times, node 3 three times and node 4 two times To show how the extended topology graph looks like for the examples, see Figure 3-4 Finally, note that in a system with more than one job per cycle, where no circuit is present, some nodes may need to be duplicated This is the case if 2 or more jobs use the same resource The node related to this resource should be duplicated such that the number of nodes related to this resource is the same as the number of jobs using this resource (see also the example from Figure 3-5) This is because every job needs its own event times If a node is used by more than one job and this node is not duplicated, only one event time related to this node is obtained After it is clear which nodes need to be duplicated how many times, the extended topol-

38 26 General modeling framework using topology graphs Figure 3-4: Extended topology graph for examples in Figure 3-3 for N = 1, 2, 1 repspectively ogy matrix T ext can be made and from that matrix again the transpose adjacency matrix is constructed, denoted by A dext The next important step is to define the routes that are possible For systems with the possibility of different routes each cycle, the topology graph shows all possible connections between resources, where the decision variables corresponding to the arcs, denoted by s ij, take max-plus binary values Therefore all possible routes can be made If there exists a path from node i to node j, a max-plus binary variable s ij (k) is assigned to that arc The system matrix corresponding to routing can easily be written down by defining the following: with s ij (k): { sij (k), if (i, j) N (T ) N (T ) [A job (s ij (k))] ji = ε, otherwise { e, if arc (i, j) is used in cycle k s ij (k) = ε, if arc (i, j) is not used in cycle k (3-3) (3-4) Now all routes can be generated by selecting specific control variables to be e and others to be ε However, not all combinations of the control variables s ij (k) for cycle k are possible and therefore infeasible routes can arise The transposed adjacency matrix can be used to define how many routes are possible The a-th power of [A dext ] ij shows the number of paths with length a from node j to node i By adding all powers of A dext, ie A dext + A 1 d ext + + A a d ext, the entry (i, j) in this matrix shows the number of ways to get from node j to node i in a steps or less The number of possible routes can be calculated by first defining matrix R: n R = A i d ext (3-5) i=1 with n representing the number of nodes in the graph Since the circuits are eliminated by the extension of the graph, the graph for each route is elementary Therefore the number of nodes is the longest possible path from node i to node j Now if node i represents the station where the job is loaded and node j represents the final station, the number of possible routes, denoted by L, can be found in [R] ji If there exists more than one node where a job can enter the system, the number of possible routes is the sum of all entries corresponding to these starting nodes and the possible end nodes When there are more jobs in one cycle, the same

39 3-2 Variable routing 27 is done but then the number of possible route sets must be considered This is the product of the number of possible routes per job Now the number of routes or route sets is the same as the number of feasible combinations of all s ij In general this number is significantly less then the possible combinations of all s ij : 2 sa, with s a representing the number of different s ij Thereby, infeasible combinations and thus infeasible routes may arise Define w l (k) as: w l (k) = ε { e if route (class) l is used in cycle k otherwise (3-6) All control variables s ij are then determined by f(w l ), where f(w l ) is the maximum of all control variables w l related to route l {1,, L}, if route l uses arc (i, j) By writing down a table with the possible combinations of all s ij for every route or route class, it can easily be seen how to handle this This will be explained by means of an example Consider the example graph presented in Figure 3-5 There are 2 jobs present in one cy- Figure 3-5: Example of a topology graph of a system with 2 jobs each cycle cle and resources 4 and 7 are used by both job 1 and job 2 Therefore node 4 and 7 are divided by node 41 and 42 and node 71 and 72 respectively This way it is still clear they belong to the same resource The new adjusted graph looks like Figure 3-6 The gray numbers next to the nodes represent the position of this node in the state vector Calculating R results in R(8, 1) = 2 and R(9, 6) = 2, which means the number of route classes L is 2 2 = 4 Now consider Table 3-1 with the combinations of decision variables s ij related to the arcs for each route class

40 28 General modeling framework using topology graphs Figure 3-6: Adjusted graph of a system with 2 jobs each cycle Table 3-1: Combinations of decision variables for each route class R1 R2 R3 R4 s i,j = f(w) s 1,2 e e e e s 1,2 = w 1 w 2 w 3 w 4 s 2,3 e ε e ε s 2,3 = w 1 w 3 s 2,41 ε e ε e s 2,41 = w 2 w 4 s 3,41 e ε e ε s 3,41 = w 1 w 3 s 41,71 e e e e s 41,71 = w 1 w 2 w 3 w 4 s 5,42 e e ε ε s 5,42 = w 1 w 2 s 5,6 ε ε e e s 5,6 = w 3 w 4 s 6,42 ε ε e e s 6,42 = w 3 w 4 s 42,72 e e e e s 42,72 = w 1 w 2 w 3 w 4 The presented method replaces every entry equal to e related to route class l in Table 3-1 by w l Then every control variable can be defined as the maximum of all w l s, present in the row of the specific control variable, for l {1,, L} Note that some s ij are always equal to e since arc (i, j) is always used By adding constraints on the control variables s ij and allowing only one w l to be e, only feasible routes are found Note that the decision variables s ij that are assigned to the arcs (i, j) where node i has only one outgoing arc are redundant in many cases This will be explained by again considering the example topology graph from Figure 3-2 Node 1 is the only node with more than one outgoing arc and therefore lets only assign the control variables s ij (k) to these arcs The

41 3-2 Variable routing 29 set of equations becomes: x 2 (k) x 1 (k) s 12 (k) τ 12 (k) x 3 (k) x 1 (k) s 13 (k) τ 13 (k) x 2 (k) x 3 (k) τ 32 (k) x 4 (k) x 2 (k) τ 24 (k) Now either s 12 (k) or s 13 (k) can be e and the other must be ε because there is only one job each cycle If s 12 (k) = e and s 13 (k) = ε, the job follows the route This because from x 3 (k) x 1 (k) ε τ 13 (k) will follow that x 3 (k) = ε and the constraint for x 2 (k) that remains is: x 2 (k) x 1 (k) τ 12 (k) ε τ 32 (k) x 2 (k) x 1 (k) τ 12 (k) If s 12 (k) = ε and s 13 (k) = e, the job will clearly follow However, since sometimes it may be desirable (or undesirable) that a job follows a certain arc, s ij (k) is assigned to every arc That way every arc can be forced to be used (or avoided) in cycle k by defining s ij (k) = e (or s ij (k) = ε) Since s ij (k) is determined by the maximum of all w l (k) that use this arc, one of these w l s must be e, for s ij(k) = e In the case where s ij (k) must be ε, all w l (k) that use this arc are forced to be equal to ε and no route can be chosen that uses arc (i, j) The procedure described is the same for both systems with one job per cycle and systems with multiple jobs per cycle The resulting matrix is the max-plus system matrix A job (s ij (k)) Furthermore, the matrices T j (k) consisting of process times for the operations in each job should be defined These process times are the weights τ ij assigned to the arcs in the topology graph For J jobs this results in A route (s ij (k), k) = A job (s ij (k)) T (k), with (possibly after some relabeling of the nodes in T ext ) A job,1 (s ij (k)) E E E A job,2 (s ij (k)) E A job (s ij (k)) = E A job,j (s ij (k)) and T 1 (k) E E E T 2 (k) E T (k) = E T J (k) Note that the matrix T (k) is the same as T ext, only now the event counter k is added That way this matrix can be updated for each new cycle If one or more external input variables u(k) are present in the system, the system matrix B 0 (k) should be defined This matrix consists of sums of process times and decision variables s uσ(u) associated with the arcs that go to the set of all direct successors of u(k): σ(u(k)) Note that if there is only one external input u(k), s uσ(u) = e For more than one external input per job each cycle s uσ(u) should either be chosen by the user or if the optimal loading station can be chosen, the optimal s uσ(u) is chosen to be e by the optimization Note that

42 30 General modeling framework using topology graphs again this decision variable is defined as the maximum of all routing variables related to the routes that use arc (u, σ(u)) Now, the constraints for the external input are of the form: x σ(u) (k) τ uσ(u) (k) s uσ(u) (k) u(k) For multiple jobs per cycle, B 0 (k) is defined as: B job,1 (k) E E E B job,2 (k) E B 0 (s uσ(u) (k), k) = E B job,j (k) with B job,j (k) = B(s uσ(u) (k)) B τ (k), where B(s uσ(u) (k)) is a matrix consisting of all s uσ(u) (k) and B τ (k) a matrix with all process times τ uσ(u) (k) The total routing constraints are now determined by: x(k) A route (s ij (k), k) x(k) B 0 (s uσ(u) (k), k) u(k) (3-7) For some systems it may hold that the routes are also described by an interaction between events in cycle k 1 and k This occurs when jobs re-enter the system after they are finished This is the case in for example a railway network since every train returns at the starting station after one cycle Then the routing constraints are defined as: 1 x(k) A route,µ (s ij (k µ), k µ) x(k µ) B 0 (s u,σ(u) (k), k) u(k) (3-8) µ=0 The methods described in this section have been implemented in Matlab for the case with one job per cycle For defining the routing matrices for systems with circuits, the topology graph should be extended first The Matlab file for defining the routing matrices and constraints related to the control variables can be seen in Appendix A The inputs are the (extended) topology matrix T (ext), the external input matrix B τ, the number of cycles looked ahead (see chapter 4) and the number of previous cycles Note that for the eventual scheduling, the decision variables s uσ(u) should be defined by the user if the choice of the starting node is a given external variable Remark 1 As explained in section 2-8, another option for defining all possible routes is parameterization of the control variables If the number of routes or route sets is an exact power of 2, the control variables can be parameterized by m max-plus binary variables and their adjoint Since there are L = 4 route classes, the max-plus binary variables s ij can be replaced by m max-plus binary variables: 2 m 1 < L 2 m Therefore in the example corresponding to Figure 3-5, m = 2 From Table 3-1 and Table 3-2 can be seen that the control variables can

43 3-3 Ordering 31 Table 3-2: Parameterization of control variables for each route class R1 R2 R3 R4 ω 1 e e ε ε ω 2 e ε e ε be replaced by the set of equations in (3-9) s 1,2 = ω 1 ω 1 s 5,42 = ω 1 s 2,3 = ω 2 s 5,6 = ω 1 s 2,41 = ω 2 s 6,42 = ω 1 (3-9) s 3,41 = ω 2 s 42,72 = ω 1 ω 1 s 41,71 = ω 1 ω 1 By finding the optimal values for ω 1 and ω 2, f(ω(k)) corresponding to the optimal route is e and the other multiplicative function f(ω(k)) are equal to ε In the scope of this research the parameterization of control variables will not be considered This might be interesting for future research Remark 2 If there are no alternative routes available for the jobs, so the routes stay the same in each cycle, the routing matrix A route (k) only consists of process times, ie: T 1 (k) E E E T 2 (k) E A route (k) = E T J (k) 3-3 Ordering Ordering is necessary for resources where more than one job, from the same cycle or different cycles, may enter at the same time Ordering within the same cycle only occurs if there is more than one job per cycle To model all ordering constraints, first it is important to define which operations may be performed on the same resource Ordering can be necessary for different situations: 1 Operations from different types of jobs within the same cycle may be performed on the same resource This may occur in systems with multiple jobs per cycle and where nodes are duplicated 2 Operations from different types of jobs from different cycles may be performed on the same resource Again this can occur in systems with duplicated nodes with multiple jobs per cycle

44 32 General modeling framework using topology graphs 3 Operations from the same type of job, but from a different cycle are performed on the same resource This type of ordering can be necessary in systems with multiple jobs per cycle and systems with one job every cycle Furthermore, it can occur in duplicated and normal nodes For every node in the (extended) topology graph an ordering constraint is introduced These constraints for node i are of the form shown in equations (3-10) and (3-11) x i (k + m) x i (k + m µ) τ i (k + m µ) w i,µ(k + m µ) (3-10) x i (k + m µ) x i (k + m) τ i (k + m) w i,µ(k + m µ) (3-11) Define the binary control variable w i,µ (k + m µ) as: and e, if operation i from cycle k + m µ precedes operation i in cycle k + m w i,µ(k + m µ) = w i,µ (k + m µ), if the order in i can switch because both k + m and k + m µ arrive there through different arcs ε, otherwise e, if operation i from cycle k + m µ precedes w i,µ (k + m µ) = operation i in cycle k + m ε, if operation i from cycle k + m precedes operation i in cycle k + m µ for µ {1,, µ max } and m Z + 0 The ordering max-plus binary control variable w i,µ (k + m µ) associated with constraints as presented in (3-10) can take different forms For nodes with one incoming arc it consists of the sum of multiple max-plus binary variables Then these ordering constraints make sure that if both job j from cycle k and job j from cycle k + m take path π(i) i and job j in cycle k passes node π(i) before job j from cycle k + m passes this node, then the order in node i must be the same as the order in π(i) For nodes with more than one incoming arc it consists of sums and maximization of multiple max-plus binary control variables Ordering is also necessary between duplicated nodes Then the control variable is w ij,µ (k + m µ) where i and j are duplicated nodes that have the same resource associated with it The different situations will be specified next, where the assumption is made a job cannot pass another job when using the same arc At the end of this section a method is described on how to adjust the constraints such that overtaking is possible Nodes with one incoming arc Nodes i with one incoming arc can be recognized by looking at A dext, namely rows i for which holds: n A dext (i, j) = 1 j=1

45 3-3 Ordering 33 This because from the number of elements equal to 1 in row i can be seen how many incoming arcs node i has If a node i has only one incoming arc it does not mean just one route passes this node The set of all predecessors can cause different paths to pass this node Therefore the order between operations in one of the predecessors may have already been switched The one thing that is certain is that the order in this node is the same as the order in its direct predecessor π(i) Furthermore, if this direct predecessor has also only one incoming arc, the order is the same as the predecessor of this direct predecessor and so on Remember that the control variable s π(i)i (k + m µ) specifies if a job in cycle k + m µ uses arc (π(i), i) If s π(i)i (k + m µ) is equal to e, the arc is used If it is equal to ε, the arc is not used Now the control variable w i,µ (k + m µ) is constructed by the max-plus equation given in (3-12) w i,µ(k + m µ) = w π(i),µ (k + m µ) s π(i)i(k + m µ) s π(i)i (k + m) (3-12) Its adjoint is defined as in (3-13): w i,µ(k + m µ) = w π(i),µ (k + m µ) s π(i)i(k + m µ) s π(i)i (k + m) (3-13) The latter constraints are from now on referred to as the follow constraints It is important to note that the adjoint of w i,µ (k + m µ) is not the same as the definition of the adjoint given in (2-8) This because both w i,µ (k + m µ) and w i,µ (k + m µ) can be ε at the same time To explain this, different situations are considered with the use of an example Consider the example graph presented in Figure 3 7 and look at the ordering in node 2 The constraints related to the event x 2 are given in (3-14) Figure 3-7: Example graph for ordering constraints x 2 (k + m) x 2 (k + m µ) τ 2 (k + m µ) w 2,µ(k + m µ) x 2 (k + m µ) x 2 (k + m) τ 2 (k + m) w 2,µ(k + m µ) (3-14) with w 2,µ(k + m µ) = w 1,µ(k + m µ) s 12 (k + m µ) s 12 (k + m) w 2,µ(k + m µ) = w 1,µ(k + m µ) s 12 (k + m µ) s 12 (k + m)

46 34 General modeling framework using topology graphs for m Z + 0 and µ {1,, µ max } Now if both cycle k + m µ and k + m use arc (1, 2), then s 12 (k + m µ) = s 12 (k + m) = e and the order in 2 depends on the order in node 1 If the order in 1 is k + m > k + m µ, then w 1,µ(k + m µ) = e and w 2,µ(k + m µ) = e and thus x 2 (k + m) > x 2 (k + m µ) On the other hand, if the order in 1 is k + m µ > k + m, then w 1,µ(k + m µ) = ε and w 1,µ(k + m µ) = e, and therefore w 2,µ(k + m µ) = ε and w 2,µ(k + m µ) = e The order in 2 then becomes x 2 (k + m µ) > x 2 (k + m) If both k + m µ and k + m do not use arc (1, 2) or if one of the two does not use arc (1, 2), w 2,µ(k + m µ) = w 2,µ(k + m µ) = ε This because in both cases, no ordering between jobs from cycle k + m and k + m µ is needed in node 2 and the constraints become: which they always are x 2 (k + m) ε x 2 (k + m µ) ε Finally, if node i does not have a predecessor, w i,µ (k + m µ) is fixed, namely this control variable is then equal to e If node i comes after the input u(k + m), w i,µ (k + m µ) = w i,µ (k + m µ) s u,σ(u) (k + m) Nodes with more than one incoming arc Consider again Figure 3-7 Node 5 has more than one incoming arc and therefore conflicts may arise when one job comes through arc (2, 5) and another through (4, 5) The order can then switch in node 5 The constraints described previously for the nodes with one incoming arc do not suffice, because these constraints only define the order if both jobs pass the same arc The constraints related to the event x 5 are the same as for the other nodes The difference is that now the control variable w 5,µ (k + m µ) consists of the maximum of different terms The first two terms are similar to the one for nodes with one incoming arc So the order in node 5 is the same as the order in one of the preceding nodes, if both jobs take the same arc towards 5 For the third term a control variable is added which makes it possible to switch

47 3-3 Ordering 35 the order if both jobs arrive at node 5 through another arc Therefore the set of equations for node 5 becomes: with and x 5 (k + m) x 5 (k + m µ) w 5,µ(k + m µ) x 5 (k + m µ) x 5 (k + m) w 5,µ(k + m µ) w 5,µ(k + m µ) =w 2,µ(k + m µ) s 25 (k + m µ) s 25 (k + m) w 4,µ(k + m µ) s 45 (k + m µ) s 45 (k + m) w 5,µ (k + m µ) s 25 (k + m µ) s 45 (k + m) w 5,µ (k + m µ) s 45 (k + m µ) s 25 (k + m) w 5,µ(k + m µ) = w 2,µ(k + m µ) s 25 (k + m µ) s 25 (k + m) w 4,µ(k + m µ) s 45 (k + m µ) s 45 (k + m) w 5,µ (k + m µ) s 25 (k + m µ) s 45 (k + m) w 5,µ (k + m µ) s 45 (k + m µ) s 25 (k + m) So now if both jobs arrive at node 5 through the same arc, the extra terms are equal to ε and the same procedure is followed as explained for nodes with one incoming arc If however both jobs arrive at node 5 through another arc, the first two terms are ε and the third and fourth term is left If both bags take another arc, w 5,µ (k + m µ) = w 5,µ(k + m µ) and the order can still be chosen by finding the optimal w 5,µ (k + m µ) Note the difference between w 5,µ (k + m µ) and w 5,µ(k + m µ) The latter defines the optimal order, while the first is activated if the order is already fixed Another possibility is that no job or only one of the jobs passes node 5 Then w 5,µ (k + m µ) = ε which is correct since then ordering in node 5 between job j from cycle k + m and k + m µ is not necessary If there are nodes with more than two incoming arcs, the maximum is taken of all follow constraints of the preceding nodes and the sums of all combinations of all incoming arcs Define the number of all incoming arcs for node i as a i Then the equation that determines w i,µ (k +m µ) for nodes with more than one incoming arc can be written generally as (3-15) w i,µ(k + m µ) = ( a i hh=1 w π(i) hh,µ (k + m µ) s π(i) hh,i(k + m) s π(i)hh,i(k + m µ)) w i,µ (k + m µ) s π(i)1,i(k + m µ) s π(i)2,i(k + m) w i,µ (k + m µ) s π(i)2,i(k + m µ) s π(i)1,i(k + m) (3-15) w i,µ (k + m µ) s π(i)ai 1,i(k + m µ) s π(i)ai,i(k + m) w i,µ (k + m µ) s π(i)ai,i(k + m µ) s π(i)ai 1,i(k + m)

48 36 General modeling framework using topology graphs In A dext such nodes i can be found by looking at row i for which holds: n A dext (i, j) > 1 j=1 Namely, if the sum of all elements in row i is larger than 1, node i has more than one incoming arc Moreover, the incoming arcs are the entries for which holds (i, j) = 1 This is used in the general framework that is made in Matlab of which the part on ordering can be seen in Appendix B Now the last nodes that need ordering constraints are the duplicated nodes, which is more complex Ordering between duplicated nodes For the follow constraints for duplicated nodes, the same procedure is followed as described previously However, ordering between duplicated nodes that have the same resource associated with them is needed For duplicated nodes i and j that are using the same resource, the constraints are: with x i (k + m) x j (k + m µ) τ j (k + m µ) w ij,µ(k + m µ) (3-16) x j (k + m µ) x i (k + m) τ i k + m w ij,µ(k + m µ) (3-17) x j (k + m) x i (k + m µ) τ i (k + m µ) w ji,µ(k + m µ) (3-18) x i (k + m µ) x j (k + m) τ j (k + m) w ji,µ(k + m µ) (3-19) e, if operation j from cycle k + m µ precedes w ij,µ(k + m µ) = operation i in cycle k + m ε, otherwise and define w ij,µ (k + m µ) as: e, if operation j from cycle k + m µ precedes w ij,µ (k + m µ) = operation i in cycle k + m ε, if operation i from cycle k + m precedes operation j in cycle k + m µ where µ {0,, µ max } for systems with multiple jobs per cycle and µ {1,, µ max } for jobs with only one job every cycle Note however that for systems with more than one job per cycle, (3-16)-(3-17) and (3-18)-(3-19) result in the same constraints for µ = 0, but with different control variables Therefore for µ = 0 holds that only w ij,0 (k + m) and its adjoint is needed, whereby the constraints (3-18)-(3-19) can be left out τ i (k) and τ j (k) represent the minimum separation time in a resource in cycle k Note that τ i (k) = τ j (k), since i and j are associated with the same resource Now the control variable w ij,µ (k + m µ) is defined differently for different situations First consider in Figure 3-6 the duplicated nodes 41 and 42, which will be referred to as node 4

49 3-3 Ordering 37 and node 5 respectively Moreover, all other nodes are also indicated by the gray numbers next to the nodes The modeling of the ordering constraints between node 4 and 5 is shown below with x 4 (k + m) x 5 (k + m µ) τ 5 (k + m µ) w 45,µ(k + m µ) x 5 (k + m µ) x 4 (k + m) τ 4 (k + m) w 45,µ(k + m µ) x 5 (k + m) x 4 (k + m µ) τ 4 (k + m µ) w 54,µ(k + m µ) x 4 (k + m µ) x 5 (k + m) τ 5 (k + m) w 54,µ(k + m µ) w 45,µ(k + m µ) =w 45,µ (k + m µ) ((s 34 (k + m) s 24 (k + m)) (s 65 (k + m µ) s 75 (k + m µ))) w 45,µ(k + m µ) = w 45,µ (k + m µ) ((s 34 (k + m) s 24 (k + m)) (s 65 (k + m µ) s 75 (k + m µ))) w 54,µ(k + m µ) =w 54,µ (k + m µ) ((s 65 (k + m) s 75 (k + m)) (s 34 (k + m µ) s 24 (k + m µ))) w 54,µ(k + m µ) = w 54,µ (k + m µ) ((s 65 (k + m) s 75 (k + m)) (s 34 (k + m µ) s 24 (k + m µ))) with m Z + 0 and µ {0,, µ max } Remember, for µ = 0, one constraint on x and its perturbed constraint can be left out Now the optimal order between 4 and 5 can always be chosen because the incoming arcs do not represent the same path This can be written generally as (3-20), w ij,µ(k + m µ) = w ij,µ (k + m µ) ( π(i) s π(i),i (k + m)) ( s π(j),j (k + m µ)) π(j) (3-20) where the selection control variable s π(i),i (k + m) is added to make sure the job passes this node This because for systems where the routes of the jobs can vary, it has to be defined whether the job is indeed using the resource, since otherwise ordering is not necessary and infeasible solutions may arise Note that the maximum of all s π(j),j (k + m µ) is redundant, since if a job in cycle k + m µ does not pass node j, x j (k + m µ) = ε and the resulting constraint is the same However, keeping a general framework in mind, this term is added such that the adjoint can immediately be obtained from (3-20): w ij,µ(k + m µ) = w ij,µ (k + m µ) ( π(i) In (3-21) the maximum of all s π(i),i (k + m) is redundant s π(i),i (k + m)) ( s π(j),j (k + m µ)) π(j) (3-21) With circuits however, the order decision variable is differently defined Therefore, consider the extended topology graph presented in Figure 3-4, example 1 The ordering between the

50 38 General modeling framework using topology graphs first duplicated nodes and their subsequent duplicated nodes is differently defined than the ordering between all duplicated nodes after 21 and 31 This is because for example the arc that leads to node 21 represents a different path than the arcs that lead to 2i, for i = 2, 3, 4 Namely, these paths are all duplicated arcs and thus represent the same path Take first as an example the ordering between node 21 and 2i Then the ordering constraints are defined as (3-16)-(3-19) and the ordering control variables are defined similarly as in (3-20)-(3-21) Only then there is generally only one incoming arc for duplicated nodes di, with i 2 and there can be more incoming arcs for d1 Now consider the ordering between for example 22 and 24, then the ordering control variables are defined as: w 22,24,µ(k + m µ) = w 31,33,µ(k + m µ) s 31,22 (k + m) s 33,24 (k + m µ) w 22,24,µ(k + m µ) = w 31,33,µ(k + m µ) s 31,22 (k + m) s 33,24 (k + m µ) w 24,22,µ(k + m µ) = w 33,31,µ(k + m µ) s 33,24 (k + m) s 31,22 (k + m µ) w 24,22,µ(k + m µ) = w 33,31,µ(k + m µ) s 33,24 (k + m) s 31,22 (k + m µ) This because the order between 22 and 24 depends on the order in their predecessors So generally the ordering decision variable for duplicated nodes that both have a duplicated incoming arc is defined as: w i,j,µ(k + m µ) = w π(i),π(j),µ (k + m µ) s π(i),i(k + m) s π(j),j (k + m µ) (3-22) Note that the ordering between node 8 and 9 in Figure 3-6 works in the same way Finally, note that the ordering constraints that define the order between duplicated nodes cannot be automatically generated from the extended topology graph Exceptions A problem arises when there are nodes with more than one incoming arc where some of these incoming arcs come from duplicated nodes If the node only has incoming arcs from duplicated nodes corresponding to the same resource, then the order in this node is fixed This because then the order depends on the order in the previous duplicated nodes Consider the example given in Figure 3-8 The extended topology graph in Figure 3-9 shows the case where node 1 and 2 are duplicated once The red line surrounding node 1 and 2 and node 3 and 4 indicates these are the duplicated nodes and that they use the same resource Then the nominal ordering in node 5 (in the original topology graph this is node 3) becomes: with x 5 (k + m) x 5 (k + m µ) τ 5 (k + m µ) w 5,µ(k + m µ) w 5,µ(k + m µ) =w 1,µ(k + m µ) s 15 (k + m) s 15 (k + m µ) w 2,µ(k + m µ) s 25 (k + m) s 25 (k + m µ) w 12,µ(k + m µ) s 15 (k + m) s 25 (k + m µ) w 21,µ(k + m µ) s 25 (k + m) s 15 (k + m µ)

51 3-3 Ordering 39 Figure 3-8: Example topology graph for ordering exception 1 Figure 3-9: Example extended topology graph for ordering exception 1 Note that the jobs cannot switch in node 5, since arc (1, 5) and (2, 5) represent the same path Therefore, if two jobs from different cycles take a different duplicated arc, the order in node 5 depends on the order between node 1 and 2 For more than two incoming arcs the same method is used, only then all direct predecessors need to be taken into account Therefore, all possible combinations of incoming arcs are then included in the equation for w i,µ (k+m µ) The next case is that a node has more than one incoming arc that come from duplicated nodes that are not all assigned to the same resource Therefore, consider Figure 3-10 and the corresponding extended topology graph in Figure 3-11 Then the ordering control variable Figure 3-10: Example topology graph for ordering exception 2 Figure 3-11: Example extended topology graph for ordering exception 2

52 40 General modeling framework using topology graphs for operation 5 in cycle k + m and k + m µ becomes: w 5,µ(k + m µ) = w 1,µ(k + m µ) s 15 (k + m) s 15 (k + m µ) w 4,µ(k + m µ) s 45 (k + m) s 45 (k + m µ) w 12,µ(k + m µ) s 15 (k + m) s 25 (k + m µ) w 21,µ(k + m µ) s 25 (k + m) s 15 (k + m µ) w 34,µ(k + m µ) s 35 (k + m) s 45 (k + m µ) w 43,µ(k + m µ) s 45 (k + m) s 35 (k + m µ) w 5,µ (k + m µ) (s 15 (k + m) s 35 (k + m µ) s 35 (k + m) s 15 (k + m µ)) w 5,µ (k + m µ) (s 15 (k + m) s 45 (k + m µ) s 45 (k + m) s 15 (k + m µ)) w 5,µ (k + m µ) (s 25 (k + m) s 35 (k + m µ) s 35 (k + m) s 25 (k + m µ)) w 5,µ (k + m µ) (s 25 (k + m) s 45 (k + m µ) s 45 (k + m) s 25 (k + m µ)) The terms that are added (with w 5,µ (k + m µ)) are the terms that make it possible to switch in node 5 if both jobs come from a different set of duplicated arcs If for example a job in cycle k + m arrives at 5 through arc (1, 5) and a job from cycle k + m µ arrives there through arc (3, 5), the optimal order can still be decided since (1, 5) and (3, 5) do not represent the same path So for this example s 15 (k + m) = s 35 (k + m µ) = e and w 5,µ (k + m µ) = w 5,µ(k + m µ) and the optimal order in 5 can be obtained by finding the optimal w 5,µ (k + m µ) The adjoint w 5,µ (k + m µ) is obtained by replacing every w i,µ, w i,j,µ and w i,µ by its complement One can imagine that for more duplicated nodes, so especially for systems with circuits and where a job can re-enter the circuit many times, the constraints for ordering between the duplicated nodes and the order in their successors explode Overall ordering decision constraints All ordering control variables are stacked in the order decision matrix W µ (k + m) which consists of binary control variables w ij,µ (k + m µ), w i,µ (k + m µ) and ε w i,µ (k + m µ), for [W µ (k+m)] ij = w ij,µ (k + m µ), ε, otherwise i = j and µ {1,, µ max} for i j and if i and j are related to the same resource, for µ {0,, µ max } (3-23)

53 3-3 Ordering 41 The complement of W µ (k + m) is written as W µ (k + m) = W µ (k + m µ) and is build up as follows w i,µ (k + m µ) for i = j, µ {1,, µ max} and [W µ (k + m)] ij = w i,µ (k + m µ) [ W µ (k+m)] ji = [W µ (k+m µ)] ji = w ij,µ (k + m µ) for i j, µ {0,, µ max} and [W µ (k + m)] ij = w ij,µ (k + m µ) ε if [W µ (k + m)] ij = ε (3-24) Moreover, the separation matrix H µ (k + m) should be defined This matrix determines the minimum separation time between two operations that may be scheduled on the same resource: τ i (k + m µ) = τ j (k + m µ), if node i in cycle k + m and j in cycle k + m µ are related to the same [H µ (k + m)] ij = resource, i, j ε, otherwise for µ = µ min,, µ max Now the total ordering decision matrix for µ = µ min,, µ max, is defined as: A ord,µ (k + m) = W µ (k + m) H µ (k + m) and the total ordering equations for cycle k become: µ max x(k) A ord,µ (k) x(k µ) (3-25) µ=µ min The Matlab file for generating the matrices for ordering is given in Appendix B A limitation of this file is that the ordering between duplicated nodes and the order in their direct successors is not taken into account Furthermore, it is again made for one job each cycle This file uses the routing file from Appendix A and the only system specific input should be to predefine that some w i,µ (k+m µ) are equal to e when proceeding with the actual scheduling Remark 1 In the methods described in this section, the assumption was made that jobs cannot pass other jobs when using the same arc However, it may occur jobs can pass each other on the same path This might be the case in a railway network with double tracks Then the decision variables should be adjusted First consider the ordering for nodes with one incoming arc The control variable w i,µ (k + m µ) then becomes: w i,µ(k + m µ) = w i,µ (k + m µ) s π(i)i (k + m µ) s π(i)i(k+m), whereby the order in node i is still free to choose if both k +m µ and k +m take arc (π(i), i) The next decision variables that should be adjusted are the ones for nodes with more than one incoming arc These constraints are changed similarly as the ones for nodes with one incoming arc Namely, all w π(i),i (k + m µ) are replaced by w i,µ(k + m µ) in equation

54 42 General modeling framework using topology graphs (3-15) Therefore, if both jobs pass node i the ordering decision variable is activated and the optimal order can still be chosen even if the jobs come through the same arc For the exceptions described in 3-3-4, the same is done For the ordering decision variables for determining the order between duplicated nodes, where the incoming arcs do not represent the same path, adjusting the definitions is not necessary For duplicated nodes both with an incoming arc that represents the same path, the decision variable w π(i),π(j),µ (k + m µ) is replaced by w ij,µ(k + m µ) Remark 2 If there are no alternative routes or route classes for the jobs, the selection control variables s ij (k + m) are redundant and the ordering constraints only consist of the ordering control variables w i,µ (k + m µ) and w ij,µ (k + m µ) If the order is fixed, for example because operations from future cycles always come after operations from the current cycle, these ordering control variables are equal to e and an MPL system is obtained The latter is the case for systems with one job each cycle where only one route is available 3-4 Overall SMPL system Now that all conditions for routing and ordering are defined, the overall SMPL system can be written down The binary control variables that the control problem will consist of for cycle k are: Routing: s ij (k) w(k) Ordering: w ij,µ (k µ) and w ij,µ(k µ) for duplicated nodes, for µ = 0,, µ max for multiple jobs per cycle and µ = 1,, µ max for one job per cycle w i,µ (k µ) and w i,µ(k µ) for all nodes, for µ = 1,, µ max s ij (k µ) for all arcs, for µ = µ min,, µ max

55 3-4 Overall SMPL system 43 All control variables can be stacked in one control vector: s ij (k µ) w 1 (k) w L (k) w 1,µ (k µ) v 1 (k) = w n,µ(k µ) w 1,µ (k µ) w n,µ (k µ) w ij,µ (k µ) w ij,µ (k µ) (3-26) Now the total system equation becomes: µ max x(k) = A µ (v 1 (k), k) x(k µ) B 0 (s uσ(u) (k), k) u(k) (3-27) µ=µ min with A µ (v 1 (k), k) = A ord,µ (w i,µ(k µ), w ij,µ(k µ), k), µ {µ 0} If the jobs return each cycle then for µ = 1 holds: A 1 (k) = A route,1 (s ij (k 1), k) A ord,1 (w i,1(k 1), w ij,1(k 1), k) For µ = 0 holds: A 0 (k) = A route,0 (s ij (k), k) A ord,0 (w ij,0(k), k) Furthermore, u(k) can be a reference r(k) or a given external variable The scheduling problem results in finding the optimal mode for event step k by obtaining the optimal control input v 1 (k) and thereby an optimal and feasible time schedule This is done by a Model Predictive Control strategy, whereby the scheduling problem is recasted as a Mixed Integer Linear Programming (MILP) problem The control vector can be used in the MILP formulation that will be addressed in chapter 4 Remark In the general modeling framework just described, synchronization is not considered This is because the synchronization constraints cannot be obtained from the topology graph of the system If the system considered has synchronization constraints, these should be defined as explained in [2] Note that these type of constraints only occur in systems where one cycle consists of multiple jobs

56 44 General modeling framework using topology graphs Using the eigenvalues and eigenvectors The eigenvalue of a system matrix A represents the total cycle time The total cycle time can be seen as the interval period required to complete an operation from start to finish The eigenvector associated with this eigenvalue represents the steady state behavior The definition of eigenvalues and eigenvectors in the max-plus algebra is similar to the definition in conventional algebra In conventional algebra, for an eigenvalue µ with associated eigenvector v of a matrix A R n n, it holds that: A v = µ v Now in max-plus algebra it holds that, given A R n n max, then if µ R max is a scalar and v R n max is a vector that contains at least one finite element such that A v = µ v, (3-28) µ is called an eigenvalue of A and v an eigenvector of A associated with eigenvalue µ Now some DESs with fixed routes, use predefined time schedules that give a lower bound for the starting time of the operations in the system The eigenvalue and eigenvector of the system matrix from the nominal operation can be used to construct such a reference (timetable) The eigenvalue λ of the system matrix A plays an important role in the reference Every λ time units an operation on the same resource can take place Therefore it should be such that the time between two consecutive operations on the same resource should differ at least λ time units since otherwise it will not be possible for the system to operate under this reference The periodic behavior of a system is characterized through the eigenvalue and the cyclicity of A [3]: x(k + σ) = λ σ x(k) for all k t(a) Here σ represents the cyclicity of A and is normally denoted by σ(a) The cyclicity of A is different from the cyclicity σ G of a graph G since the cyclicity of A is the cyclicity of the critical graph of A This can be used to construct the reference, since for a certain k t(a) the time schedule differs λ σ with the previous cycle By taking the vector x(k) that belongs to k = t(a) as the initial timetable, the system will show periodic behavior (for systems with a nominal case) For many SMPL systems, especially the ones without fixed routes, the max-plus eigenvalue cannot be used since the system consists of a number of modes and therefore has not one system matrix A However, the concept of the maximum growth rate can be used For an SMPL system (2-21), define A l α where [A l α] i,j = [A l ] i,j α The maximum growth rate λ of the SMPL system represents the maximum average cycle time of the system and is the smallest α for which there exists a max-plus diagonal matrix S = diag (s 1,, s n ) with finite diagonal elements s i, such that [ S A l α S 1] 0, i, j, l ij If the asymptotic slope ρ of the reference signal r(k) is smaller than the maximum growth rate λ, the system cannot complete tasks in time and y(k) r(k) will grow unbounded in time Therefore, the condition λ < ρ is necessary for stability [7] Note that for an MPL system the latter is equivalent to the condition that the growth rate ρ of the reference signal should be larger than the largest max-plus eigenvalue λ

57 Chapter 4 Control for SMPL systems Now that a general modeling framework is obtained using the topology graph of a system, the system needs to be controlled In the scheduling of DESs this means finding the optimal schedule for event step k Many systems that are modeled by using max-plus algebra can be controlled by a control strategy called Model Predictive Control (MPC) Usually MPC uses linear or non-linear discrete-time models for the process to be controlled However, MPC has been extended to SMPL systems, due to its attractive features The main advantages of using MPC are its constraint handling capabilities and the use of the receding horizon principle For SMPL systems this means not the whole schedule is calculated at once, but only the jobs in the nearest future are calculated which will reduce the computation time Furthermore, MPC can easily adapt to model changes [2], [8] 4-1 Model Predictive Control for SMPL systems Consider the max-plus algebraic model of the form (2-16) An important difference with a discrete time model is that now the components of the input and the state are event times and therefore the counter k is an event counter, whereas in a discrete time model k increases at each clock cycle Also the A-matrix in an SMPL system like (2-21) changes when switching to another mode, where in conventional MPC the A-matrix is fixed This has to be taken into account in the prediction of future event times This is done by changing the event counter of the control variables present in the system matrices By finding the optimal control variables in each cycle, different system matrices are obtained every cycle There are many similarities between conventional MPC and MPC for SMPL systems which is shown in [8], where this section is mainly based on For the general framework considered here, the assumption is made there is no input u(k) that can be controlled like in a production system Furthermore, it is assumed the system that needs to be controlled is modeled by only using max-plus binary control variables Therefore the method presented in [8] is adjusted to

58 46 Control for SMPL systems fit the concepts discussed previously Important is to note that in this context there are two types of systems Events in some systems may depend on previous, current and/or future events and control variables, so control variables from cycle k µ where µ can be a negative integer, a positive integer or 0 This is the case when an event from a future cycle can occur before an event in the current cycle For other systems it may hold that x(k) depends on cycle k µ where µ is a nonnegative integer This difference has to be taken into account in the prediction model which will be explained next Prediction model Since it is assumed that in general the output is included in the state vector, the prediction model described in this section is of x(k) Consider the SMPL system µ max x(k) = A µ (k) x(k µ) B 0 (k) u(k) (4-1) µ=µ min where the value of µ min depends on the type of system Type 1: current cycle does not depend on future cycles In this case holds that µ = 0,, µ max The value of µ max depends on the number of previous cycles x(k) depends on Take as prediction horizon N p, which determines how many steps are looked ahead In repsonse to a possible future perturbation, the prediction horizon makes it possible to take a control action at the current event step The following structure arises: x(k) = Ã0(k) x(k) Ã1(k) x(k 1) õ max (k) x(k µ max ) B 0 (k) ũ(k) (4-2) with ˆx(k) u(k) ˆx(k + 1) x(k) =,ũ(k) = u(k + 1) ˆx(k + N p ) u(k + N p ) and A 0 (k) E E A 1 (k) A 1 (k + 1) A 0 (k + 1) E E à 0 (k) =, à A 2 (k + 1) 1 (k) =, A Np (k + N p ) A Np 1(k + N p ) A 0 (k + N p ) A Np+1(k + N p ) A µmax (k) B 0 (k) E E à µmax (k) =, E B 0 (k + 1) E B0 (k) = E E E E B 0 (k + N p )

59 4-1 Model Predictive Control for SMPL systems 47 where the assumption is made that µ max > N p à µ (k + m) are E If µ max N p, some of the matrices in Type 2: operations from current cycle can switch with operations from future cycles For this type holds that µ = µ min,, µ max Again, the value of µ max depends on the number of cycles that must be looked back The value µ min defines the number of cycles ahead that consist of operations that can start before the operations in cycle k started Other than for type 1, the system needs to be extended before it can be controlled Otherwise ordering between the current cycle and future cycles is not possible In general holds that µ max > µ min This because if for example an operation in cycle k can switch with an operation from cycle k +m, for m = 1, 2, 3, then µ min = 3 When the time instant for the operation in cycle k +3 is determined, µ max should at least be equal to 3 to be able to take into account the ordering between k + 3 and the previous cycle k Furthermore, the reason for choosing µ max larger than µ min is that when there is a minimum separation time in resources, it could happen that if in cycle k not enough previous cycles are taken into account, conflicts can still arise The general structure is the same as (4-2) The only difference is the extended system matrix à 0 (k), where the assumption is made that µ min = N p : A 0 (k) A Np (k) A 1 (k + 1) A 0 (k + 1) A 1 Np (k + 1) à 0 (k) = A Np (k + N p ) A Np 1(k + N p ) A 0 (k + N p ) If µ min < N p, some of the matrices of the upper triangular of Ã0(k) are E A µ (k) is the adjoint of A µ (k + µ) Take for example the matrix A 1 (k + 1) and its complement A 1 (k): [ ] [ ] w A 1 (k + 1) = 1,1 (k) ε w ε w 2,1 (k), A 1 (k) = 1,1 (k) ε ε w 2,1 (k) All future values of v(k + m) for m = 0,, N p can be captured in a vector: ṽ 1 (k) = v 1 (k) v 1 (k + N p ) where ṽ 1 (k) consists of all decision variables up to cycle k + N p which are stacked in the system matrices Ã0(k) and B 0 (k) Cost function Now that a model is found to express the future event times of the system, the cost function can be defined In the SMPL model (2-21) (2-23) there are two possible input signals, namely v(k) and u(k) However, in this work only v(k) is considered Define the input sequence by [ T ṽ 1 (k) = v1 T (k),, vt 1 p)] (k + N

60 48 Control for SMPL systems If each entry of v 1 (k) corresponds to a specific control action like a specific scheduled event order, v 1 (k) is assumed to be binary, which it is in the scope of this research Now the goal is to find the optimal mode for event step k by computing the optimal control sequence ṽ 1 (k) that minimizes the cost function J(k) This optimization problem may be subjected to linear constraints on the inputs and the states The ] cost function consists of the input and output cost functions in the event period [k, k + N p : J(k) = J out (k) + λj in (k), (4-3) where the weight λ 0 is a tuning parameter Usually the output cost function is given by N p n J out (k) = max α iκ i (k + N p ) + σ mi κ i (k + m) i=1,,n m=0 i=1 where σ mi is a weighting scalar The first term of J out (k) is the total production length over the next N p jobs which is called the makespan The second term is related to the weighted sum of all predicted event times The choice of the most suitable objective function depends on the problem that needs to be solved Often the objective is to minimize the global makespan (so the total length of the schedule, denoted by N tot ) However, when N tot is big it is usually better to choose a prediction horizon N p N tot and the aim will be to minimize J out (k) with α i = 1 and 0 σ mi 1 Then κ i (k + N p ) = x i (k + N p ) and κ i (k + m) = x i (k + m) Then the most important thing is to minimize the largest event time from cycle k + N p and thereby minimize the length of the schedule up to N p However, in general a small weight σ mi is assigned to the second term because it is still desired that every event time is taken into account In other cases the objective might be to minimize the sum of delays with respect to a reference or due date signal [2] Then α i = 0 and σ mi = 1 Either κ i (k + m) = max (x i(k + m) i=1,,n r i (k + m), 0) or κ i (k + m) = max (r i(k + m) x i (k + m), 0) is substituted in the output cost i=1,,n function The choice depends on the objective For some systems the objective may be that the time instant of event x i (k +m) is preferably not smaller than r i (k +m) (latter definition) Note that sometimes for this case the constraint x i (k + m) r i (k + m) is already added to the total system dynamics, see equation (3-27) Then κ i (k + m) = x i (k + m) r i (k + m) is substituted in the output cost function and the objective is that x i (k + m) is as close to r i (k + m) as possible For other systems it may be desirable that the time instant of event x i (k + m) is preferably not larger than r i (k + m) (first definition) The due date signal is stacked in the vector r(k) = r(k) r(k + N p ) The input cost function is a function of ṽ 1 (k) and is usually defined as N p n v J in,v1 (k) = λ i v 1i (k + m) m=0 i=1

61 4-1 Model Predictive Control for SMPL systems 49 This function denotes the penalty for all changes in ordering or synchronization in cycle k+m, where λ i 0 are weights to punish any action corresponding to a variable v 1i (k + m) [1], [9] However, note that in some systems there is no nominal case and the optimal schedule is different in every cycle Then there is no need for a penalty function As in conventional MPC the parameter λ makes a trade-off between the output cost function and the input cost function Constraints The cost function obtained in the previous subsection must be subjected to some constraints, which will be explained next The additional condition u(k + m) = u(k + m) u(k + m 1) 0 (4-4) makes sure the start of event (k + m), so at time u(k + m), will always be later than the start of event (k + m 1) Furthermore, a constraint is introduced such that the increments of u(k) are assumed to become constant after event step (k + N c 1): u(k + m) = u(k + N c 1), (4-5) for m = N c,, N p, where N c is the control horizon (N c N p ) which reduces the number of decision variables and the corresponding complexity and can be chosen between 1 and N p For the control variable v(k) often the same procedure is followed Beyond control horizon N c, v(k) is assumed to be constant, resulting in the following constraint: for m = N c,, N p v(k + m) = v(k + N c 1), (4-6) Overall Model Predictive Control problem Now that all conditions are derived, the MPC control problem for event step k can be defined as subject to µ max min J(k) (4-7) { x(k),ṽ 1 (k)} x(k + m) ( A µ (k + m) x(k + m µ)) B 0 (k + m) u(k + m), (4-8) µ=µ min

62 50 Control for SMPL systems for m = 0,, N p u(k + m) 0, for m = 0,, N p (4-9) v(k + m) v(k + m 1) = 0, for m = N c,, N p (4-10) u(k + m) u(k + N c 1) = 0, for m = N c,, N p (4-11) A c (k)ṽ(k) c c (k) (4-12) where (4-8) represents the system dynamics that have to be taken into account Note that A µ (k + m) is generally a matrix consisting of sums of process times and max-plus binary variables present in v 1 (k + m) (4-12) represents possible additional linear constraints on the max-plus binary control variables Finally it is important to note that the ordering constraints from previous cycles that switches order between current and future cycles are neglected when the receding horizon shifts Take as an example the following set of equations: x i (k + 1) x i (k) w i,1(k) τ i (k) x i (k) x i (k + 1) w i,1(k) τ i (k + 1) Now if in cycle k the control variable w i,1 (k) = ε and thus w i,1 (k) = e, the following constraints are obtained in cycle k: x i (k + 1) ε x i (k) x i (k + 1) e τ i (k + 1) However, in the next iteration, the latter constraint is lost because there is only looked at constraints for k + m, with m = 1,, N p + 1 So the only constraint left is: x i (k + 1) ε Now if the order switches between the current cycle and a future cycle, the headway time for resource i is neglected in future iterations Therefore, when applying MPC, the previous perturbed ordering constraints that include the headway time need to be added This results in extra constraints for cycle k + m: x(k + m) v 1 (k) τ(k) x(k) (4-13) Tuning The parameter λ is a scalar that satisfies 0 < λ < 1 which makes a trade-off between minimization of the tracking error and the number of broken synchronizations or changed orders needed λ should be chosen relatively large if it is important to maintain certain orders or synchronizations The parameters N p and N c (N c N p ) determine the size of the problem First of all, the time interval [1, N p ] should contain the crucial dynamics of the process and important information of the due date sequence However, when chosen too large, the MPC problem may not be tractable anymore, since the problem needs to be solved during each operations cycle and so the available time is limited When N p and N c are chosen too small this will have a negative impact on the performance of the overall system The following rule of thumb is proposed in [10]: N p should be chosen such that it covers the (expected) period over which the delays or perturbations die out The choice of N c mainly depends on the computational complexity of the problem For small-sized scheduling problems N c can be taken rather large, whereas for large scheduling problems a small N c will be necessary to be able to compute the MPC solution sufficiently fast, so before the start of the next cycle

63 4-2 Solving the optimization problem Solving the optimization problem The literature discussed in this section mainly originates from [11] In SMPL systems the optimal control problem will generally result in an integer optimization problem, which has the following form: min f(x) x (4-14) subject to h(x) = 0 (4-15) g(x) 0 (4-16) ] x = [ xr x i (4-17) x r R nr, x i Z n i (4-18) where (4-15) are the equality constraints and (4-16) are the inequality constraints that restrict the solution to a certain allowed region of the parameter space If x consist of both real parameters and integer parameters, so n r, n i > 0, the optimization problem is called a mixed integer optimization problem Furthermore, an all integer optimization problem is obtained if all variables need to be integer, which means n r = 0 in (4-18) Finally, if f(x) is linear or affine in x and the constraints are linear or affine in x, a mixed integer linear programming (MILP) problem is obtained The goal of the optimization is to find an optimal and feasible solution However, in [11] is explained that finding the global optimum is in many cases impossible in practice An explanation for this is that many integer optimization problems are mathematically defined as NP-hard problems, which means that the number of potential solutions grows exponentially as a function of the problem size Evaluating all possible solutions would be the simplest approach to solving the optimization problem However, because of the exponential growth of the solution space, this results in an exponentially growing computation time and even for small-sized problems this approach will fail (see [11] for more detail) Since evaluating all potential solutions is impossible for most problems, the goal is reduced to finding a feasible solution which preferably approaches the optimality of the global optimum Recast MPC problem into MILP problem Mixed integer linear programming (MILP) can be used if f(x) in (4-14) is linear or affine in x, so of the form c T x Furthermore the constraints (4-15)-(4-16) must be linear or affine in the parameter vector x and so MILP is of the following form: min c T x x (4-19) subject to Ax b ] (4-20) x = [ xr x i (4-21) x r R nr, x i Z n i (4-22)

64 52 Control for SMPL systems Before MILP can be used to solve the scheduling problem in (S)MPL systems, first the MPC problem has to be recast into a MILP formulation When using max-plus binary variables, the scheduling parameters are either zero or infinity For the actual numerical implementation the infinite value ε cannot be used Therefore, the max-plus binary variables have to be replaced by conventional binary variables To do so, the following approximation can be used: v i (k) = βv i (k) where β 0 is a very large negative number and v i (k) {0, 1} is a conventional binary variable such that { 0, for vi (k) = e v i (k) = 1, for v i (k) = ε Furthermore, the adjoint of v i (k) can be approximated by v i (k) = β(1 v i (k)) This approximation can be used because the assumption is that the time instants events happen are limited Therefore β should be much larger than the maximal x(k +m), for m Z +, such that x i (k + m) + β is always much smaller than zero Moreover, following the method presented in [2], constraint (4-8) can be written as a set of constraints: [x(k + m)] i [A(k + m)] il + [x(k + m µ)] l (4-23) [x(k + m)] i [B(k + m)] ih + [u(k + m µ)] h (4-24) for i = 1,, n, l = 1,, n, h = 1,, m u, m = 0,, N p and µ = µ min,, µ max, where n is the number of states and m u is the number of inputs The constraints on the max-plus binary control variables should be transformed in constraints fitting the MILP formulation This can be done by following the concepts described in section 2-9 To be able to rewrite the whole MPC problem in the MILP formulation, the inequality constraints on the ordering control variables should be converted to constraints in conventional plus-times algebra First consider the constraints for w i,µ (k + m µ) that hold for nodes i with only one incoming arc, for convenience repeated here: w i,µ(k + m µ) = w π(i),µ (k + m µ) s π(i),i(k + m µ) s π(i),i (k + m) (4-25) These constraints are transformed to inequality constraints in conventional plus-times algebra in the same way as was done for equation (2-36) in section 2-9 Thereby (4-25) is transformed to the set of constraints (4-26) with conventional binary control variables w i,µ(k + m µ) w π(i),µ (k + m µ) w i,µ(k + m µ) s π(i),i (k + m µ) w i,µ(k + m µ) s π(i),i (k + m) w π(i),µ (k + m µ) + s π(i),i (k + m µ) + s π(i),i (k + m) w i,µ(k + m µ) 0 (4-26)

65 4-2 Solving the optimization problem 53 For the constraints for w i,µ (k + m µ) that hold for the nodes with more than one incoming arc transforming the constraints is more complex The method presented for equation (2-38) in section 2-9 is followed Therefore, help variables are introduced Define for every term a max-plus binary help variable δ iqh (k + m µ), with q h q and q the number of terms the maximum is taken of Furthermore, define a i as the number of incoming arcs for node i Then the constraints for nodes with more than one incoming arc are written as (4-27) w i,µ(k + m µ) = δ i1 (k + m µ) δ iq (k + m µ) δ i(q +1)(k + m µ) δ i(q +2)(k + m µ) δ i(q 1) (k + m µ) δ iq (k + m µ) (4-27) with δ i1 (k + m µ) = w π(i) 1,µ (k + m µ) s π(i) 1,i(k + m µ) s π(i)1,i(k + m) δ iq (k + m µ) = w π(i) ai,µ (k + m µ) s π(i) ai,i(k + m µ) s π(i)ai,i(k + m) δ i(q +1)(k + m µ) = w i,µ (k + m µ) s π(i)1,i(k + m µ) s π(i)2,i(k + m) δ i(q +2)(k + m µ) = w i,µ (k + m µ) s π(i)2,i(k + m µ) s π(i)1,i(k + m) δ i(q 1) (k + m µ) = w i,µ (k + m µ) s π(i)ai 1,i(k + m µ) s π(i)ai,i(k + m) δ iq (k + m µ) = w i,µ (k + m µ) s π(i)ai,i(k + m µ) s π(i)ai 1,i(k + m) The latter equations for δ iqh are each handled as the constraints for nodes with only one incoming arc Now only constraint (4-27) must be transformed to constraints consisting of conventional binary variables This is done as is explained for equation (2-40) in section 2-9 Now all inequality constraints, including the converted inequality constraints on the decision variables, can be put in the following form: E x(k) + F 1 ṽv 1 (k) B θ(k) + F 2 ṽv 2 (k) (4-28) where ṽv 1 (k) is a vector containing all control variables up to the prediction horizon N p, ṽv 2 (k) is a vector containing all uncontrollable variables including the ones from the past that cannot be changed anymore and θ(k) represents a vector consisting of all process times from previous, current and future cycles Next, consider the routing constraints for the control variables These constraints result in equality constraints Define L ij as the set of all control variables w l that are related to a route that uses arc (i, j) Furthermore, L ij is defined as the cardinality of L ij The constraint that makes sure only the control variables that activate an arc are e if a route that uses this arc is chosen is handled different than the method for equation (2-40) in section 2-9 This because in s ij = L ij, always only one element in L ij is e and all other elements are ε Therefore only one conventional equality constraint is needed to transform the max-plus binary constraint into a conventional constraint, which is shown in (4-29) s ij (k) = L ij s ij (k) = w l (k) L ij + 1 (4-29) }{{} w l (k) L ij Max-plus }{{} Conventional

66 54 Control for SMPL systems The next routing constraint that should be converted is the condition that if route l is chosen, only w l is e and w l = ε, l l Remember L is the number of routes or route classes available in one cycle Then the latter constraint is transformed to the constraint shown in (4-30) L w l (k) = L 1 (4-30) l=1 All routing constraints related to max-plus binary variables can now be converted and result in the set of equality constraints (4-31) F eq ṽv 1 (k) = b eq (4-31) Now define the vectors x(k), ṽv 1 (k) and ũ(k) The cost function J(k) [ as defined in section ] is linear in x(k), ṽv 1 (k) and ũ(k) and so there exists a vector c = c T 1 c T 2 c T 3 c T 4 such that: J(k) = c T 1 x(k) + c T 2 ṽv 1 (k) c T 3 ũ(k) + c T 4 κ(k) (4-32) Note that the form of J(k) depends on the type of system considered In a railway system for example, the vector ũ(k) is replaced by r(k), which represents the predefined time schedule In other systems the vector ũ(k) may not be present at all Moreover, remember that the objective can also be to minimize the delay with respect to a reference, such that κ(k + m) = max(x(k + m) r(k + m), 0) if it is desirable that x(k + m) r(k + m) Then help variables κ(k + m), for m = 0,, N p are stacked in the vector κ(k) where κ(k + m) is subjected to the additional constraints: κ(k + m) x(k + m) r(k + m) κ(k + m) 0 In [12] is denoted that the MILP problem can be solved using one of the several existing commercial and free solvers, such as CPLEX, Xpress-MP, GLPK, lp_solve The authors of [12] refer to [13] and [14] for an overview However, if the network is too large, the MILP solvers will not converge fast enough and other solvers are needed to efficiently solve the integer optimization problem These methods are generally called heuristics For more information about these techniques referred is to [11] After the routing and ordering constraints are obtained by entering the topology matrix and input matrix in the general Matlab code, the problem should be recast as to a MILP formulation Appendix C gives a general Matlab code where the matrices for the MILP formulation are obtained whereby the optimal schedule for the next N p event steps can be calculated Ofcourse the cost function should be chosen and implemented by the user The standard structure in the general framework of the vectors ṽv 1 (k), ṽv 2 (k), x(k) and θ(k) is given in Appendix C-3

67 Chapter 5 Case studies: three discrete event systems modeled using the general framework A variety of DESs are already modeled as an MPL system or SMPL system, where the scheduling problem always results in finding the optimal max-plus binary control variables resulting in an optimal route, order and synchronization However, many decisions in the process of modeling may depend on the type of system Not all systems contain routing, ordering and synchronization and some scheduling decisions may be more important for one system than for another system The input variable u(k) can take different forms, it can be predefined as in the railway network, it can be a given external variable or it can be a controllable variable for example in just-in-time production What also may depend on the type of system is the choice for the most suitable control variable, so one related to a mode or binary variables that correspond to a specific control action For very large systems it is almost impossible to model all possible combinations of ordering relations and synchronizations and therefore it is recommended to control the system through binary variables To elaborate on these differences, different systems are modeled using the general modeling framework from chapter 3 First legged locomotion is considered in section 5-1 Section 5-2 describes the scheduling of multiple sheets in a printer and section 5-3 describes the modeling of a railway network 5-1 Legged locomotion This section mainly follows the concepts and definitions given in [15] and [16] Consider a Zebro robot with recirculating legs as shown in Figure 5-1, where the numbers represent the leg index numbering assumed in this section Now define:

68 56 Case studies: three discrete event systems modeled using the general framework Figure 5-1: Hexapod Robot l i (k)= time instant leg i lifts off the ground for the kth time t i (k)= time instant leg i touches the ground for the kth time both for the kth event index Let leg "swing" be the term used to denote a leg is in flight and let leg "stance" be the term used to denote a leg is touching the ground A gait G is defined as an ordering relation of groups of legs: G = l 1 l 2 l m (5-1) This relation means that the set of legs l i+1 swings immediately after all legs l i have reached stance arriving from their own swing One job can be defined as a set of legs and the events are the lift-off and touch down of a set of legs This is because synchronization is needed between the lift off of one job and the touch down of another job A cycle is complete if all sets of legs have lifted of and touched down again and therefore there is more than one job in one cycle Note that this system is a special system because a job never exits the system So a job can be seen as an infinite long job For a trotting gait of a 4-legged robot (a quadruped), define the gait as G = {1, 4} {2, 3}, so leg 1 and 4 move simultaneously and the same holds for leg 2 and 3 Also leg 1 and 4 are synchronized with leg 2 and 3 The black arcs in the graph presented in Figure 5-2 represent the topology graph Since in this case there are two jobs each cycle, this graph is actually divided in two topology graphs, ie one for each job The set of legs {1, 4} is job 1 and the set {2, 3} is job 2 Furthermore, because synchronization is needed between the lift off of one leg and the touch down of another leg Suppose the aim is to synchronize leg i with leg j such that leg i can only lift off τ seconds after leg j has touched the ground

A Generalized Eigenmode Algorithm for Reducible Regular Matrices over the Max-Plus Algebra

A Generalized Eigenmode Algorithm for Reducible Regular Matrices over the Max-Plus Algebra International Mathematical Forum, 4, 2009, no. 24, 1157-1171 A Generalized Eigenmode Algorithm for Reducible Regular Matrices over the Max-Plus Algebra Zvi Retchkiman Königsberg Instituto Politécnico Nacional,

More information

Modeling and Stability Analysis of a Communication Network System

Modeling and Stability Analysis of a Communication Network System Modeling and Stability Analysis of a Communication Network System Zvi Retchkiman Königsberg Instituto Politecnico Nacional e-mail: mzvi@cic.ipn.mx Abstract In this work, the modeling and stability problem

More information

Model predictive control for discrete-event systems with soft and hard synchronization constraints

Model predictive control for discrete-event systems with soft and hard synchronization constraints Delft University of Technology Fac. of Information Technology and Systems Control Systems Engineering Technical report bds:00-20 Model predictive control for discrete-event systems with soft and hard synchronization

More information

A comparison of sequencing formulations in a constraint generation procedure for avionics scheduling

A comparison of sequencing formulations in a constraint generation procedure for avionics scheduling A comparison of sequencing formulations in a constraint generation procedure for avionics scheduling Department of Mathematics, Linköping University Jessika Boberg LiTH-MAT-EX 2017/18 SE Credits: Level:

More information

On max-algebraic models for transportation networks

On max-algebraic models for transportation networks K.U.Leuven Department of Electrical Engineering (ESAT) SISTA Technical report 98-00 On max-algebraic models for transportation networks R. de Vries, B. De Schutter, and B. De Moor If you want to cite this

More information

Chapter 3: Discrete Optimization Integer Programming

Chapter 3: Discrete Optimization Integer Programming Chapter 3: Discrete Optimization Integer Programming Edoardo Amaldi DEIB Politecnico di Milano edoardo.amaldi@polimi.it Website: http://home.deib.polimi.it/amaldi/opt-16-17.shtml Academic year 2016-17

More information

Chapter 3: Discrete Optimization Integer Programming

Chapter 3: Discrete Optimization Integer Programming Chapter 3: Discrete Optimization Integer Programming Edoardo Amaldi DEIB Politecnico di Milano edoardo.amaldi@polimi.it Sito web: http://home.deib.polimi.it/amaldi/ott-13-14.shtml A.A. 2013-14 Edoardo

More information

A Mixed Lyapunov-Max-Plus Algebra Approach to the Stability Problem for a two Species Ecosystem Modeled with Timed Petri Nets

A Mixed Lyapunov-Max-Plus Algebra Approach to the Stability Problem for a two Species Ecosystem Modeled with Timed Petri Nets International Mathematical Forum, 5, 2010, no. 28, 1393-1408 A Mixed Lyapunov-Max-Plus Algebra Approach to the Stability Problem for a two Species Ecosystem Modeled with Timed Petri Nets Zvi Retchkiman

More information

MPC for max-plus-linear systems: Closed-loop behavior and tuning

MPC for max-plus-linear systems: Closed-loop behavior and tuning Delft University of Technology Fac. of Information Technology and Systems Control Systems Engineering Technical report bds:00-11 MPC for max-plus-linear systems: Closed-loop behavior and tuning T. van

More information

Model predictive control for switching max-plus-linear systems with random and deterministic switching

Model predictive control for switching max-plus-linear systems with random and deterministic switching Delft University of Technology Delft Center for Systems and Control Technical report 07-038 Model predictive control for switching max-plus-linear systems with random and deterministic switching T. van

More information

Complexity reduction in MPC for stochastic max-plus-linear systems by variability expansion

Complexity reduction in MPC for stochastic max-plus-linear systems by variability expansion Delft University of Technology Fac of Information Technology and Systems Control Systems Engineering Technical report CSE02-007 Complexity reduction in MPC for stochastic max-plus-linear systems by variability

More information

A Mixed Integer Linear Program for Optimizing the Utilization of Locomotives with Maintenance Constraints

A Mixed Integer Linear Program for Optimizing the Utilization of Locomotives with Maintenance Constraints A Mixed Integer Linear Program for with Maintenance Constraints Sarah Frisch Philipp Hungerländer Anna Jellen Dominic Weinberger September 10, 2018 Abstract In this paper we investigate the Locomotive

More information

Abstract. 1 Introduction

Abstract. 1 Introduction The max-plus algebra approach to railway timetable design R.M.P. Goverde Faculty of Civil Engineering and Geo Sciences, Delft University o/ Tec/mob^ f 0 Boz ^% ggoo G^ De% 7/^e A^e^er/a^^ email: goverde@ct.tudelft.nl

More information

Sub-Optimal Scheduling of a Flexible Batch Manufacturing System using an Integer Programming Solution

Sub-Optimal Scheduling of a Flexible Batch Manufacturing System using an Integer Programming Solution Sub-Optimal Scheduling of a Flexible Batch Manufacturing System using an Integer Programming Solution W. Weyerman, D. West, S. Warnick Information Dynamics and Intelligent Systems Group Department of Computer

More information

Markov Chains Handout for Stat 110

Markov Chains Handout for Stat 110 Markov Chains Handout for Stat 0 Prof. Joe Blitzstein (Harvard Statistics Department) Introduction Markov chains were first introduced in 906 by Andrey Markov, with the goal of showing that the Law of

More information

c 2011 Nisha Somnath

c 2011 Nisha Somnath c 2011 Nisha Somnath HIERARCHICAL SUPERVISORY CONTROL OF COMPLEX PETRI NETS BY NISHA SOMNATH THESIS Submitted in partial fulfillment of the requirements for the degree of Master of Science in Aerospace

More information

On Computing Supply Chain Scheduling Using Max-Plus Algebra

On Computing Supply Chain Scheduling Using Max-Plus Algebra Applied Mathematical Sciences, Vol. 10, 2016, no. 10, 477-486 HIKARI Ltd, www.m-hikari.com http://dx.doi.org/10.12988/ams.2016.618 On Computing Supply Chain Scheduling Using Max-Plus Algebra Subiono Department

More information

On the Complexity of Mapping Pipelined Filtering Services on Heterogeneous Platforms

On the Complexity of Mapping Pipelined Filtering Services on Heterogeneous Platforms On the Complexity of Mapping Pipelined Filtering Services on Heterogeneous Platforms Anne Benoit, Fanny Dufossé and Yves Robert LIP, École Normale Supérieure de Lyon, France {Anne.Benoit Fanny.Dufosse

More information

Clock-driven scheduling

Clock-driven scheduling Clock-driven scheduling Also known as static or off-line scheduling Michal Sojka Czech Technical University in Prague, Faculty of Electrical Engineering, Department of Control Engineering November 8, 2017

More information

The Stability Problem for Discrete Event Dynamical Systems Modeled with timed Petri Nets Using a Lyapunov-Max-Plus Algebra Approach

The Stability Problem for Discrete Event Dynamical Systems Modeled with timed Petri Nets Using a Lyapunov-Max-Plus Algebra Approach International Mathematical Forum, Vol. 6, 2011, no. 11, 541-556 The Stability Problem for Discrete Event Dynamical Systems Modeled with timed Petri Nets Using a Lyapunov-Max-Plus Algebra Approach Zvi Retchkiman

More information

Integer programming: an introduction. Alessandro Astolfi

Integer programming: an introduction. Alessandro Astolfi Integer programming: an introduction Alessandro Astolfi Outline Introduction Examples Methods for solving ILP Optimization on graphs LP problems with integer solutions Summary Introduction Integer programming

More information

Recoverable Robustness in Scheduling Problems

Recoverable Robustness in Scheduling Problems Master Thesis Computing Science Recoverable Robustness in Scheduling Problems Author: J.M.J. Stoef (3470997) J.M.J.Stoef@uu.nl Supervisors: dr. J.A. Hoogeveen J.A.Hoogeveen@uu.nl dr. ir. J.M. van den Akker

More information

EDF Scheduling. Giuseppe Lipari May 11, Scuola Superiore Sant Anna Pisa

EDF Scheduling. Giuseppe Lipari   May 11, Scuola Superiore Sant Anna Pisa EDF Scheduling Giuseppe Lipari http://feanor.sssup.it/~lipari Scuola Superiore Sant Anna Pisa May 11, 2008 Outline 1 Dynamic priority 2 Basic analysis 3 FP vs EDF 4 Processor demand bound analysis Generalization

More information

Railway Timetable Stability Analysis Using Stochastic Max-Plus Linear Systems

Railway Timetable Stability Analysis Using Stochastic Max-Plus Linear Systems Railway Timetable Stability Analysis Using Stochastic Max-Plus Linear Systems Rob M.P. Goverde 1, Bernd Heidergott 2, Glenn Merlet 3 1 Delft University of Technology, Department Transport & Planning Stevinweg

More information

OPTIMAL INPUT SIGNAL DESIGN FOR IDENTIFICATION OF MAX PLUS LINEAR SYSTEMS

OPTIMAL INPUT SIGNAL DESIGN FOR IDENTIFICATION OF MAX PLUS LINEAR SYSTEMS OPTIMAL INPUT SIGNAL DESIGN FOR IDENTIFICATION OF MAX PLUS LINEAR SYSTEMS Gernot Schullerus, Volker Krebs, Bart De Schutter, Ton van den Boom Institut für Regelungs- und Steuerungssysteme, Universität

More information

Randomly switching max-plus linear systems and equivalent classes of discrete event systems

Randomly switching max-plus linear systems and equivalent classes of discrete event systems Delft University of Technology Delft Center for Systems and Control Technical report 8-8 Randomly switching max-plus linear systems and equivalent classes of discrete event systems T. van den Boom and

More information

The Simplex Method: An Example

The Simplex Method: An Example The Simplex Method: An Example Our first step is to introduce one more new variable, which we denote by z. The variable z is define to be equal to 4x 1 +3x 2. Doing this will allow us to have a unified

More information

2.6 Complexity Theory for Map-Reduce. Star Joins 2.6. COMPLEXITY THEORY FOR MAP-REDUCE 51

2.6 Complexity Theory for Map-Reduce. Star Joins 2.6. COMPLEXITY THEORY FOR MAP-REDUCE 51 2.6. COMPLEXITY THEORY FOR MAP-REDUCE 51 Star Joins A common structure for data mining of commercial data is the star join. For example, a chain store like Walmart keeps a fact table whose tuples each

More information

1 Algebraic Methods. 1.1 Gröbner Bases Applied to SAT

1 Algebraic Methods. 1.1 Gröbner Bases Applied to SAT 1 Algebraic Methods In an algebraic system Boolean constraints are expressed as a system of algebraic equations or inequalities which has a solution if and only if the constraints are satisfiable. Equations

More information

Spectral Properties of Matrix Polynomials in the Max Algebra

Spectral Properties of Matrix Polynomials in the Max Algebra Spectral Properties of Matrix Polynomials in the Max Algebra Buket Benek Gursoy 1,1, Oliver Mason a,1, a Hamilton Institute, National University of Ireland, Maynooth Maynooth, Co Kildare, Ireland Abstract

More information

Alternative Characterization of Ergodicity for Doubly Stochastic Chains

Alternative Characterization of Ergodicity for Doubly Stochastic Chains Alternative Characterization of Ergodicity for Doubly Stochastic Chains Behrouz Touri and Angelia Nedić Abstract In this paper we discuss the ergodicity of stochastic and doubly stochastic chains. We define

More information

Max-Consensus in a Max-Plus Algebraic Setting: The Case of Fixed Communication Topologies

Max-Consensus in a Max-Plus Algebraic Setting: The Case of Fixed Communication Topologies Max-Consensus in a Max-Plus Algebraic Setting: The Case of Fixed Communication Topologies Behrang Monajemi Nejad, Sid Ahmed Attia and Jörg Raisch Control Systems Group ( Fachgebiet Regelungssysteme ),

More information

An approximation method for computing the expected value of max-affine expressions

An approximation method for computing the expected value of max-affine expressions Delft University of Technology Delft Center for Systems and Control Technical report 15-034 An approximation method for computing the expected value of max-affine expressions S.S. Farahani, T. van den

More information

Control of manufacturing systems using state feedback and linear programming

Control of manufacturing systems using state feedback and linear programming Proceedings of the 44th IEEE Conference on Decision and Control, and the European Control Conference 2005 Seville, Spain, December 12-15, 2005 WeA15.2 Control of manufacturing systems using state feedback

More information

Zero controllability in discrete-time structured systems

Zero controllability in discrete-time structured systems 1 Zero controllability in discrete-time structured systems Jacob van der Woude arxiv:173.8394v1 [math.oc] 24 Mar 217 Abstract In this paper we consider complex dynamical networks modeled by means of state

More information

Chapter 7 Network Flow Problems, I

Chapter 7 Network Flow Problems, I Chapter 7 Network Flow Problems, I Network flow problems are the most frequently solved linear programming problems. They include as special cases, the assignment, transportation, maximum flow, and shortest

More information

Modeling and Control for (max, +)-Linear Systems with Set-Based Constraints

Modeling and Control for (max, +)-Linear Systems with Set-Based Constraints 2015 IEEE International Conference on Automation Science and Engineering (CASE) Aug 24-28, 2015. Gothenburg, Sweden Modeling and Control for (max, +)-Linear Systems with Set-Based Constraints Xavier David-Henriet

More information

Intrinsic products and factorizations of matrices

Intrinsic products and factorizations of matrices Available online at www.sciencedirect.com Linear Algebra and its Applications 428 (2008) 5 3 www.elsevier.com/locate/laa Intrinsic products and factorizations of matrices Miroslav Fiedler Academy of Sciences

More information

MATRICES. a m,1 a m,n A =

MATRICES. a m,1 a m,n A = MATRICES Matrices are rectangular arrays of real or complex numbers With them, we define arithmetic operations that are generalizations of those for real and complex numbers The general form a matrix of

More information

Event driven manufacturing systems as time domain control systems

Event driven manufacturing systems as time domain control systems Proceedings of the 44th IEEE Conference on Decision and Control, and the European Control Conference 2005 Seville, Spain, December 12-15, 2005 MoA135 Event driven manufacturing systems as time domain control

More information

Time stealing: An adventure in tropical land

Time stealing: An adventure in tropical land 1/ 21 Time stealing: An adventure in tropical land Marianne Johnson Manchester, 16th November 2010 2/ 21 Time stealing: An adventure in tropical land For Dave on the occasion of his 60th Birthday (with

More information

Matrix factorization and minimal state space realization in the max-plus algebra

Matrix factorization and minimal state space realization in the max-plus algebra KULeuven Department of Electrical Engineering (ESAT) SISTA Technical report 96-69 Matrix factorization and minimal state space realization in the max-plus algebra B De Schutter and B De Moor If you want

More information

Receding-horizon control for max-plus linear systems with discrete actions using optimistic planning

Receding-horizon control for max-plus linear systems with discrete actions using optimistic planning Delft University of Technology Receding-horizon control for max-plus linear systems with discrete actions using optimistic planning Xu, Jia; Busoniu, L; van den Boom, Ton; De Schutter, Bart DOI 10.1109/WODES.2016.7497879

More information

Johns Hopkins Math Tournament Proof Round: Automata

Johns Hopkins Math Tournament Proof Round: Automata Johns Hopkins Math Tournament 2018 Proof Round: Automata February 9, 2019 Problem Points Score 1 10 2 5 3 10 4 20 5 20 6 15 7 20 Total 100 Instructions The exam is worth 100 points; each part s point value

More information

Modeling and control of switching max-plus-linear systems with random and deterministic switching

Modeling and control of switching max-plus-linear systems with random and deterministic switching Discrete Event Dyn Syst 2012 22:293 332 DOI 10.1007/s10626-011-0123-x Modeling and control of switching max-plus-linear systems with random and deterministic switching TonJ.J.vandenBoom Bart De Schutter

More information

arxiv: v1 [cs.cr] 20 Dec 2012

arxiv: v1 [cs.cr] 20 Dec 2012 Modeling and Performance Evaluation of Computer Systems Security Operation D. Guster N. K. Krivulin arxiv:1212.5289v1 [cs.cr] 20 Dec 2012 Abstract A model of computer system security operation is developed

More information

Session-Based Queueing Systems

Session-Based Queueing Systems Session-Based Queueing Systems Modelling, Simulation, and Approximation Jeroen Horters Supervisor VU: Sandjai Bhulai Executive Summary Companies often offer services that require multiple steps on the

More information

Delay management with capacity considerations.

Delay management with capacity considerations. Bachelor Thesis Econometrics Delay management with capacity considerations. Should a train wait for transferring passengers or not, and which train goes first? 348882 1 Content Chapter 1: Introduction...

More information

Decentralized Stabilization of Heterogeneous Linear Multi-Agent Systems

Decentralized Stabilization of Heterogeneous Linear Multi-Agent Systems 1 Decentralized Stabilization of Heterogeneous Linear Multi-Agent Systems Mauro Franceschelli, Andrea Gasparri, Alessandro Giua, and Giovanni Ulivi Abstract In this paper the formation stabilization problem

More information

Model predictive control for max-plus-linear systems via optimistic optimization

Model predictive control for max-plus-linear systems via optimistic optimization Delft University of Technology Delft Center for Systems and Control Technical report 14-09 Model predictive control for max-plus-linear systems via optimistic optimization J. Xu, B. De Schutter, and T.J.J.

More information

SEQUENTIAL AND SIMULTANEOUS LIFTING IN THE NODE PACKING POLYHEDRON JEFFREY WILLIAM PAVELKA. B.S., Kansas State University, 2011

SEQUENTIAL AND SIMULTANEOUS LIFTING IN THE NODE PACKING POLYHEDRON JEFFREY WILLIAM PAVELKA. B.S., Kansas State University, 2011 SEQUENTIAL AND SIMULTANEOUS LIFTING IN THE NODE PACKING POLYHEDRON by JEFFREY WILLIAM PAVELKA B.S., Kansas State University, 2011 A THESIS Submitted in partial fulfillment of the requirements for the degree

More information

Distributed Randomized Algorithms for the PageRank Computation Hideaki Ishii, Member, IEEE, and Roberto Tempo, Fellow, IEEE

Distributed Randomized Algorithms for the PageRank Computation Hideaki Ishii, Member, IEEE, and Roberto Tempo, Fellow, IEEE IEEE TRANSACTIONS ON AUTOMATIC CONTROL, VOL. 55, NO. 9, SEPTEMBER 2010 1987 Distributed Randomized Algorithms for the PageRank Computation Hideaki Ishii, Member, IEEE, and Roberto Tempo, Fellow, IEEE Abstract

More information

MULTIPLE CHOICE QUESTIONS DECISION SCIENCE

MULTIPLE CHOICE QUESTIONS DECISION SCIENCE MULTIPLE CHOICE QUESTIONS DECISION SCIENCE 1. Decision Science approach is a. Multi-disciplinary b. Scientific c. Intuitive 2. For analyzing a problem, decision-makers should study a. Its qualitative aspects

More information

EDF Scheduling. Giuseppe Lipari CRIStAL - Université de Lille 1. October 4, 2015

EDF Scheduling. Giuseppe Lipari  CRIStAL - Université de Lille 1. October 4, 2015 EDF Scheduling Giuseppe Lipari http://www.lifl.fr/~lipari CRIStAL - Université de Lille 1 October 4, 2015 G. Lipari (CRIStAL) Earliest Deadline Scheduling October 4, 2015 1 / 61 Earliest Deadline First

More information

arxiv: v2 [math.oc] 8 Jan 2018

arxiv: v2 [math.oc] 8 Jan 2018 A discrete event traffic model explaining the traffic phases of the train dynamics in a metro line system with a junction Florian Schanzenbächer 1, Nadir Farhi 2, Zoi Christoforou 3, Fabien Leurent 3,

More information

No class on Thursday, October 1. No office hours on Tuesday, September 29 and Thursday, October 1.

No class on Thursday, October 1. No office hours on Tuesday, September 29 and Thursday, October 1. Stationary Distributions Monday, September 28, 2015 2:02 PM No class on Thursday, October 1. No office hours on Tuesday, September 29 and Thursday, October 1. Homework 1 due Friday, October 2 at 5 PM strongly

More information

Transfer Line Balancing Problem

Transfer Line Balancing Problem Transfer Line Balancing Problem Transfer Line Balancing Problem (TLBP) was introduced in [3] In comparison with the well-known assembly line balancing problems, TLBP has many new assumptions reflecting

More information

Petri nets analysis using incidence matrix method inside ATOM 3

Petri nets analysis using incidence matrix method inside ATOM 3 Petri nets analysis using incidence matrix method inside ATOM 3 Alejandro Bellogín Kouki Universidad Autónoma de Madrid alejandro. bellogin @ uam. es June 13, 2008 Outline 1 Incidence matrix Tools 2 State

More information

Numerical Linear Algebra

Numerical Linear Algebra Chapter 3 Numerical Linear Algebra We review some techniques used to solve Ax = b where A is an n n matrix, and x and b are n 1 vectors (column vectors). We then review eigenvalues and eigenvectors and

More information

NUMERICAL MATHEMATICS & COMPUTING 7th Edition

NUMERICAL MATHEMATICS & COMPUTING 7th Edition NUMERICAL MATHEMATICS & COMPUTING 7th Edition Ward Cheney/David Kincaid c UT Austin Engage Learning: Thomson-Brooks/Cole wwwengagecom wwwmautexasedu/cna/nmc6 October 16, 2011 Ward Cheney/David Kincaid

More information

Analysis of Algorithms. Unit 5 - Intractable Problems

Analysis of Algorithms. Unit 5 - Intractable Problems Analysis of Algorithms Unit 5 - Intractable Problems 1 Intractable Problems Tractable Problems vs. Intractable Problems Polynomial Problems NP Problems NP Complete and NP Hard Problems 2 In this unit we

More information

Clojure Concurrency Constructs, Part Two. CSCI 5828: Foundations of Software Engineering Lecture 13 10/07/2014

Clojure Concurrency Constructs, Part Two. CSCI 5828: Foundations of Software Engineering Lecture 13 10/07/2014 Clojure Concurrency Constructs, Part Two CSCI 5828: Foundations of Software Engineering Lecture 13 10/07/2014 1 Goals Cover the material presented in Chapter 4, of our concurrency textbook In particular,

More information

Introduction to integer programming III:

Introduction to integer programming III: Introduction to integer programming III: Network Flow, Interval Scheduling, and Vehicle Routing Problems Martin Branda Charles University in Prague Faculty of Mathematics and Physics Department of Probability

More information

Distributed model predictive control for railway traffic management

Distributed model predictive control for railway traffic management Delft University of Technology Delft Center for Systems and Control Technical report 16-013 Distributed model predictive control for railway traffic management B. Kersbergen, T. van den Boom, and B. De

More information

Model predictive control for stochastic switching max-plus-linear systems

Model predictive control for stochastic switching max-plus-linear systems Delft University of Technology Delft Center for Systems and Control Technical report 12-025 Model predictive control for stochastic switching max-plus-linear systems S. van Loenhout, T. van den Boom, S.

More information

Overview. Discrete Event Systems Verification of Finite Automata. What can finite automata be used for? What can finite automata be used for?

Overview. Discrete Event Systems Verification of Finite Automata. What can finite automata be used for? What can finite automata be used for? Computer Engineering and Networks Overview Discrete Event Systems Verification of Finite Automata Lothar Thiele Introduction Binary Decision Diagrams Representation of Boolean Functions Comparing two circuits

More information

Lecture 12 (Tue, Mar 5) Gaussian elimination and LU factorization (II)

Lecture 12 (Tue, Mar 5) Gaussian elimination and LU factorization (II) Math 59 Lecture 2 (Tue Mar 5) Gaussian elimination and LU factorization (II) 2 Gaussian elimination - LU factorization For a general n n matrix A the Gaussian elimination produces an LU factorization if

More information

Totally unimodular matrices. Introduction to integer programming III: Network Flow, Interval Scheduling, and Vehicle Routing Problems

Totally unimodular matrices. Introduction to integer programming III: Network Flow, Interval Scheduling, and Vehicle Routing Problems Totally unimodular matrices Introduction to integer programming III: Network Flow, Interval Scheduling, and Vehicle Routing Problems Martin Branda Charles University in Prague Faculty of Mathematics and

More information

Time and Schedulability Analysis of Stateflow Models

Time and Schedulability Analysis of Stateflow Models Time and Schedulability Analysis of Stateflow Models Marco Di Natale Scuola Superiore S. Anna Haibo Zeng Mc Gill University Outline Context: MBD of Embedded Systems Relationship with PBD An Introduction

More information

Numerical Analysis Lecture Notes

Numerical Analysis Lecture Notes Numerical Analysis Lecture Notes Peter J Olver 8 Numerical Computation of Eigenvalues In this part, we discuss some practical methods for computing eigenvalues and eigenvectors of matrices Needless to

More information

R u t c o r Research R e p o r t. The Optimization of the Move of Robot Arm by Benders Decomposition. Zsolt Robotka a RRR , DECEMBER 2005

R u t c o r Research R e p o r t. The Optimization of the Move of Robot Arm by Benders Decomposition. Zsolt Robotka a RRR , DECEMBER 2005 R u t c o r Research R e p o r t The Optimization of the Move of Robot Arm by Benders Decomposition Zsolt Robotka a Béla Vizvári b RRR 43-2005, DECEMBER 2005 RUTCOR Rutgers Center for Operations Research

More information

On The Best Principal. Submatrix Problem

On The Best Principal. Submatrix Problem On The Best Principal Submatrix Problem by Seth Charles Lewis A thesis submitted to University of Birmingham for the degree of Doctor of Philosophy (PhD) School of Mathematics University of Birmingham

More information

Nikolai K. Krivulin. St.Petersburg State University

Nikolai K. Krivulin. St.Petersburg State University A MAX-ALGEBRA APPROACH TO MODELING AND SIMULATION OF TANDEM QUEUEING SYSTEMS Nikolai K Krivulin StPetersburg State University Abstract Max-algebra models of tandem single-server queueing systems with both

More information

Tutorial on Mathematical Induction

Tutorial on Mathematical Induction Tutorial on Mathematical Induction Roy Overbeek VU University Amsterdam Department of Computer Science r.overbeek@student.vu.nl April 22, 2014 1 Dominoes: from case-by-case to induction Suppose that you

More information

Gaussian Elimination -(3.1) b 1. b 2., b. b n

Gaussian Elimination -(3.1) b 1. b 2., b. b n Gaussian Elimination -() Consider solving a given system of n linear equations in n unknowns: (*) a x a x a n x n b where a ij and b i are constants and x i are unknowns Let a n x a n x a nn x n a a a

More information

(x 1 +x 2 )(x 1 x 2 )+(x 2 +x 3 )(x 2 x 3 )+(x 3 +x 1 )(x 3 x 1 ).

(x 1 +x 2 )(x 1 x 2 )+(x 2 +x 3 )(x 2 x 3 )+(x 3 +x 1 )(x 3 x 1 ). CMPSCI611: Verifying Polynomial Identities Lecture 13 Here is a problem that has a polynomial-time randomized solution, but so far no poly-time deterministic solution. Let F be any field and let Q(x 1,...,

More information

About closed-loop control and observability of max-plus linear systems: Application to manufacturing systems

About closed-loop control and observability of max-plus linear systems: Application to manufacturing systems About closed-loop control and observability of max-plus linear systems: Application to manufacturing systems Laurent Hardouin and Xavier David-Henriet perso-laris.univ-angers.fr/~hardouin/ ISTIA-LARIS,

More information

Tropical Optimization Framework for Analytical Hierarchy Process

Tropical Optimization Framework for Analytical Hierarchy Process Tropical Optimization Framework for Analytical Hierarchy Process Nikolai Krivulin 1 Sergeĭ Sergeev 2 1 Faculty of Mathematics and Mechanics Saint Petersburg State University, Russia 2 School of Mathematics

More information

COMPUTER SCIENCE TRIPOS

COMPUTER SCIENCE TRIPOS CST.2016.2.1 COMPUTER SCIENCE TRIPOS Part IA Tuesday 31 May 2016 1.30 to 4.30 COMPUTER SCIENCE Paper 2 Answer one question from each of Sections A, B and C, and two questions from Section D. Submit the

More information

Representations of All Solutions of Boolean Programming Problems

Representations of All Solutions of Boolean Programming Problems Representations of All Solutions of Boolean Programming Problems Utz-Uwe Haus and Carla Michini Institute for Operations Research Department of Mathematics ETH Zurich Rämistr. 101, 8092 Zürich, Switzerland

More information

CIS 4930/6930: Principles of Cyber-Physical Systems

CIS 4930/6930: Principles of Cyber-Physical Systems CIS 4930/6930: Principles of Cyber-Physical Systems Chapter 11 Scheduling Hao Zheng Department of Computer Science and Engineering University of South Florida H. Zheng (CSE USF) CIS 4930/6930: Principles

More information

Characterization of Semantics for Argument Systems

Characterization of Semantics for Argument Systems Characterization of Semantics for Argument Systems Philippe Besnard and Sylvie Doutre IRIT Université Paul Sabatier 118, route de Narbonne 31062 Toulouse Cedex 4 France besnard, doutre}@irit.fr Abstract

More information

How to deal with uncertainties and dynamicity?

How to deal with uncertainties and dynamicity? How to deal with uncertainties and dynamicity? http://graal.ens-lyon.fr/ lmarchal/scheduling/ 19 novembre 2012 1/ 37 Outline 1 Sensitivity and Robustness 2 Analyzing the sensitivity : the case of Backfilling

More information

CMSC 451: Lecture 7 Greedy Algorithms for Scheduling Tuesday, Sep 19, 2017

CMSC 451: Lecture 7 Greedy Algorithms for Scheduling Tuesday, Sep 19, 2017 CMSC CMSC : Lecture Greedy Algorithms for Scheduling Tuesday, Sep 9, 0 Reading: Sects.. and. of KT. (Not covered in DPV.) Interval Scheduling: We continue our discussion of greedy algorithms with a number

More information

arxiv: v2 [cs.dm] 2 Mar 2017

arxiv: v2 [cs.dm] 2 Mar 2017 Shared multi-processor scheduling arxiv:607.060v [cs.dm] Mar 07 Dariusz Dereniowski Faculty of Electronics, Telecommunications and Informatics, Gdańsk University of Technology, Gdańsk, Poland Abstract

More information

AUTOMORPHISM GROUPS AND SPECTRA OF CIRCULANT GRAPHS

AUTOMORPHISM GROUPS AND SPECTRA OF CIRCULANT GRAPHS AUTOMORPHISM GROUPS AND SPECTRA OF CIRCULANT GRAPHS MAX GOLDBERG Abstract. We explore ways to concisely describe circulant graphs, highly symmetric graphs with properties that are easier to generalize

More information

Non-Preemptive and Limited Preemptive Scheduling. LS 12, TU Dortmund

Non-Preemptive and Limited Preemptive Scheduling. LS 12, TU Dortmund Non-Preemptive and Limited Preemptive Scheduling LS 12, TU Dortmund 09 May 2017 (LS 12, TU Dortmund) 1 / 31 Outline Non-Preemptive Scheduling A General View Exact Schedulability Test Pessimistic Schedulability

More information

Lecture 4. 1 Circuit Complexity. Notes on Complexity Theory: Fall 2005 Last updated: September, Jonathan Katz

Lecture 4. 1 Circuit Complexity. Notes on Complexity Theory: Fall 2005 Last updated: September, Jonathan Katz Notes on Complexity Theory: Fall 2005 Last updated: September, 2005 Jonathan Katz Lecture 4 1 Circuit Complexity Circuits are directed, acyclic graphs where nodes are called gates and edges are called

More information

Planning and Scheduling of batch processes. Prof. Cesar de Prada ISA-UVA

Planning and Scheduling of batch processes. Prof. Cesar de Prada ISA-UVA Planning and Scheduling of batch processes Prof. Cesar de Prada ISA-UVA prada@autom.uva.es Outline Batch processes and batch plants Basic concepts of scheduling How to formulate scheduling problems Solution

More information

EE263 Review Session 1

EE263 Review Session 1 EE263 Review Session 1 October 5, 2018 0.1 Importing Variables from a MALAB.m file If you are importing variables given in file vars.m, use the following code at the beginning of your script. close a l

More information

Introduction into Vehicle Routing Problems and other basic mixed-integer problems

Introduction into Vehicle Routing Problems and other basic mixed-integer problems Introduction into Vehicle Routing Problems and other basic mixed-integer problems Martin Branda Charles University in Prague Faculty of Mathematics and Physics Department of Probability and Mathematical

More information

Using Markov Chains To Model Human Migration in a Network Equilibrium Framework

Using Markov Chains To Model Human Migration in a Network Equilibrium Framework Using Markov Chains To Model Human Migration in a Network Equilibrium Framework Jie Pan Department of Mathematics and Computer Science Saint Joseph s University Philadelphia, PA 19131 Anna Nagurney School

More information

Basic counting techniques. Periklis A. Papakonstantinou Rutgers Business School

Basic counting techniques. Periklis A. Papakonstantinou Rutgers Business School Basic counting techniques Periklis A. Papakonstantinou Rutgers Business School i LECTURE NOTES IN Elementary counting methods Periklis A. Papakonstantinou MSIS, Rutgers Business School ALL RIGHTS RESERVED

More information

REVISION SHEET DECISION MATHS 2 DECISION ANALYSIS

REVISION SHEET DECISION MATHS 2 DECISION ANALYSIS REVISION SHEET DECISION MATHS 2 DECISION ANALYSIS The main ideas are covered in AQA Edexcel MEI OCR D2 Before the exam you should know The meaning of the different kinds of node. Be able to construct a

More information

The Asynchronous t-step Approximation for Scheduling Batch Flow Systems

The Asynchronous t-step Approximation for Scheduling Batch Flow Systems Brigham Young University BYU ScholarsArchive All Theses and Dissertations 2016-06-01 The Asynchronous t-step Approximation for Scheduling Batch Flow Systems David R. Grimsman Brigham Young University Follow

More information

ON COST MATRICES WITH TWO AND THREE DISTINCT VALUES OF HAMILTONIAN PATHS AND CYCLES

ON COST MATRICES WITH TWO AND THREE DISTINCT VALUES OF HAMILTONIAN PATHS AND CYCLES ON COST MATRICES WITH TWO AND THREE DISTINCT VALUES OF HAMILTONIAN PATHS AND CYCLES SANTOSH N. KABADI AND ABRAHAM P. PUNNEN Abstract. Polynomially testable characterization of cost matrices associated

More information

Math 471 (Numerical methods) Chapter 3 (second half). System of equations

Math 471 (Numerical methods) Chapter 3 (second half). System of equations Math 47 (Numerical methods) Chapter 3 (second half). System of equations Overlap 3.5 3.8 of Bradie 3.5 LU factorization w/o pivoting. Motivation: ( ) A I Gaussian Elimination (U L ) where U is upper triangular

More information

TOPIC 2 Computer application for manipulating matrix using MATLAB

TOPIC 2 Computer application for manipulating matrix using MATLAB YOGYAKARTA STATE UNIVERSITY MATHEMATICS AND NATURAL SCIENCES FACULTY MATHEMATICS EDUCATION STUDY PROGRAM TOPIC 2 Computer application for manipulating matrix using MATLAB Definition of Matrices in MATLAB

More information

Lecture 20 : Markov Chains

Lecture 20 : Markov Chains CSCI 3560 Probability and Computing Instructor: Bogdan Chlebus Lecture 0 : Markov Chains We consider stochastic processes. A process represents a system that evolves through incremental changes called

More information

Toward the Resolution of Resource Conflict in a MPL-CCPM Representation Approach

Toward the Resolution of Resource Conflict in a MPL-CCPM Representation Approach Toward the Resolution of Resource Conflict in a MPL-CCPM Representation Approach MUNENORI KASAHARA Nagaoka University of Technology Nagaoka, Niigata 940-2188 JAPAN s063349@ics.nagaokaut.ac.jp HIROTAKA

More information