我对方程式中的数字有疑问!这是一个例子:
\documentclass[openany]{Thesis}
\usepackage[top=3cm,right=3cm,bottom=2.5cm,left=2.5cm]{geometry}
\usepackage{xepersian}
\usepackage{amssymb}
\settextfont[Scale=1.4]{XBNiloofar}
\setlatintextfont[Scale=1.2]{XB Zar}
\setdigitfont{PGaramond}
\usepackage{pifont}
\usepackage{bm}
\usepackage[font=small,labelfont=bf]{caption}
\usepackage[dvips]{graphicx}
\usepackage[export]{adjustbox}
\graphicspath{{./}{Figures/}}
\usepackage[noadjust]{cite}
\begin{document}
\begin{equation} \label{eq:solve}
x^2 - 5 x + 6 = 0
\end{equation}
\begin{equation}
x_1 = \frac{5 + \sqrt{25 - 4 \times 6}}{2} = 3
\end{equation}
\begin{equation}
x_2 = \frac{5 - \sqrt{25 - 4 \times 6}}{2} = 2
\end{equation}
\end{document}
这是我的.cls 文件:
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{thesis}[2007/10/19 v1.0]
\LoadClass[12pt,a4paper,BCOR=.7cm,headsepline,bibliography=totoc]{scrbook}
\renewcommand\headfont{\small\textRL}
\renewcommand*\sectfont{\normalcolor\bfseries}
\DeclareOption{MsThesis}{\AtEndOfPackage{\def\@fordegree{\if@Latin Ms Thesis\else پایاننامه کارشناسی ارشد\fi}}}
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{scrbook}}
\ProcessOptions
\RequirePackage{amsmath,amsthm}
\newlength\OddM@rg
\if@twoside\def\sw@pmargs{\oddsidemargin\evensidemargin}\else
\def\sw@pmargs{
\OddM@rg\paperwidth \addtolength\OddM@rg{-\textwidth}
\addtolength\OddM@rg{-\oddsidemargin} \addtolength\OddM@rg{-2\hoffset} \addtolength\OddM@rg{-2in} \oddsidemargin\OddM@rg}
\sw@pmargs \fi
\sloppy\parindent1.5em
\def\PrepareForBiblio{\cleardoubleemptypage\pagestyle{plain}\backmatter\baselineskip0.8\baselineskip}
\def\PrepareForLatinPages{\cleardoubleemptypage\pagestyle{empty}\sw@pmargs\latin}
\newenvironment{abstract}[1]
{\def\@pkeywds{#1}\cleardoubleemptypage\begin{center}\Large\bfseries\st@title\end{center}\subsection*{\if@Latin Abstract\else چکیده\fi}\begin{quote}}
{\end{quote}\paragraph*{\if@Latin Keywords\else کلمات کلیدی\fi:}{\@pkeywds.}\cleardoubleemptypage}
\newenvironment{قدردانی}{\cleardoubleemptypage\centerline{\Large\bfseries قدردانی}\begin{quote}}{\end{quote}\cleardoubleemptypage}
\newenvironment{تصویب}{\def\BSkp{\par\vskip3\bigskipamount} \def\SSkp{\par\vskip\bigskipamount}
\def\signat{امضاء: . . . . . . . . . . .\\[1cm]}
\def\داور%
##1##2{##1: & {\large##2} & \signat}
\cleardoubleemptypage\begin{center}\large\bfseries به نام او\SSkp\st@university\end{center}
\BSkp{\large\@fordegree}\SSkp
\begin{tabular}{rr} عنوان: & {\large\st@title} \\[\medskipamount] \@by: & {\large\st@author} \end{tabular}
\BSkp{\large کمیته داوران}\SSkp
\begin{center}\begin{tabular*}{.9\textwidth}{r r @{\extracolsep{\fill}} l}
\@undersup: & {\large\st@supervisor} & \signat
\ifdefined\st@consult \@undercons: & {\large\st@consult} & \signat\fi
}{
&& تاریخ: . . . . . . . . .
\end{tabular*}\end{center}}
%مشخصات پایاننامه
\let\origin@lmaketitle\maketitle
\def\makethesistitle{
\def\@titlehead{\centering\st@logo\\\smallskip\large\st@university}
\def\@title{\st@title}
\def\@subject{\@fordegree\\\st@subject}
\def\@author{{\normalsize\@by}\\{\st@author} \\[1.5\bigskipamount]%
{\normalsize\@undersup}\\{\itshape\st@supervisor}%
\ifdefined\st@consult\\[1.5\bigskipamount]{\normalsize\@undercons}\\{\itshape\st@consult}\fi
\\[1.5\bigskipamount]}
\def\@date{\ifdefined\st@date\st@date\else\if@Latin\latintoday\else\today\fi\fi}
\origin@lmaketitle
\newcommand\date[1]{\def\st@date{##1}}
\newcommand\title[1]{\def\st@title{##1}}
\newcommand\author[1]{\def\st@author{##1}}
\newcommand\subject[1]{\def\st@subject{##1}}}
\renewcommand\date[1]{\def\st@date{#1}}
\renewcommand\title[1]{\def\st@title{#1}}
\renewcommand\author[1]{\def\st@author{#1}}
\renewcommand\subject[1]{\def\st@subject{#1}}
\newcommand\logo[1]{\def\st@logo{#1}}
\newcommand\university[1]{\def\st@university{#1}}
\newcommand\supervisor[1]{\def\st@supervisor{#1}}
\newcommand\consult[1]{\def\st@consult{#1}}
\def\@undersup{\if@Latin Supervisor\else استاد راهنما\fi}
\def\@undercons{\if@Latin Under consult of\else استاد مشاور\fi}
\def\@by{\if@Latin By\else نگارش\fi}
\def\@fordegree{\if@Latin PhD Thesis\else پایاننامه دکتری\fi}
\newtheorem{theorem}{قضیه}[chapter]
\renewcommand\thetheorem{\thechapter\@SepMark\arabic{theorem}}
\newtheorem{definition}[theorem]{تعریف}
\newtheorem{notation}[theorem]{قرارداد}
\newtheorem{proposition}[theorem]{گزاره}
\newtheorem{lemma}[theorem]{لم}
\newtheorem{remark}[theorem]{تذکر}
\newtheorem{example}[theorem]{مثال}
\def\localisecommands{
\eqcommand{دانشگاه}{university}
\eqcommand{موضوع}{subject}
\eqcommand{استادراهنما}{supervisor}
\eqcommand{استادمشاور}{consult}
\eqcommand{آرم}{logo}
\eqcommand{تقدیم}{dedication}
\eqenvironment{اثبات}{proof}
\eqenvironment{لم}{lemma}
\eqenvironment{قضیه}{theorem}
\eqenvironment{تذکر}{remark}
\eqenvironment{گزاره}{proposition}
\eqenvironment{قرارداد}{notation}
\eqenvironment{تعریف}{definition}
\eqenvironment{مثال}{example}}
因此,当我在方程式中输入一些数字时,它不会出现!请看示例:
\begin{equation} \label{eq:solve}
x^2 - 5 x + 6 = 0
\end{equation}
\begin{equation}
x_1 = \frac{5 + \sqrt{25 - 4 \times 6}}{2} = 3
\end{equation}
\begin{equation}
x_2 = \frac{5 - \sqrt{25 - 4 \times 6}}{2} = 2
\end{equation}
和结果: