Hecke algebra of $(\mathrm{GL}(2, \mathbb{Q}), \mathrm{GL}(2, \mathbb{Z}))$

In the Wikipedia article about the Hecke algebra of a locally compact group, it is noted that if we take $$(\mathrm{GL}(2, \mathbb{Q}), \mathrm{GL}(2, \mathbb{Z}))$$ as the pair $$(G,K)$$ of a unimodular locally compact topological group $$G$$ and a closed subgroup $$K$$ of $$G$$ and then look at its Hecke algebra, as in the space of bi-$$K$$-invariant continuous function of compact support $$C_c(G)_K$$, we get the usual Hecke algebra generated by the Hecke operators in the theory of modular forms.

Why is that? I get that there is some connection between the "double coset"-construction of the Hecke algebra of modular forms and the biinvariance of such functions, but I can not quite see the link between the maps $$T_n: \mathbb{S}^k(\Gamma) \to \mathbb{S}^k(\Gamma)$$ and biinvariant maps $$f: G \to \mathbb{C}$$ with compact support.

I know that there are similar questions on MSE, but most of them refer specifically to an adelic setting, and I think it should be possible to understand this connection without talking about adeles. Thank you in advance!

• What is the topology on $GL_2(\Bbb{Q})$? Take a "compactly supported" bi-$SL_2(\Bbb{Z})$ invariant subset $S\subset SL_2(\Bbb{Q})$, write it as $S=\bigcup_{j=1}^J \gamma_j SL_2(\Bbb{Z})$, then $A f=\sum_{j=1}^J f|_k \gamma_j$ is in the algebra generated by the Hecke operators $M_k(SL_2(\Bbb{Z}))\to M_k(SL_2(\Bbb{Z}))$. You obtain $T_p$ from $S = SL_2(\Bbb{Z})\pmatrix{p&0\\ 0&1}SL_2(\Bbb{Z})$. Commented Dec 14, 2021 at 23:41
• I probably do not have a deep enough understanding of this topic, but why do we immediately see that $\sum_{j=1}^{J} f|_{k} \gamma_j$ is in the algebra generated by the Hecke operators? Moreover, for your given $S$, how do we see that we get exactly those $\gamma_j$'s that give us the Hecke operators back? It would be great if you could elaborate your argument a little. Commented Dec 15, 2021 at 23:14

This is worked out in detail in my lecture notes "Modular forms and representations of GL(2)", https://warwick.ac.uk/fac/sci/maths/people/staff/david_loeffler/teaching/tcc-gl2/. See Lecture 5 in particular, section 6.2, for the dictionary between the representation-theoretic and classical definition of the Hecke op $$T_p$$.