# Hecke Operator- sum over divisors of a number

I am trying to write out the Hecke Operator; however, I don't know how to sum over all divisors of an integer. Could someone please give me some advice how to do that. Below is the Hecke Operator definition I use:

$$T_NZ(\tau)= \sum_{d|N}\sum_{\kappa=0}^{d-1}Z\left(\frac{N\tau/d +\kappa}{d}\right)$$

Many thanks!!

• E.g. Sum[f[d], {d, Divisors[122]] Jul 13, 2017 at 9:02
• Thank you!! I got it.. Jul 13, 2017 at 11:45

DivisorSum[] can be used for this:
hecke[f_, n_Integer?Positive, τ_] :=

hecke[KleinInvariantJ[τ], 3, τ]