Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

The problem

Using this template I want to have an author in the list of authors with multiple affiliations.

Like in this mockup ("Othercoauthor" has multiple affiliations):

enter image description here

The code

This is some exemplary code (you only need ifmbe.cls):

\documentclass[nouppercase]{ifmbe}

\title{Authors With Multiple Affiliations}

\affiliation{First Institution/Department, Affiliation, City, Country }{FIRSTAFF}
\affiliation{Second Institution/Department, Affiliation, City, Country }{SECONDAFF}

\author{A.B. Firstauthor}{FIRSTAFF}
\author{C. Coauthor}{SECONDAFF}
\author{D.E. Othercoauthor}{FIRSTAFF}

\begin{document}

\maketitle

\end{document}

The output is the same as in the mockup except for the affiliations of "Othercoauthor" (only "1" in superscript).

The \author command is defined in ifmbe.cls like this:

\renewcommand{\author}[2]{
      \stepcounter{ifmbe@authors}
      \expandafter\def\csname ifmbe@author\alph{ifmbe@authors}\endcsname
      {#1$^{\expandafter\the\csname ifmbe@affiliationcounter#2\endcsname}$}
}

What I have tried

I tried "faking" it by putting superscript numbers into the author's name. However, the text size/shape of the numbers that I put manually there was slightly off and I couldn't figure out why.

I rewrote the renewing of \author such that the command took a larger number of arguments. However, this didn't help since I couldn't put "empty" affiliations for those authors that had less affiliations than the number of arguments.

So I guess I need to make the number of arguments variable or add optional arguments.

share|improve this question
add comment

1 Answer

up vote 7 down vote accepted

I did a basic redefinition of \author to include an optional argument; the value used in this argument will be appended, together with a comma, to the superscript number used in the affiliation:

\documentclass[nouppercase]{ifmbe}

\makeatletter
\renewcommand{\author}[3][]{
      \stepcounter{ifmbe@authors}
      \expandafter\def\csname ifmbe@author\alph{ifmbe@authors}\endcsname
      {#2$^{\expandafter\the\csname ifmbe@affiliationcounter#3\endcsname
        \if\relax\detokenize{#1}\relax\else,#1\fi}$}
}
\makeatother

\title{Authors With Multiple Affiliations}
\affiliation{First Institution/Department, Affiliation, City, Country }{FIRSTAFF}
\affiliation{Second Institution/Department, Affiliation, City, Country }{SECONDAFF}
\author{A.B. Firstauthor}{FIRSTAFF}
\author{C. Coauthor}{SECONDAFF}
\author[2]{D.E. Othercoauthor}{FIRSTAFF}

\begin{document}

\maketitle

\end{document}

enter image description here

A more general redefinition could be made, but for a one-case situation, this should be enough.

share|improve this answer
    
Nice workaround, thank you! Also works with multiple values like e.g. \author[2,3,4,5]{D.E. Othercoauthor}{FIRSTAFF} –  Tobold Apr 9 '13 at 16:05
    
@Tobold You're welcome. And yes, you can use multiple values (with the precaution of giving them in order). –  Gonzalo Medina Apr 9 '13 at 16:07
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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