To solve a Polynomial equation solver with multiple method