Mathematical model insights into arsenic detoxification