Hi all,
Not sure if this is best done via excel solver, formula, or VBA, but I have the below problem:
A cell setting a maximum size, set in this example to '25'.
A set of numbers, which cannot be split, only combined, to fit into groups equaling 25, e.g.:
<colgroup><col width="64" style="width:48pt"> </colgroup><tbody>
</tbody>
In this case I'd like the numbers to be sorted into groups where they fit into 25 as best as possible, the desired set would be below:
<colgroup><col width="64" style="width:48pt"> </colgroup><tbody>
</tbody>
The top two rows = 25, as do rows 3 and 4, finally rows 5 and 6 equal 24. It is important that the numbers do not go over 25, but can be below, as long as they're the most efficient combination to do so.
If I have a list of say 100 numbers, the objective is to minimise the amount of times I have to divide them by 25, to have as few denominators as possible.
I am really unsure how to approach this one, any help would be greatly appreciated, thank you!!
Not sure if this is best done via excel solver, formula, or VBA, but I have the below problem:
A cell setting a maximum size, set in this example to '25'.
A set of numbers, which cannot be split, only combined, to fit into groups equaling 25, e.g.:
Size: |
10 |
11 |
15 |
14 |
7 |
17 |
<colgroup><col width="64" style="width:48pt"> </colgroup><tbody>
</tbody>
In this case I'd like the numbers to be sorted into groups where they fit into 25 as best as possible, the desired set would be below:
Size |
10 |
15 |
11 |
14 |
7 |
17 |
<colgroup><col width="64" style="width:48pt"> </colgroup><tbody>
</tbody>
The top two rows = 25, as do rows 3 and 4, finally rows 5 and 6 equal 24. It is important that the numbers do not go over 25, but can be below, as long as they're the most efficient combination to do so.
If I have a list of say 100 numbers, the objective is to minimise the amount of times I have to divide them by 25, to have as few denominators as possible.
I am really unsure how to approach this one, any help would be greatly appreciated, thank you!!