HPCC-12046 Ensure min/max activity are numerically sorted and include edges

Signed-off-by: Gavin Halliday <gavin.halliday@lexisnexis.com>