Pull request to integrate qasm parser

This PR makes several changes centered around creating a circuit from the
[qasm quantum circuit language](http://www.media.mit.edu/quanta/qasm2circ/).
Examples of the parser are now included on the [sympy quantum circuit parsing
notebook](http://nbviewer.ipython.org/5843312). Roughly half of the examples
from the MIT page now plot directly from the qasm text.

Most of these changes are in the qasm.py file, which defines a Qasm class
that does most of the work.

Did a rebase of these changes on 8/8/2013 to make sure they could be merged
easily. Have since learned that this complicates things unnecessarily,
at least in terms of the number of commits that show up here.