摘要
提出基于误差位和小数位的乘积有效数字自动提取方法。该方法由相乘数据的有效位数决定乘积的误差位数,再由乘积的总位数与其误差位数求出乘积的有效位数,进而提取其有效数字。考虑到乘积在计算机中溢出和非溢出两种情况,采用乘积的整数位数和小数位数来计算乘积的总位数,乘积的小数位数由相乘数据的小数位数求出,乘积的整数位数通过计数的方法得到。理论分析表明,在任意情况下,两个有效数字相乘,其积的误差位数与两数中位数较大的有效数字位数相同。实验结果表明,有效数字提取算法能对计算机存储范围内的乘积有效数字进行正确、完整、有效地提取,且满足大学物理实验数据自动处理的要求。
Automatic extraction algorithm of significant digit of product based on error figures and decimal figures is proposed, in which the product error figures are decided by multiplication data, the product' s significant figures are evaluated from the product' s total figures and error figures, consequently, the significant digit of product can be completely extracted. Taking into account either overflow or non-overflow of product in the computer, the integer figures and decimal figures in product are considered to evaluate the product' s total figures. The product' s decimal figures are derived from the decimal figures of multiplication data, the product' s integer figures are counted out from the product. It is theoretically demonstrated that the error figures of product of two significant digits equal to the larger figures among the two significant digits in any case. Experimental result shows that the algorithm can extract product' s significant digit in the computer storage scope with correctness, completeness and effectiveness; the algorithm meets the requirement for automatic college physics experimental data processing.
出处
《计算机应用与软件》
CSCD
北大核心
2012年第8期294-296,共3页
Computer Applications and Software
基金
国家大学生创新性实验计划(G0920120029321)
浙江工业大学之江学院教学方法改革专项(1281000910)
关键词
乘积
乘积的误差位数
乘积的小数位数
乘积有效数字的自动提取
Product Product error figures Product decimal figures Automatic extraction of significant digit of product