Allocate projects to suppliers subject to overall threshold project aggregate value per supplier

Hello,

Need your help in solving the below problem:

  • A company has 50 projects. Each project has a project amount.

  • Company has a list of suppliers.

  • For any given supplier, the company has a threshold limit on the overall project amount that the supplier can handle called ‘Threshold’.

  • The total amount of projects that a supplier is associated should be less than the threshold value.

  • The goal is to allocate the projects to suppliers.

  • The number of projects can increase or decrease as well as the threshold value can change.

The data file ‘project-supplier-distribution.xlsx’ is attached. The excel file has 4 tabs:

  • threshold - overall sum of project amount per supplier (threshold) limit

  • suppliers - list of suppliers

  • project - the list of project, the project amounts. For each project, we need to find out the allotted supplier, cumulative project amount and total amount at the supplier level.

  • Sample-Result-Threshold-500 - The tab contains the solution for a threshold value of 500. In the tab, I have illustrated a possible loop logic to derive the result but not able to put it in Knime.

My guess is that we need to use:

  • Chunk loop to process each project

  • Chunk loop to allot each supplier

  • Recursive loop to compute and track the overall cumulative project value, assign the supplier and change the supplier once the threshold value is reached.

  • Flow variables for threshold value, current supplier, and cumulative project value

  • Flow variable Node or Widget to change the threshold value

project-supplier-distribution.xlsx