标签:span line therefore bec 快速 because math inline 矩阵
易知,有\(S_n = \lceil{a + \sqrt{b}}\rceil ^ n\)
\(\because a ^ 2 - 1 < b < a ^ 2\)
\(\therefore a - \sqrt{b} \in [0, 1]\)
\(\therefore (a - \sqrt{b}) ^ n \in [0, 1]\)
\(\therefore \lceil{a + \sqrt{b}}\rceil ^ n = (a + \sqrt{b}) ^ n + (a - \sqrt{b}) ^ n\)
\(\therefore \lceil{a + \sqrt{b}}\rceil ^ n = x_1 ^ n + x_2 ^ n\)
\(\therefore 有特征方程: x ^ 2 - (x_1 + x_2) * x + x_1 * x_2 = 0\)
\(\therefore 此特征方程为 t ^ 2 - 2at + a ^ 2 - b = 0 的特征方程\)
\(\therefore 构造F_n = 2a * F_{n - 1} + (b - a ^ 2)F_{n - 2}, 矩阵快速幂即可。\)
标签:span line therefore bec 快速 because math inline 矩阵
原文地址:https://www.cnblogs.com/yangxuejian/p/12051469.html