18

I am trying to insert a abstract into my document as shown below, this gives me an error 'Environment abstract undefined'. I have used this format a few times without this problem occurring, I believe this is down to the use of book as a document class. I don't want the abstract to be a chapter.

\documentclass[a4paper,10pt]{book}
\usepackage[utf8]{inputenc}

\begin{document} \begin{abstract} Insert anstract here \end{abstract}

marli
  • 165
mitchnufc
  • 699
  • That is true; book does not define an abstract environment, while something like article does. What do you want the output to look like... similar to that of article? – Werner Mar 03 '13 at 17:53
  • 2
    You should have a look at http://tex.stackexchange.com/questions/68222/define-abstract-environment-in-book. – jub0bs Mar 03 '13 at 18:34
  • similar to an article but with chapters includes. I don't like the standard article document, as I was using far too many subsections. – mitchnufc Mar 03 '13 at 20:11

3 Answers3

21

Other than the suggested link in one of the comments, you may also simply use:

\addchap*{Abstract}

To have a nice chapter heading that does not appear in the ToC. At least, that is the way to go when using the class scrbook.

For the document class book, you can use:

\chapter*{Abstract}

To achieve the same.

user26372
  • 1,706
5

I would solve it in this way:

\documentclass{book}
\usepackage{lipsum}

%   Reduce the margin of the summary:
\def\changemargin#1#2{\list{}{\rightmargin#2\leftmargin#1}\item[]}
\let\endchangemargin=\endlist 

%   Generate the environment for the abstract:
\newcommand\summaryname{Abstract}
\newenvironment{Abstract}%
    {\small\begin{center}%
    \bfseries{\summaryname} \end{center}}

\begin{document}

\chapter{Title of the chapter}

% Insert bastract
\begin{Abstract}
\begin{changemargin}{1cm}{1cm}
Your text:\lipsum[10]
\end{changemargin}
\end{Abstract}

\section{Title of the section}
\lipsum[17]

\end{document}

enter image description here

Lord AX
  • 61
4

You can use the abstract package, which contains \renewenvironment{abstract} and its own implementation. But since this environment is not defined in book, we should define it first:

\newenvironment{abstract}{}{}
\usepackage{abstract}