Well let's take a look at the dimensions of this table.
Every node participates in every step, so each step takes order of N work,
and we're doubling the hop count on each step, thus there's log of N steps,
so it takes N log N work to construct the entire table.
Note this is more expensive than the serial algorithm which takes linear work, order of N work.
However, the serial algorithm also takes N steps,
whereas, we're finishing N log N steps here.
那么让我们来看看这个表的维度。
每个节点都要参与到每一步,所以每一步需O(N)工作量,
我们现在将每一步的跃点计数增加了一倍,因此这是log N步,
所以需要花 N log N 工作量来构建整个表。
注意到这比串行算法代价更大,串行算法进行线性计算,O(N)工作量,
串行算法也需要 N 步,
然而我们在这里需要完成 N log N 步。