Sunday, January 30, 2011

The Mathematics of Facebook

Have you ever wondered why Facebook always shows you what you want to see? The news feed filters out people you never talk to and presents you with info about people you like. Do you know how Facebook does this? Or, when you start typing a name in the search box, do you know how Facebook predicts what you are trying to type? Most people don’t even notice this happening. And that’s what Mark Zuckerburg and his team want. They want you to go onto Facebook and be immersed in the information you see right when you log in. It’s not magic, yet it’s not all that complicated either. All of this can be described by the mathematics of Facebook.


So much of the site’s refinement and smoothness is based on math. When you want to know something, it’s already in front of you. You don’t need to go out and search to find the info that is relevant to you; Facebook does that behind the scenes, using numbers. Everything is based on algorithms. Everything that you do on Facebook is recorded and used to make your experience better. Say you click on your friend’s profile and looked through her photos - Facebook now knows that you want to see information about this person more often than the friend you never talk to. When you post on a wall, or when you chat, or when you send a message (or have any other type of connection on the site), Facebook will know that you want to consume information about this individual.

One of the biggest ways that Facebook knows your true “friends” from your online acquaintances is through photos. Who else is tagged in the photos that you’re tagged in? Or better yet - who is tagged in your profile pictures? Facebook realizes that these people are people that you spend time with (in the real world, off of the internet), and the site uses this knowledge to its advantage.

From The Social Network, Columbia Pictures 2010

Complex mathematical formulas and equations are used by the site to analyze all this data that it collects. As seen in The Social Network, some of the code used for Zuckerburg’s Facesmash website and Facebook are based on algorithms ranking users, preferences and every possible relationship that you have online. Brilliant mathematicians, computer scientists and coders work to invent and continually improve the math that defines what you see on Facebook.
From personal experience, Facebook does an excellent job knowing what its users like and what they do not. The right sidebar of Facebook often contains links to friends’ photo albums and photos related to the page you’re currently looking at. I’ve been with friends who sit there and click through the photo suggestions and then click on the new suggestions and so forth, wasting so much time. The click through percentages of these suggested links must be astronomically higher than any side ads on other websites, like Google.



I love how Facebook is so dependent on mathematics. I am currently studying applied mathematics at UC Berkeley and would kill for the opportunity to work with math at a place such as Facebook. The power of math and the power of Facebook scare me a little, though. I hope Facebook doesn’t know more about my "friends" than I do.