Interest community routing method in opportunity network

The invention discloses an interest community dividing and routing method in an opportunity network, the liking degree of a certain interest by a node is used for measuring a corresponding interest attribute vector, and a data package head information vector is defined to indicate a data package type. Through cosine similarity, similarity of the interest attribute vector of the node and the data package head information vector is calculated, and the node in the network is classified in a corresponding interest community. On the basis, a corresponding routing algorithm is designed. When routing is carried out in the community, community attributes and distance attributes of the node are considered, and a data package forwarding strategy is designed. When routing is carried out among communities, multi-community attributes and the distance attributes of the node are considered comprehensively, and a data package forwarding strategy is designed. The routing algorithm increases the delivery rate of the network, reduces network average delay and meanwhile effectively reduces network spending.