[NTG-context] How to typeset differential (math)?

Procházka Lukáš Ing. - Pontex s. r. o. LPr at pontex.cz
Wed Jun 17 16:35:38 CEST 2015


On Wed, 17 Jun 2015 16:23:01 +0200, Manuel Blanco <manuelbl at ucm.es> wrote:

> The easy way to answer that:
> \definemathcommand[dif][nolop]{\mfunction{d}} didn't work because it's
> intended for log-like functions, and you don't want a log-like
> function, but a differential, which behaves differently (for instance,
> you *want* space between the function and the argument in `\sin x \cos
> y` but you *don't want* spaces between the “d” and the variable in
> `\dif x \dif y`).
> About `\mfunction` I don't know, I think what's in the wiki is enough,
> it's the command that sets the font used for other upright functions
> (notice that some people prefer italic differentials hence the
> definition would be \define\dif{\mathop{}\!d}).
> And about how does that work, well, basically what you want is a thin
> space added on the left, but not on the right, so \mathop{} gives a
> thin space on both sides, then with \! you remove the thin space on
> the right and you then leave the \mfunction{d} with normal spacing.
> That definition behaves correctly in every case (except if you use
> “physics-like” notation where the differential comes just after \int).
> I hope I don't leave anything relevant out (but I'm no expert).

... thank you for deep explanation!


Ing. Lukáš Procházka | mailto:LPr at pontex.cz
Pontex s. r. o.      | mailto:pontex at pontex.cz | http://www.pontex.cz
Bezová 1658
147 14 Praha 4

Tel: +420 241 096 751
Fax: +420 244 461 038

More information about the ntg-context mailing list