Uses for Wolfram Alpha in programming - search

Now that Wolfram Alpha is released, I am interested in finding out if it can be used as a time-saver in daily programming.
What would you use Wolfram Alpha to do, that earlier took you more time to do manually?
I guess the "Web and Computer systems"-examples is a good start, but there must be more hidden gems that will be really practical for us programmers.
A short list of examples:
MD5-hashing / SHA-hashing
Quick lockup of unicode and HTML-codes for symbols
Color-codes
Please only include one search query per answer, then we can rate them to get the best ones to the top.
(I made this one a community-wiki, since we will be using the voting for ranking)
Note: If some of the links in the answers don't work (eg: wolfram doesn't find any results, then replace all + with spaces..

I might 'save time' by not playing around with it and doing real work instead. :)

Calculating lift coefficients of NACA profiles (example).
(I made a program for this, but it's nice to have the option to do it quick)

I probably won't use it for anything. I don't know about you, but I deal with enough black boxes on a daily basis, and I'd rather use the ones that have been tried and tested thoroughly.

This might come back to haunt me later, but it strikes me that although there might be a point to WA used in a mechanical manner, from my perspective I'm thinking it's not the hard calculable information questions which are the problem which needs to be solved, it's the soft human data which defies classification or rigid modelling. Google seem to understand this, not sure Stephen Wolfram does.
OTOH it could be that anyone can be Colin Laney now.

Someone double check me here:
The MD5 hash of "Wolfram Alpha" (no quotes) is:
882b 0be2 79eb 7e88 86cd 3dae 19c1 d267
And not:
a615 9984 9aee b7be 3091 68bc 0ab7 ?
EDIT: The hash changes every time given the same query...what kind of hash is this?
http://www14.wolframalpha.com/input/?i=MD5%22Wolfram+Alpha%22

Related

statistical anomaly?

I wrote some code that processes 135,000 books. I just got word from my retailer that 983 books seem to have an issue and is blaming my code for "screwing up" his inventory. I have a friend on the inside that says that there has been an on going issue with his inventory and it doesnt look to be me.
I'm thinking that if the issue was my code, more than .73% (983/135,000) of the data would be affected. How do I reply to him in mathematical terms to disprove his theory that it was my code?
Maybe exactly 983 books have a cedilla. Or Japanese characters. Or diphthongs.
I don't think there's any way you can use statistics here that won't cause statisticians to cringe.
Why don't you just offer a 0.73% discount to your fee, based on the outcome? :-)
Or, offer to fix the problem, meaning that they'll have to provide the information as to why they think they're screwed up.
In other words, make them specify what "screwed up" actually means. Do they not open in the reader? Do they open but characters or formatting are incorrect? Do they "brick" the reading devices?
Without real information, there's little you can do.

Non-optimal solutions for 15-puzzle game

I am applying A* (and IDA*) search with manhattan heuristic for finding solution to 15-puzzle problem.
Using the fact that i dont want an optimal solution for the problem how can i can speed up the search as the current routine is too slow.
Well, it's not exactly a solution, but it might help. Once I've been working for a HOG game with that same puzzle as a minigame and it turned much easier to generate a problem, than find a solution.
What I mean is, we can turn a solved puzzle into unsolved by randomly moving "window" according to rules. And logging each field position for future use. Then we let user play a bit and if she gives up, we can solve a puzzle for her easily by finding the common position in user and our log. We just play back via user log to the common position and back from it to the solved position via ours log.
Of course, this is a hack and not a real solution, but it works fine in gamedev. And not only for this particular game. Most repositioning puzzles can be "solved" this way.

Implementing "best match" for sound effects

I am looking for some advice on categorizing a library of sound effects. I have a large set of random sound effects, (think whistles, pops, growls, creaks, gunshots etc). I would like to be able to take a growl for example, and find the next growl that sounds the closest to the original.
Given a sound, what sound from my set sounds the closest to it.
I have done a fair amount of googling and have found two avenues that I am still researching. One is using echonest, although their "best match" support looks not promising for public users. The other option is diving into FFT and building my own matching algorithm. This is a fine option and would be a great learning experience but I wanted to get some opinions from others who might know a little more about sound processing; especially short clips .5sec - 3sec range, not full length music.
Thanks!
I have worked in movie postproduction for years and as far as I know, there is no way to do that automatically. Every file has meta information in its file header which describes what the sound is like. You are then actually not searching for the file names but in the meta string.
I don't think that it is trivial to sort effects programmatically as two effects that sound similar might be totally different if you look at the waveform.
You would need to extract significant information about a sound that you can then compare.
I am also not a DSP expert, maybe there are methods to do this
If you're interested in trying to build your own system to do this, I can suggest a few keywords that might help to refine your Google searches. In the academic research community, the task you're describing is often called "content-based audio searching". I know there's been a lot of work done on it, and though most pertains to music, sound effects have definitely been the focus of a number of studies.
You might want to start with the work of Pedro Cano.
Also, I recently heard about a company that's doing similar work. You might want to check out products from Imagine Research.
Those are just a couple of ideas off the top of my head. I'm not %100 sure they'll be helpful. If they are, please let me know!

What is the best way to learn Touch Typing? [duplicate]

This question already has answers here:
Closed 13 years ago.
Duplicate
How do I improve my Typing Skills?.**
I tried the test on http://speedtest.10-fast-fingers.com/. I reach only:
You type 337 characters per minute You
have 58 correct words and you have 1
wrong words
How can I improve my typing speed? What free resources do you know of?
Should I learn the Dvorak Keyboard?
Practice is the best way to get faster. I've found TypeRacer to be a fun and easily accessible game. Using it I quickly got from around 55 words per minute to over 70.
I removed all of the key caps from my IBM Model-M. Since I can't see the letters, I was forced to learn their positions and type without looking at the keys other than to initially orient my hands. When you're not able to take shortcuts, you tend to learn very quickly.
Mario taught me.
I also took the test and reached 371 characters with one mistake. However, for programming, I would not see this as a bad result. I'm more worried about how to use tools like Intellisense and code templates better to speed up my coding. The jedi coding demo shows that you can get much higher gains that way than by doubling your typing speed.
No need to learn Dvorak according to XKCD (and more here).
I also remember reading in The Design of Everyday Things that QWERTY actually does quite a good job or spreading the commonly used letters across your fingers and whilst the Dvorak keyboard is a little better than QWERTY the benefits aren't significant enough to justify making the change. (If I can find my copy I'll try and put up an exact quote.)
As with all things: practice makes perfect. Making posts on StackOverflow is a start :)
Unless if you want to win typing contests, a Qwerty or Azerty keyboard will work just fine.
You don't need to learn Dvorak. I can type 600+ Chars/minute on a querty pad, no problem.
The key is: Repetition, repetition, repetition.
What you're doing while you learn typing is creating new 'highways' straight form your brain's spelling center through your spine to your fingers.
Hence, a good typist will spell a word in his mind, and his fingers 'automatically' type those characters because there's a 10 lane highway from his brain to his fingers. In your case, it's a modest 3 lane highway.
Practice, practice, practice.
Good training for if you already know how to type : www.play4traffic.com
There's also loads of typing tutor programs available online, but the key is repetition and persistance.
My native language is Dutch, so in english it's not as good. I tried the test you gave:
317 points, so you achieved position 194065 of 2927935 on the ranking list
You type 476 characters per minute
You have 80 correct words and you have 4 wrong words
Why?
Why do you want to type more quickly? I seldom find that my fingers or typing speed are the issue when it comes to software development. Sure I have a fair speed, but programming is about SO much more than typing speed. I've been using a QUERTY keyboard since about 1983 so I guess repetition helps.
But learning to hold back on typing and thinking about what it is you're about to do is far more valuable IMHO.
Having said that, I would expect any developer to be able to type reasonably quickly using most fingers, or at least more than their two index fingers ;)
This game taught me a few years back.
The Typing Of The Dead
I can now type fairly quickly without looking at the keyboard. You need to learn to use the correct hand position. Then you must have good discipline and only use the correct finger to type the correct letters. I even went so far as to delete correct chars typed with the wrong finger.
It takes time, and you will almost definitely go slower before you go faster, but it is worth it.

Advice on how to be graphically creative [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
I've always felt that my graphic design skills have lacked, but I do have a desire to improve them. Even though I'm not the worlds worst artist, it's discouraging to see the results from a professional designer, who can do an amazing mockup from a simple spec in just a few hours. I always wonder how they came up with their design and more importantly, how they executed it so quickly.
I'd like to think that all good artists aren't naturally gifted. I'm guessing that a lot of skill/talent comes from just putting in the time.
Is there a recommended path to right brain nirvana for someone starting from scratch, a little later in life? I'd be interested in book recommendations, personal theories, or anything else that may shed some light on the best path to take. I have questions like should I read books about color theory, should I draw any chance I have, should I analyze shapes like an architect, etc...
As far as my current skills go, I can make my way around Photoshop enough where I can do simple image manipulation...
Thanks for any advice
Most of artistic talent comes from putting in the time. However, as in most skills, practicing bad habits doesn't help you progress.
You need to learn basic drawing skills (form, mainly) and practice doing them well and right (which means slowly). As you practice correctly, you'll improve much faster.
This is the kind of thing that changes you from a person who says, "It doesn't look right, but I can't tell why - it's just 'off' somehow" to a person who says, "Oops, the arm is a bit long. If I shorten the elbow end it'll change the piece in this way, if I shorten the hand end it'll change the piece this way..."
So you've got to study the forms you intend to draw, and recognize their internally related parts (the body height is generally X times the size of the head, the arms and legs are related in size but vary from the torso, etc). Same thing with buildings, physical objects, etc.
Another thing that will really help you is understanding light and shadow - humans pick up on shape relationships based on outlines and based on shadows.
Color theory is something that will make your designs attractive, or evoke certain responses and emotions, but until you get the form and lighting right the colors are not something you should stress. One reason why art books and classes focus so much on monochrome drawings.
There are books and classes out there for these subjects - I could recommend some, but what you really need is to look at them yourself and pick the ones that appeal to you. You won't want to learn if you don't like drawing fruit bowls, and that's all your book does. Though you shouldn't avoid what you don't like, given that you're going the self taught route you should make it easy in the beginning, and then force yourself to draw the uninteresting and bland once you've got a bit of confidence and speed so you can go through those barriers more quickly.
Good luck!
-Adam
That's a difficult thing. Usually people think "artistic skills" come from your genes but actually they do not.
The bests graphic designer I know have some sort of education in arts. Of course, photoshop knowledge will allow you to do things but being interested in art (painting specially) will improve your sensitivity and your "good taste".
Painting is a pleasure, both doing it and seeing it. Learning to both understand and enjoy it will help and the better way to do it is by going to museums. I try to go to as much expositions as I can, as well as read what I can on authors and styles (Piccaso, Monet, Dali, Magritte, Expresionism, Impresionism, Cubism, etc) that will give you a general overview that WILL help.
On the other side... you are a programmer so you shouldn't be in charge of actually drawing the icons or designing the enterprise logo. You should however be familiarized with user interface design, specially with ease of use, and terms as goal oriented design.
Of course, in a sufficiently large company you won't be in charge of the UI design either, but it will help anyway. I'd recommend the book About Face, which centers in goal oriented design as well as going through some user interface methapores and giving some historic background for the matter.
I'm no artist and I'm colorblind, but I have been able to do fairly well with track creation for Motocross Madness and other games of that type (http://twisteddirt.com & http://dirttwister.com).
Besides being familiar with the toolset I believe it helps to bring out your inner artist.
I found that the book "Drawing on the Right Side of the Brain" was an amazing eye opening experience for me.
One of the tricks that it uses is for you to draw a fairly complicated picture while looking at the picture upside down. If I had drawn it while looking at it right side up it would have looked horrible. I impressed myself with what I was able to draw while copying it while it was upside down.
I did this many years ago. I just looked at their website and I think I will order the updated book and check out their DVD.
I have a BFA in Graphic Design, although I don't use it much lately. Here's my $.02.
Get a copy of "Drawing on the Right Side of the Brain" and go through it. You will become a better artist/drawer as a result and I'm a firm believer that if you can't do it with pencil/paper you won't be successful on the computer. Also go to the bookstore and pick up a copy of How or one of the other publications. I maintain a subscription to How just for inspiration.
I'll see if I can dig up some web links tonight for resources (although I'm sure others will provide some).
most importantly, carry a sketch book and use it. Draw. Draw. Draw.
Drawing is probably what I'd recommend the most. Whenever you have a chance, just start drawing. Keep in mind that what you draw doesn't have to be original; it's a perfectly natural learning tool to try and duplicate someone else's work. You'll learn a lot. If you look at all the great masters, they had understudies who actually did part of their masters' works, so fight that "it must be original" instinct that school's instilled in you, and get duplicating. (Just make sure you either destroy or properly label these attempts as copies--you don't want to accidentally use them later and then be accused of plagiarism..)
I have a couple of friends in the animation sector, and one of them told me that while she was going through college, the way she was taught to draw the human body was to go through each body part, and draw it 100 times, each in a completely different pose. This gets you comfortable with the make-up of the object, and helps you get intimately knowledgeable about how it'll look from various positions.
(That may not apply directly to what you're doing, but it should give you an indicator as to the amount of discipline that may be involved in getting to the point you seek.)
Definitely put together a library of stuff that you can look to for inspiration. Value physical media that you can flip through over websites; it's much quicker to flip through a picture book than it is to search your bookmarks online. When it comes to getting your imagination fired up, having to meticulously click and wait repeatedly is going to be counter-productive.
Inspiration is probably your biggest asset. Like creative writing, and even programming, looking at what people have done and how they have done will give you tools to put in your toolbox.
But in the sense of graphic design (photoshop, illustrator, etc), just like programmers don't enjoy reinventing the wheel, I don't think artwork is any different. Search the web for 'pieces' that you can manipulate (vector graphics: example). Run through tutorials that can easily give you some tricks. Sketch out a very rough idea, and look through web images to find something that has already created.
It's like anything else that you wish to master, or become proficient in. If you want it, you've got to practice it over, and over, and over.
I, too was not born with a strong design skillset, in fact quite the opposite. When I started out, my philosophy was that if the page or form just works then my job was done!
Over the years though, I've improved. Although I believe I'll never be as good as someone who was born with the skills, sites like CSS Zen Garden among others have helped me a lot.
Read into usability too, as I think usability and design for computer applications are inextricably entwined. Books such as Don Norman's "The Design of Everyday Things" to Steve Krug's "Don't Make Me Think", have all helped improve my 'design skills'... slightly! ;-)
Good luck with it.
As I mentioned in a thread yesterday, I have found working through tutorials for Adobe Photoshop, Illustrator, InDesign, and After Effects to be very helpful. I use Adobe's Kuler site for help with colors. I think that designers spend a lot of time looking at other's designs. Some of the books out there on web site design might help, even for designing applications. Adobe TV has a lot of short videos on graphic design in general, as well as achieving particular results in one of their tools. I find these videos quite helpful.

Resources