Optimal and Approximate Factored Decision Making