add static rng, range, and fast loggamma.