我不明白为什么下面的 tex 文件无法编译。
\documentclass{elsarticle}
\usepackage[hmargin=1in,vmargin=1in]{geometry}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{amsfonts}
\usepackage{amsthm}
\usepackage{arcs}
\usepackage{tikz}
\begin{document}
$\overarc{POQ}$ $+ \widehat{QOR} + \widehat{ROP}= 2\pi r$
\end{document}
答案1
此处讨论了其他过度符号非常宽的帽子符号。使用 scalerel,这里使用该解决方案的变体:
\documentclass{article}
\usepackage{scalerel}
\newcommand\reallywidehat[1]{%
\begin{array}{c}
\stretchto{
\scaleto{
\scalerel*[\widthof{#1}]{\bigwedge}
{\rule[-\textheight/2]{1ex}{\textheight}} %WIDTH-LIMITED BIG WEDGE
}{1.25\textheight} % THIS STRETCHES THE WEDGE A LITTLE EXTRA WIDE
}{0.5ex}\\ % THIS SQUEEZES THE WEDGE TO 0.5ex HEIGHT
#1\\ % THIS STACKS THE WEDGE ATOP THE ARGUMENT
\rule{0ex}{.01ex}
\end{array}
}
\newcommand\reallywideparen[1]{%
\begin{array}{c}
\stretchto{
\scaleto{
\scalerel*[\widthof{#1}]{\frown}
{\rule[-\textheight/2]{1ex}{\textheight}} %WIDTH-LIMITED BIG WEDGE
}{1.25\textheight} % THIS STRETCHES THE WEDGE A LITTLE EXTRA WIDE
}{0.5ex}\\ % THIS SQUEEZES THE WEDGE TO 0.5ex HEIGHT
#1\\ % THIS STACKS THE WEDGE ATOP THE ARGUMENT
\rule{0ex}{.01ex}
\end{array}
}
\begin{document}
$\reallywideparen{POQ}$ $+ \reallywidehat{QOR} + \reallywidehat{ROP}= 2\pi r$
\end{document}