a slightly simpler way to install the dcd function