How does Facebook recommend a friend to you?

## ABSTRACT:

A social network is made by groups out of people or associations that are associated with a typical interest. Online social networking (person to person) communication locales like Twitter, Facebook and Orkut are among the most visited sites on the Internet. In no time, there is an incredible enthusiasm for attempting to comprehend the complexities of this sort of system from both hypothetical and applied perspective. The comprehension of these informal community diagrams is vital to enhance the present interpersonal organization frameworks, furthermore to grow new applications. Here, we propose a friend recommendation system for social medias in view of the topology of the system diagrams. The topology of the system that interfaces a user to his friends is inspected and a local social network called Oro-Aro is utilized as a part of the analyses. We built up a calculation that investigations the sub-diagram made by a user and all the others associated individuals independently by three degrees of separation. However, just users isolated by two level of degree of separation are possible to be proposed as a friend. The calculation utilizes the examples characterized by their associations with discovering those users who have comparable conduct as the root user. The suggestion component was produced taking into account the portrayal and investigations of the system shaped by the user's friends and friends-of-friends (FOF).

## A SHORT ANSWER:

We proposed a friend recommendation system that suggests new links between user nodes within the network. The central problem can be viewed as a procedure to propose relevant parameters for nodes relationship using the information from the social network topology and statistical properties obtained by using classical metrics of complex networks. Even though, topology-based approaches for recommendation systems have already been suggested by other researchers we proposed different clustering indexes and a novel user calibration procedure using Genetic Algorithm (GA).

A social networks an organized group of people or association made out of nodes that are associated with one or more specific sort of relationship, similar to qualities, thoughts, interests, business, companion-ships, family relationship, strife, and exchanging. Investigation and estimations social network analyze the social relations as far as nodes and associations. Nodes in such system speak to individual USERs of the framework, and associations compare to the relations between the USERs of the SNSs. In our investigations, we utilized the information acquired from the Oro-Aro interpersonal organization ( http://www.oro-aro.com) that was created by the Recife Centre for Advanced Studies and Systems (C.E.S.A.R) (http://www.cesar.org.br/system is situated in Brazil and it was produced with the goal to encourage the trading of encounters understudy of the Center of Informants and the product engineers at CESAR. The system is made 634 nodes and 5076 edges. Some pre-processing was connected on the proposed calculation could be actualized. The Oro-Aro permits the making of a one-way relationship, i.e. a user can add another user to his rundown of contact without the other USER to endorse the connection. This sort of system is like twitter, a microblogging system. In this manner, a channel was utilized to evaluate each of the restricted relationship, i.e. who did not have an opposite relationship. The method decreased by 29% quantity of edges and 8% in the quantity of nodes (disconnected sub-systems were expelled). This method was important to acquire a system with symmetric likewise the majority of the informal communities just relationship. Figure 1 demonstrates a graphical representation of the Oro informal organization. Every hub speaks to a user and the edges a two-route relationship between users.

The proposed friend recommendation n system is based on the structural properties of social networks. The topological characteristics, the information, and the metrics are derived from the complex network theory. It is observed that these types of networks are defined as being either small-world or scale free. This characteristic can be used to the development of a reliable recommendation.

The recommendation mechanism procedure utilizes the graph topology of the SNS to filter and order a set of nodes that have some important properties in relation to a given node Vi. The nodes of the resulting set are recommendations of new edges that should be connected to node Vi. The creation of these new edges is used to improve the node Vi, besides providing benefits to entire network in terms of friendship connection.

The process of recommendation is divided into two steps: a filtering procedure followed by an ordering.  Filtering is an important step because it separates the nodes with higher possibilities to be a recommendation, consequently reducing the total number of nodes to be processed in the network. The ordering step considers some properties to put the most relevant nodes in the top of the resulting list. as expected the result depends on the user recommendation system is generated for. therefore, we applied an adaptive solution using the genetic algorithm.

## A LONG ANSWER:

In Facebook recommendation system, they use the Genetic algorithm. The genetic algorithm is used by biologist to analyze the next generation from a family tree. Inside the genetic algorithm, there are three components, such as selection, crossover, mutation. These are explained below:

**SELECTION:** choosing the best part of the next generation.

**CROSSOVER:** inheriting the gene from the “parents”.

**MUTATION:** minimizing the systematic error inside the family tree.

There are basic explanations for the genetic algorithm in the biology area; however, when engineers utilize in the communication network, some technical terms are changed. In the communication network, the “family tree” is already there. For the recommendation system, engineers need to find the best nodes to include in your network.

The crossover method will give the potential nodes. But how? In this method, the system will generate “next generation” which inherent the best part of the “parents.” Inside the network, the potential nodes will be found regarding the identity of the node, for example, the place, the college and the major etc. However, these identities are changing with the time, so the node’s identity will be changed. The mutation method is introduced in this case.

The mutation is fixing the systematic error which means introduce the “accidence” inside the family tree. In the Facebook recommendation, it is introduced to modify the node’s identity, for example, people move out the place, people graduate etc. It can fix the systematic changing error because the node changing.

However, in the reality, you cannot get unlimited friends. Normally, the first row of the recommending friends is from the same area. Sometimes, you are surprised to see you will have a global friend who is not the same country as you. In this case, the selection method is used by the engineers. They will select the potential nodes in more advanced ways to match more similarities with you. Moreover, you cannot find unlimited friends in your friend recommendation because the selection method is used to filter the node which is really far away from you. In the mathematics explanation, it means convergence. When the number is convergent, it means the recommending friends number reach the maximum numbers. The system finds all the friends that suit the criteria. Thus, at the end of the recommending friends are most global friends which you will be surprised.

The most significant part of the recommendation system is the selection method. When the system selects the node, the network is exciting already. Thus, we need to find which the node is. The Facebook is using the cluster coefficient and the cluster density to find the suitable node.

## MATHEMATICAL ANALYSIS:

### Cluster Density:

Inside a network, it connects different nodes. We define two different network types. One is the local network and the other is the global network. By different connections, it has different densities. If a node can be added inside the network, the cluster density outside the network should be greater than a certain value. Then, it can be transmitted, which means increasing the network links.

The density is calculated as the real size of edges where the origin and destiny nodes are in

C

{\displaystyle C}

 divided by the quantity of edges of the clique (complete graph) formed by all the nodes contained in

C

{\displaystyle C}

 .

# P

∑

i
∈
c

(

∑

j
∈
c

(

M

i
j

)
)

(

C

∗
(

C

−
1
)
)

/

2

(
1
)

Where

M

i
j

{\displaystyle M\_{ij}}

 is the element

i
,
j

{\displaystyle i,j}

of the adjacency matrix.

### Cluster Co-Efficient:

#### GLOBAL CLUSTERING COEFFICIENT:

The global clustering coefficient is based on triplets of nodes. A triplet consists of three connected nodes. A triangle includes three closed triplets, one centred on each of the nodes (n.b. this means the three triplets in a triangle come from overlapping selections of nodes). The global clustering coefficient is the number of closed triplets (or 3 x triangles) over the total number of triplets (both open and closed). It is the average Coefficient of the Network. It will be predefined by the Facebook to determine the node importance in the particular network.

###### EQUATION:

The global clustering coefficient is defined as:

# C

3
×

number of triangles

number of connected triplets of vertices

{\displaystyle C = \frac{3 \times \mbox{number of triangles}}{\mbox{number of connected triplets of vertices}}}

=

number of closed triplets

number of connected triplets of vertices

(
2
)

{\displaystyle = \frac{\mbox{number of closed triplets}}{\mbox{number of connected triplets of vertices}}\ \ \ \ \ \ \ \ \ \ (2)}

In this formula, a connected triplet is defined to be a connected subgraph consisting of three vertices and two edges. Thus, each triangle forms three connected triplets, explaining the factor of three in the formula.

#### Local Clustering Coefficient:

The local clustering coefficient of a vertex (node) in a graph quantifies how close its neighbors are to being a clique (complete graph).

##### Local clustering coefficient for directed graphs

C
i

=

{

e

j
k

:

v
j

,

v
k

∈

N
i

,

e

j
k

∈
E
}

K
i

(

K
i

−
1
)

(
3
)

{\displaystyle C\_i = \frac{|\{e\_{jk}:v\_j,v\_k \isin N\_i,e\_{jk} \isin E\}|}{K\_i(K\_i-1)}\ \ \ \ \ \ \ \ \ \ (3)}

The neighborhood

N
i

{\displaystyle N\_i }

 for a vertex

v
i

{\displaystyle v\_i}

 is defined as its immediately connected neighbours as follows:

N
i

=
{

v
j

:

e

i
j

∈
E
∨

e

j
i

∈
E
}

(
4
)

{\displaystyle N\_i = \{v\_j : e\_{ij} \in E \or e\_{ji} \in E\}\ \ \ \ \ \ \ \ \ \ (4)}

We define

k
i

{\displaystyle k\_i}

 as the number of vertices,

N
i

{\displaystyle |N\_i| }

, in the neighborhood,

N
i

{\displaystyle N\_i }

 , of a vertex.

##### Local clustering coefficient for undirected graphs

C
i

=

2

{

e

j
k

:

v
j

,

v
k

∈

N
i

,

e

j
k

∈
E
}

K
i

(

K
i

−
1
)

(
5
)

{\displaystyle C\_i = \frac{2|\{e\_{jk}:v\_j,v\_k \isin N\_i,e\_{jk} \isin E\}|}{K\_i(K\_i-1)}\ \ \ \ \ \ \ \ \ \ (5)}

An undirected graph has the property that

e

i
j

{\displaystyle e\_{ij} }

and

e

j
i

{\displaystyle e\_{ji} }

are considered identical.

## EXAMPLE:

Here is an example. When the p = 1/3, we can add the node inside the network.

In this Figure the values are showing the different densities of the nodes and P1 and P2 are the parent nodes for the network. The Density of the node should be greater than 1/3 but it should be less than 1 (parent node density).

## CONCLUSION:

We have displayed a companion proposal framework in light of the topology of an interpersonal organization. The learning of the structure and topology of these SNSs consolidated with quantitative properties of the chart are utilized to build up the proposal framework. The social network utilized, the Oro-Aro, is littler than the vast majority of the well known interpersonal organizations, for example, Facebook, Orkut or MySpace. Other than being littler in size, it is additionally less got to, thus the rate of 44% of users reaction to the test. Not surprisingly, our calculation was superior to the FOF, another arrangement that is additionally in light of system topology. Notwithstanding the little distinction between the exhibitions, we trust that the size and flow of the system assumes a noteworthy part. The Oro-Aro system has just 634 clients, and the normal of the companion per clients is just 8.1. Hence, we can accept that the FOF calculation performs well in little systems; however the subsequent rundown is most likely little. In bigger systems, as Facebook or Orkut in which the normal companion size surpasses 200, the FOF couldn't recognize the best suggestions when there are little contrasts in FOF criteria. The motivation behind why our answer can perform better in bigger systems is a direct result of its half-breed nature of taking in thought three distinctive records. Since the FOF is utilized as a feature of our answer which suggests that in the most pessimistic scenario the calculation has the same execution and that the joined bunching files with the versatile component of the Genetic Algorithm are capable of the enhanced execution. The investigations results appeared to be extremely encouraging; be that as it may it is still important to apply this calculation in systems much bigger in size and action. A few papers have examined the topological structure of SNSs and others complex systems. In any case, we have demonstrated that these examinations can be utilized to build up some pragmatic applications in the field of suggestion framework. For future work, it is critical to test the proposed component all the more seriously in a bigger system utilizing a few test bunches. Furthermore, this methodology in view of  system topology can be additionally utilized for another sort of  suggestion systems framework separated from SNSs. A  case is the in numerous e-trade frameworks that  constitute bipartite systems created by clients and  items and could be mapped as single element charts.

## References

[1]Hsu, C.-C., Chen, H.-C., Huang, K.-K., &amp; Huang, Y.-M. (September 01, 2012). Personalized auxiliary material recommendation system based on learning style on Facebook applying an artificial bee colony algorithm. Computers and Mathematics with Applications, 64, 5, 1506-1513.

[2]Huang, S., Zhang, J., Wang, L., &amp; Hua, X.-S. (February 01, 2016). Social Friend Recommendation Based on Multiple Network Correlation. IEEE Transactions on Multimedia, 18, 2, 287-299.

[3]Naruchitparames, J., Gunes, M. H., Louis, S. J., &amp; 2011 IEEE Congress on Evolutionary Computation (CEC). (June 01, 2011). Friend recommendations in social networks using genetic algorithms and network topology. 2207-2214.

[4]Silva, N. B., Tsang, I.-R., Cavalcanti, G. D. C., Tsang, I.-J., &amp; 2010 IEEE Congress on Evolutionary Computation (CEC). (July 01, 2010). A graph-based friend recommendation system using Genetic Algorithm. 1-7.