OpenCvSharp.Cv2.SolvePoly C# (CSharp) Method

SolvePoly() public static method

finds real and complex roots of a polynomial
public static SolvePoly ( InputArray coeffs, OutputArray roots, int maxIters = 300 ) : double
coeffs InputArray The array of polynomial coefficients
roots OutputArray The destination (complex) array of roots
maxIters int The maximum number of iterations the algorithm does
return double
        public static double SolvePoly(InputArray coeffs, OutputArray roots, int maxIters = 300)
        {
            if (coeffs == null)
                throw new ArgumentNullException(nameof(coeffs));
            if (roots == null)
                throw new ArgumentNullException(nameof(roots));
            coeffs.ThrowIfDisposed();
            roots.ThrowIfNotReady();
            double ret = NativeMethods.core_solvePoly(coeffs.CvPtr, roots.CvPtr, maxIters);
            GC.KeepAlive(coeffs);
            roots.Fix();
            return ret;
        }
        #endregion
Cv2