This post is a direct extension of this one. How can I define a proof environment with a different typeset name than "Proof" in a non-English document in addition to the original proof environment, rather than in lieu of it?
The language I am interested in is Hebrew, and the LaTeX language support I use is provided by the polyglossia
package in tandem with the xelatex
engine, but I'm also interested in the combination babel
+ lualatex
.
Following is a LaTeX document, saved as ~/test.tex
, as a starting point.
\documentclass{article}
\usepackage{amsthm}
\newtheorem{theorem}{משפט}
\usepackage{polyglossia}
\setmainlanguage{hebrew}
\setmainfont{Arial}
\begin{document}
Following is an interesting theorem.
\begin{theorem}
A house is not a home.
\end{theorem}
\begin{proof}
A chair is still a chair, even when there's no one sitting there.
But a chair is not a house, and a house is not a home.
\end{proof}
\end{document}
When the following instructions are executed in the Terminal:
> cd ~
> xelatex test
the file ~/test.pdf
is created. When opened in a PDF viewer, the file displays as follows.
Note that Hebrew is a right-to-left language.
The desired solution would enable me to add the following to ~\test.tex
immediately below the \end{proof}
line:
\begin{explanation}
A chair is still a chair, even when there's no one sitting there.
But a chair is not a house, and a house is not a home.
\end{explanation}
with the resulting PDF file displaying like this:
Note that the desired output can be accomplished on an ad-hoc basis by adding the option [הסבר]
to the proof
environment, thus: \begin{proof}[הסבר] ... \end{proof}
. However, I'm looking for a solution that would enable me to declare a new environment with a different name than proof
.
\end{proof}
a copy of the\begin{proof} ... \end{proof}
part, but change the two occurrences of the wordproof
intoexplanation
, the new PDF document would look similar to the one shown above with the difference that under the proof there'll be another proof that would look almost the same as the one above it, except that the first (i.e. right-most) word won't be "הוכחה" but rather "הסבר".