added first-time random seeding to constructors