Described and illustrated is a system for management of diabetes that includes an infusion pump, glucose sensor and controller with a method programmed into the controller. The infusion pump is configured to deliver insulin to a subject. The glucose sensor is configured to sense glucose levels in the subject and provide output signals representative of the glucose levels in the subject. The controller is programmed to switchover from one mode of MPC control based on a predetermined range of blood glucose values to another MPC mode based on a predetermined target.揭示並闡釋一種包括一注入泵、葡萄糖感測器及控制器之管理糖尿病之系統以及一種經程式化至該控制器中之方法。該注入泵經組態以輸送胰島素給一對象。該葡萄糖感測器經組態以感測該對象的葡萄糖位準並且提供表示該對象葡萄糖位準的輸出信號。該控制器係經程式化以從一基於預判定範圍的血液葡萄糖值之MPC控制模式切換至另一基於預判定目標之MPC模式。