debug array indexing and median filter; faster array copying and summing; diagnostics
array better diagnostics
makefile -D's for debugging