A dynamic programming based column generation approach