Digital-Media / HagenbergThesis

Hagenberg LaTeX Thesis Template
Other
196 stars 45 forks source link

Replace $$ ... $$ with \[ ... \] #125

Closed hochleitner closed 3 years ago

hochleitner commented 3 years ago

The use of equations with $$ ... $$ seems to be discouraged in LaTeX since it's a plain TeX command. It can obviously break stuff as mentioned in the following sources:

Reading this I'd say we replace the part in mathematik.tex of the tutorial with the LaTeX friendly syntax, although I'm too little of a LaTeX math expert to say if there are any implications. I did a quick test and didn't see any changes. @imagingbook, could you confirm this?

Also, \( ... \) should then probably used instead of $ ... $ although there is definitely the case of readability that favors the dollar signs.

There are some pros and cons mentioned here: https://tex.stackexchange.com/questions/510/are-and-preferable-to-dollar-signs-for-math-mode. I'm not sure though if most of the things are relevant to our documents.

imagingbook commented 3 years ago

Reading this (which I did before) I'd say that they never really come forward with a good reason for replacing $ ... $ by \( ... \). Anyone is free to declare "deadly sins", but this one is unreasonable from my point. I strongly suggest to keep the old $...$ scheme simply because it is easier to type and read. Also, some editors do not seem to syntax-highlight properly with \( ... \). For displayed math I have no objections to change, since we use the AMS package anyways.

hochleitner commented 3 years ago

I agree, so let's replace the double dollar signs and leave the single ones the way they are (this is explicitly not in the deadly sins, only the $$, so I guess they are okay.

If you have a look at the last Stack Exchange link there are quite some discussions who LaTeX 3 will handle all of this. They're already 5 years old, not sure how that turned out or if it's still in discussion. But this is probably the best argument for one syntax or the other because it's probably the most future-proof way to go.

hochleitner commented 3 years ago

Closed with commit a971702.