IPython notebooks already do that, with MathJax, plots, symbolic algebra, and full programming support too. What you've done is neat - I am all in favour of remaking things for fun (working on a grep clone...) - but it does seem like better alternatives already exist.
http://johnmacfarlane.net/pandoc/ may be your best friend, in this case :) Here you can write in markdown and include TeX, thereafter converting to many different formats (using, for example, mimeTeX, MathJax, etc).
As someone who really enjoys taking notes in Markdown, and prefers it over most other alternatives, this is appreciated. Thanks for making this. I look forward to using it in class tomorrow.