0

to meet the requirements for our lab reports I need to use a special citation style. It is basically the numeric-comp style from biblatex but the citations shall be superscripts. Everything else is to be the same. As I am using KOMA-Script(documentclass scrartcl), I cannot load the cite-package, because LaTeX tells me they are incompatible. For now, I used this trick below but that is not a good solution, as I would have to define a new command for every different number of references when multiple citing.

\newcommand{\supcite}[1]{$^{\text{\cite{#1}}}$}

I am using Biber, if that is relevant. Does anyone have a solution for this problem? Thanks in advance.

  • Welcome to TeX SX! Did you try with biblatex? It's easier to customise. – Bernard Apr 15 '16 at 14:01
  • 1
    You can use the command \supercite. If you insist you can reroute \cite to \supercite. Note though that in that case you can't use pre- or postnotes. – moewe Apr 15 '16 at 15:38
  • 1
    Off-topic: They should probably be text superscripts rather than maths superscripts. – cfr Apr 15 '16 at 23:41
  • The \supercite command fits my needs except of one thing: The citations are not put in brackets which is needed (and I would prefer it because I am often citing specific data so that the citations might be mixed up with exponents). Is it possible to modify the \supercite command? – Enno Apr 18 '16 at 6:46
  • Check out Biblatex supercite command with use of square brackets (like a reference style in Wikipedia). Though you probably need to move those \bibopenbrackets/\bibclosebrackets a bit, and there are some changes needed for numeric-comp, so I have written down the answer below. – moewe Apr 18 '16 at 11:51
3

Just use the following redefinition of \supercite with just \bibopenbracket and \bibclosebracket sprinkled in.

\DeclareCiteCommand{\supercite}[\mkbibsuperscript]
  {\bibopenbracket
   \usebibmacro{cite:init}%
   \let\multicitedelim=\supercitedelim
   \iffieldundef{prenote}
     {}
     {\BibliographyWarning{Ignoring prenote argument}}%
   \iffieldundef{postnote}
     {}
     {\BibliographyWarning{Ignoring postnote argument}}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:comp}}
  {}
  {\usebibmacro{cite:dump}%
   \bibclosebracket}

If you replace the \supercite above by \cite you redefine the standard \cite command.

  • As far I can see this solves my problem. Thanks a lot! – Enno Apr 18 '16 at 15:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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