pruning chain complexes over polynomial and local rings