N, M = map(int,input().split()) mod = 10**9+7 for i in range(1, M+1): if i == 1: print(N) else: a = int((N+1)/i) if a < 2: print(0) elif N == a*i-1: print((pow(a, i-1, mod)*(a-1))%mod) else: print((pow(a, (1+a)*i-N-2, mod)*pow(a+1, N-a*i+1, mod)*(a-1))%mod)