跳转至
\[ \newcommand{\bs}{\boldsymbol} \newcommand{\bsX}{\boldsymbol{X}} \newcommand{\bf}{\mathbf} \newcommand{\msc}{\mathscr} \newcommand{\mca}{\mathcal} \newcommand{\T}{\text{T}} \newcommand{\rme}{\mathrm{e}} \newcommand{\rmi}{\mathrm{i}} \newcommand{\rmj}{\mathrm{j}} \newcommand{\rmd}{\mathrm{d}} \newcommand{\rmm}{\mathrm{m}} \newcommand{\rmb}{\mathrm{b}} \newcommand{\and}{\land} \newcommand{\or}{\lor} \newcommand{\exist}{\exists} \newcommand{\sube}{\subseteq} \newcommand{\lr}[3]{\left#1 #2 \right#3} \newcommand{\intfy}{\int_{-\infty}^{+\infty}} \newcommand{\sumfy}[1]{\sum_{#1=-\infty}^{+\infty}} \newcommand{\vt}{\vartheta} \newcommand{\ve}{\varepsilon} \newcommand{\vp}{\varphi} \newcommand{\Var}{\text{Var}} \newcommand{\Cov}{\text{Cov}} \newcommand{\edef}{\xlongequal{def}} \newcommand{\prob}{\text{P}} \newcommand{\Exp}{\text{E}} \newcommand{\t}[1]{\text#1} \newcommand{\N}{\mathbb{N}} \newcommand{\Z}{\mathbb{Z}} \newcommand{\Q}{\mathbb{Q}} \newcommand{\R}{\mathbb{R}} \newcommand{\C}{\mathbb{C}} \newcommand{\versionofnewcommand}{\text{260125}} \]

Neurons and Mathematics

Leaky Integrate-and-Fire Model

首先, 该模型的合理性有个重要条件: 神经元的动作电位在形式上都差不多. 事实上, 正因为此, 神经信号并非依靠 spike 的形式传播, 而是作为 "events", 即考察它发生的时间序列.

书中给 "integrate-and-fire model" 作如下定义: Neuron models where action potentials are described as events, without attempt to describe the shape of an action potential.

Integrate-and-fire model 有两个重要的 components:

  1. 描述膜电位 \(u_i(t)\) 动态的方程: 一个一阶线性微分方程
  2. 生成 spike 的机制: 引入一个 threshold for spiking.

\(R-C\) Curcuit Analysis

接下来, 我们先讨论该线性偏微分方程的导出:

在生物学的视角: 对于每一个神经元, 传递神经信号的过程从突触后膜接受神经递质开始. 后膜的离子通道打开, 引发离子内流, 引起膜电位变化. 我们希望对该过程用数学方法建模. 考虑到:

  1. 携带离子通道的细胞膜的可视为电导/电阻 \(R\).
  2. 细胞膜上的钠钾泵等通道通过搬运电荷维持了静息电位, 上述的电阻也可以视为一个电源, 其电动势为静息电位 \(u_{rest}\), 内阻为 \(R\).
  3. 膜内外贴附不同正负电荷量的形态可视为电容 \(C\)

于是, 细胞膜可视为一个电源与电容串联的电路. 等价于一个零内阻的电源+电阻+电容, 即一个 \(R-C\) 电路; 或者说, 电源连着一个漏电 (leaky) 的电容器. 这也是更一般的表示形式. 值得思考的是, 电路中的 "导线" 是什么? 其实是细胞内/外液啦.

因此, 了解 \(R-C\) 电路的特征就很重要了.

将一个电流源的一侧电极连到细胞外液, 另一侧连到细胞内液, 给予 input 电流 \(I(t)\); 同时测定细胞内外的电势差 \(u(t)\) . 根据基尔霍夫定律, 应该有:

\[ I(t)=I_R+I_C=\frac{u(t)-u_{rest}}{R}+C\frac{\text{d}u}{\text{d}t} \]

设一个时间常数:

\[ \tau_m=R\cdot C\\ \Rightarrow \tau_m\cdot \frac{\text{d}u}{\text{d}t}=-[u(t)-u_{rest}]+RI(t) \]

在 Neuroscience 中, 该一阶线性微分方程称为 "the equation of passive membrane"

接下来, 我们解一下该微分方程. 为了方便, 设 \(V=u(t)-u_{rest}\), 且电流大小为定值 \(I\), 则原方程化为

\[ \begin{aligned} &&\tau_m\cdot\frac{\text{d}(V-RI)}{\text{d}t}(V-RI)&=-(V-RI)\\ \Leftrightarrow&\ &\frac{1}{V-RI}\cdot\text{d}(V-RI)&=-\frac{1}{\tau_m}\cdot\text{d}t\\ \Leftrightarrow&\ &V-RI&=e^{-t/\tau_m}\cdot \text{Const} \end{aligned} \]

根据初始条件, \(t=0\)\(V=0\), 解得 \(\text{Const}=-RI\). 于是:

\[ V=RI\cdot(1-e^{t/\tau_m}) \]

右边这一坨, 就是电流 \(I\) 在时间 \(t\) 内对电压做的贡献.

Impluse Current Input

如果当 \(t=t_0,\ V=V_0\) 时停止输入电流, 则

\[ \tau\cdot\frac{\text{d}V}{\text{d}t}=-V\\ \Rightarrow V=V_0\cdot e^{-(t-t_0)/\tau} \]

继续, 当 \(t=t_1,\ V=V_1\) 时, 输入恒定电流 \(I_1\), 直到 \(t=t_1^\prime,\ V=V_1^\prime\). 那么, 在 \(t_1< t < t_1^\prime\) 时, 电压升高:

\[ \begin{aligned} &&\frac{1}{V-RI_1}\cdot\text{d}(V-RI_1)&=-\frac{1}{\tau}\cdot\text{d}t\\ &\Leftrightarrow& \frac{V-RI_1}{V_1-RI_1}&=e^{-(t-t_1)/\tau}\\ &\Leftrightarrow& V&=({V_1-RI_1})\cdot e^{-(t-t_1)/\tau}+RI_1\\ \end{aligned} \]

进一步整理:

$$ \begin{aligned} V&=({V_1-RI_1})\cdot e^{-(t-t_1)/\tau_m}+RI_1\ &=V_1\cdot e^{-(t-t_1)/\tau_m}+RI_1\cdot(1-e^{-(t-t_1)/\tau_m})

\end{aligned} $$

可以分为两部分来看, \(V_1\cdot e^{-(t-t_1)/\tau_m}\) 是初始的电压 \(V_1\) 随时间自然衰减的结果, \(RI_1\cdot(1-e^{-(t-t_1)/\tau_m})\)\(V\) 初值为 \(0\) 时得到的解. 因此, 上述 "充电-放电-充电" 的循环中, 电压的计算具有一定的线性性质. 具体而言, 假设 \(t=0\) 时, 初始电压为 \(V_0\), 在 \(t=t_1,\cdots,t_k,\cdots\) 时分别给予时长为 \(\Delta_1,\cdots,\Delta_k,\cdots\) 的电流 \(I_1,\cdots,I_k,\cdots\) 进行充电. 设第 \(k\) 次充电完毕后的电压为 \(V_k\),

定义第 \(k\) 次充电对电压的贡献 \(U_k=RI_k(1-e^{-\Delta_k/\tau_m})\), 以及第 \(k\) 次充电结束的时间 \(t_k^\prime=t_k+\Delta_k\), 则:

\[ \begin{aligned} &&V_{k}&=V_{k-1}\cdot\exp(-\frac{t_k^\prime-t_{k-1}^\prime}{\tau_m})+U_k\\ \Leftrightarrow&& V_k\cdot \exp(t_{k}^\prime/\tau_m)&=V_{k-1}\cdot\exp(t_{k-1}^\prime/\tau_m)+U_k\cdot\exp(t_{k}^\prime/\tau_m)\\ \Leftrightarrow&& V_k\cdot \exp(t_{k}^\prime/\tau_m)-V_{k-1}\cdot\exp(t_{k-1}^\prime/\tau_m)&=U_k\cdot\exp(t_{k}^\prime/\tau_m) \end{aligned} \]

于是, 累加就有:

\[ V_k\cdot \exp(t_{k}^\prime/\tau_m)-V_0\cdot \exp(0/\tau_m)=\sum_{i=1}^{k}U_i\exp(t_i^\prime/\tau_m) \]

从而:

$$ \begin{aligned} V_k&=\sum_{i=1}^{k}U_i\exp\left(-\frac{t_k^\prime-t_i^\prime}{\tau_m}\right)+V_0\exp\left(\frac{-t_k^\prime}{\tau_m}\right)\

\end{aligned} $$

即, 计算第 \(k\) 次充电的电压, 可以视为先前每一次充电贡献的电压 \(U_i\) 随时间衰减的线性累加. 聪明的你应当可以看出, 这实际上已经有卷积的影子了.

进一步地, 如果每次充电都是个极短的脉冲, 即 \(\Delta \ll \tau_m\), 就有 \(1-\exp(-\Delta_k/\tau_m)=\Delta_k/\tau_m\). 因此,

\[ U_k=RI_k(1-e^{-\Delta_k/\tau_m})=RI_k\ \frac{\Delta_k}{\tau_m}\\ \]

\(I_k\Delta_k=Q_k\), 是每次脉冲输入的电荷量, \(R/\tau_m=1/C\), 就有

\[ U_k=RI_k\frac{\Delta_k}{\tau_m}=\frac{Q_k}{C} \]

这是非常合理的!

在实际的神经细胞中, 我们的确可以作这样的近似. 于是每一次脉冲输入都可以用 \(\delta\) 函数刻画.

\[ I(t)=q\ \delta(t) \]

对于单个脉冲的结果, 我们一般称为 impulse-response function 或者 Green's function:

\[ u(t)-u_{rest}=q\ \frac{R}{\tau_m}\ \exp(-\frac{t}{\tau_m}) \]

Threshold for Spike Firing

先进行一些名词与符号的定义.

"Firing Time" refers to the moment when a given neuron emits an action potential \(t^f\). And after \(t^f\), the potential is IMMEDIATELY reset to a new value \(u_r\).

\[ t^f:u(t^f)=\vartheta\\ \underset{\delta\to 0;\delta>0}{\lim}u(t^f+\delta)=u_r \]

在这之后, 电位的变化仍依据之前的 Leaky Integration 得出.

以上对 Threshold 的定义, 加上 Passive Membrane 的 Leaky Integration 方程, 构成了 Leaky Integrate-and-Fire Model.

进一步地, 我们还可以定义 Spike Train: 对于 neuron \(i\), 用 \(t_i^f,\ f=1,2,\cdots\) 来表示该 neuron 的若干 firing times.

\[ S_i(t)=\sum_f \delta(t-t_i^f) \]

这样, 就用一系列冲激函数表示了某个神经元发生 spike 的序列.

Time Dependent Input

如果 Input 电流不是常数, 而是随时间变化的, 该如何分析呢? 首先搬出之前讨论的一阶线性常微分方程: (先暂时忽略 threshold)

\[ \begin{aligned} &&\tau_m\cdot \frac{\text{d}u}{\text{d}t} &=-[u(t)-u_{rest}]+RI(t)\\ \Rightarrow &&\frac{\text{d}V}{\text{d}t}+\frac{1}{\tau_m}V &=\frac{R}{\tau_m}I(t)\\ \Rightarrow &&V &=\frac{R}{\tau_m}\int_{-\infty}^t I(s)\exp(-\frac{s}{\tau_m})\ \text{d}s \end{aligned} \]

习惯上, 我们对 \(I\) 做这样的改写: 将它 "翻转过来"

\[ V=\frac{R}{\tau_m}\int_0^{+\infty} I(t-s)\exp(-\frac{s}{\tau_m})\ \text{d}s \]

这下看懂了, 这就是卷积嘛. 还记得信号与系统中我们学到过, 卷积和一阶线性微分方程有很强的关联! (所以应该也能猜到后面要搞点 Fourier 变换了.)

接着, 尝试引入 threshold. 既然讨论的都是电流了, 就要从电流入手: 当 \(t^f\) 时刻电位达到 \(\vartheta\), 就会立刻触发一个 spike, 但 LIF model 中 spike 是被抽象为一个 \(t^f\) 代表的 "event", 而非电位的实际变化过程. 电位的改变只在 \(t^f+\delta\) 时刻, 从 \(\vartheta\to u_r\). 于是, threshold 可以用 \(t^f\) 时的电流表示. 记该电流为 reset current \(I_r\), 容易有:

\[ I_r(t)=-q_r\sum_f\delta(t-t^f)=-C(\vartheta-u_r)\cdot S(t)\\ \]

稍微思考一下负号的意义, 实际上它代表 "reset".

将 reset current 也加入微分方程得到的结果:

\[ V(t)=-\sum_f(\vartheta-u_r)\exp(-\frac{t-t^f}{\tau_m})+\frac{R}{\tau_m}\int_0^{+\infty} I(t-s)\exp(-\frac{s}{\tau_m})\ \text{d}s \]

这一大坨看起来复杂, 其实还蛮好理解的. 一个是 reset current 的衰减效应, 一个是 input current 与衰减函数的卷积, 仍然代表整体的衰减效应.

如果将 reset current 以积分表达写成连续的形式, 即:

\[ \begin{aligned} &\sum_f(u_r-\vartheta)\exp(-\frac{t-t^f}{\tau_m})\\ =&\sum_f\int_{0}^{+\infty}(u_r-\vartheta)\exp(-\frac{t-s}{\tau_m})\cdot \delta(s-t^f)\ \text{d}s\\ =&\int_{0}^{+\infty}(u_r-\vartheta)\exp(-\frac{t-s}{\tau_m})\cdot \sum_f\delta(s-t^f)\ \text{d}s\\ =&\int_{0}^{+\infty}(u_r-\vartheta)\exp(-\frac{t-s}{\tau_m})\cdot S(s)\ \text{d}s \end{aligned} \]

\[ \eta(t)=(u_r-\vartheta)\exp(-\frac{t}{\tau_m})\\ \kappa(t)=\frac{R}{\tau_m}\exp(-\frac{t}{\tau_m}) \]

则:

\[ V(t)=\int_0^{+\infty}\eta(s)S(t-s)\text{d}s+\int_0^{+\infty}\kappa(s)I(t-s)\text{d}s \]

\(\eta,\ \kappa\) 视为滤波器, 且不拘泥于指数衰减的形式, 就有了上述更具普遍性的结果. 其中, 第一项, filter η describes the reset of the membrane potential; 第二项, filter κ summarizes the linear electrical properties of the membrane. 关于这个模型的详细信息, 会在本书 Part Two 讨论.