[Numpy-discussion] Combinations of objects (?)

Andrea Gavana andrea.gavana@gmail....
Mon Oct 20 04:20:05 CDT 2008

Hi All,

    this is probably a very silly question, but combinatorial math is
not exactly my strength and I am not even sure on how to formulate the
question. I apologize if it is a very elementary problem.
Let's suppose that I have 60 oil wells and 3 surface facilities. Every
well must be tied-in (linked, attached) to one and only one of these
surface facilities. No orphan well is allowed (i.e., a well not
attached to any surface unit) and no multi-links are allowed (i.e.,
one well attached to 2 or more units). Is there any simple way in
numpy (scipy?) in which I can get the number of possible combinations
of wells attached to the different 3 units, without repetitions? For
example, I could have all 60 wells attached to unit number 1, then 59
on unit 1 and 1 on unit 3 and so on...

Thank you for your suggestions.


"Imagination Is The Only Weapon In The War Against Reality."

More information about the Numpy-discussion mailing list