preliminary DTF function
hook up DTF, and tweak a few other functions