checked for degenerate case (minthresh == maxthresh) and disallowed.
fixes issue #1