create and use a precomputed schedule of samples

* map-reduce algorithm to precompute the samples