Implementation of Prony algorithm