## 3 Methodology
### POI Group Recommendation Algorithm  
Each group contains several users and the users have different preferences. Different from some researches which generate a POI list for each user and aggregate all users' recommendations for the group, the group is regarded as a \"user\". The group preference model construction process is described in the previous section, and each group is represented by a vector in this paper, then collaborative filtering algorithm is employed to obtain the preference POI of a group through similarity computation. Meanwhile, intragroup divergence is also taken into account to get group recommendation results, and we develop a novel group divergence computation method for candidate POIs. Finally, the score of the POI group recommendation is a linear combination of the results based on collaborative filtering and group divergence. Collaborative filtering algorithm is one of the most widely used and successful methods in the field of recommendation system. Similarity computation is important for collaborative filtering algorithm. As we regard the group as a virtual user, and we recommend the POIs visited by users who have similar hobbies to this group. For any user \(v\) and a group \(g\), the similarity between \(g\) and \(v\) is obtained by the following two parts:  
(1) Similarity computation from feature preference perspective. We calculate the similarity of feature preference between the group and the user \(v\). Here, the method to calculate the cosine similarity of the feature vector between them as the similarity relationship between them is shown as follows. \[sim_{g,v}^{m}=\frac{\sum_{i=1}^{M}p_{g,m_{i}}p_{v,m_{i}}}{\sqrt{\sum_{i=1}^{M }(p_{g,m_{i}})^{2}}\sqrt{\sum_{i=1}^{M}(p_{v,m_{i}})^{2}}} \tag{10}\]  
where \(p_{g,m_{i}}\) is the feature vector of group \(g\), and \(p_{v,m_{i}}\) is the feature vector of user \(v\). (2) Similarity computation from users' check-ins perspective. It is to calculate the similarity between the group and the user \(v\) based on the check-ins. To further get higher similarity results, we count historical check-in records of each member in the group. Then we compute the similarity between each member in the group and a user based on the check-in record. The average similarity of all group members and a user is expressed as the similarity of the group and a user. \[sim_{g,v}^{u}=\frac{1}{n(g)}\times\sum_{u\in g}\frac{\sum_{k=1}^{L}r_{u,k}r_{v,k}}{\sqrt{\sum_{k=1}^{L}(r_{u,k})^{2}}\sqrt{\sum_{k=1}^{L}(r_{v,k})^{2}}} \tag{11}\]  
where \(r_{u,l}\) and \(r_{v,l}\) denotes the check-in information of user \(u\) in the group and user \(v\), respectively. If user \(u\) has checked in at location \(l\), \(r_{u,l}=1\). Otherwise, \(r_{u,l}=0\). \(sim_{g,v}^{u}\) is the similarity based on historical records. \(n(g)\) denotes the size of group. Furthermore, the similarity of a group and a user is a simple combination of \(sim_{g,v}^{m}\) and \(sim_{g,v}^{u}\). Furthermore, we normalize the sum of the two and get the similarity between \(g\) and \(v\). In summary, the preference similarity between group \(g\) and any user \(v\) is as follows:  
\[sim_{g,v}=sim_{g,v}^{m}+sim_{g,v}^{u} \tag{12}\]  
(3) Group recommendation based on collaborative filtering algorithm. After obtaining the similarity between group \(g\) and user \(v\), we recommend the locations visited by users similar to group \(g\) through collaborative filtering. The result represents the preference of the group. For example, a group likes to go to location A. Then, the score of each location for the group can be computed based on collaborative filtering. While calculating results according to collaborative filtering, it is found that only users with high similarity to group \(g\) have affected recommendation results to the group \(g\), so this paper designs a threshold \(\theta\) in Equation (13) to constrain \(sim_{g,v}\). \[sim_{g,v}=0,if\ \ sim_{g,v}<\theta \tag{13}\]  
Finally, we recommend the selected locations visited by users to the group through user based collaborative filtering.