This repository contains the Python code for Statistical Tolerance Analysis and Statistical Tolerance Synthesis discussed in the MDPI publication Speeding up Statistical Tolerance Analysis to Real Time. It can be used to improve existing Statistical Tolerance Analysis and Statistical Tolerance Synthesis workflows without having to resort to proprietary software solutions.
In order to achieve high-performance computing with Python, the NumPy library is used for the CPU implementation. We also use CuPy for a convenient implementation on the GPU. For the tolerance optimization procedure, we rely on the Differential evolution algorithm from SciPy.
This presented code provides a solution to the tolerance problem described in the publication linked above. It can of course be adapted to other tolerance problems by modifying the closed component equation and the cost function in common_analysis.py.