Randomly Distributing A Pre-Determined Sum Over 12 Non-Contiguous Cells

HGLIII

New Member
Joined
Jun 19, 2019
Messages
14
Good Afternoon,

Does anyone know of a way to distribute a certain number (say 25,000,000) over a group of non-contiguous cells, while adhering to a floor, or minimum number, for each respective cell? Also, formulas in the past have been "biased" toward the upper-most positioned cells (so that the distribution falls unevenly, skewed toward the first 2 or 3 cells), so we would need to avoid that if possible.

Looking for something along the lines of:

Total Sum: 25,000,000
Minimum Increments: 100,000

1. 5,000,000
2. 7,500,000
3. 100,000
4. 1,300,000
5. 11,100,000
etc.

Thanks very much!

HGL

P.S. - I know some members have kindly offered their help in the past, but for some reason none of the suggestions seem to end up working. Perhaps this is impossible...
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
Good evening.

P.S. - I know some members have kindly offered their help in the past, but for some reason none of the suggestions seem to end up working. Perhaps this is impossible...
In that case it might have been helpful to say what you've already tried, and in what way it didn't work.

Anyway, here's one idea.

In A1 - Total Sum Value
In A2 - Minimum Increments Value

In B1
=rand()

Copy this down for however many values you want, let's say 5, so =rand() is in every cell in B1:B5.

In C1
Code:
=ROUND(A$1*(B1/SUM(B$1:B$5)),-LOG(A$2))
And copy down as far as required, in this case C1:C5.

Note that this won't ALWAYS sum exactly back to the Total Sum, because of the way that the rounding works.
A crude way to correct this would be to make one of the values be a simple differential between the sum of all the other values, and the Total Sum.
 
Last edited:
Upvote 0
Gerald, I implemented the overall formula and differential suggestion, and it worked beautifully - thank you very, very much!
 
Last edited:
Upvote 0

Forum statistics

Threads
1,213,494
Messages
6,113,981
Members
448,538
Latest member
alex78

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top