# Production Line Optimization in MATLAB

I'm trying to model a metal treatment process to improve its efficiency. We have 11 different components that all have to flow through the same process, but each component spends a different amount of time in each process. We are noticing a lot of downtime for certain machines, as components are going in at a random order, so we want to figure out the optimal order to put each component through the process. A flowchart for the process is shown below.

Ideally, we'd start one component on step 1 as soon as the previous component left step 1, so we'd have 6 components going at once, all on different steps. Most steps, as shown in the flowchart, can only be done on a single component at once. The complicating factor is that the treatment oven is used in both steps 2 and 5. There are two ovens, however 4 of our components will only fit in oven 1, while the other 7 fit in either oven. I have a model I developed that works on a process where each machine is only used in 1 step, but having the same machines used for 2 steps complicates this. I need to do this in MATLAB if at all possible.

Any suggestions on how to go about modeling this would be much appreciated!

• Can you extend this question by an example which includes the times in each step? Commented Jul 26 at 5:49
• ... also, what happen when, for example, the cooling room is blocked when a component finishes the oven? Will the component then stay in the oven? Will the component then be damaged? Or does that not happen, because required time in the oven is always larger than in the cooling room? We really need to see some numbers, I guess. Commented Jul 26 at 6:02
• I'll give an example with 5 parts for simplicity. I'll list the times in order of the steps: Part 1: 30min, 23min, 45min, 33min, 21min, 31min Part 2: 30min, 23min, 45min, 33min, 21min, 31min Part 3: 33min, 21min, 53min, 39min, 26min, 24min Part 4: 33min, 21min, 53min, 39min, 26min, 24min Part 5: 25min, 21min, 37min, 22min, 14min, 29min Note that some times are repeated Commented Jul 26 at 14:18
• The parts can stay in the oven as long as necessary for step 2. I.e. if it calls for 30 minutes it can stay for 45 minutes with no damage. But in step 5, they must be removed immediately when the time runs out. All other processes, it can wait in the previous step for as long as necessary without issues. Commented Jul 26 at 14:21
• Please edit your question to respond to comments. This is crucial information, but is difficult to find in a comment chain. Commented Jul 26 at 16:31