Math in Plone

1,458 views

Published on

Published in: Technology, Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
1,458
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
6
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Math in Plone

  1. 1. Authoring and Publishing Math in Plone & FullMarks
  2. 2. How do crazy people put math on the web? <ul><li>Write it on a piece of paper, take a photo and upload it to your site. Seriously?
  3. 3. Write some Latex, print it out, take a photo and upload it. Hard core!
  4. 4. Write some Latex convert it to an SVG image and upload it. Wow you can do that! </li></ul>
  5. 5. Can you see the problem with all of these approaches?
  6. 6. No collaboration on the web
  7. 7. MathML to the rescue!
  8. 8. What is MathML <ul><li>A standard published by the W3C
  9. 9. MathML Version 1.0 published in 1998
  10. 10. XML for describing Math
  11. 11. MathML deals not only with presentation (Presentation MathML) but also the semantic meaning of an equation (Content MathML). </li></ul>
  12. 12. <ul>The expression ax 2 + bx + c as Presentation MathML </ul><?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?> <!DOCTYPE math PUBLIC &quot;-//W3C//DTD MathML 2.0//EN&quot; &quot;http://www.w3.org/Math/DTD/mathml2/mathml2.dtd&quot;> <math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot;> <mrow> <mi>a</mi> <mo>+</mo> <msup> <mi>x</mi> <mn>2</mn> </msup> <mo>+</mo> <mi>b</mi> <mo>+</mo> <mi>x</mi> <mo>+</mo> <mi>c</mi> </mrow> </math>
  13. 13. <ul>The expression ax 2 + bx + c as Content MathML </ul><?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?> <!DOCTYPE math PUBLIC &quot;-//W3C//DTD MathML 2.0//EN&quot; &quot;http://www.w3.org/Math/DTD/mathml2/mathml2.dtd&quot;> <math> <apply> <plus/> <apply> <times/> <ci>a</ci> <apply> <power/> <ci>x</ci> <cn>2</cn> </apply> </apply> <apply> <times/> <ci>b</ci> <ci>x</ci> </apply> <ci>c</ci> </apply> </math>
  14. 14. All that markup for such a simple formula! No way give me my pencil, paper and camera.
  15. 15. Where MathML is too hard for human consumption WYSYWIG editors and text markup can help
  16. 16. ASCIIMath is simple text-based notation for math that is translated to MathML using Javascript. It was developed by Peter Jipsen from Chapman University in California.
  17. 17. ASCIIMath Facts <ul><li>Allows input in both ASCIIMath and Latex
  18. 18. Transforms to Presentation MathML
  19. 19. One single javascript library: <script src=”ASCIIMathML.js” type=”text/javascript”/> </li></ul>
  20. 20. ASCIIMath Examples <ul><li>E = m c^2
  21. 21. sum_(i=1)^n i^3=((n(n+1))/2)^2
  22. 22. e^(i pi)=-1
  23. 23. AA x in CC (sin^2x+cos^2x=1)
  24. 24. sqrt(x y)
  25. 25. Try them out here: http://mathcs.chapman.edu/~jipsen/mathml/asciimathdemo.html </li></ul>
  26. 26. Only one problem. After 12 frickin years MathML is still only supported by Firefox.
  27. 27. “MathJax is an open source JavaScript display engine for mathematics that works in all modern browsers. No more setup for readers. No more browser plugins. No more font installations… It just works.” http://mathjax.org
  28. 28. Math in Plone <ul><li>David Lippman developed TinyMCE Plugins that use ASCIIMathML.js for entering math. Math and function graphs are rendered as images.
  29. 29. For FullMarks, we rewrote these plugins to store and render MathML.
  30. 30. All MathML is converted by MathJax for cross-browser display.
  31. 31. Function graphs are rendered as SVG since this is not currently supported by the MathML standard. Browser support for SVG is much better than MathML. </li></ul>
  32. 32. Links <ul><li>MathML Standard: http://www.w3.org/TR/MathML2/
  33. 33. ASCIIMath.js: http://mathcs.chapman.edu/~jipsen/mathml/asciimath.html
  34. 34. MathJax: http://www.mathjax.org/
  35. 35. FullMarks TinyMCE Plugins: http://pypi.python.org/pypi/fullmarks.tinymceplugins.asciimath http://pypi.python.org/pypi/fullmarks.tinymceplugins.asciimath
  36. 36. Source for plugins: http://github.com/fullmarks </li></ul>

×