LaTeX forum ⇒ Graphics, Figures & Tableswide figures in 1st page for two column documents

Information and discussion about graphics, figures & tables in LaTeX documents.
abhijit8
Posts: 4
Joined: Tue Nov 02, 2010 12:08 pm

wide figures in 1st page for two column documents

Postby abhijit8 » Tue Nov 02, 2010 2:59 pm

I want to place figures on the front page of a two column document, something like http://frank.dellaert.com/pubs/Dellaert10iros.pdf and this(pdf).

The figure* allows to include images spread across full width of two column documents. But it has some limitations. Only top(t) placement works, and does not appear on the same page where they are defined. I found stfloats package, which solves the top placement restriction, but it still demands to be defined 1 page prior.

Any suggestions on how to solve this?
Last edited by abhijit8 on Wed Nov 03, 2010 10:31 am, edited 1 time in total.

User avatar
localghost
Site Moderator
Posts: 9204
Joined: Fri Feb 02, 2007 12:06 pm

Postby localghost » Tue Nov 02, 2010 9:32 pm

I see two approaches which only differ in the caption for the image right beneath the title.

  1. For the first document with caption.
    1. \documentclass[11pt,a4paper,english]{article}
    2. \usepackage[T1]{fontenc}
    3. \usepackage[latin1]{inputenc}
    4. \usepackage{babel}
    5. \usepackage[font=small,labelfont=bf,tableposition=top]{caption}
    6. \usepackage{multicol}
    7. \usepackage{blindtext}
    8.  
    9. \title{Two column document with figure underneath title}
    10. \author{abhijit8}
    11.  
    12. \begin{document}
    13. \maketitle
    14. \noindent
    15. \begin{minipage}{\textwidth}
    16. \centering\noindent
    17. \rule{0.75\linewidth}{0.5\linewidth}
    18. \captionof{figure}{\blindtext}
    19. \end{minipage}
    20.  
    21. \begin{multicols}{2}
    22. \blinddocument
    23. \end{multicols}
    24. \end{document}
  2. For the second document without caption.
    1. \documentclass[11pt,a4paper,english]{article}
    2. \usepackage[T1]{fontenc}
    3. \usepackage[latin1]{inputenc}
    4. \usepackage{babel}
    5. \usepackage[font=small,labelfont=bf,tableposition=top]{caption}
    6. \usepackage{multicol}
    7. \usepackage{blindtext}
    8.  
    9. \title{Two column document with image underneath title\\ \normalsize Approach 1}
    10. \author{abhijit8}
    11.  
    12. \begin{document}
    13. \maketitle
    14. \noindent
    15. \begin{minipage}{\textwidth}
    16. \centering\noindent
    17. \rule{0.9\linewidth}{0.2\linewidth}
    18. \end{minipage}
    19.  
    20. \begin{multicols}{2}
    21. \blinddocument
    22. \end{multicols}
    23. \end{document}

    For this case there is a second solution.
    1. \documentclass[11pt,a4paper,twocolumn,english]{article}
    2. \usepackage[T1]{fontenc}
    3. \usepackage[latin1]{inputenc}
    4. \usepackage{babel}
    5. \usepackage[font=small,labelfont=bf,tableposition=top]{caption}
    6. \usepackage{blindtext}
    7.  
    8. \title{Two column document with image underneath title\\ \normalsize Approach 2}
    9. \author{abhijit8}
    10. \date{\rule{0.9\linewidth}{0.2\linewidth}}
    11.  
    12. \begin{document}
    13. \maketitle
    14.  
    15. \blinddocument
    16. \end{document}
The rest depends on the used document class.

Note that the blindtext package is only loaded for creating dummy text thus is not part of the solution.


Best regards and welcome to the board
Thorsten
LaTeX Community Moderator
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes


¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1

abhijit8
Posts: 4
Joined: Tue Nov 02, 2010 12:08 pm

Postby abhijit8 » Wed Nov 03, 2010 10:20 am

Thanks a lot for the solutions. Is there a way to do away with the multiciols environment, since i need to use floats like figures. I tried /twocolumn instead of \begin{multicols}{2}, but it forces a new page.

I have found an another solution, by the use of \begin{strip}..\end{strip} environment, included in the cuted package.

  1. \documentclass[11pt,a4paper,two column,english]{article}
  2. \usepackage[T1]{fontenc}
  3. \usepackage[latin1]{inputenc}
  4. \usepackage{babel}
  5. \usepackage[font=small,labelfont=bf,tableposition=top]{caption}
  6. \usepackage{blindtext}
  7. \usepackage{cuted}
  8.  
  9. \title{Two column document with figure underneath title}
  10. \author{abhijit8}
  11.  
  12. \begin{document}
  13. \maketitle
  14. \noindent
  15.  
  16. \begin{strip}
  17. \centering\noindent
  18. \rule{0.75\linewidth}{0.5\linewidth}
  19. \captionof{figure}{\blindtext}
  20. \end{strip}
  21.  
  22. \blinddocument
  23. \end{document}

User avatar
localghost
Site Moderator
Posts: 9204
Joined: Fri Feb 02, 2007 12:06 pm

Postby localghost » Wed Nov 03, 2010 10:29 am

I can't really follow. You can use floats (starred versions) as usual within the multicols environment. As you already discovered on your own, the \twocolumn switch is no option.
LaTeX Community Moderator
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes


¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1

abhijit8
Posts: 4
Joined: Tue Nov 02, 2010 12:08 pm

Postby abhijit8 » Wed Nov 03, 2010 10:46 am

Sorry for the confusion. I was trying to say that I am not able to use standard figure/table (non-starred) in the multicols environment. I get an error:
./new.tex:0:Floats and marginpars not allowed inside `multicols'environment!.


Is there a way to use the standard floats inside multicols environment?
Otherwise, I am now able to get the desired output with the strip environment.

User avatar
localghost
Site Moderator
Posts: 9204
Joined: Fri Feb 02, 2007 12:06 pm

Postby localghost » Wed Nov 03, 2010 11:22 am

abhijit8 wrote:[…] I was trying to say that I am not able to use standard figure/table (non-starred) in the multicols environment. […] Is there a way to use the standard floats inside multicols environment? […]

Perhaps you should be more precise about what you are after. The unstarred versions can't be used here. But if we are talking about figures and tables within one column of a multicolumn environment, you can use an approach that works with the caption package.
  1. \documentclass[11pt,a4paper,twocolumn,english]{article}
  2. \usepackage[T1]{fontenc}
  3. \usepackage[utf8]{inputenc}
  4. \usepackage{babel}
  5. \usepackage[font=small,labelfont=bf,tableposition=top]{caption}
  6. \usepackage{blindtext}
  7. \usepackage{cuted}
  8.  
  9. \title{Two column document with figure underneath title}
  10. \author{abhijit8}
  11.  
  12. \begin{document}
  13. \maketitle
  14.  
  15. \begin{strip}
  16. \centering\noindent
  17. \rule{0.75\linewidth}{0.5\linewidth}
  18. \captionof{figure}{\blindtext}
  19. \end{strip}
  20.  
  21. \blindtext[2]
  22.  
  23. \medskip
  24. \noindent
  25. \begin{minipage}{\linewidth}
  26. \centering
  27. \rule{0.75\linewidth}{0.5\linewidth}
  28. \captionof{figure}{The quick brown fox jumps over the lazy dog}
  29. \end{minipage}
  30.  
  31. \medskip
  32. \blindtext[4]
  33. \end{document}

And thanks for bringing the very useful cuted package to my attention. It could be the solution to some older discussions about related problems here.
LaTeX Community Moderator
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes


¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1


Return to “Graphics, Figures & Tables”

Who is online

Users browsing this forum: No registered users and 6 guests