# Finding an optimal machine assigning

I have $$m$$ machines and $$n$$ jobs. Each machine has a load capacity. Each job can be only handled by either one or two machine, and each job takes some time to finish. After it finished, new jobs can be assigned to that machine.

I am trying to find an optimal way to assign each job to each machine by sorting all the jobs by load capacity, after that filling jobs into each available machine. After all machine is assign, I will looking for the min of all the times to complete jobs. Then subtract it from all waiting time to find the next available machine.

So by this layout machine m1 will be assigned job a1, m2:a2, m3:b1, m4:a3, m5:empty, and m6:a4,b2,b3.

Is the a way to mathematically proof the optimal with respect to time? It's similar to job shop problem but instead of only there is only 1 machine of each kind, mine has many developers.google.com/optimization/scheduling/job_shop

• It's similar to job shop problem but instead of only there is only 1 machine of each kind, mine has many developers.google.com/optimization/scheduling/job_shop – Anh Dinh Apr 10 at 5:30
• There's a whole literature on scheduling and assignment problems. I suggest you do some reading. – Raphael Apr 10 at 5:58
• Note that programming is offtopic here. – Raphael Apr 10 at 5:58