As part of the production of masscustomization products, I have to solve the following problem. A fixed set of sequences (changes from one product to another) is associated with a percentage value of quality defects each. Now my goal is to find the optimal order (by minimizing the quality defects) in which to manufacture a fixed set of products in a particular week.
For example, I have to produce 4 different products (each manufactured X times): Changes from A to A leads in average to 5% scrap products. Change from Product A to B normally leads to 5 percent scrap parts, B to A to 10% scrap, B to C to 7.5% scrap and so on. As I stated above the overall objective would be to minimize the total scrap (error) products.
I'm unsure how to formulate this as an optimization problem properly. In university I heard something about the viterbi algorithm. Is this applicable here or how would I approach such a task?