# Multithreading-Based Algorithm for High-Performance Tchebichef Polynomials with Higher Orders
To extend the size of the generated polynomial to handle a size larger than 1096, an algorithm is presented in [31] by combining both the \(n\)- and \(x\)-direction TTRRs with a new mathematical model of the location of the required coefficients to be computed. Although this algorithm extends the size up to 4000 samples, it suffers from errors due to the noncomputed coefficients. This problem is solved by [PERSON] [32] through implementing the Gram-Schmidt orthogonalization process. This algorithm increases the computed size to up to 8000 samples; however, its computation complexity is very high as depicted in [33]. Thus, the algorithm presented in [31] is extended to handle signal sizes larger than 8100 samples as proposed in [33] without increasing the computation complexity. Advances in hardware technology have led to the integration of multiple processor cores on a single chip [34]. Therefore, the challenge of maximizing hardware utilization to accelerate algorithm execution has become a crucial consideration in the pursuit of efficient, stable, and accurate results. Different researchers across various fields have adopted multithreading techniques to significantly enhance performance in their respective domains [35; 36; 37; 38; 39]. In addition, in the era of exponentially growing signal sizes, practical problems tend to pose potential challenges [40]. Therefore, it is of practical importance to develop effective solutions for dealing with large-scale signals, which can serve as a solution for addressing related issues. For a small signal size, Tchebichef polynomials (TPs) are considered an ideal solution, but their application to larger-scale problems is slow in practice and somehow inaccurate. Although the literature is rich with algorithms that develop the computation of the TPs, all the presented algorithms are computed sequentially. This makes the computation of the Tchebichef polynomials very slow, especially for large-sized signals, and incurs additional processing costs. To this end, this paper presents a new algorithm that is capable of handling large-sized signals with high orders efficiently without suffering from the computation overhead and enhancing both stability and performance. We leverage multithreading to distribute the computation load evenly among multiple threads, thereby optimizing the use of available processing capabilities as efficiently as possible. Our method integrates both \(n\)- and \(x\)-direction recurrence algorithms with a refined inspection of coefficient stability to mitigate numerical instability and maintain integrity effectively, with a new inspection process to identify where the Tchebichef polynomials coefficients become stable. By splitting up individual calculations across several threads, we make an efficient use of the computing power that is available. In addition, we design a distribution strategy that guarantees a uniform workload across threads in order to attain a balanced processing load. Our study evaluates the proposed approach for discrete Tchebichef polynomials with different sizes, thread counts, and parameters. This approach aims to enhance numerical stability and reduce computational complexity, providing a more balanced and efficient solution for large-sized signals and high-order Tchebichef polynomial computation. Therefore, the proposed work computes high-order TPs coefficients quickly, steadily, and accurately, opening the door for their use in complex image processing and computer vision applications. The details of this manuscript can be summarized as follows: Section 2 provides a summary of the significance of moments in signal processing and computer vision, highlighting the importance of discrete Tchebichef polynomials. In addition, we discuss the mathematical foundations of discrete Tchebichef polynomials and Tchebichef moments, explaining their main aspects of mathematical formulation. A detailed explanation of the proposed algorithm is presented in Section 3.