on master help sign in
Mathdown/README.md
69 lines 1.3 kB history raw
1# Mathdown
2A lightweight syntax for matrices.
3Outputs [MathML](https://en.wikipedia.org/wiki/MathML) format.
5## Syntax
6```
7[
81 2 3
93 2 8
11```
12![](images/mat1.png)
14You can also use [Markdown](https://en.wikipedia.org/wiki/Markdown)-style text emphasis
15- `_<text>_` or `*<text>*` for _italic_
16- `__<text>__` or `**<text>**` for __bold__
17- `___<text>___` or `***<text>***` for ___italic and bold___
19```
21***1*** 2 __3__
22 3 _2_ 8
24```
25![](images/mat2.png)
27You can use `_` to leave an empty space in the matrix
29```
31***1*** 2 __3__ | _
32 _ _2_ 8 | 4
34```
35![](images/mat3.png)
37Newlines separate `elements` of your expressions.
38`//` denotes the start of a normal comment. It is not present in the output.
40```
42***1*** 2 __3__ | _ // This is a normal comment
43_ _2_ 8 | 4
461⊕=0
47->
48a=2b
50// This is also a normal comment
531 2
545 3
56```
57![](images/mat4.png)
59`#` is used to make a `separator` comment. It separates your expressions into different `<math>` elements and is converted to an `xml` comment in the output document.
61## Usage
62`mathdown -b:r -i input.mth -o output.xml`
64### Parameters
65- `-i <file path>` Specifies the input path
66- `-o <file path>` Specifies the output pathfile
67- `-b:s` Uses square brackets
68- `-b:r` Uses round brackets
69- `-b:l` Uses line brackets