simplified and finished dpll