- First off, your assumption is wrong that only the increase in value gets taxed. No, the entire value of your holding gets taxed, see § 6 Abs. 1 Satz 1 Außensteuergesetz (AStG) [1].
- The factor 13.75 originates from the calculation method called "vereinfachtes Ertragswertverfahren" (~ simplified earnings-based method), which itself is defined in Bewertungsgesetz (BewG), § 11 Wertpapiere und Anteile [2]
- Factor 13.75 is defined in Bewertungsgesetz (BewG), § 203 Kapitalisierungsfaktor [3]
- The tax rate of 42% is the marginal tax rate in Germany (at least below €250k income, beyond that it's 45%) - so the assumption here is that, in the year in which you leave Germany, you've already had some salary income (say, €90k) which bumps you into the marginal tax rate for any additional income on top of that.
[1] https://www.gesetze-im-internet.de/astg/__6.html