Refs #8385 Refactor code to sum spectra.
Merge branch 'feature/8385_compiler_warnings' into develop