This is similar to how MinionPro
deals with open vs closed mathematical g's.
\documentclass{article}
\mathcode`l="8000
\begingroup
\makeatletter
\lccode`\~=`\l
\DeclareMathSymbol{\lsb@l}{\mathalpha}{letters}{`l}
\lowercase{\gdef~{\ifnum\the\mathgroup=\m@ne \ell \else \lsb@l \fi}}%
\endgroup
\begin{document}
\( l = 2 \) \( \lim = 2 \)
\end{document}
You are not using correct dot
language.
Underscores in node names work fine indeed, as node names have to consist of digits, letters, and underscores, not starting with a digit. Your graph defines nodes a, bar, b, and c, where b is contained in a subgraph.
What you actually want to achieve is probably:
\documentclass{article}
\usepackage{dot2texi}
\usepackage{tikz}
\usetikzlibrary{shapes,arrows}
\makeatletter
\@ifundefined{verbatim@out}{\newwrite\verbatim@out}{}
\makeatother
\begin{document}
\begin{dot2tex}[tikz,options=-t math]
digraph G {
n0[label="a\bar{b}"];
n0 -> c;
}
\end{dot2tex}
\end{document}
which yields
Regarding your second question, you can put LaTeX commands, including math stuff ($...$
) in any label if you add them as texlbl
attributes, see the dot2tex
manual for details. But remember that the graph must still be defined in valid dot
language.
Best Answer
I found
\Lbag
and\Rbag
instmaryrd
; reflecting a reduced version of them, joining them at the top and adding the bar yields