Fixed noise calculation and corresponding unit test