[Tex/LaTex] Graph theory notation

math-modesymbolsunicode-math

I am writing a TeX document with some graph theory notation and there is some notation I couldn't get:

enter image description here

I checked in Word and it's Cambria Math font, but when I used the {unicode-math} package it delivers an error that it has to work with the XeLaTeX engine instead of pdf. When I change the engine to be XeLaTeX the document doesn't compile anymore.

Another notation is the dependency notation:

enter image description here

which I couldn't produce normally. I tried this:

    \newcommand{\indep}{\rotatebox[origin=c]{90}{$\models$}}
    \newcommand{\nindep}{\rotatebox[origin=c]{90}{$\not\models$}}

and it didn't turn out so good.

How can i get these symbols to look right?

Best Answer

If you don't need it presented in \scriptstyle, etc, then this might suffice.

\documentclass{article}
\usepackage{graphicx}
\def\depend{\mathbin{%
  \ooalign{$\perp$\cr$\,\perp$\cr\scalebox{1.3}[.5]{\raisebox{5pt}{$\mkern2mu/$}}}}}
\begin{document}
$\mathcal{G}\depend X$
\end{document}

enter image description here

If one does need it in different math styles, then maybe this:

\documentclass{article}
\usepackage{graphicx,scalerel}
\def\depend{\mathbin{\ThisStyle{%
  \ooalign{$\SavedStyle\perp$\cr$\SavedStyle\,\perp$\cr\scalebox{1.3}[.5]{%
    \kern-1pt\raisebox{5\LMpt}{$\SavedStyle\mkern4mu/$}}}}}}
\begin{document}
$\mathcal{G}\depend X$\par
$\scriptstyle\mathcal{G}\depend X$\par
$\scriptscriptstyle\mathcal{G}\depend X$
\end{document}

enter image description here

Related Question