\documentclass{article}
\usepackage[fleqn]{amsmath}
\usepackage[pdf,cfg=quiz,forpaper,pointsonleft,
% compile with exactly one of the following three
    nosolutions
%    answerkey
%    vspacewithsolns
]{eqexam}

\examNum{2}\numVersions{2}\forVersion{a}
\longTitleText
    {Quiz~\nExam--003}
    {Quiz~\nExam--007}
\endlongTitleText
\shortTitleText
    {Q{\nExam}s3}
    {Q{\nExam}s7}
\endshortTitleText


\title[\sExam]{\bfseries\Exam}
\author{D. P. Story}
\subject[C1]{Calculus I}
\date{Spring \the\year}
\keywords{Test~\nExam, Section \vA{003}\vB{007}}
\email{dpstory@uakron.edu}

\vspacewithkeyOn
\solAtEndFormatting{\eqequesitemsep{3pt}}
\everymath{\displaystyle}

\begin{document}

\maketitle

\begin{exam}{qz02}

\begin{instructions}[Global Instructions:]
Solve each of the following problems without error. \textit{Show all details.} Box in your
$\boxed{\text{answers.}}$ Use good notation, you \emph{will} be marked off for bad notation.
\end{instructions}

\begin{problem}[3]
Identify all numbers $x$ at which the function $ f(x) = \frac{x+2}{\sqrt{\vA{x-1}\vB{2-x}}} $ is continuous.

\begin{solution}[.75in]
We require $ \vA{x - 1}\vB{2-x} >0 $ or $ \vA{x > 1}\vB{x<2} $. In
interval notation, the set of all numbers at which $f$ is continuous is
$\boxed{\vA{( 1, \infty )}\vB{(-\infty, 2)} }$.
\end{solution}
\end{problem}

\begin{problem}[3]
Given  $ f(x) = \begin{cases}
    3x^2 - 2x           & x < -1 \\
    6x^2  + x \vB{+1}   & x \ge -1
\end{cases}$. Is this function (a) continuous at $ x = -1 $;, (b)~discontinuous with a removable discontinuity
at $ x = -1 $; or (c)~discontinuous with a jump discontinuity at $ x = -1 $?  Justify your response.

\begin{solution}[2in]
Look at the left and right limits:
\begin{align*}
    \lim_{x\to-1^-}f(x) &= \lim_{x\to-1^-} 3x^2 - 2x = 5\\
    \lim_{x\to-1^+}f(x) &= \lim_{x\to-1^+}  6x^2  + x \vB{+1} = \vA{5}\vB{6} \vA{=}\vB{\neq} f(-1)
\end{align*}
Thus, $\lim_{x\to-1^-}f(x) \vA{=}\vB{\neq}
\lim_{x\to-1^+}f(x)\vA{=f(-1)}$. The two sided limit \vA{exists}\vB{does
not exist}\vA{ and $\lim_{x\to-1}f(x)=f(-1)$}. This function \vA{is}\vB{is
not} continuous at $x=-1$, \vB{it has a jump discontinuity, since
$\lim_{x\to-1^-}f(x) \neq \lim_{x\to-1^+}f(x)$}; as a result, the answer
is \vA{(a)}\vB{(c)}.
\end{solution}
\end{problem}

\begin{problem}[4]
Define the function $ f(x) = 3x^2 - 2x $. Use one of the formulas:
\[
        m = \lim_{x\to a} \frac{f(x) - f(a)}{x-a}\quad\text{or}\quad
        m = \lim_{h\to 0} \frac{f(a+h) - f(a)}{h}
\]
Then the slope of the line tangent to the graph of $f$ at the point $
\vA{( 1, 1 )}\vB{(-1,5)} $.

\renameSolnAfterTo{}
\begin{solution}[2in]\ifkeyalt We make the following calculations:\fi
\begin{multicols}{2}
\noindent\textbf{Calculations}
\begin{verA}
\begin{alignat*}{2}
    m &= \lim_{x\to1} \frac{f(x)-f(1)}{x-1}\\&
        = \lim_{x\to1} 3x+1&&\quad\text{from side calc}\\&
        = \boxed4
\end{alignat*}
\end{verA}
\begin{verB}
\begin{alignat*}{2}
    m &= \lim_{x\to-1} \frac{f(x)-f(-1)}{x+1}\\&
        = \lim_{x\to-1} 3x-5&&\quad\text{from side calc}\\&
        = \boxed{-8}
\end{alignat*}
\end{verB}

\columnbreak
\noindent\textbf{Side Calculations}
\begin{verA}
\begin{align*}
    f(x)-f(1) &= 3x^2 - 2x - 1\\&
                = (x-1)(3x+1)
\intertext{thus, the difference quotient is}
   \frac{f(x)-f(1)}{x-1} &= 3x+1
\end{align*}
\end{verA}
\begin{verB}
\begin{align*}
    f(x)-f(-1) &= 3x^2 - 2x - 5\\&
                = (x+1)(3x-5)
\intertext{thus, the difference quotient is}
   \frac{f(x)-f(-1)}{x+1} &= 3x-5
\end{align*}
\end{verB}


\vfill
\vspace*{\sameVspace}
\vfill
\end{multicols}
\end{solution}
\begin{workarea}{\sameVspace}\parindent0pt\bfseries
\begin{multicols}{2}
\textbf{Calculations}

\vfil\vspace*{\sameVspace}\vfil


\columnbreak
\textbf{Side Calculations}

\vfil\vspace*{1.9in}\vfil

\end{multicols}
\end{workarea}

\end{problem}

\end{exam}
\end{document}
