What exactly is a theta function
$$\vartheta(z; \tau) = \sum_{n=-\infty}^\infty \exp (\pi i n^2 \tau + 2 \pi i n z)= 1 + 2 \sum_{n=1}^\infty \left(e^{\pi i\tau}\right)^{n^2} \cos(2\pi n z) = \sum_{n=-\infty}^\infty q^{n^2}\eta^n"$$
and how does it arise naturally? (as in how does it just fall out of a computation illustrating the necessity for taking the trouble to give it a name?). Books like Whittaker-Watson simply say Elliptic functions can be represented as quotients of theta functions, them apparently being useful for explicit computations, so surely there is a natural way to see why this is so without knowing them in advance?
Note: Not as interested in the number theory motivation, more the elliptic integrals/functions and mathematical physics motivation,
Some sources say they are just Fourier series (of what?), other sources say they are quotients of Fourier series, other sources define them as an infinite product (which apparently hints at periodicity implying a useful Fourier representation), Goursat just call's it a Laurent series (of what?). Other sources say it is the Fourier series of a periodic version of some un-understandable function $\sigma$ appearing in elliptic functions (which doesn't seem to have anything to do with how one defines the theta function anyway).
Thus, assuming a theta function is a (quotient of?) Fourier series, what is it a Fourier series of, and how does it arise naturally?