Valentine’s Day for Math Nerds

adam whitaker

If you are a romantic math geek…your moment has arrived. In the spirit of Valentine’s Day, go ahead and type (or paste) this into Google search:

sqrt(cos(x))*cos(300x)+sqrt(abs(x))-0.7)*(4-x*x)^0.01, sqrt(6-x^2), -sqrt(6-x^2) from -4.5 to 4.5

Twitter user @Huckberry tipped us off to the fact that typing in the algebraic equation plots several different functions on a graph that forms the shape of a heart.

The series includes various square roots, absolute values and cosine functions — mathematical functions often taught in high school math courses. The plotted lines change direction due to the absolute value function flipping the sign of the x-coordinate, creating a mirror image across the y-axis.

The “cos(300x)” part of the formula was also written to make the line go quickly up and down as it traces out the interior of the heart. This creates the colored-in effect. Meanwhile, if you change the “300″ number in the equation to “500,” the color fills up the heart. That part of the formula is related to frequency.

Although the equation wasn’t written by Google, this is not the first time users have been able to type in certain keywords into search for a seasonal surprise. For example, type “Do a barrel roll” or the word “askew” into Google.

More awesome Google tricks to come!

By | 2012-02-10T23:41:54+00:00 February 10th, 2012|Holidays|0 Comments

About the Author:

Adam Whitaker

Leave A Comment