On 9/01/2019 3:28 AM, Bernt Lie wrote:
I use LyX 2.3.1 under Windows 10.I'm trying to create an "operator" for the infinitesimal d. Thus, instead of writing $dx$ -- which leads to "d" in italic font, I go to Document/Settings... and the LaTeX Preamble field: \DeclareMathOperator{\diff}{d} Next, in the document, I write $\diff x$, i.e., I type: \diff + space + x when in math mode. The result is that "d" is typeset in roman font, which is what I want. HOWEVER, the spacing between the roman d and the x is a little bit too large to be pretty. OK -- I have tried to insert a negative space (\! + space) in the document, and that helps. However, now the spacing is a little bit too small... * Question: is there a slightly smaller negative spacing? Also: how can I insert the negative space into the operator definition? Doing: \DeclareMathOperator{\diff}{\! d} doesn't work. Thanks! -B
For your interest, I recently uploaded version 3 of my diffcoeff package to CTAN. This provides a command \diff for writing differential coefficients (derivatives) with multiple options for tweaking the display, and a command \dl for writing differentials with an option for inserting a specified amount of space before the differential -- something you might want to do in an integral for instance to separate the integrand from the dx.
Andrew --- This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus
