regex - How to embed all numbers within $ $ -
regex - How to embed all numbers within $ $ -
i preparing thesis in latex. want embed of real numbers (numbers decimal points) in table environment within $ $. best approach so. there many tables , files saved in utf-8 encoding.
example:
\begin{table}[htbp] \caption{پایگاه دادهی نمونه استفاده شده در مثال \ref{ex:exp1}، (آ) پایگاه دادهی اصلی ، (ب) نسخهی 3-بی نامی} \centering \begin{tabular}{|r|r|r|r|r|} \cline{1-2}\cline{4-5} 681.00 & 404.00 & & 327.55 & 280.92 \\ % % % \multicolumn{3}{c}{(آ)} & \multicolumn{2}{c}{(ب)} \end{tabular}% \label{tab:lf_3} \end{table}
must changed to
\begin{table}[htbp] \caption{پایگاه دادهی نمونه استفاده شده در مثال \ref{ex:exp1}، (آ) پایگاه دادهی اصلی ، (ب) نسخهی 3-بی نامی} \centering \begin{tabular}{|r|r|r|r|r|} \cline{1-2}\cline{4-5} $681.00$ & $404.00$ & & $327.55$ & $280.92$ \\ % % % \multicolumn{3}{c}{(آ)} & \multicolumn{2}{c}{(ب)} \end{tabular}% \label{tab:lf_3} \end{table}
thanks
you can define new column type:
\usepackage{array} \newcolumntype{r}{>{${}}r<{{}$}@{}}
now alter r
r
.
\begin{table}[htbp] \caption{پایگاه دادهی نمونه استفاده شده در مثال \ref{ex:exp1}، (آ) پایگاه دادهی اصلی ، (ب) نسخهی 3-بی نامی} \centering \begin{tabular}{|r|r|r|r|r|} \cline{1-2}\cline{4-5} 681.00 & 404.00 & & 327.55 & 280.92 \\ % % % \multicolumn{3}{c}{(آ)} & \multicolumn{2}{c}{(ب)} \end{tabular}% \label{tab:lf_3} \end{table}
regex interpreter tex
Comments
Post a Comment