A Task-Centric Theory for Iterative Self-Improvement with Easy-to-Hard Curricula