将数学字体更改为 Arial

将数学字体更改为 Arial

我正在提交一篇手稿式的奖学金论文,格式必须是 12pt Arial。我可以使用 LuaLaTeX 来实现。然而,一旦我实现了这一点,我很快就意识到数学字体与更粗的 Arial 字体搭配起来很不协调。

文档中的数学字体可以改为 Arial 吗?我一直对在 LaTeX 文档中更改数学字体感到困惑。

我如何更改数学字体来使其更接近 Arials 样式?

谢谢!

\documentclass[12pt, letterpaper]{article}
\usepackage[margin=1in
%,showframe
]{geometry}
\usepackage{fontspec}
\setmainfont{Arial}
\usepackage{fancyhdr}
\usepackage{physics}
\fancyhf{}
\pagestyle{fancy}
\lhead{Undergrad Student} % your name here
\rhead{The University}
\usepackage[style=numeric,sorting=none]{biblatex}
\addbibresource{references.bib}
\setlength{\headheight}{12.5pt}
\usepackage{titlesec}
\titlespacing*{\section}{0pt}{*.5}{*.5}
\titleformat*{\section}{\normalsize\bfseries}
\usepackage{lipsum}

\begin{document}
\begin{center}
{\underline{Math in Arial}}
\end{center}
\section{Introduction}
I think the default math font looks odd when paired with Arial. Here is an example: $n = 4$. The math just looks a lot weaker than the text. $\int_0^{\frac{\pi}{2}} \int_0^1 x \sin{(x^2-y)}\dd{y}\dd{x}$\\\\
Is there a way to use Arial font for the math symbols? $(n-1) + (2^n + 1) = 2^n + n$\\

\noindent \lipsum[1]


\end{document} 

在此处输入图片描述

答案1

正确的方法是使用unicode-math无衬线数学字体。

但是,可用的无衬线数学字体并不多。如果您需要没有数学字体的特定字体系列,您可以尝试一下该mathastext软件包。这将用普通文本中的字母和数字替换数学字符。结果并不完美,但值得一试……

% !TeX TS-program = lualatex
\documentclass[12pt, letterpaper]{article}
\usepackage[margin=1in
%,showframe
]{geometry}
\usepackage[no-math]{fontspec}
\setmainfont{Arial}
\usepackage{mathastext}
\usepackage{fancyhdr}
\usepackage{physics}
\fancyhf{}
\pagestyle{fancy}
\lhead{Undergrad Student} % your name here
\rhead{The University}
\usepackage[style=numeric,sorting=none]{biblatex}
\addbibresource{references.bib}
\setlength{\headheight}{12.5pt}
\usepackage{titlesec}
\titlespacing*{\section}{0pt}{*.5}{*.5}
\titleformat*{\section}{\normalsize\bfseries}

\usepackage{lipsum}



\begin{document}

\begin{center}
{\underline{Math in Arial}}
\end{center}
\section{Introduction}
I think the default math font looks odd when paired with Arial. Here is an example: $n = 4$. The math just looks a lot weaker than the text. $\int_0^{\frac{\pi}{2}} \int_0^1 x \sin{(x^2-y)}\dd{y}\dd{x}$\\\\
Is there a way to use Arial font for the math symbols? $(n-1) + (2^n + 1) = 2^n + n$\\

\noindent \lipsum[1]


\end{document} 

在此处输入图片描述


如果您只是担心 Arial 看起来比您的数学字体更粗,您可以尝试更粗的衬线数学字体。在那里,您将拥有更多成熟的数学字体选择,例如

% !TeX TS-program = lualatex
\documentclass[12pt, letterpaper]{article}
\usepackage[margin=1in
%,showframe
]{geometry}


\usepackage[bitstream-charter]{mathdesign}

\usepackage[no-math]{fontspec}
\setmainfont{Arial}
\usepackage{fancyhdr}
\usepackage{physics}
\fancyhf{}
\pagestyle{fancy}
\lhead{Undergrad Student} % your name here
\rhead{The University}
\usepackage[style=numeric,sorting=none]{biblatex}
\addbibresource{references.bib}
\setlength{\headheight}{12.5pt}
\usepackage{titlesec}
\titlespacing*{\section}{0pt}{*.5}{*.5}
\titleformat*{\section}{\normalsize\bfseries}

\usepackage{lipsum}



\begin{document}

\begin{center}
{\underline{Math in Arial}}
\end{center}
\section{Introduction}
I think the default math font looks odd when paired with Arial. Here is an example: $n = 4$. The math just looks a lot weaker than the text. $\int_0^{\frac{\pi}{2}} \int_0^1 x \sin{(x^2-y)}\dd{y}\dd{x}$\\\\
Is there a way to use Arial font for the math symbols? $(n-1) + (2^n + 1) = 2^n + n$\\

\noindent \lipsum[1]


\end{document} 

在此处输入图片描述

相关内容