Math Monday: Candy Images

Science
Math Monday: Candy Images

By George Hart for the Museum of Mathematics

Math_Monday_banner02_600px.jpg

Tim Chartier at Davidson College has discovered that if you make things out of candy there’s no lack of volunteers to help you clean up. He takes images and transforms them mathematically into arrays of candy pieces. Here you can see President Obama, as rounded to the set of m&m color values. Mathematically, the algorithm picks the available color which is closest in red-green-blue-space to the average of the pixels it replaces.

Tim’s program has controls that allow the user to change the image, the candy, and the resolution.  Since Easter is coming up, you may find a use for this recipe to make another U.S. president, this time from 400 peeps:

As Tim notes on his blog, “The best part is taking it apart!”

More:
See all of George Hart’s Math Monday columns

What will the next generation of Make: look like? We’re inviting you to shape the future by investing in Make:. By becoming an investor, you help decide what’s next. The future of Make: is in your hands. Learn More.

Tagged

Gareth Branwyn is a freelance writer and the former Editorial Director of Maker Media. He is the author or editor of over a dozen books on technology, DIY, and geek culture. He is currently a contributor to Boing Boing, Wink Books, and Wink Fun. His free weekly-ish maker tips newsletter can be found at garstipsandtools.com.

View more articles by Gareth Branwyn
Discuss this article with the rest of the community on our Discord server!

ADVERTISEMENT

Escape to an island of imagination + innovation as Maker Faire Bay Area returns for its 16th iteration!

Prices Increase in....

Days
Hours
Minutes
Seconds
FEEDBACK