The following is just an example that gives the general idea. It contains a patch of the \chapter
command that is suitable for the standard book class; for other document classes, the patch could (and in general will) be different. Of course, etoolbox's \patchcmd
could be used instead.
\documentclass[a4paper]{book}
\usepackage[T1]{fontenc}
\usepackage{lipsum}
\makeatletter
\renewcommand\chapter{%
% \if@openright\cleardoublepage\else\clearpage\fi
\vfil \penalty-9000 \vfilneg
% Something from the following two lines could be retained:
% \thispagestyle{plain}%
% \global\@topnum\z@
\@afterindentfalse
\secdef\@chapter\@schapter
}
\makeatother
% \tracingpages = 1
\begin{document}
\chapter{First}
\lipsum[1-16]
\chapter{Second}
A very short chapter.
\chapter{Third}
Another very short chapter.
\chapter{Fourth}
This is true minimalism.
\chapter{Fifth}
\lipsum[17-20]
\chapter{Sixth}
\lipsum[21]
\chapter{Seventh}
\lipsum[22]
\chapter{Eighth}
\lipsum[23-24]
\chapter{Ninth}
\lipsum[25-32]
\chapter{Tenth}
And so on\ldots
\end{document}
Edit
As another example, for the memoir class (as explicitly requested), the patch would be:
\documentclass[a4paper]{memoir}
\usepackage[T1]{fontenc}
\usepackage{lipsum}
\makeatletter
\renewcommand\chapter{%
% Do not remove support for "article" option:
\ifartopt\par\@nameuse{chapterblock}\else
% \clearforchapter
\vfil \penalty-9000 \vfilneg
% Something from the following two lines could be retained:
% \thispagestyle{chapter}
% \global\@topnum\z@
\fi
\m@mindentafterchapter
\@ifstar{\@m@mschapter}{\@m@mchapter}%
}
\makeatother
% \tracingpages = 1
\begin{document}
\chapter{First}
\lipsum[1-16]
\chapter{Second}
A very short chapter.
\chapter{Third}
Another very short chapter.
\chapter{Fourth}
This is true minimalism.
\chapter{Fifth}
\lipsum[17-20]
\chapter{Sixth}
\lipsum[21]
\chapter{Seventh}
\lipsum[22]
\chapter{Eighth}
\lipsum[23-24]
\chapter{Ninth}
\lipsum[25-32]
\chapter{Tenth}
And so on\ldots
\end{document}
And so on…
\filbreak
command of plain TeX, provided that you prohibit page breaks in the first page or so of every chapter. – GuM May 19 '15 at 16:14\vfil\penalty-500\vfilneg
. 500 units of "bonus" should be enough to overcome other bonuses that might occur in the first few lines of the new chapter. – GuM May 19 '15 at 16:44