On History-Dependent Optimization Models: A Unified Framework to Analyze Models with Habits, Satiation and Optimal Growth