diff --git a/numerical_methods/durand_kerner_roots.cpp b/numerical_methods/durand_kerner_roots.cpp index 70288d2c5..5d9baa932 100644 --- a/numerical_methods/durand_kerner_roots.cpp +++ b/numerical_methods/durand_kerner_roots.cpp @@ -18,11 +18,14 @@ * ``` * Sample implementation results to compute approximate roots of the equation * \f$x^4-1=0\f$:\n - * ![Error - * evolution](https://raw.githubusercontent.com/kvedala/C-Plus-Plus/docs/images/numerical_methods/durand_kerner_error.svg) - * - * ![Roots - * evolution](https://raw.githubusercontent.com/kvedala/C-Plus-Plus/docs/images/numerical_methods/durand_kerner_roots.svg) + * Error evolution during root approximations computed every
+ * iteration. Roots evolution - shows the initial approximation of the
+ * roots and their convergence to a final approximation along with the iterative
+ * approximations */ #include @@ -52,7 +55,7 @@ std::complex poly_function(const std::valarray &coeffs, int n; // #ifdef _OPENMP - // #pragma omp parallel for reduction(+ : real, imag) + // #pragma omp target teams distribute reduction(+ : real, imag) // #endif for (n = 0; n < coeffs.size(); n++) { std::complex tmp = @@ -132,7 +135,6 @@ std::pair durand_kerner_algo( bool break_loop = false; while (!check_termination(tol_condition) && iter < INT16_MAX && !break_loop) { - std::complex delta = 0; tol_condition = 0; iter++; break_loop = false;