Recommender Systems (RS) is widely employed in information retrieval in social networks due to the prevalence of social networking services. Since the matrix factorization (MF) model has a good expandability, social information is easy to be integrated into the model. In general, researchers convert social information to social regularization. Moreover, similarity function is the key in social regularization to constrain the MF objective function. Previous researchers defined the similarity of users’ rating behavior on the same items as users’ interest in similarity. However, they neglected two problems: First, the friendship is a superficial social network that cannot reflect the intimacy among users. Second, the superficial social network generally cannot represent users’ interest in similarity. Recently, researchers have found that both the number of co-friends and friends sub-graph improve users’ interest in similarity, but they do not give a mathematical definition. In this paper, we use these two factors to design two new similarity functions. To use them in the MF-based RS, we come up with two kinds of social regularization for each similarity function. Compared with previous social regularization, our methods can more precisely explain users’ interest similarity. The experimental analysis on a large dataset shows that our approaches improve the performance of the state-of-the-art social recommendation model.