我不知道这个论坛是否是发布我的问题的正确地方,无论如何,它与 TeX 有关。
Mathjax 似乎将命令参数上方的横线创建\sqrt
为一个带有一系列非常密集的虚线的框,如下图所示。有没有办法将此结果放入纯 TeX 环境中?
答案1
我发布了对我的问题的部分答案:我实际上将从根数的条形图作为密集的破折号序列得到,但我还需要告诉 TeX 它如何提高这个条形图(见下文)。
\newsymbol\trattino 1039 %to get dashes over the argument of the root (amssym.tex needed)
\newbox\radicandobox
\newbox\trattinobox
\def\radice#1#2{%
\setbox\trattinobox\hbox{$\mathord\trattino$}% the dash as a symbol
\setbox\radicandobox\hbox{$#2$}
\sqrt{\vphantom{\vrule height\ht\radicandobox depth\dp\radicandobox}}% a \sqrt contains an invisible line, which dimensions are those of radicand
{\raise#1\ht\radicandobox% the overbar formed by dashes is raised of #1 from its natural heigth
\hbox to\wd\radicandobox{% the overbar itself
\xleaders\hbox to.5\wd\trattinobox{\hss$\mathord\trattino$\hss}\hfill}}%
\kern-\wd\radicandobox{#2}% the radicand is replaced under the bar (dashed bar)
}
$\radice{1.2}{a}, \radice{.92}{2},\radice{.87}{2+b}, \radice{1.1}{\alpha+\radice{.92}{2}}, \radice{.975}{\displaystyle{a+b\over c}}$
我不知道是否有办法固定该高度,从而彻底解决这个问题。无论如何,这可能是正确的方法。