Hot answers tagged

13

Here's a version that also changes size in subscripts and superscripts, maintaining the correct line width for the circle and the slash. \documentclass{article} \usepackage{amsmath,amssymb} \usepackage{pict2e} \makeatletter % line thickness \newcommand{\hermis@thickness}[1]{% \fontdimen8 \ifx#1\displaystyle\textfont\else \ifx#1\textstyle\textfont\else ...


9

Maybe something like this? \documentclass{article} \usepackage{amsmath, amssymb} \usepackage{graphicx} \newlength{\harpoonswidth} \settowidth{\harpoonswidth}{$\rightleftharpoons$} \newcommand*{\circnotharpoons}{% \mathrel{\ooalign{% $\rightleftharpoons$\cr% \makebox[\harpoonswidth]{% \begin{picture}(10,10)(-5,0) ...


9

Not too sure what exactly you want, but I propose this code, based on the \stackinset command which hopefully is not too far from what you'd like: \documentclass[11pt]{article} \usepackage{amsmath} \usepackage{amssymb} \usepackage{stackengine} \newcommand{\Orightharpoonup}{\mathrel{\stackMath\stackinset{c} {0pt}{c}{0.5pt}{\circ}{\relbar\mkern-3.2mu\...


8

A little extension on egreg's answer that scales to the math style being used via \mathchoice: \documentclass{article} \newcommand{\mmmodels}{% \mathrel{ {|} \mathchoice{\mkern -3.5mu}{\mkern -3.5mu}{\mkern -4mu}{\mkern -4.5mu} {\equiv} } } \begin{document} $a \mmmodels b_{a \mmmodels b_{a \mmmodels b}}$ \end{document}


8

You can mimick the definition of \models, but with a slight change so the subscript is a bit lower. \documentclass{article} \usepackage{amsmath} \newcommand{\mmmodels}{\mathrel{|\mkern-3.5mu{\equiv}}} \begin{document} \[ \mmmodels_K \] \end{document}


6

U+2AE2 VERTICAL BAR TRIPLE RIGHT TURNSTILE ⫢ is \vDdash in unicode-math for lualatex and xelatex or compatible packages such as stix2 for pdflatex \documentclass{article} \usepackage{stix2} \begin{document} \[ A \vDdash B \] \end{document}


6

You might use \verb|###_#__##_##_####|, but this has the problem that it cannot go in the argument to another command. A different strategy might be to use 1 to denote # and 0 to denote the underscore. This way you can also very simply modify the final appearance by just acting on the definition. \documentclass{article} \ExplSyntaxOn \NewDocumentCommand{\...


6

Consider using \rule instead of a math minus -. It's defined as \rule[<raise>]{<width>}{<thickness>}. \documentclass{article} \usepackage{xcolor} \begin{document} \textcolor{blue}{$-$} \textcolor{blue}{\rule[.5ex]{1em}{.4pt}} \textcolor{blue}{\rule[.5ex]{1em}{1pt}} \textcolor{blue}{\rule[.5ex]{1em}{2pt}} \end{document}


4

You don't want to load both mathpazo and stix2, because the latter sets up different font encodings for math fonts and messes them up. You want instead to use the special arrow as a text symbol. How to do it? We find \stix@MathSymbol{\rightwhitearrow}{\mathord}{arrows1}{"EF} in stix2.sty. So let's look for arrows1 and we find \DeclareSymbolFont{arrows1}{...


4

Since the long style is based on longtable, you automatically end up with a horizontally centered list. To nevertheless left align it, you can define your own custom style based on the original definition of the long style: \newglossarystyle{mylong}{% \renewenvironment{theglossary}% {\begin{longtable}[l]{@{}lp{\glsdescwidth}}}% %<-------------- ...


4

With a current texsystem you can use albatross to query fonts. Call on a terminal albatross U+1F48A It should give a list of fonts. On my system (windows) it found the followings for your glyph. Some of them can be colored, the technical details can differ here: some need the harfbuzz renderer, others can be colored with lua code. But I have no idea how ...


3

With a lilypond file like \new RhythmicStaff \with {\remove "Staff_symbol_engraver"} { \relative { \time 1/4 \hide Staff.TimeSignature \tuplet 3/2 {a8' 8 8} 8 8 \tuplet 3/2 {r8 8 8} 8 8 4 } \addlyrics { Eye less in Ga za at the mill with slaves}} I could produce something similar to examples It's suposed that with ...


3

℣ (U+2123) and ℟ (U+211F) are Unicode characters, so use a font that has these characters (e.g., Noto Serif): \usepackage{fontspec} \setmainfont{<name of font with these characters>} Or you can specify a fallback font, where Nimbus Roman lacks ℣ and ℟, so we use Noto Serif's: \usepackage{fontspec, newunicodechar} \setmainfont{Nimbus Roman} \...


3

You get subscripts in maths mode with _{<stuff>}, so to get an A with a subscript zero you'd type $A_{0}$.


3

Using a more reasonable test document without the unrelated packages: \documentclass{article} \begin{document} $n \in \mathbb{Z}^{+}$ \end{document} With \usepackage{amsfonts,mathabx} With \usepackage{amsfonts} With \usepackage{stix2} With \usepackage{newtxmath} There are dozens more math fonts available and no purely objective way of choosing between ...


3

The character | is special for MakeIndex, so you need to escape it. \documentclass{article} \usepackage{imakeidx} \makeindex \begin{document} Test\index{Norm!1@$"|"| \cdot "|"|$} Test2\index{Norm!1@$1_X$} Test3\index{Norm!1@$"\"| \cdot "\"|_X$} \printindex \end{document} The .ind file will contain \begin{theindex}...


3

This seems to be an interaction between stix2 and mathpazo using different 8-bit encodings. The mathpazo package by itself does not have this problem unless stix2 is also loaded: \documentclass[11pt,a4paper]{scrbook} \tracinglostchars=3 \usepackage{mathpazo} \usepackage[ngerman]{babel} \DeclareRobustCommand{\heterozyg}{$^{+/-}$} \DeclareRobustCommand{\...


2

I suggest you switch to \textsuperscript text-mode directives. \documentclass[11pt,a4paper]{scrbook} %\usepackage[utf8]{inputenc} % that's the default nowadays \usepackage[T1]{fontenc} \usepackage[ngerman]{babel} \usepackage{stix2} \usepackage{mathpazo} \DeclareRobustCommand{\heterozyg}{\textsuperscript{+/-}} \DeclareRobustCommand{\minuszyg}{\...


2

The turnstile package is designed for typesetting various configurations of turnstiles with or without text above and below the bar. For your case, you want a single vertical bar on the left followed by a triple horizontal bar, and no text, so the command is \sttstile{}{}: \documentclass{article} \usepackage{turnstile} \begin{document} \[ \sttstile{}{} K \...


2

I like Skillmon's solution with tabularx. But here are two other ways. \documentclass{article} \usepackage{lipsum} \usepackage{tikz} \usetikzlibrary{calc, tikzmark} \usepackage{framed} \newlength{\leftbarwidth} \setlength{\leftbarwidth}{1pt} \newlength{\leftbarsep} \setlength{\leftbarsep}{.5em} \newenvironment{doubleleftbar}{% \def\FrameCommand{{\...


2

Rather than reimplementing the whole thing, it's simpler to do a couple of patches: \documentclass[ a4paper, leqno]{article} \usepackage{amsmath} \usepackage{xpatch} \NewCommandCopy{\laxcolim}{\varinjlim} \makeatletter \NewCommandCopy{\varllim@}{\varlim@} \xpatchcmd{\laxcolim}{\varlim@}{\varllim@}{}{} \xpatchcmd{\varllim@}{lim}{llim}{}{} \makeatother \...


1

You can make it yourself by putting a \cdot inside \triangleleft. And I'd prefer to use \underline rather than \underset \documentclass{article} \newcommand{\tdot}{\underline\triangleleft\kern-3.2pt{\cdot}\thinspace} \begin{document} \[ x \tdot y \] \end{document}


1

You can use \text to access the text mode symbol font, although you might want to raise it slightly, depending what you want it to look like (\raisebox might help) \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{stix} \usepackage{mathtools} \usepackage{musixtex} \title{Chiave di Basso prova} \author{PUCK} \date{\today} \begin{document} \...


Only top voted, non community-wiki answers of a minimum length are eligible