Please disable Adblockers and enable JavaScript for domain CEWebS.cs.univie.ac.at! We have NO ADS, but they may interfere with some of our course material.
Διδακτικη and itex2MML
Διδακτικη is this wiki, pronounced Didaktiki, and documented by many.
itex2MML is a parser which translates itex-code (LaTex similar code) to MML, the mathematics markup language.
The following Fonts have to be installed: «https://developer.mozilla.org/en/Mozilla_MathML_Project/Fonts».
The text below was copied from «Instiki's page» to CEWebS' Didaktiki, it was reorganized, parsed and put into shape to show similarities and differences of the itex implementation, i.e., you should see the commands which work and which don't. Examples added by CC, some are taken from the AMSTeX documentation.
Basics
«itex2MML»'s notation is similar to LaTeX's basic math symbols nd commands, but differs in many things: You cannot define macros, the array environment has a different syntax, and some basics like \hbox and \mbox can't be used.
To obtain the mathematical symbols and formulas in Διδακτικη (Didaktiki) you have to put the itex-code either in between two $ signs (inline), or, to get a centered formula, in between an \[ - \] pair on a single line(!!), just like in plain LaTeX.
The following code
A simple formula like $a^2+b^2=c^2$ does not always hold
but a centered formula may look nice:
\[\sum_{k=1}^n k=\frac{n\cdot(n+1)}{2}\]
is parsed by Didaktiki using itex and renders
A simple formula like does not always hold
but a centered formula may look nice:
Links
Greek Letters
\Alpha, \alpha |
\Xi, \xi |
|||||
\Beta, \beta |
O, \omicron |
|||||
\Gamma, \gamma |
\Pi, \pi |
|||||
\Delta, \delta |
\varpi |
|||||
\Epsilon, \epsilon |
\Rho, \rho |
|||||
\varepsilon |
\varrho, |
|||||
\Zeta, \zeta |
\Sigma, \sigma |
|||||
\Eta, \eta |
\varsigma |
|||||
\Theta, \theta |
\Tau, \tau |
|||||
\vartheta |
\Upsilon, \upsilon |
|||||
\Iota, \iota |
\Phi, \phi |
|||||
\Kappa, \kappa |
\varphi |
|||||
\varkappa |
X, \chi |
|||||
\Lambda, \lambda |
\Psi, \psi |
|||||
\Mu, \mu |
\Omega, \omega |
|||||
\Nu, \nu |
\backepsilon |
Symbols
\aleph |
|||
\beth |
|||
\ell |
|||
\hbar |
|||
\Im |
|||
\imath |
|||
\jmath |
|||
\eth |
|||
\Re |
|||
\wp |
|||
\infty=\infinity |
|||
\emptyset =\varnothing |
|||
\digamma |
Mathematical Functions
\arccos |
\lg |
|||||
\arcsin |
\lim |
|||||
\arctan |
\liminf |
|||||
\arg |
\limsup |
|||||
\cos |
\ln |
|||||
\cosh |
\log |
|||||
\cot |
\max |
|||||
\coth |
\min |
|||||
\csc |
\mod |
|||||
\deg |
\pmod{5} |
|||||
\det |
\Pr |
|||||
\dim |
\sec |
|||||
\exp |
\sin |
|||||
\gcd |
\sinh |
|||||
\inf |
\sup |
|||||
\hom |
\tan |
|||||
\ker |
\tanh |
Arrows
\rightarrow |
\leftsquigarrow |
|||||
\to |
\rightsquigarrow |
|||||
\longrightarrow |
\leftrightsquigarrow |
|||||
\Rightarrow |
\upuparrows |
|||||
\implies |
\rightleftarrows |
|||||
\hookrightarrow |
\rightrightarrows |
|||||
\embedsin |
\dashleftarrow |
|||||
\mapsto |
\dashrightarrow |
|||||
\map |
\curvearrowleft |
|||||
\leftarrow |
\curvearrowbotright |
|||||
\longleftarrow |
\downdownarrows |
|||||
\Leftarrow |
\leftleftarrows |
|||||
\impliedby |
\leftrightarrows |
|||||
\hookleftarrow |
\righttoleftarrow |
|||||
\leftrightarrow |
\lefttorightarrow |
|||||
\Leftrightarrow |
\circlearrowleft |
|||||
\Longleftrightarrow |
\circlearrowright |
|||||
\iff |
\curvearrowright |
|||||
\nearrow |
\leftarrowtail |
|||||
\nearr |
\rightarrowtail |
|||||
\nwarrow |
\leftrightsquigarrow |
|||||
\nwarr |
\Lleftarrow |
|||||
\searrow |
\Rrightarrow |
|||||
\searr |
\looparrowleft |
|||||
\swarrow |
\looparrowright |
|||||
\swarr |
\Lsh |
|||||
\neArrow |
\Rsh |
|||||
\neArr |
\twoheadleftarrow |
|||||
\nwArrow |
\twoheadrightarrow |
|||||
\nwArr |
\nLeftarrow |
|||||
\seArrow |
\nleftarrow |
|||||
\seArr |
\nLeftrightarrow |
|||||
\swArrow |
\nleftrightarrow |
|||||
\swArr |
\nRightarrow |
|||||
\darr |
\nrightarrow |
|||||
\Downarrow |
\downharpoonleft |
|||||
\uparr |
\downharpoonright |
|||||
\Uparrow |
\leftrightharpoons |
|||||
\downuparrow |
\rightleftharpoons |
|||||
\duparr |
\upharpoonleft |
|||||
\updarr |
\upharpoonright |
|||||
\Updownarrow |
Delimiters
(,),[,] |
\lfloor |
|||||
\langle = \lang |
\rfloor |
|||||
\rangle = \rang |
\uparrow |
|||||
\lbrace = \{ |
\downarrow |
|||||
\rbrace = \} |
\updownarrow |
|||||
\lceil |
\vert = |, |
|||||
\rceil |
\Vert = \| |
In TeX, delimiters are non-stretchy, by default. Stretchy delimiters are obtained with \left<delim> and \right<delim>. Each \left<delim> must be matched with a corresponding \right<delim>. If you don't want a visible matching delimiter, you can match with the invisible delimiters, \left. and \right. .
Fixed-size large delimiters are generated with the modifiers
\big \Big \bigg \Bigg
\bigl \Bigl \biggl \Biggl
\bigr \Bigr \biggr \Biggr
For example, \Biggr) generates , a very large (3× natural size) right parenthesis; \bigl\vert generates , a large (1.2× natural size) left vertical bar.
Operators
\amalg |
||
\angle |
||
\measuredangle |
||
\sphericalangle |
||
\approx |
||
\approxeq |
||
\thickapprox |
||
\ast |
||
\asymp |
||
\backslash |
||
\because |
||
\between |
||
\bottom = \bot |
||
\boxminus = \minusbox |
||
\boxplus = \plusbox |
||
\boxtimes = \timesbox |
||
\boxdot |
||
\bowtie |
||
\bullet |
||
\cap = \intersection |
||
\cup = \union |
||
\Cap |
||
\Cup |
||
\cdot |
||
\circledast |
||
\circledcirc |
||
\clubsuit |
||
\curlyvee |
||
\curlywedge |
||
\diamondsuit |
||
\divideontimes |
||
\dotplus |
||
\heartsuit |
||
\spadesuit |
||
\circ |
||
\bigcirc |
||
\cong |
||
\ncong |
||
\dagger |
||
\ddagger |
||
\dashv |
||
\Vdash |
||
\vDash |
||
\nvDash |
||
\VDash |
||
\nVDash |
||
\vdash |
||
\nvdash |
||
\Vvdash |
||
\Diamond |
||
\diamond |
||
\div |
||
\equiv |
||
\nequiv |
||
\eqcirc |
||
\neq = \ne |
||
\Bumpeq |
||
\bumpeq |
||
\circeq |
||
\doteq |
||
\doteqdot |
||
\fallingdotseq |
||
\risingdotseq |
||
\exists |
||
\nexists |
||
\flat |
||
\forall |
||
\frown |
||
\smallfrown |
||
\gt |
||
\ngtr |
||
\gg |
||
\ggg |
||
\geq = \ge |
||
\ngeq |
||
\geqq |
||
\ngeqq |
||
\geqslant |
||
\ngeqslant |
||
\eqslantgtr |
||
\gneq |
||
\gneqq |
||
\gnapprox |
||
\gnsim |
||
\gtrapprox |
||
\gtrsim |
||
\gtrdot |
||
\gtreqless |
||
\gtreqqless |
||
\gtrless |
||
\gvertneqq |
||
\in |
||
\notin |
||
\ni |
||
\notni |
||
\intercal |
||
\invamp = \parr |
||
\lhd |
||
\unlhd |
||
\leftthreetimes |
||
\rightthreetimes |
||
\lt |
||
\nless |
||
\ll |
||
\lll |
||
\leq = \le |
||
\nleq |
||
\leqq |
||
\nleqq |
||
\leqslant |
||
\nleqslant |
||
\eqslantless |
||
\lessapprox |
||
\lessdot |
||
\lesseqgtr |
||
\lesseqqgtr |
||
\lessgtr |
||
\lesssim |
||
\lnapprox |
||
\lneq |
||
\lneqq |
||
\lnsim |
||
\ltimes |
||
\lvertneqq |
||
\lozenge |
||
\blacklozenge |
||
\mid = \shortmid |
||
\nmid |
||
\nshortmid |
||
\models |
||
\multimap |
||
\nabla = \Del |
||
\natural |
||
\not = \neg |
||
\odot |
||
\odash = \circleddash |
||
\otimes |
||
\oplus |
||
\ominus |
||
\oslash |
||
\parallel |
||
\nparallel |
||
\shortparallel |
||
\nshortparallel |
||
\partial |
||
\Perp = \Vbar |
||
\perp |
||
\pitchfork |
||
\pm |
||
\mp |
||
\prec |
||
\nprec |
||
\precapprox |
||
\precnapprox |
||
\preceq |
||
\npreceq |
||
\preccurlyeq |
||
\curlyeqprec |
||
\precsim |
||
\precnsim |
||
\prime |
||
\backprime |
||
\propto |
||
\varpropto |
||
\rhd |
||
\unrhd |
||
\rtimes |
||
\setminus |
||
\smallsetminus |
||
\sharp |
||
\sim |
||
\nsim |
||
\backsim |
||
\simeq |
||
\backsimeq |
||
\thicksim |
||
\smile |
||
\smallsmile |
||
\sslash |
||
\subset |
||
\nsubset |
||
\subseteq |
||
\nsubseteq |
||
\subseteqq |
||
\nsubseteqq |
||
\subsetneq |
||
\subsetneqq |
||
\varsubsetneq |
||
\varsubsetneqq |
||
\Subset |
||
\succ |
||
\nsucc |
||
\succeq |
||
\nsucceq |
||
\succapprox |
||
\succnapprox |
||
\succcurlyeq |
||
\curlyeqsucc |
||
\succsim |
||
\succnsim |
||
\supset |
||
\nsupset |
||
\supseteq |
||
\nsupseteq |
||
\supseteqq |
||
\supsetneq |
||
\supsetneqq |
||
\varsupsetneq |
||
\varsupsetneqq |
||
\Supset |
||
\square = \Box |
||
\blacksquare = \qed |
||
\sqcup |
||
\sqcap |
||
\sqsubset |
||
\sqsubseteq |
||
\sqsupset |
||
\sqsupseteq |
||
\star |
||
\bigstar |
||
\therefore |
||
\times |
||
\top |
||
\triangle |
||
\triangledown |
||
\triangleleft |
||
\triangleright |
||
\blacktriangle |
||
\blacktriangledown |
||
\bigtriangleup |
||
\bigtriangledown |
||
\blacktriangleleft |
||
\blacktriangleright |
||
\ntriangleleft |
||
\ntriangleright |
||
\ntrianglelefteq |
||
\ntrianglerighteq |
||
\trianglelefteq |
||
\trianglerighteq |
||
\triangleq |
||
\vartriangleleft |
||
\vartriangleright |
||
\uplus |
||
\vee |
||
\veebar |
||
\wedge |
||
\barwedge |
||
\doublebarwedge |
||
\wr |
||
\coloneqq |
||
\Coloneqq |
||
\coloneq |
||
\Coloneq |
||
\eqqcolon |
||
\Eqqcolon |
||
\eqcolon |
||
\Eqcolon |
||
\colonapprox |
||
\Colonapprox |
||
\colonsim |
||
\Colonsim |
||
\dblcolon |
In keeping with AMSLaTeX rater than MathML's conventions, \smallsetminus (? = U+FE68) is designated as a small (non-stretchy) reverse solidus,
\backslash is a reverse solius (\ = U+05C). \setminus (\ = U+2216) is stretchy.
Dots
\dots |
|||
\ldots |
|||
\cdots |
|||
\ddots |
|||
\udots |
|||
\vdots |
|||
\colon |
While ":" is allowed in mathmode, it doesn't (neither in LaTeX nor in itex) produce the desired spacing for, e.g., f:A?B. Use \colon, instead.
Large Math Operators and Integrals
\bigcup = \Union |
\coprod = \coproduct |
|||||
\bigcap = \Intersection |
\prod = \product |
|||||
\bigodot |
\sum |
|||||
\bigoplus = \Oplus |
\int = \integral |
|||||
\bigotimes = \Otimes |
\iint = \doubleintegral |
|||||
\bigsqcup |
\iiint = \tripleintegral |
|||||
\biguplus |
\iiiint = \quadrupleintegral |
|||||
\bigwedge = \Wedge |
\oint = \conint = \contourintegral |
|||||
\bigvee = \Vee |
Sizes and Styles
\displaystyle \frac{a}{b} |
|||
\textstyle \frac{a}{b} |
|||
\textsize \frac{a}{b} |
|||
\scriptsize \frac{a}{b} |
|||
\scriptscriptsize\frac{a}{b} |
|||
\mathit{A} |
|||
\mathbf{A} = \boldsymbol{A} |
|||
\mathrm{A} |
|||
\mathbb{A} |
|||
\mathfrak{A} = \mathfr{A} |
|||
\mathcal{A} |
|||
\text{A} |
Spaces
\, = \thinspace |
|||
\: = \medspace |
|||
\; = \thickspace |
|||
\quad |
|||
\qquad |
|||
I\!N = I\negspace N |
|||
\phantom{AB} |
|||
\mathrlap |
Itex2MML::Error |
||
\mathllap |
Itex2MML::Error |
||
\mathclap |
Itex2MML::Error |
||
\space |
Itex2MML::Error Itex2MML::Error |
Unknown: Syntax of \space
Accents
\bar |
|||
\overline=\closure=\widebar |
|||
\underline |
|||
\vec |
|||
\widevec |
|||
\dot |
|||
\ddot |
|||
\dddot |
|||
\ddddot |
|||
\tilde |
|||
\widetilde |
|||
\check |
|||
\widecheck |
|||
\hat |
|||
\widehat |
|||
\slash |
|||
\boxed |
Fractions, Sub/Superscripts and Roots
\frac |
|||
\tfrac |
|||
\binom |
|||
\over |
|||
\atop |
|||
\substack |
|||
\overbrace |
|||
\underbrace |
|||
\underset |
|||
\overset=\stackrel |
|||
\underoverset |
|||
\tensor |
|||
\multiscripts |
|||
\sqrt |
|||
\root |
|||
\operatorname |
|||
\mathop |
|||
\mathbin |
|||
\mathrel |
Environments
\begin{env}…\end{env}
where env is one of:
matrix, pmatrix, bmatrix, Bmatrix, vmatrix, Vmatrix, smallmatrix, cases, aligned, gathered, split, svg
Examples
F=\begin{cases}A&B\\C&D\end{cases} |
|||
\begin{aligned}L & = \lim_{|x| \to \infty}\frac{\cos\frac{1}{x}\cdot\frac{-1}{x^2}}{\frac{-1}{x^2}}\\ & = \lim_{|x| \to \infty} {\cos\frac 1x} \cdot \frac{-1}{x^2} \cdot \frac{x^2}{-1}\\ & = \cos\frac 1{\infty} = \cos 0 = 1 \end{aligned} (align environment of AMSTeX) |
|||
\begin{split}a& =b+c-d\\& \quad +e-f\\& =g+h\\& =i\end{split} |
|||
\begin{gathered}a_1=b_1+c_1\\a_2=b_2+c_2-d_2+e_2\end{gathered} (gather environment of AMSTeX) |
\begin{matrix}1&2&3\\4&5&6\end{matrix} |
|||
\begin{matrix}1&2&3\\4&5&6\end{matrix} |
|||
\begin{pmatrix}1&2&3\\4&5&6\end{pmatrix} |
|||
\begin{bmatrix}1&2&3\\4&5&6\end{bmatrix} |
|||
\begin{Bmatrix}1&2&3\\4&5&6\end{Bmatrix} |
|||
\begin{vmatrix}1&2&3\\4&5&6\end{vmatrix} |
|||
\begin{Vmatrix}1&2&3\\4&5&6\end{Vmatrix} |
|||
\begin{smallmatrix}1&2&3\\4&5&6\end{smallmatrix} |
|||
\left(\begin{smallmatrix}1&2&3\\4&5&6\end{smallmatrix}\right) |
Colours
\color{colourspec} changes the current foreground colour.
\bgcolor{colourspec} changes the current background colour.
colourspec is either
- an HTML named-colour:
aqua, black, blue, fuchsia, gray, green, lime, maroon, navy, olive, purple, red, silver, teal, white, or yellow
- or is an RGB colour value:
#rgb or #rrggbb, where rgb or rrggbb is a 3- or 6-digit hexadecimal number.
#000000 is black, #FFFFFF is white, and #1AC=#11AACC.
Examples
a{b\color{red}c\color{#0F0}d}e |
|||
a { b \color{red} \text{c} \color{#0F0} \text{d} } e |
|||
a { b \bgcolor{red} \c \bgcolor{#0F0} \d } e |
The alternate LaTeX syntax, involving specifying a colour model, e.g.
\color[cmyk]{0, 0.1, 0.5, 0.3}
is not supported.
Not implemented in Didaktiki
SVG Environment
The SVG Environment allows you to embed snippets of SVG in itex equations. To assist in Instiki's LaTeX export feature, you can also include a graphicx command:
\begin{svg}
...
\end{svg}
\includegraphics[width=...]{foo}
where foo.pdf is a file containing a PDF version of the graphic. In itex, the \includegraphics command is defined as a NOOP, and the SVG is embedded in the MathML output. In Instiki's LaTeX export, the opposite is true: the svg environment is a NOOP, and the \includegraphics command is included in the output.
WebTeX-style Arrays and Array Options
\array
\arrayopts
\collayout (=\colalign),
\rowalign,
\align,
\eqcols,
\eqrows,
\collines,
\rowlines,
\frame,
\padding
\rowopts
\colalign,
\rowalign
\cellopts
\colalign,
\rowalign,
\rowspan,
\colspan
Interactivity
Not implemented as links and messages are implemented differently. The following syntax would have messed all up.
\href{url}{expression}
Turns a mathematical expression into a clickable link. This makes use of Xlink.
Displays the message text in the browser's status-line, when the user hovers his mouse over the mathematical expression. Does not work natively in Mozilla/Firefox, but is easily implemented with a touch of Javascript?.
\tooltip{message}{expression}
Displays the message text as a tooltip, when the user hovers his mouse over the mathematical expression. Also does not work natively in Mozilla/Firefox. Instead, Mozilla/Firefox supports the (nonexistent) title attribute. So, the same Javascript, below, works around the problem.
\fghilight{colourspec}{expression} ( = \fghighlight)
\bghilight{colourspec}{expression} ( = \bghighlight)
Deprecated, and will be dropped from a future version of itex2MML. Change the foreground/background colour of an expression when the user clicks on it. The current implementation uses deprecated MathML 1.0 attributes (which do not seem to be supported by current browsers). The suggested MathML 2.0 replacements are highly non-portable. Use CSS+Javascript instead.
\toggle{expression1}{expression2}
Toggle between these two expressions when the user clicks on them.
Equation Numbering
While itex2MML, the stream filter, does not provide such facilities, various tools built around it, like the itex2MML MovableType plugin and Maruku provide enhanced features, such as equation-numbering and cross-referencing. Itex2MML::Error…Itex2MML::Error produces an unnumbered equation. \[…\] produces a numbered equation. Optionally, \[…\] can contain a label
\[...\label{foo}...\]
You can then refer back to this equation by (eq:foo) or \eqref{foo}. These are automatically turned into hyperlinks.
Letzte Änderung: 02.09.2011, 11:22 | 1186 Worte