Unusual Wolfram|Alpha Queries

Published on Thursday, August 02, 2012 in , , , , , , ,

Wolfram|Alpha's interactive front pageLast month, Wolfram|Alpha introduced a cool new interactive front page, featuring icons you can click to learn more about its related topic. For example, clicking the atom picture brings up a query for nuclear power production in France.

Since they're sharing some of their favorite searches, I thought I'd share some of mine, as well.

Pythagorean triples search: A Pythagorean triple is any group of three integers (whole numbers) a, b, and c, that satisfies the Pythagorean theorem equation:

a2 + b2 = c2.

Probably the most famous Pythagorean triple is 3, 4, 5, which qualifies because:

32 + 42 = 52.

Wolfram|Alpha displays several examples here.

What if you want to find all Pythagorean triples involving a given length, however? You can use this query, setting a to any desired leg length. In that example, we're looking for a leg length of 25 by setting a to 25, and we find that a = 25, b = 60 and c = 65 is one possible Pythagorean triple, and a = 25, b = 312 and c = 313 is another. The inspiration for this query came from this Pythagorean theorem slideshow on slideshare.

However, the above search only works for legs of a given length, and won't find a hypotenuse of a given length. So, I re-worked the formulas and came up with a version that searches for any given hypotenuse length. In the example search for 25 (done by setting c=25), we find a = 20, b = 15 and c = 25 for one set, and a = 24, b = 7 and c = 25 for the other.

Quizzes: Sometimes I use Wolfram|Alpha to generate sample data to help test myself. For example, if you're practicing either the Day of the Week For Any Date feat or my Day One version, you can generate a random month calendar in the 20th century using this query. If you prefer a full calendar of a random 20th century year, use this search. Obviously, you'll either need someone to help by generating this data out of your sight, or find a way to cover part of the screen.

For practicing the square root estimation feat I recently posted, it's a simple matter to have Wolfram|Alpha generate random numbers from 1 to 1000. If someone else is helping you, you can also have the answer on the screen for their verification. For example, if the randomly generated number is 862, your estimate should be 29 and 21/59ths, which is reflected on the screen showing a=29, b= 21, c=59.

If you like the “cat stuck on a pole” presentation for the square root estimation feat, Wolfram|Alpha can generate random numbers in the right range for that, as well.

Faro Shuffle Simulation: If you're not familiar with the faro shuffle, it's a challenging shuffle that seems to be a regular riffle shuffle, but has a predictable, even mathematical, outcome. Below is a demonstration of the fact that 8 faro shuffles will return the deck to its original order:

Note how, in the video, the Ace of Spades begins as the card on the face, and remains as the card on the face throughout all the shuffles. In card slang, this is referred to as an out-faro, since the face card (or top card, if the deck were held face-down) always stays out. If it went in under a new face/top card, it would be referred to as an in-faro.

I developed this Wolfram|Alpha query to research what happens in faro shuffles of decks of various sizes. In this, you set y to the number of cards involved (52 in the link). The variable z is set to either 1 for a in-faro (as in the link), or 0 for an out-faro. This is easy to remember, since 1 looks like I, for In-faro, and 0 looks like O for Out-faro.

I explain the use of this algorithm in more detail in this Magic Cafe post and this one.

Birthday Problem: In the following video, James Grime asks among the 23 people on the field in a soccer game (11 from each team plus the referee), what are the odds that two people have the same birthday? (We're not including the year, and we're assuming that we know that none of the people on the field were born on February 29th.

It's one thing to hear about this, and another to check it out for yourself. If you want to see the data for any amount of people from 2 to 60, check out this query. As you can see, by the time you reach 57 people, the odds are better than 99% of them sharing a birthday! To really understand this data, however, check it out as a graph instead. You'll see it rises surprisingly quickly, and begins to level off as it starts to become a near-certainty around 50 or more people.

That's all for now. If you have any unusual and favorite Wolfram|Alpha queries of your own, please share them in the comments!

Spread The Love, Share Our Article

Related Posts

Post Details

1 Response to Unusual Wolfram|Alpha Queries

4:02 PM

Birthday Problem

Thanks for posting this. This always blows me away! I don't believe it's true! But it's math! So I know it's true. It's just hard to grasp it because it seems so wrong.