Saturday, 27 November 2010

Dabbling in Mathematica 8

I've just updated my version of Mathematica to version 8, and I'm quite impressed. Lots of new commands and features, which I've been trying on two tube journeys so far. Here are a few I find interesting:

Speak["Some text"]

This one is from Mathematica 7 actually, but I had never seen it before. Use it to turn your computer into a slave repeater with something like

N[π,10]//ToString//Speak

Or better yet use it to program a Bingo game (to come).

CurrentImage[]

Get images from your computer camera and do real-time computations on them. Try for example

Dynamic[EdgeDetect[CurrentImage[]]]

Probability is my main subject, so I'm pleased to see that Mathematica has two new commands, Probability and NProbability, for computing the probability of all sorts of events and distributions.

Another function related to probability:

StableDistribution[type,α,β,μ,σ]

Finally. Stable distributions were available as part of an intermediary package called StableDistribution (see also here), but now it's built-in.

Last but not least,

TextRecognize[image]

will convert the text of an image into actual text. It's not full-proof, but it can be useful. Test it on some scanned paper you have and have your computer read it using

TextRecognize[image]//Speak

This is just a teaser of what I'm playing with now. I'll discuss more commands and features (e.g. free form programming) in future posts.

No comments:

Post a Comment