\[K\left(k\right)=\frac{\pi}{2}\left(1+2\sum_{n=1}^{\infty}q^{n^{2}}\right)^{2},\]