1

I would like to define a \Log command which does essentially the same as \log, but has a capital first letter (I want to use both of them). I am using amsart (I think this does not matter).

4
  • 2
    The kernel defines \def\log{\mathop{\operator@font log}\nolimits}, so i assume \def\Log{\mathop{\operator@font Log}\nolimits} can work. – Johannes_B Aug 19 '16 at 7:20
  • Thanks. Both worked fine for me. Can you shortly explain why the second one is better? – TheGeekGreek Aug 19 '16 at 7:25
  • Ah very nice. I will have a closer look at this. Thanks! – TheGeekGreek Aug 19 '16 at 7:28
  • 2
    @Johannes_B why not the standard \DeclaeMathOperator\Log{Log}? amsart is loading amsmath – daleif Aug 19 '16 at 7:39
4

The standard method of making \log like macros (requires amsmath, which amsart loads automatically) is to use

\DeclareMathOperator\Log{Log}

Addendum: If you instead use \DeclareMathOperator* then the created macro will behave like \lim, that is _n goes under the name in a displayed context

7
  • 2
    Isn't this a clear duplicate? – egreg Aug 19 '16 at 8:02
  • @egreg probably, it was faster to write an answer than to find the duplicate – daleif Aug 19 '16 at 8:38
  • 1
    I added an entry in the “Often referenced questions” meta thread. However, searching for declaremathoperators is:answer score:10 seems fast enough, doesn't it? tex.stackexchange.com/… – egreg Aug 19 '16 at 8:38
  • @egreg bookmarked – daleif Aug 19 '16 at 8:50
  • @egreg Personally, i find this answer better in terms of style. There is no mention of amsmath at all. Often, the questions we use for closing as dupe are of that kind of (missing) quality and many of them would need a bit of extra explanation. – Johannes_B Aug 21 '16 at 8:42

Not the answer you're looking for? Browse other questions tagged or ask your own question.