[Tex/LaTex] How to Enter Address in LyX in this form

addressesformattinglyx

I am currently in article AMS document class. In LyX I'd like to enter my name and address in the following form:

enter image description here

Note that there's not a large gap between the author's name and the address. I would prefer not to include the address in the author section (since I am creating a 2-sided document whose headers alternate between a short title and the author).

In LyX I have two options that I am aware of:

  1. Use Address mode in Front Matter. The problem with this is that it includes the address at the end of the document.

  2. Enter it manually. I enter the address in standard mode then center it but there's still too much spacing between the author and the address (e.g., when I put .1 cm of vertical space, I get over an inch of space in the PDF).

How can I enter my address so that it appears as in the picture above AND does not part of Author? If I need to directly change the source code (i.e., editing the preamble, settings or entering an ERT), please include some detail on how I can go about that.

MWE

 \documentclass[oneside,english]{amsart}
 \usepackage[T1]{fontenc}
 \usepackage[latin9]{inputenc}
 \usepackage{amsthm}

 \makeatletter
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Textclass specific LaTeX commands.
 \numberwithin{equation}{section}
 \numberwithin{figure}{section}

 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.
 \title[Short version]{Long version}
 \usepackage{mathtools}

 \makeatother

 \usepackage{babel}
 \begin{document}

 \title{{\small{Title}}}


 \author{Author\\
 }


 \address{Address }\maketitle

 \end{document}

Best Answer

To have the ultimate control over where this content is displayed and whether/not it ends up elsewhere in the document, I would patch \@maketitle in the Document > Settings... > LaTeX Preamble using etoolbox:

\usepackage{etoolbox}

\patchcmd{\@maketitle}% <cmd>
  {\ifx\@empty\@dedicatory}% <search>
  {\smallskip
    \begin{center}
    \footnotesize% Size of the address content
    \begin{tabular}{c}
      Department of Who Cares \\
      University of Nowhere \\
      Randomville, RND
    \end{tabular}
  \end{center}
  \ifx\@empty\@dedicatory}% <replace>
  {}{}% <success><failure>

The above patch inserts the address just after setting the authors - \@setauthors - and just before the dedicatory - \@dedicatory. Note that some other packages may redefine \@maketitle. This patch works under the default definition of \@maketitle, which forms part of amsart.

enter image description here

enter image description here

Related Question