Manufacturing Technology 2023, 23(4):551-556 | DOI: 10.21062/mft.2023.065
Research on Floating Point Accumulation Based on Improved Kahan Algorithm
- Institute of Robotics Engineering, Anhui Sanlian University, Hefei, China
In the actual factory production, there are often cases of liquid flow accumulation, and most of the controllers used in the project are PLC. Usually, the flow meter is used to measure the instantaneous flow, and then the analog (4-20mA) signal is transmitted to the PLC, and the PLC accumulates the cumulative flow within a certain period of time according to the instantaneous flow transmitted by the flow meter. Due to the floating point type of PLC, the direct accumulation will not reach the accuracy standard, and the cumulative error will occur. In order to eliminate the cumulative error, this paper proposes an improved algorithm based on Kahan 's algorithm. The improved algorithm greatly reduces the error of the cumulative flow than the original Kahan algorithm. The reduction of error is of great significance to the data analysis and production calculation of liquid or solid flow in the field of process industry control.
Keywords: Traffic accumulation, Kahan algorithm, pLC, Floating point number calculation, Reduce error
Grants and funding:
Research on prediction model of wound infection after lumbar fusion and internal fixation based on big data funded by the Education Department of Anhui Province in 2021, (KJ2021A1189). Research on Fatigue Driving Monitoring System Based on Machine Learning Education Department of Anhui Province in 2020 funded project for cultivating outstanding talents in colleges and universities (gxyq2020080). Major Project of Anhui Sanlian University Collaborative Center (ZJQR23001)
Received: May 24, 2023; Revised: August 9, 2023; Accepted: August 30, 2023; Prepublished online: August 30, 2023; Published: September 5, 2023 Show citation
References
- MOHAMED ASAN BASIRI, M., NOOR MAHAMMAD, S. K. An Efficient Hardware-Based Higher Radix Floating Point MAC Design. ACM Transactions on Design Automation of Electronic Systems, 2015, 20(1): 15:1-15:25.
Go to original source...
- RAO B.D. Floating point arithmetic and digital filters. IEEE Transactions on Signal Processing: A publication of the IEEE Signal Processing Society, 1992, 40(1): 85-95.
Go to original source...
- LIN CHAOPENG. Rounding error of PLC floating point number in flow accumulation and its avoidance method. 2014 Symposium on pressure processing equipment. 2014: 165-166, 76.
- ZENG B., NEUVO Y. Analysis of floating point round offerrors using dummy multiplier coefficient sensitivities. IEEE Transactions on Circuits and Systems, 1991, 38(6):590-601.
Go to original source...
- SHAO LIN, LIU CHANG, JI BOFENG, et al. Development and application of corrosion-resistant elbow flowmeter. Petrochemical automation, 2023, 59 (2):66-70.
- HE W, SHI J, SU T, et al. Automated test generation for IEC 61131-3 ST programs via dynamic symbolic execution. Science of Computer Programming, 2021, 206(1):102608.
Go to original source...
- WEIGANG HE, XIA MAO, TING SU, YANHONG HUANG, JIANQI SHI. Data Flow Testing for PLC Programs via Dynamic Symbolic Execution. 2021 28th Asia-Pacific Software Engineering Conference (APSEC), 2021:152-160
- H. SIMON AND S. KOWALEWSKI. Mode-Aware Concolic Testing for PLC Software. International Conference on Integrated Formal Methods. Springer, 2018:367-376.
Go to original source...
- YU ZHANG, JIECHANG WU, SHUO ZHANG, PAN SU. Design of ship pipeline diagnostic control system based on mass flow. 2019 IEEE 4th Advanced Information Technology, Electronic and Automation Control Conference (IAEAC). IEEE, 2019: 1718-1921.
Go to original source...
- WENJIN ZHOU, YANLONG WANG, et al. The invention relates to a method and a device for detecting the drainage flow rate of a hidden water tank. E3S Web of Conferences 236, 01043 (2021):1-3
Go to original source...
- LI XIAOLONG, LI WANPING, LIU HONGWANG, et al. Design and application of control system for water flow test device with standard meter method .Electromechanical technology of hydropower station, 2023, 6(2):58-60,128.
- JI GANG, SHEN CHUANGQIAN. Flow measurement of gas-containing liquids .Automatic instruments, 2023, 44(1): 1-7.
- MA LIHUI. Self-diagnosis and correction of abnormal gas flow in double-chamber kiln. Shanxi Metallurgy, 2022 (8): 178-180.
- ZHAO LUDONG. Discussion on the application of PLC in the reverse blowing system of negative pressure large bag filter. Journal of Liaoning University of Science and Technology, 2022, 24 (5): 22-24.
- WANG YANZHI, CAO ZHIQUAN, WU JIN. Application of ultrasonic flowmeter in thermal test. Automation and instrumentation, 2022 (6): 239-241.
- LIU CHANGSHENG. An online data recording method based on Siemens SIMATIC WinCC software. Metal processing (cold processing), 2022 (6):72-73.
- TAO YUAN. Flow accumulation using Kahan algorithm in PLC. Industrial control computer, 2018, 31(11): 139, 141.
- JIA QIANG. Research and application of new algorithm for PLC flow accumulation. Digital technology and application, 2016 (4):125.
- POZOVNYI, O., ZAHORULKO, A., KRMELA, J., ARTYUKHOV, A. & KRMELOVÁ, V. 2020. Calculation of the Characteristics of the Multi-gap Seal of the Centrifugal Pump, in Dependence on the Chambers' Sizes. Manufacturing Technology, 20, 361-367.
Go to original source...
- ZHUHAI GREE Electric Appliance Co., Ltd. A PLC floating point and fixed point conversion control system and method: CN201911072286.3. 2020-12-25.
- ZHANG XIN, ZHANG YING. Restrictions and improvement methods for cumulative flow results in Siemens PLC programming. Proceedings of the 2015 National Metallurgical Automation Information Network. 2015: 273-275.
- SHEN ZONGJIANG, LIN DEYU. Limitation and improvement methods of flow accumulation results in Siemens PLC programming. Construction engineering technology and design, 2015(22): 2057-2060.
- MOLNÁR, D., BLATNICKÝ, M. & DIŽO, J. 2022. Comparison of Analytical and Numerical Approach in Bridge Crane Solution. Manufacturing Technology, 22, 192-199.
Go to original source...
- QU XIAOHUI. Siemens PLC system in the measurement of the cumulative function of the correction method. Low carbon world, 2015:132-134.
- TIMKO, P., HOLUBJAK, J., BECHNÝ, V., NOVÁK, M., CZÁN, A. & CZÁNOVÁ, T. 2023. Surface Analysis and Digitization of Components Manufactured by SLM and ADAM Additive Technologies. Manufacturing Technology, 23, 127-134.
Go to original source...
- ČERNOHLÁVEK, V., SVOBODA, M., ŠTĚRBA, J., CHALUPA, M. & SAPIETA, M. 2020. Analytical and experimental solution of vibrations of a system of bound bodies. Manufacturing Technology, 20, 699-707.
Go to original source...
- CHENG CAN, WEI ZHIYONG, HEI DAQIAN. Design of a PGNAA facility using D-T neutron generator for bulk samples analysis. Nuclear Instruments and Methods in Physics Research, Section B. Beam Interactions with Materials and Atoms. 2019.45230-35.
Go to original source...
This is an open access article distributed under the terms of the Attribution-NonCommercial 4.0 International License (CC BY-NC 4.0), which permits non-comercial use, distribution, and reproduction in any medium, provided the original publication is properly cited. No use, distribution or reproduction is permitted which does not comply with these terms.