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é-切比雪夫不等式;第二种方法基于鞅与Azuma-Hoeffding不等式。研究表明,对于成对求和,使用SR可使得前向误差的概率界与log(n)u成比例,而采用默认舍入模式时,前向误差的确定界为O(log(n)u)。我们考察了两种计算方差的算法,即"教科书"算法和"双遍"算法,两者均表现出非线性误差。通过上述两种方法,我们证明在SR下,这些算法前向误差的概率界为O($\sqrt$ nu),而确定界为nu。我们进一步表明,当使用成对求和实现教科书算法和双遍算法时,该优势依然成立,其前向误差的概率界与log(n)u成比例。