1 | ASCIIMathML Formulae |
---|
2 | ==================== |
---|
3 | |
---|
4 | http://www1.chapman.edu/~jipsen/mathml/asciimath.html[ASCIIMathML] is |
---|
5 | a clever JavaScript written by Peter Jipsen that dynamically |
---|
6 | transforms mathematical formulae written in a wiki-like plain text |
---|
7 | markup to http://www.w3.org/Math/[MathML] markup which is displayed as |
---|
8 | standard mathematical notation by the Web Browser. See 'Appendix E' |
---|
9 | in the AsciiDoc User Guide for more details. |
---|
10 | |
---|
11 | The AsciiDoc `xhtml11` backend supports ASCIIMathML -- it links the |
---|
12 | ASCIIMathML script and escapes ASCIIMathML delimiters and special |
---|
13 | characters to yield valid XHTML. To use ASCIIMathML: |
---|
14 | |
---|
15 | 1. Include the `-a asciimath` command-line option when you run |
---|
16 | `asciidoc(1)`. |
---|
17 | 2. Enclose ASCIIMathML formulas inside math or double-dollar |
---|
18 | passthroughs or in math passthrough blocks. |
---|
19 | |
---|
20 | Here's the link:asciimathml.txt[AsciiDoc source] that generated this |
---|
21 | page. |
---|
22 | |
---|
23 | .NOTE |
---|
24 | - When you use the `asciimath:[]` inline macro you need to escape `]` |
---|
25 | characters in the formulas with a backslash, escaping is unnecessary |
---|
26 | if you use the double-dollar macro (for examples see the second |
---|
27 | formula below). |
---|
28 | - See the |
---|
29 | http://www1.chapman.edu/~jipsen/mathml/asciimath.html[ASCIIMathML] |
---|
30 | website for ASCIIMathML documentation and the latest version. |
---|
31 | - If the formulas don't appear to be correct you probably need to |
---|
32 | install the correct math fonts (see the |
---|
33 | http://www1.chapman.edu/~jipsen/mathml/asciimath.html[ASCIIMathML] |
---|
34 | website for details). |
---|
35 | - See the link:latexmathml.html[LaTeXMathML page] if you prefer to use |
---|
36 | LaTeX math formulas. |
---|
37 | |
---|
38 | A list of example formulas: |
---|
39 | |
---|
40 | - $$`[[a,b],[c,d]]((n),(k))`$$ |
---|
41 | - asciimath:[x/x={(1,if x!=0),(text{undefined},if x=0):}] |
---|
42 | - asciimath:[d/dxf(x)=lim_(h->0)(f(x+h)-f(x))/h] |
---|
43 | - +++`sum_(i=1)\^n i=(n(n+1))/2`$+++ and *bold |
---|
44 | asciimath:[int_0\^(pi/2) sinx\ dx=1]* |
---|
45 | - asciimath:[(a,b\]={x in RR : a < x <= b}] |
---|
46 | - asciimath:[x^2+y_1+z_12^34] |
---|
47 | |
---|
48 | ********************************************************************* |
---|
49 | The first three terms factor to give |
---|
50 | asciimath:[(x+b/(2a))^2=(b^2)/(4a^2)-c/a]. |
---|
51 | |
---|
52 | asciimath:[x+b/(2a)=+-sqrt((b^2)/(4a^2)-c/a)]. |
---|
53 | |
---|
54 | Now we take square roots on both sides and get |
---|
55 | asciimath:[x+b/(2a)=+-sqrt((b^2)/(4a^2)-c/a)]. |
---|
56 | Finally we move the asciimath:[b/(2a)] to the right and simplify to |
---|
57 | get the two solutions: |
---|
58 | *asciimath:[x_(1,2)=(-b+-sqrt(b^2-4ac))/(2a)]*. |
---|
59 | |
---|
60 | ********************************************************************* |
---|
61 | |
---|