It should not fire an alert after one alert_after period, because that would be the same as alert_after = 0

I didn't like the inconsistency of having identical behavior between alert_after = 0 and alert_after = 20 at (occurrences=1, interval=20).

I also:
 * moved type coercions around so that the body of the logic is only ever dealing with integers
 * replaced floating point division by logic for detecting the zero case
 * wrapped lines