Planning is a function that involves