The main objective of this work is to investigate non-linear errors and pairwise summation using stochastic rounding (SR) in variance computation algorithms. We estimate the forward error of computations under SR through two methods: the first is based on a bound of the variance and Bienaym{\'e}-Chebyshev inequality, while the second is based on martingales and Azuma-Hoeffding inequality. The study shows that for pairwise summation, using SR results in a probabilistic bound of the forward error proportional to log(n)u rather than the deterministic bound in O(log(n)u) when using the default rounding mode. We examine two algorithms that compute the variance, called ''textbook'' and ''two-pass'', which both exhibit non-linear errors. Using the two methods mentioned above, we show that these algorithms' forward errors have probabilistic bounds under SR in O($\sqrt$ nu) instead of nu for the deterministic bounds. We show that this advantage holds using pairwise summation for both textbook and two-pass, with probabilistic bounds of the forward error proportional to log(n)u.
翻译:本研究的主要目标是探究方差计算算法中采用随机舍入(SR)时的非线性误差及成对求和问题。我们通过两种方法估计SR下的计算前向误差:第一种基于方差界与Bienaymé-Chebyshev不等式,第二种基于鞅论与Azuma-Hoeffding不等式。研究表明,对于成对求和而言,采用SR可获得与log(n)u成正比的前向误差概率界,而默认舍入模式下的确定性误差界为O(log(n)u)。我们考察了两种存在非线性误差的方差计算算法——"教科书算法"与"两遍扫描算法"。利用上述两种方法,我们证明在SR下这些算法的前向误差具有O($\sqrt$ nu)量级的概率界,而其确定性误差界为nu量级。进一步研究表明,当教科书算法与两遍扫描算法均采用成对求和时,该优势依然成立,此时前向误差的概率界与log(n)u成正比。