Several Bug Fixed

Now the algorithm works for dynamic structures too