[Tex/LaTex] Typesetting mathematical formulas in line breaking

isoline-breakingmath-modetypography

When you typeset a mathematical formula is there a rule regarding the breaking of the formula in a new line, meaning if for instanse the formula breaks in a plus sign (+) or in a equal sign (=) then you must insert it in the new line also or is it enough if it is only in the previous line?

Is there a rule, for example, between this:

enter image description here

and this:

enter image description here

Edit I

As I understand from what has been written in my post I see that there are indeed some "rules" that must be used to produce a correct mathematical formula. Is there a way so the output to be produced automatically correct? If not it seems that it is quite a hard job to produce correct mathematical formulas.

Best Answer

I have never seen any rules on this, but both of your examples are quite hard to read. I will just point out some thoughts about readability:

  • a minus followed by a minus could be understood as a plus. When reading the whole formula (and not being used to such repetition like in Russia, as pointed out by egreg), I would read j sin z minus minus j sin z which makes me need to read it again.

  • it seems to be common style to set the sign in the next line. Your first example looks like a broken first line and a new equation on the second line. As the sign belongs to the term following, I would leave the sign always stuck to the right side term

  • In school and later in university I learned: "always put just one equal-sign on one line". I think that's a good rule to keep short formula lines and a nice aligning. (For sure, you know all the environments to do this)

As a reference I only found the German standard DIN 1338 from march 2011, which is the current standard at present. Concerning the breaking of formulae in case the lines are too long, they write:

  • if more than one = symbol is used in the formula, it shall be broken before this symbol. The equal symbols shall be set at the beginning of each line and aligned below the first = symbol.

  • long terms get broken before a + or - symbol. If possible, not inside of brackets (parentheses). The sign is set at the beginning of the new line but more to the right than the prior = symbol.

  • If a product must be split, the multiplication dot is set at the beginning of the new line but more to the right than the prior = symbol. If one of the factors consists of a big sum or difference, the previous rule (breaking sums) can be considered

  • Roots shall be written in power notation and broken as mentioned in the two previous rules. The same for fractions. The denominator shall be written as factor with negative power and broken like in rules 2 or 3

  • Units always have to stick to their value. (Using the siunitx package will prevent this type or error automatically)

On my earlier comment regarding the "one equal symbol per line": DIN 1338 and DIN EN ISO 80000-1 do not write a word about this topic, but they use multiple = symbols quite often. So this "rule" can already be revised.

Related Question