Clarification: The question may be related to the the quine fun question, but IMHO it is quite distinct.
The question here to write an "ouroboros" in TeX, i.e., a file that includes itself as a figure. In other words, the output should include in it a figure which presents the figure. In a sense, this is like a fractal, since the figure would show a the entire document, which hopefully is only one page. Now, in this figure, you would see a scaled down image of the output, which would have in it a figure.
In other words, the "ouroboros" is not a "quinn", but rather something like this image:

or this one:

Here is my attempt to do that:
\documentclass[twocolumn,10pt]{article}
\usepackage{pdfpages}
\usepackage{lipsum}
\title{The Ouroboros}
\author{U. Roboros}
\begin{document}
\maketitle
\lipsum[1]
\par
\begin{figure}
\includepdf[frame,scale=0.4]{ouroboros.pdf} %
\end{figure}
\par
\lipsum[3]
\par
\lipsum[2]
\end{document}
The idea is that in each run of the file through LaTeX, it would present an image, which is included as a figure in the next run.
This can be thought of as an amusing exercise, but a solution could be useful in writing documentation for TeX files; the idea being that you generate a LaTeX file,
e.g, using bashful, compile it, and then include it as a figure.
The above solution cannot work, since the moment you run latex, the previous PDF file is erased. Perhaps a solution would be to have two files, each including the other. Another option is to copy the input into a temporary file, compile it, and then include it.
Another issue with the above is that pdfpags seems, at least for me, to be in conflict with the figure environment.
Note that the some of the answers to Self-replicating (La)TeX document do similar things, let the file include itself in some sense. Here, this should be done at the rendered level, rather than on textual basis.






\includepdf[]{}starts a new page.figurecannot include a page break. So, yes, they are incompatible. And essentially so. You'd need\includegraphics[]{}instead... – cfr Mar 22 '15 at 00:18\includpdf. – Yossi Gil Mar 22 '15 at 01:39\let\newpage=\relaxbefore the\includepdfkills the new page (best be inside a group at that point). – Andrew Stacey Mar 22 '15 at 07:13\includegraphics? – cfr Mar 22 '15 at 14:46\includepdfeasier when I want a full page inclusion, ie I want the PDF page as the background to the current page, possibly for further annotation. With\includegraphicsthen TeX complains if the graphic is larger than the available text space on the page. – Andrew Stacey Mar 22 '15 at 20:53\includepdf, too. (Although I tend not to use it for backgrounds.) – cfr Mar 22 '15 at 21:11\newpagefrom\includepdfsince that was something I'd wanted to do myself. I hadn't thought about the context. Sorry. – Andrew Stacey Mar 23 '15 at 22:05=? If so, do you know why? Just curious....) – cfr Mar 23 '15 at 22:22=.\let\a\band\let\a=\bare the same. I find the second easier to see at a glance what it's doing so tend to put the equals sign in place. I understand that in the Good Old Days, tokens were precious and so the=was frowned upon. Nowadays, we're gluttonous about tokens so the difference is in the mind of the beholder. – Andrew Stacey Mar 23 '15 at 22:51=just makes me expect a number ;). – cfr Mar 23 '15 at 23:49