I've been playing with lots of Poisson sums lately, and I thought this one to be interesting: $$\sum_{k\in\mathbb{Z}}\left(\frac{1}{(k+x)\sinh{[(k+z)\pi q}]}-\frac{1}{\pi q (k+z)^2}\right)$$I want to find a closed form for this sum and its derivatives over $x$ when $x=0$ and $q=1$. Since its poles are of the form $k+\frac{in}{q}\,(k,n\text { integers})$ with double-order poles at the integers, I figure its expression may include trigonometric and theta functions...but I can't figure anything beyond its singularities. Any help would be appreciated.
I've managed to turn the sum into a Fourier series $\left(-4\sum_{k\ge 1}\ln(1+e^{-2k\pi/q})\cos{2k\pi z}-2\ln2\right)$, but even with its simplicity, I haven't been able to crack it.
(Edit) I think I have a way to evaluate the Fourier series: if I expand the cosines into Taylor series, then I just have to sum series of the form $$\sum_{k \ge 1}k^{2n}\ln(1+e^{-2k\pi/q})$$ which I can rewrite as $$\sum_{m\ge 1}\frac{(-1)^{m-1}}m\sum_{k\ge 1}k^{2n}e^{-2km\pi/q}$$and since $\displaystyle{\sum_{k\ge 1}e^{-2km\pi/q}=\frac1{e^{2m\pi/q}-1}}$, $\displaystyle{\sum_{k\ge 1}k^2e^{-2km\pi/q}=\frac14\frac{\cosh{\frac{m\pi}q}}{\sinh^3{\frac{m\pi}q}}}$ and subsequent sums consist of a hyperbolic cosine times an odd reciprocal polynomial in the hyperbolic sine, I've reduced my problem to evaluating sums of the form $$\sum_{m \ge 1}\frac{(-1)^{m-1}}m \frac{\cosh{\frac{m\pi}q}}{\sinh^{2n+1}{\frac{m\pi}q}}$$which is also $\displaystyle{\int{\sum_{k\ge 1}\frac{(-1)^{k-1}\sinh{kz}}{\sinh^{2n+1}{\frac{k\pi}q}}\, dz}}$ with $z=\frac{i\pi}q$. But here I am stuck.
I've found something promising: four theta functions I've been studying lately, \begin{align}\vartheta(z,q)&=q^{-1/2}\prod_{k\ge1}(1-e^{-2k\pi/q})(1+e^{-(2k-1)\pi/q+2i\pi z})(1+e^{-(2k-1)\pi/q-2i\pi z})\\ \theta(z,q)&=q^{-1/2}\prod_{k\ge1}(1-e^{-2k\pi/q})(1-e^{-(2k-1)\pi/q+2i\pi z})(1-e^{-(2k-1)\pi/q-2i\pi z})\\ \varphi(z,q)&=2q^{-1/2}e^{-\pi/(4q)}\sin\pi z\prod_{k\ge1}(1-e^{-2k\pi/q})(1-e^{-2k\pi/q+2i\pi z})(1-e^{-2k\pi/q-2i\pi z})\\ \phi(z,q)&=2q^{-1/2}e^{-\pi/(4q)}\cos\pi z\prod_{k\ge1}(1-e^{-2k\pi/q})(1+e^{-2k\pi/q+2i\pi z})(1+e^{-2k\pi/q-2i\pi z}) \end{align} satisfy useful quasi-periodic identities: \begin{align}\vartheta(z+k+in/q,q)&=e^{n^2\pi/q-2in\pi z}\vartheta(z,q)\\[1ex] \theta(z+k+in/q,q)&=(-1)^ne^{n^2\pi/q-2in\pi z}\theta(z,q)\\[1ex] \varphi(z+k+in/q,q)&=(-1)^{k+n}e^{n^2\pi/q-2in\pi z}\varphi(z,q)\\[1ex] \phi(z+k+in/q,q)&=(-1)^ke^{n^2\pi/q-2in\pi z}\phi(z,q) \end{align}thus with $[\vartheta',\theta',\varphi',\phi'](z,q)=\partial_z[\vartheta,\theta,\varphi,\phi](z,q)$, \begin{align}\vartheta'(k+in/q,q)&=-2in\pi e^{n^2\pi/q}\vartheta(0,q)\\[1ex] \theta'(k+in/q,q)&=-2in\pi(-1)^ne^{n^2\pi/q}\theta(0,q)\\[1ex] \varphi'(k+in/q,q)&=(-1)^{k+n}e^{n^2\pi/q}\varphi'(0,q)\\[1ex] \varphi''(k+in/q,q)&=(-1)^{k+n}\cdot-4in\pi e^{n^2\pi/q}\varphi'(0,q)\\[1ex] \phi'(k+in/q,q)&=-2in\pi(-1)^ke^{n^2\pi/q}\phi(0,q). \end{align} And my sum has poles at $x=-k+in/q$ with residues equal to $$\frac1{-in/q\cdot\pi q\cosh(-in\pi)}=\frac{i(-1)^n}{n\pi} (n\neq0),$$so it could feature $1/\varphi(z,q)$...and while I'd be tempted to guess the remaining poles would be covered by $\sin\pi z$, that won't produce the right denominator—but $\phi'(z,q)$ can! Specifically, I'll get $-2in\pi (-1)^ne^{2n^2\pi/q}(\varphi'\cdot\phi)(0,q)$ as the denominator, but I can cancel out the exponential by adding $\vartheta^2(z,q)$ to the numerator—leaving$$\frac{(-1)^{-n}\vartheta^2(0,q)}{-2in\pi\varphi'\phi(0,q)}=\frac i{2\pi}\frac{(-1)^n}n\frac{\vartheta^2}{\varphi'\phi}(0,q)$$ as my residue...
So my sum now may have the form$$2\frac{\varphi'\phi}{\vartheta^2}(0,q)\frac{\vartheta^2}{\varphi\phi'}(z,q)$$but I don't know if $\phi'(z,q)$ has any more zeros; and there's an additional series of double poles at the integers, but that's easy to resolve:$$\lim_{z\to n}2\frac{\varphi'\phi}{\vartheta^2}(0,q)(z-n)^2\frac{\vartheta^2}{\varphi\phi'}(z,q)=2\frac{\varphi'\phi}{\vartheta^2}(0,q)\frac{\vartheta^2}{\varphi'\phi''}(0,q)=2\frac\phi{\phi''}(0,q)$$I calculated the residues at the integers and got $0$ for all of them, so now I have \begin{align}2\frac{\varphi'\phi}{\vartheta^2}(0,q)\frac{\vartheta^2}{\varphi\phi'}(z,q)&=2\pi^2\frac\phi{\phi''}(0,q)\csc^2\pi z\\ &\quad+2\frac{\varphi'\phi}{\vartheta^2}(0,q)\sum_{k\in\mathbb Z\\n\ge1}\left(\frac1{z-k-in/q}\frac{\vartheta^2}{\varphi'\phi'}(k+in/q,q)+\frac1{z-k+in/q}\frac{\vartheta^2}{\varphi'\phi'}(k-in/q,q)\right)\\ &=2\pi^2\frac\phi{\phi''}(0,q)\csc^2\pi z\\ &+2\frac{\varphi'\phi}{\vartheta^2}(0,q)\sum_{k\in\mathbb Z\\n\ge1}\left(\frac1{z-k-in/q}\frac1{-2in\pi(-1)^n}\frac{\vartheta^2}{\varphi'\phi}(0,q)\\ \qquad+\frac1{z-k+in/q}\frac1{2in\pi(-1)^{-n}}\frac{\vartheta^2}{\varphi'\phi}(0,q)\right)\\ &=2\pi^2\frac\phi{\phi''}(0,q)\csc^2\pi z\\ &\quad+\frac i\pi\sum_{k\in\mathbb Z\\n\ge1}\frac{(-1)^n}n\frac{2in/q}{(z-k)^2+n^2/q^2}\\ &=2\pi^2\frac\phi{\phi''}(0,q)\csc^2\pi z\\ &\quad-\frac2{\pi q}\sum_{k\in\mathbb Z}\left(\frac{\pi q}{2(z-k)}\operatorname{csch}[\pi q(z-k)]-\frac1{2(z-k)^2}\right)\\ &=2\pi^2\frac\phi{\phi''}(0,q)\csc^2\pi z+\frac\pi q\csc^2\pi z-\sum_{k\in\mathbb Z}\frac1{(z+k)\sinh[\pi q(z+k)]}\end{align} There'll have to be an extra entire function (in $z$) in the final formulation to correct my result, since it fails at $z=1/2$: $$2\frac{\varphi'\phi}{\vartheta^2}(0,q)\frac{\vartheta^2}{\varphi'\phi}(1/2,q)\neq\frac\pi q+2\pi^2\frac\phi{\phi''}(0,q)-2\ln\frac\vartheta\phi(0,q/2)$$but I know that that extra function must be $1$-periodic and even...