![将小写字母 m 下调至 \(\models\) 和 \(\vdash\)?](https://linux22.com/image/457173/%E5%B0%86%E5%B0%8F%E5%86%99%E5%AD%97%E6%AF%8D%20m%20%E4%B8%8B%E8%B0%83%E8%87%B3%20%5C(%5Cmodels%5C)%20%E5%92%8C%20%5C(%5Cvdash%5C)%EF%BC%9F.png)
根据 Steven B. Segletes 对这个问题的回答,给出以下 MWE重叠和垂直对齐,可以得到相应的(\models)和(\vdash)下陷微小的 m?
\documentclass{article}
\usepackage{stackengine,amsmath}
\newcommand\oversetnorm{.4\normalbaselineskip}
\makeatletter
\newcommand\myoverset[3][\oversetnorm]{%
\binrel@{#3}\binrel@@{\mathop{\ensurestackMath{%
\stackengine{#1}{#3}{\scriptstyle#2}{O}{c}{F}{F}{L}}}}}
\makeatother
\begin{document}
\(\myoverset{\textsc{m}}{\models\,}\), \(\myoverset{\textsc{m}}{\vdash\,}\)
\end{document}
答案1
我猜你想要的是类似以下的东西。
我重新定义了,\models
因为我真的无法忍受默认渲染。
\documentclass{article}
\usepackage{amsmath}
\usepackage{graphicx}
\makeatletter
% redefine \models to be similar to \vdash
\renewcommand{\models}{\mathrel{\mathpalette\models@\relax}}
\newcommand{\models@}[2]{%
\begingroup
\mspace{-1.3mu}%
\sbox\z@{$\m@th#1\vdash$}
\resizebox{\width}{\dimexpr\ht\z@+\dp\z@}{\raisebox{\depth}{$\m@th#1|$}}%
\mspace{-3.8mu}%
\nonscript\mspace{0.8mu}%
\raisebox{0.25\height}{\resizebox{\wd\z@}{\height}{$\m@th#1=$}}%
\endgroup
}
\newcommand{\inset}[1]{\mathrel{\mathpalette\inset@{#1}}}
\newcommand{\inset@}[2]{%
\makebox[0pt][l]{$\m@th#1\mspace{3mu}_{#2}$}
}
\makeatother
\newcommand{\mmodels}{\inset{\scriptscriptstyle\textnormal{\scshape m}}\models}
\newcommand{\mvdash}{\inset{\scriptscriptstyle\textnormal{\scshape m}}\vdash}
\begin{document}
\(\models\vdash\)
\quad\(\scriptstyle\models\vdash\scriptscriptstyle\models\vdash\)
\(\mmodels\mvdash\)
\end{document}