Search code examples
githubmarkdownkatex

Special Letters not working on KATEX on Github


After May 2022, github are now accepting KATEX directly on markdown using $$$$

I'm trying to use the following letters on markdown using the $$$$ special characters to use the KATEX on my github but the following letters are not working.

Code Letter displayed expected
$$\N$$ $$\N$$ image
$$\Z$$ $$\Z$$ image
$$\Reals$$ $$\Reals$$ image
$$\R$$ $$\R$$ image
$$\natnums$$ $$\natnums$$ image

in github:

enter image description here


Solution

  • After some study, I find out a KATEX command called \mathbb{text} who cna change the font from the text inside the curly brackets

    One example:

    $$ A =  \lbrace x \in \mathbb{N} \space | \space x < 5 \rbrace $$
    

    Some information:

    \lbrace and \rbrace are the { } curly brace symbol in KATEX

    \space insert space between texts

    In github thanks to \mathbb{text} it can make the symbol i showed in my question:

    enter image description here

    The table of symbol and code

    Code Symbol
    $$\mathbb{N}$$ $$\mathbb{N}$$
    $$\mathbb{Z}$$ $$\mathbb{Z}$$
    $$\mathbb{R}$$ $$\mathbb{R}$$

    On Github preview:

    github preview markdown