refs #10384 added couple of unit tests and perf test for new Algo

and couple of minor bugs discovered when running these tests.
Merge branch 'feature/10384_flatBackground' into develop