# How to insert Greek letters directly in math environment?

Why are non-Latin characters not displayed in formulas, even when using XeLaTeX?

\documentclass{article}
\usepackage{xltxtra}

\begin{document}

$\omega$ %displyed
$ω$ %not displyed

\end{document}


You can use the following sites to copy and paste a lot of math symbols directly to your tex file, using unicode-math package:

Beside more readability in your markup you have not to search for a specific package that provide a special symbol.

-
I suggest you change the question. Obviously similar problems like How to use $beta$ instead of ... have similar solutions. –  Marc van Dongen Sep 29 '12 at 4:29
@MarcvanDongen Feel free to edit my question. –  PHPst Sep 29 '12 at 13:37
I think you are perfectly able to do this your self. –  Marc van Dongen Sep 29 '12 at 13:52

You can't use non-latin alphabets in math formulas for font reasons, even XeTeX use traditional Type1/MetaFont math fonts by default.

You can, however, use unicode-math package with OpenType math fonts:

\documentclass{article}
\usepackage{unicode-math}
\setmathfont{Latin Modern Math}
\begin{document}

$α + β + γ + δ = ε$

$∫f(x)dx = ∑_k Λ_k$

\end{document}

-
@ Is unicode-math stable and reliable enough? Can I replace common math packages with it? –  PHPst May 7 '12 at 10:05
@Reza: Just use it. It is good enough. –  Leo Liu May 7 '12 at 11:29
It is not quite perfect yet though (the version in TeX Live 2012 should be significantly improved). On the other hand, Unicode mathematics is so much nicer to type/read that I don't really care about the bad typesetting. –  Caramdir May 18 '12 at 4:07
@Caramdir: how do you type that nicely? Do you have a space cadet keyboard, or is there some trick that I am not aware of to type math symbols on a regular keyboard without intensive keymap modding? –  Federico Poloni May 27 '12 at 18:36
@FedericoPoloni Using the Neo keyboard layout (I actually imported a German keyboard, as the US keyboard has a slightly different physical layout, that makes Neo uncomfortable to use.) See also tex.stackexchange.com/questions/1979/… –  Caramdir May 27 '12 at 18:56

Not at all difficult:

\documentclass[a4paper]{article}
\usepackage{fontspec}

\mathcodeω=\omega

\begin{document}

$\omega=ω$

\end{document}


Repeat for all the symbols you need, along the same path. However, switching to unicode-math might be handier:

\documentclass[a4paper]{article}
\usepackage{unicode-math}
\setmathfont{Latin Modern Math}

\begin{document}

$\omega=ω$

\end{document}
`
-