> # produce all possible combinations of rind and cind as > # indices into an equivalent flattened for a > indices = add.outer(rind*a.shape[1],cind).flat > put(a, indices, b.flat) > Whoops! I suppose that should be: put(a.flat, indices, b.flat)