Fixed math and population errors