0
\documentclass{article}
\usepackage{geometry}
\usepackage{amsthm, amsmath, amssymb}
\usepackage{anyfontsize}
\newgeometry{vmargin={15mm}, hmargin={12mm}}
\makeatletter
\newcommand{\mathleft}{\@fleqntrue\@mathmargin0pt}
\newcommand{\mathcenter}{\@fleqnfalse}
\makeatother


\begin{document}
\fontsize{18}{21.6}
\mathleft
\begin{gather*}
    8x^2+10x-3=0\\\\
    8x^2-2x+12x-3=0\\\\
    2x(4x-1)+3(4x-1)=0\\\\
    (2x+3)(4x-1)=0\\\\
    x=-\frac{3}{2}\;or\;\frac{1}{4}\\\\\\\\\\\\
    -7x^2-4x+3=0\\\\
    -7x^2-7x+3x+3=0\\\\
    -7x(x+1)+3(x+1)=0\\\\
    (3-7x)(x+1)=0\\\\
    x=\frac{3}{7}\;or\;-1\\\\\\\\\\\\
    x^2+4=8x-8\\\\
    x^2-8x+12=0\\\\
    x^2-2x-6x+12=0\\\\
    x(x-2)+-6(x-2)=0\\\\
    (x-6)(x-2)=0\\\\
    x=2\;or\;6
\end{gather*}

\end{document}

When I run this code I get a pdf with the first page blank and some of the actual text outside the page. How can I fix it so that it does not leave a blank page and the text stays in the page so that if it can't fit it creates a new page and puts the text there. Both of these issues disappear if the text between begin gather and end gather is small, but how do I make it work regardless of the amount of text or size of the font? The question is similar to this but I am not using the xcolor package or counters. To get the pdf I am using the TexShop application installed from mactex.

1 Answers1

3

Your content won't fit the page at that font size, and gather won't allow a page break. You can add \allowdisplaybreaks[1] to your preamble to change this behavior. See: https://tex.stackexchange.com/a/57344

rmolina
  • 183