fixed the bug in parameter generation when number of years is more than 3