move increase_stack_size to class System
fix boundary error for magnetic island term