Re-implemented RNG for CUDA backend

closes #77