fix coef_k bug