A factory consists of m machines: M1, ..., Mm, and needs to process n jobs every day. Job j needs to be processed once by each machine in the order (Mj(1), ..., Mj(m)). Machine Mi takes time pij to process job j. A machine can only process one job at a time, and once a job is started on any machine, it must be processed to completion.
The objective is to minimize the sum of the completion times of all the jobs. Provide an integer programming formulation for this problem.