3

I have a problem with the proof enviroment. I'm writing my thesis in german, so the name for the proof enviroment should be Beweis and when I look online everybody says it will do that automatically. But in my case it doesn't it always says Proof: . The other Problem is it doesn't set an end of proof symbol which it should also do automatically. I tried making an new enviroment called {bew} but that doesn't help either I hope somebody can help me.
Here is my code:

\documentclass[12pt,a4paper,oneside,final]{amsbook}
%Sprache
\usepackage[ngerman]{babel}
\usepackage[T1]{fontenc}
%Zeichensatz
\usepackage[utf8]{inputenc}
%PDF Integrierung
\usepackage{pdfpages}
%Formatierung
\usepackage[left=3.5cm,right=2.5cm,top=2cm,bottom=2cm]{geometry}
\usepackage[onehalfspacing]{setspace}
%Mathepackages
\usepackage{amsfonts,amstext,amsmath,amsthm,amssymb,mathrsfs}
%Algorithmen
\usepackage{algorithm, program}
\usepackage{physics}
%diverses
\usepackage{enumerate}
\usepackage[section]{placeins}
\newcommand{\HRule}{\rule{\linewidth}{0.5mm}}
%Theoreme und Gleichungen
\numberwithin{equation}{chapter}
\numberwithin{figure}{chapter}
\newtheorem{prop}{Satz}
\newtheorem{lemma}{Lemma}
\newtheorem{korro}{Korollar}
\newtheorem{theorem}{Theorem}
\floatname{algorithm}{Algorithmus}
\newenvironment{bew}{\begin{proof}[Beweis]\end{proof}}

\begin{document}
\begin{proof}
Test 1
\end{proof}
\begin{proof}{Beweis}
Test 2
\end{proof}
\begin{bew}
Test 3
\end{bew}
\end{document}
  • @barbarabeeton Sadly that doesn't solve the Problem after including that line the problem still exists – Naro Sep 22 '16 at 19:41
  • @egreg -- hmmm. looked very thoroughly, but didn't find with grep in all language packages in the babel area. but since you've found the problem, deleting my comment. – barbara beeton Sep 22 '16 at 19:48
1

The program package is the culprit:

925 %% \proof macro for theorems and lemmas:
926 \def\proof{\normalshape{\setlength{\parskip}{0pt}\par\addvspace\medskipamount
927                         \noindent{\bf Proof: }}\ignorespaces}

(line numbers added for reference). It's of course a silly definition, but it overrides the one given by amsthm. The package also redefines \qed and \qedsymbol.

Here's a minimal example:

\documentclass{amsart}
\usepackage[ngerman]{babel}
\usepackage{program}

\begin{document}
\begin{proof}
xyz
\end{proof}

\end{document}

enter image description here

If I comment out \usepackage{program}, I get the expected result:

enter image description here

with the tombstone at the far end, omitted for getting a well sized picture.

However, you can't simply switch the order of packages, assuming you really need program.

What you can do is as follows (example reduced to a minimum):

\documentclass{amsart}
\usepackage[ngerman]{babel}

\usepackage{amsthm}
% save \proof, \qed and \qedsymbol
\let\amsthmproof\proof
\let\amsthmqed\qed
\let\amsthmqedsymbol\qedsymbol
% load program
\usepackage{program}
% revert
\let\proof\amsthmproof
\let\qed\amsthmqed
\let\qedsymbol\amsthmqedsymbol

\begin{document}

\begin{proof}
xyz
\end{proof}

\end{document}

Loading amsthm with amsart or amsbook is not required, because these classes use their own version, but it is important in case you decide to change document class.

As far as I can tell, all language definition files provided with babel feature a localization of \proofname; here's the output of a grep search:

/usr/local/texlive/2016/texmf-dist/tex/generic/babel-albanian/albanian.ldf:65:  \def\proofname{V\"ertetim}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-bahasa/bahasai.ldf:106:  \def\proofname{Bukti}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-bahasa/bahasam.ldf:109:  \def\proofname{Bukti}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-basque/basque.ldf:75:  \def\proofname{Frogapena}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-belarusian/belarusianb.ldf:172:    \def\proofname{Доказ}%  [amsthm]
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-belarusian/belarusianb.ldf:236:    \def\proofname{Доказ}%  [amsthm]
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-belarusian/belarusianb.ldf:292:    \def\proofname{\CYRD\cyro\cyrk\cyra\cyrz}%  [amsthm]
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-belarusian/belarusianb.ldf:343:    \def\proofname{\CYRD\cyro\cyrk\cyra\cyrz}%  [amsthm]
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-bosnian/bosnian.ldf:65:  \def\proofname{Dokaz}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-breton/breton.ldf:74:  \def\proofname{Proof}%  <-- needs translation
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-bulgarian/bulgarian.ldf:190:  \def\proofname{%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-bulgarian/bulgarian.ldf:219:  \SetString\proofname{Доказателство}
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-bulgarian/bulgarian.ldf:267:  \SetString\proofname{%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-catalan/catalan.ldf:77:  \def\proofname{Demostraci\'o}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-croatian/croatian.ldf:71:  \def\proofname{Dokaz}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-czech/czech.ldf:103:  \def\proofname{D\r{u}kaz}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-danish/danish.ldf:72:  \def\proofname{Bevis}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-dutch/dutch.ldf:84:        \def\proofname{Bew"ys}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-dutch/dutch.ldf:123:    \def\proofname{Bewys}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-english/english.ldf:133:  \def\proofname{Proof}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-esperanto/esperanto.ldf:72:  \def\proofname{Pruvo}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-estonian/estonian.ldf:76:  \def\proofname{T\~oestus}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-finnish/finnish.ldf:71:  \def\proofname{Todistus}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-french/frenchb.ldf:806:   \SetString{\proofname}{Démonstration}
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-french/frenchb.ldf:831:   \SetString{\proofname}{D\'emonstration}
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-friulan/friulan.ldf:56:    \def\proofname{Dimostrazion}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-galician/galician.ldf:106:  \def\proofname{Demostraci\'on}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-georgian/georgiancaps.tex:35:    \def\proofname{დამტკიცება}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-georgian/georgiancaps.tex:60:    \def\proofname{\geod\geoa\geom\geot\geok\geoi\geoc\geoe\geob\geoa}
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-georgian/georgiancaps.tex:83:    \def\proofnamecap{\GEOD\GEOA\GEOM\GEOT\GEOK\GEOI\GEOC\GEOE\GEOB\GEOA}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-german/germanb.ldf:90:  \def\proofname{Beweis}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-german/ngermanb.ldf:68:  \def\proofname{Beweis}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-greek/greek.ldf:166:  \def\proofname{\textAlpha\textpi\acctonos\textomicron
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-greek/greek.ldf:181:  \def\proofname{\accpsili\textAlpha\textpi\acctonos\textomicron
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-greek/greek.ldf:220:  \def\proofname{\accpsili\textAlpha\textpi\acctonos\textomicron\textdelta\textepsilon
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-hebrew/hebrew.ldf:106:  \def\proofname{\@ensure@R{\hebhe\hebvav\hebkaf\hebhet\hebhe}}
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-hungarian/magyar.ldf:1598:  \def\proofname{Bizony\'\i t\'as}% AMS-\LaTeX
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-icelandic/icelandic.ldf:77:  \SetString{\proofname}{Sönnun}
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-icelandic/icelandic.ldf:104:  \SetString{\proofname}{S\"{o}nnun}
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-interlingua/interlingua.ldf:72:  \def\proofname{Prova}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-irish/irish.ldf:72:  \def\proofname{Cruth\'unas}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-italian/italian.ldf:48:  \def\proofname{Dimostrazione}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-kurmanji/kurmanji.ldf:76: \def\proofname{Del{\^\i}l}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-latin/latin.ldf:74:  \def\proofname{Demonstratio}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-macedonian/macedonian.ldf:199:    \def\proofname{%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-norsk/norsk.ldf:75:    \def\proofname{Bevis}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-norsk/norsk.ldf:101:    \def\proofname{Bevis}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-occitan/occitan.ldf:45:   \def\proofname{Demostracion}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-piedmontese/piedmontese.ldf:49:    \def\proofname{Dimostrassion}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-polish/polish.ldf:74:  \def\proofname{Dow\'od}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-portuges/portuges.ldf:102:    \def\proofname{Demonstra\c{c}\~ao}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-portuges/portuges.ldf:134:    \def\proofname{Demonstra\c{c}\~ao}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-romanian/romanian.ldf:74:  \def\proofname{Demonstra\c{t}ie} %
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-romansh/romansh.ldf:25:  \def\proofname{Demonstraziun}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-russian/russianb.ldf:174:    \def\proofname{Доказательство}%  [amsthm]
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-russian/russianb.ldf:240:    \def\proofname{Доказательство}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-russian/russianb.ldf:317:    \def\proofname{{\cyr\CYRD\cyro\cyrk\cyra\cyrz\cyra\cyrt
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-russian/russianb.ldf:390:    \def\proofname{{\cyr\CYRD\cyro\cyrk\cyra\cyrz\cyra\cyrt
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-samin/samin.ldf:71:  \def\proofname{Duo\dj{}a\v stus}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-scottish/scottish.ldf:71:  \def\proofname{Proof}%    <-- needs translation
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-serbian/serbian.ldf:65:  \def\proofname{Dokaz}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-serbianc/serbianc.ldf:59:  \def\proofname{\CYRD\cyro\cyrk\cyra\cyrz}%{Доказ}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-slovak/slovak.ldf:106:  \def\proofname{D\^okaz}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-slovenian/slovene.ldf:71:  \def\proofname{Dokaz}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-sorbian/lsorbian.ldf:82:  \def\proofname{Proof}%  <-- needs translation
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-sorbian/usorbian.ldf:82:  \def\proofname{Proof}%  <-- needs translation
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-spanglish/spanglish.ldf:63:  \def\proofname{Demostraci\'on}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-spanish/spanish.ldf:131:  \SetString{\proofname}{Demostración}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-spanish/spanish.ldf:158:  \SetString{\proofname}{Demostraci\'{o}n}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-swedish/swedish.ldf:71:  \def\proofname{Bevis}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-thai/thai.ldf:128:  \def\proofname{\thaiPhoPhan\thaiSaraI%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-turkish/turkish.ldf:72:  \def\proofname{Kan\i t}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-turkish/turkish.ldf:104:  \SetString\proofname{Kanıt}
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-turkish/turkish.ldf:144:  \SetString\proofname{Kan\i t}
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-ukrainian/ukraineb.ldf:166:  \def\proofname{{\cyr\CYRD\cyro\cyrv\cyre\cyrd\cyre\cyrn\cyrn\cyrya}}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-vietnamese/vietnamese.ldf:98:  \SetString{\proofname}{Chứng minh}
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-vietnamese/vietnamese.ldf:137:  \SetString{\proofname}{Ch\'\uhorn ng minh}%
/usr/local/texlive/2016/texmf-dist/tex/generic/babel-welsh/welsh.ldf:74:  \SetString{\proofname}{Prawf}
  • Thank you very much ! That solved the problem. I had some problems with the program package before. Seems like the package is the cause for a lot of conflict. Next time i will try to avoid it. – Naro Sep 22 '16 at 19:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.