Refactoring: Moving some functions to interval container classes in order to ensure class invariants. Stable{msvc-9.0, gcc-3.4.4}