[NTG-context] Bug in math alignment

Otared Kavian otared at gmail.com
Wed Nov 2 10:38:01 CET 2022


Hi Hans and Mikael,

I think there is an issue with the size of math fonts in \frac when used in math alignments, as it is is shown in the following example.


%% begin bug-mathalignment.tex
\definemathmatrix[alignedcases]
	[align={1:right,2:left,3:left},
	distance=3pt,
	left={\left\{},
	right={\right.},
	style=\displaystyle]

\starttext
Consider this
\placeformula
\startformula
\startalignedcases
\NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
\NC  \frac{\partial u}{\partial {\bi n}} \NC = V u + \phi \NC \qquad\text{on }\, \partial\Omega. \NR
\stopalignedcases
\stopformula
or this (with\type{\displaystyle} added)
\placeformula 
\startformula
\startalignedcases
\NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
\NC  \displaystyle\frac{\partial u}{\partial {\bi n}} \NC = V u + \phi \NC \qquad\text{on }\, \partial\Omega. \NR
\stopalignedcases
\stopformula
Actually, one should have this
\startformula
\frac{\partial u}{\partial {\bi n}}  = V u + \phi  \qquad\text{on }\, \partial\Omega.
\stopformula
If one adds \type{\displaystyle} both to the numerator and denominator of \type{\frac}, the result is correct:
\placeformula 
\startformula
\startalignedcases
\NC - \Delta u \NC = 0 \NC \qquad\text{in }\, \Omega \NR
\NC  \frac{\displaystyle\partial u}{\displaystyle\partial {\bi n}} \NC = V u + \phi \NC \qquad\text{on }\, \partial\Omega. \NR
\stopalignedcases
\stopformula

\stoptext
%% end bug-mathalignment.tex



More information about the ntg-context mailing list