Move dcf to a derived function