# Thermodynamic Formalism in Neuronal Dynamics and Spike Train Statistics
## 4 Spiking Neuronal Network Models: The Leaky Integrate-and-Fire and Beyond
### Gibbs Distribution of the Discrete Lif Model  
Thanks to the integrated Equation (28) and because the integrated noise is Gaussian it is now easy to compute the probability that neuron \(k\) spikes at time \(n+1\)_given_ the history \(x\), \(P\left(\,x_{n+1}^{k}=1\,|\,x_{-\infty,n}\,\right)=P\left(\,V_{n+1}^{k}\geq\theta \,|\,x_{-\infty,n}\,\right)\):  
\[P\left(\,x_{n+1}^{k}=1\,|\,x_{-\infty,n}\,\right)=f\left(\,\frac{\theta-\sum_{ j=1}^{N}W_{kj}\eta_{kj}(n,x)-\sum_{l=\tau_{k}(x,n)}^{n}\gamma^{n-l}S_{l}^{k}}{ \sigma_{B}\sqrt{\frac{1-\gamma^{2(n+1-\tau_{k}(x,n))}}{1-\gamma^{2}}}}\,\right) \tag{29}\]  
where \(f(z)=\int_{z}^{+\infty}\,\frac{e^{-\frac{z^{2}}{2}}}{\sqrt{2\pi}}\,dz\). Here, we have used a small abuse of notation. The conditioning upon \(x_{-\infty,n}\) means, in fact, the conditioning upon the sequence \(x_{n-1,R(x)}\), where \(R(x)=\min\left\{\,k=1\ldots N|\tau_{k}(x,n)\,\right\}\). We condition upon the spike history prior to \(n\) back to the last time where all neurons had been reset at least once. While, for Equation (29). we just need to consider the history back to \(\tau_{k}(x,n)\), the conditioning upon \(x_{n-1,R(x)}\) is necessary when considering the conditional join probability of spiking patterns. The joint probability is conditionally independent given the past:  
\[P\left(\,x_{n+1}\,|\,x_{-\infty,n}\,\right)=\prod_{k=1}^{N}\left(\,x_{n+1}^{k} \,P\left(\,x_{n+1}^{k}=1\,|\,x_{-\infty,n}\,\right)+\left(\,1-x_{n+1}^{k}\, \right)\,\left(\,1-P\left(\,x_{n+1}^{k}=1\,|\,x_{-\infty,n}\,\right)\,\right) \,\right). \tag{30}\]  
Let us comment this result. Equation (30) is the transition probability, of the form (20), where the normalised Gibbs potential \(\phi\) can be explicitly written, in terms of the synaptic interactions and the parameter \(\sigma_{B}\) controlling the noise amplitude. However, note that, in contrast to (20), where the memory of the spike sequence was fixed independently of \(x\), here the memory depends of \(x\), providing a variable length Markov chain [115; 116]. Actually, \(R(x)\) is an unbounded function of \(x\) as one can find, for all \(r\in\left\{\,-\infty,n\,\right\}\), a sequence \(x\), such that \(R(x)=r\) (take the sequences where all \(x_{n}^{k}=0\), \(k=1\ldots N\), \(n>r\) and \(x_{r}^{k}=1\) for at least one \(k\)). Thus, we have to deal with the extension of Markov chains, to chains with unbounded memory introduced in Section 2.7. The existence and uniqueness of a Gibbs distribution compatible with this chain is guaranteed by the exponential decay of the memory controlled by \(\gamma<1\)[23]. In this case, the potential fulfills the conditions described in Section 2.7. Finally, in (30), the transition probabilities explicitly depend on time because of the stimulus dependent term. They are, therefore, not translation invariant. While the extension of Gibbs distributions to non time-translation invariant chains can be rigorously done (upon the exponential decay of memory [90]), we restrict ourselves now to the case without stimulus (\(S_{n}^{k}=0,\forall k=1\ldots N,n\in\mathbb{Z}\)) to apply Thermodynamic Formalism, until Section 4.5, where we discuss linear response.  
Note that (29) bares a strong resemblance to the GLM Ansatz (21).