# LuaLaTeX empty math symbols

Consider the following minimal example:

\documentclass{minimal}

\usepackage{fontspec}
\usepackage{unicode-math}

\defaultfontfeatures{Ligatures=TeX}
\setmainfont{TeX Gyre Pagella}
\setsansfont[Scale=MatchLowercase]{Tex Gyre Heros}
\setmonofont{Tex Gyre Cursor}
\setmathfont{TeX Gyre Pagella Math}

\begin{document}
$a \boxdiag b$

$a \boxbslash b$
\end{document}


If compiled with lualatex minimal.tex, the output ends up in something like

a b
a b


That means, the symbols \boxdiag and \boxbslash are not printed. Why do I even not get an error message? Are the symbols missing and I need to load a package for them?

• you do get a warning in the log Missing character: There is no ⧄ (U+29C4) in font TeXGyrePagellaMath:mode=base ;script=math;language=DFLT;+tlig;! Missing character: There is no ⧅ (U+29C5) in font TeXGyrePagellaMath:mode=base ;script=math;language=DFLT;+tlig;! so it seems the font doesn't have those symbols Aug 16, 2016 at 15:59
• you are right the warning is reported in the file minimal.log but is not output on the console where I would have expected the warning/error message. Thank you letting me know! Aug 16, 2016 at 17:25

As the warning in the log states, the font doesn't have those characters. Since they are just boxes, you could steal them from any font that does without too much typographic pain, xits math works:

\documentclass{minimal}

\usepackage{fontspec}
\usepackage{unicode-math}

\defaultfontfeatures{Ligatures=TeX}
\setmainfont{TeX Gyre Pagella}
\setsansfont[Scale=MatchLowercase]{Tex Gyre Heros}
\setmonofont{Tex Gyre Cursor}
\setmathfont{TeX Gyre Pagella Math}
\setmathfont[range={\boxdiag,\boxbslash}]{XITS Math}

\begin{document}
$a \boxdiag b$

$a \boxbslash b$
\end{document}

• Thank you for your explanations! Interestingly on the console output the warning is not shown but in the log file it is. Didn't expect such a behaviour. Aug 16, 2016 at 17:29