implemented the findpolynomal method and corrected the access to the eigen vector