1. 把公式(1)中的变量a1a_1a​1​​、a2a_2a​2​​和常量分开来写

L(a1,a2)=i=1Nj=1NaiajyiyjK(xi,xj)i=1Nai1 \begin{aligned} L(a_1, a_2) = \sum_{i=1}^N\sum_{j=1}^Na_ia_jy_iy_jK(x_i, x_j) - \sum_{i=1}^Na_i && {1} \end{aligned}

为了简化公式,令:
f(i,j)=aiajyiyjK(xi,xj)2 \begin{aligned} f(i, j) = a_ia_jy_iy_jK(x_i,x_j) && {2} \end{aligned}

公式(1)简化为:
L(a1,a2)=i=1Nj=1Nf(i,j)i=1Nai3 \begin{aligned} L(a_1, a_2) = \sum_{i=1}^N\sum_{j=1}^Nf(i,j) - \sum_{i=1}^Na_i && {3} \end{aligned}

在公式(3)中,将a1a_1a2a_2是变量,其它参数a是常量,把公式(3)分成包含变量的部分和常量部分:
L(a1,a2)=f(1,1)+f(1,2)+j=3Nf(1,j)+f(2,1)+f(2,2)+j=3Nf(2,j)+i=3Nf(i,1)+i=3Nf(i,2)++i=3Nj=3Nf(i,j)a1a2i=3Nai4 \begin{aligned} L(a_1, a_2) = f(1,1)+f(1,2)+\sum_{j=3}^Nf(1,j) \\ +f(2,1)+f(2,2)+\sum_{j=3}^Nf(2,j) \\ +\sum_{i=3}^Nf(i,1)+\sum_{i=3}^Nf(i,2) + +\sum_{i=3}^N\sum_{j=3}^Nf(i,j) \\ -a_1 - a_2 - \sum_{i=3}^Na_i && {4} \end{aligned}

要L(a_1, a_2)对a_1和a_2求导,公式(4)中的常数部分对求导结果不影响,直接合并为一个不需要关心具体内容的常数项,得:
L(a1,a2)=f(1,1)+f(1,2)+j=3Nf(1,j)+f(2,1)+f(2,2)+j=3Nf(2,j)+i=3Nf(i,1)+i=3Nf(i,2)a1a2+5 \begin{aligned} L(a_1, a_2) = f(1,1)+f(1,2)+\sum_{j=3}^Nf(1,j) \\ +f(2,1)+f(2,2)+\sum_{j=3}^Nf(2,j) \\ +\sum_{i=3}^Nf(i,1)+\sum_{i=3}^Nf(i,2) \\ -a_1 - a_2 + \text{常数项}&& {5} \end{aligned}

根据f(i,j)的定义可知,f具有对称性,得:
L(a1,a2)=f(1,1)+2f(1,2)+f(2,2)+2j=3Nf(1,j)+2j=3Nf(2,j)a1a2+6 \begin{aligned} L(a_1, a_2) = f(1,1)+2f(1,2)+f(2,2) \\ +2\sum_{j=3}^Nf(1,j) +2\sum_{j=3}^Nf(2,j) \\ -a_1 - a_2 + \text{常数项}&& {6} \end{aligned}

results matching ""

    No results matching ""