adding iterative MDF implementation