fixed randsource2d

fixed randsource2d after speed fix