Suppose I have C
clusters and Q
elements to be randomly distributed into the C
clusters. We have to comply with the following restrictions:
- Each cluster has capacity, i.e a number representing the number of elements that can be allocated there
- Each cluster
c_k
has associated two positive numbersa_k
andb_k
, withk = 1, 2, ..., C
. And each elementq_j
has associated aw_j
positive number withj = 1, 2, ..., Q
. The elementq_j
can be allocated inc_k
if and only ifa_k <= w_j <= b_k
, for everyk, j
. - Solutions may not be found, so we have to raise an exception
For example suppose Q = 4
and C = 2
, with W = [1,2,1,2]
representing the w_j
values, andZ = [2, 2]
are the clusters capacity (each cluster can allocate 2 elements) and WT = [(0,2), (0,2)]
is the vector of restrictions on the clusters. In this case any 2-permutation of the 4 elements is a valid solution.
I am here to search for references of a similar problem.
Aucun commentaire:
Enregistrer un commentaire