Added propagation engine that uses topological order and prevents stackoverflow errors