modularize the construction of approximation DAG