removed unused tests, added constants for bounds, static cast vs. C casts, all for poisson