implemented getNextInvalid to find the end of a valid time period
implemented getNextInvalid to find the end of a valid time period
fixed dayOfYear - issue #8