set z hours in a year / 1*8760 / alias (z,zz); scalar init stopping criteria ; init = 0; parameter a(z) number of days in january , b(z) add interval of 24 hours ; set u2(zz) feasible elements should equal to b(z) ; init = 0; a('1') = 1 ; b('1') = 2 ; loop(z $ (init ne 1) , a(z+1) = a(z) + 1; b(z+1) = b(z) + 24; u2(zz) $ (ord(zz)=b(z)) = yes ; init $ {a(z+1) eq 31} = 1; ) ; display a,b,u2;