Fix bugs in algorithms. Template dvector assignment from initializer_list.