我有以下一段代码:
\documentclass{article}
\oddsidemargin 43pt
\textheight 20.4 cm
\textwidth 14.0 cm
\parskip 6.8 pt
\parindent 12 pt
\usepackage{mathtools}
\begin{document}
\begin{table}[h]
\hrule
\begin{align}
\label{E}
\tag{E}
&\text{Axioms:} &&s =t &&&\text{for all equations $s=t$ in $E$}\\[0mm]
\label{Ref}
\tag{Reflexivity}
&\text{ }
&&s=s &&&\text{for every term $s$}
\\[0mm]
\label{Sym}
\tag{Symmetry}
&\text{Rules:}
&& \frac{s=t}{t=s}
&&&\text{ }
\\[0mm]
\label{Trans}
\tag{Transitivity}
&\text{ }
&&\frac{s=t,t=v}{s=v}
&&&\text{ }
\\[0mm]
\label{Cong}
\tag{Congruence}
&\text{ }
&&\frac{s_1=t_1, \ldots, s_n = t_n}{f(s_1,\ldots,s_n) = f(t_1,\ldots t_n)}
&&&\text{for every $n$-ary $f$}
\\[0mm]
\label{Subs}
\tag{Substitution}
&\text{ }
&&\frac{s=t}{\sigma(s) = \sigma(t)}
&&&\text{for $\sigma$ a substitution}
\end{align}
\hrule
\caption{Axioms and rules for an equational logic with axiom set $E$}
\label{tab: equational logic}
\end{table}
\end{document}
可以看出,前两列向左对齐,后两列向右对齐。现在我希望第三列和第四列也向左对齐(第四列不一定)。
我尝试了表格,但无法引用行(例如使用 \eqref{E})。我也喜欢行之间的垂直间距(在表格环境中会失败)
我希望有人知道怎么做
答案1
据我所知,你想要类似的东西
&
只需从每一行中删除一个,这样\text
最后一列就会左对齐而不是右对齐。
\documentclass{article}
\oddsidemargin 43pt
\textheight 20.4 cm
\textwidth 14.0 cm
\parskip 6.8 pt
\parindent 12 pt
\usepackage{mathtools}
\begin{document}
\begin{table}[htp]
\hrule
\begin{align}
\label{E}
\tag{E}
&\text{Axioms:} &&s =t &&\text{for all equations $s=t$ in $E$}\\[0mm]
\label{Ref}
\tag{Reflexivity}
&\text{ }
&&s=s &&\text{for every term $s$}
\\[0mm]
\label{Sym}
\tag{Symmetry}
&\text{Rules:}
&& \frac{s=t}{t=s}
&&\text{ }
\\[0mm]
\label{Trans}
\tag{Transitivity}
&\text{ }
&&\frac{s=t,t=v}{s=v}
&&\text{ }
\\[0mm]
\label{Cong}
\tag{Congruence}
&\text{ }
&&\frac{s_1=t_1, \ldots, s_n = t_n}{f(s_1,\ldots,s_n) = f(t_1,\ldots t_n)}
&&\text{for every $n$-ary $f$}
\\[0mm]
\label{Subs}
\tag{Substitution}
&\text{ }
&&\frac{s=t}{\sigma(s) = \sigma(t)}
&&\text{for $\sigma$ a substitution}
\end{align}
\hrule
\caption{Axioms and rules for an equational logic with axiom set $E$}
\label{tab: equational logic}
\end{table}
\end{document}