How do i use a cyrillic glyph/symbol/character in a math formula?
If you're not short of math symbol fonts, you can define a new one:
\documentclass{article}
\usepackage[X2,T1]{fontenc}
\DeclareSymbolFont{cyrillic}{X2}{cmr}{m}{n}
\SetSymbolFont{cyrillic}{bold}{X2}{cmr}{bx}{n}
\DeclareMathSymbol{\khk}{\mathord}{cyrillic}{139}
\begin{document}
$a+\khk(b)_{\khk(b)}$
\end{document}
The advantage of the X2 encoding is that it covers all (well, almost all) glyphs in the various Cyrillic encodings.
If you're short of symbol fonts, a less efficient solution is to use \text
.
\documentclass{article}
\usepackage[X2,T1]{fontenc}
\usepackage{amsmath}
\DeclareRobustCommand{\khk}{%
\mathord{\text{\usefont{X2}{cmr}{m}{n}\symbol{139}}}%
}
\begin{document}
$a+\khk(b)_{\khk(b)}$
\end{document}
You can change the type of the math atom, if it is not \mathord
, into something else (\mathrel
, if it should be a relation symbol).
You can also use directly the letter in the formulas, with UTF-8. This is for the second solution, the first one will work the same.
\documentclass{article}
\usepackage[X2,T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\DeclareUnicodeCharacter{04C3}{\khk}
\DeclareRobustCommand{\khk}{%
\mathord{\text{\usefont{X2}{cmr}{m}{n}\symbol{139}}}%
}
\begin{document}
$a+Ӄ(b)_{Ӄ(b)}$
\end{document}
Sorry, no Japanese or Bengali, this way. Think to your readers who would have a hard time in deciphering those symbols.