Given an integer c, the sequence a0,a1,a2,... is generated using the recurrence relation a0=c and ai=ai−1i+2021ai−1 for all i≥1. Given that a0=c, let f(c) be the smallest positive integer n such that an−1 is a multiple of 47. Compute k=1∑46f(k).