revised from chen duan