added with_root.cpp