The traditional support vector machine (SVM) often has an over-fitting problem when outliers exit in the training data set. Fuzzy support vector machine (FSVM) provides an effective approach to deal with the problem. It can reduce the effects of outliers by fuzzy membership functions. Choosing a proper fuzzy membership is very important. In this paper, a new fuzzy membership function is proposed to solving classification problems for FSVM. We define it not only basing on the distance between each data point and the center of class, but also an affinity among samples which can be defined by K nearest neighbor distances. Experimental results show the good performance of the present approach.