\documentclass[11pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[top=0.9in, bottom=0.8in, left=0.7in, right=0.7in]{geometry}
\setlength{\headheight}{15pt}
\usepackage{amsmath, amssymb, amsthm}
\usepackage{fancyhdr}
\usepackage{enumitem}
\usepackage{tikz}
\usepackage{pgfplots}
\pgfplotsset{compat=1.18}
\usepackage{booktabs}
\usepackage{tasks}
\usepackage{multicol}

% --- Header & Footer ---
\pagestyle{fancy}
\fancyhf{}
\lhead{\textbf{Arizona State University}}
\rhead{\textbf{MAT 266: Calculus for Engineers II}}
\renewcommand{\headrulewidth}{0.4pt}

% --- Max's Little Custom Macros ---
\settasks{
    label=\textbf{\Alph*.}, 
    label-width=1.5em,      
    item-indent=2.5em,      
    after-item-skip=2ex,    
    after-skip=0.5cm        
}

\newcounter{mcq}
\newcommand{\mcquestion}[1]{
    \stepcounter{mcq}
    \vspace{0.2cm}
    \noindent \textbf{\themcq.} #1
}

\newcommand{\mcoptions}[6]{
    \begin{tasks}(3)
        \task #1 \task #2 \task #3
        \task #4 \task #5 \task #6
    \end{tasks}
}

\newcommand{\mcoptionsWide}[6]{
    \begin{tasks}(2)
        \task #1 \task #2 \task #3
        \task #4 \task #5 \task #6
    \end{tasks}
}

\newcommand{\mcoptionsOnePerLine}[6]{
    \begin{tasks}(1)
        \task #1 
        \task #2 
        \task #3
        \task #4 
        \task #5 
        \task #6
    \end{tasks}
}

\begin{document}

% ================= PAGE 1 =================
    \begin{center}
        \vspace*{-1cm}
        {\Huge \textbf{PRACTICE EXAM 1}}\\[0.1cm]
    \end{center}
    \vspace{0.1cm}
    \noindent \textbf{Printed Name:} \underline{\hspace{8cm}} \textbf{Class Start Time:} \underline{\hspace{3.5cm}}

    \vspace{0.1cm}
    \noindent 
    \begin{itemize}[itemsep=0pt, leftmargin=1.5em, topsep=0pt]
        \item Record answers to Section 1 in the grid below, or you will receive a score of 0 for Section 1.
        \item Graphing Calculators are allowed. All other devices strictly prohibited.
        \item Only the first sheet of paper will be marked, and only returned if you come to office hours.
    \end{itemize}
    \vspace{0.1cm}

\noindent \textbf{\large SECTION 1: Multiple Choice: Record One Clear Letter Answer Here (6 Points Each)}
\begin{center}
\renewcommand{\arraystretch}{1.6}
\begin{tabular}{|c|c|c|c|c|c|c|c|c|c|c|c|}
\hline
\textbf{1} & \textbf{2} & \textbf{3} & \textbf{4} & \textbf{5} & \textbf{6} & \textbf{7} & \textbf{8} & \textbf{9} & \textbf{10} & \textbf{11} & \textbf{12}\\
\hline
\hspace{0.35cm} & \hspace{0.35cm} & \hspace{0.35cm} & \hspace{0.35cm} & \hspace{0.35cm} & \hspace{0.35cm} & \hspace{0.35cm} & \hspace{0.35cm} & \hspace{0.35cm} & \hspace{0.35cm} & \hspace{0.35cm} & \hspace{0.35cm} \\
\hline
\end{tabular}
\end{center}

\vspace{0.04cm}
\hrule
\vspace{0.14cm}

\noindent \textbf{\large SECTION 2: Free Response (14 Points Each)} \\

\vspace{0.04cm}

\noindent \textbf{Question 13: } Evaluate the integral. Show all algebraic steps and substitutions clearly.
\[ \int  \frac{2x^2+2x+3}{(2x+1)(x^2+1)} \, dx \]

\vspace{10cm}

\newpage

% ================= PAGE 2 =================

\noindent \textbf{Question 14: } A particle moves along a straight line with velocity $v(t) = 9t e^{-3t+9}$ meters per second after $t$ seconds. Find how far it travels during the first 3 seconds. 
\\(Write down the integral and show all steps of the integration. Give an exact answer.)

\vfill

\hrule
\vspace{0.3cm}

\noindent \textbf{\large SECTION 1: Multiple Choice Questions} \\
\textit{Select the single best answer and write it in the grid on Page 1.}

\vspace{0.2cm} 

% Q1
\mcquestion{Find the following indefinite integral: $\displaystyle \int \frac{24x^3}{\sqrt{3x^4 + 7}} \, dx$}
\mcoptions
{$2\sqrt{3x^4 + 7} + C$}
{$4\sqrt{3x^4 + 7} + C$} 
{$12\sqrt{3x^4 + 7} + C$}
{$8\sqrt{3x^4 + 7} + C$}
{$\displaystyle \frac{24}{\sqrt{3x^4 + 7}} + C$}
{$\displaystyle \frac{4}{3}\sqrt{3x^4 + 7} + C$}
\vspace{0.2cm}

% Q2
\mcquestion{Select the appropriate substitution from the list given below that would most efficiently simplify the evaluation of the integral: $\displaystyle \int \frac{\sqrt{9 - \arctan(x)}}{1+x^2} \, dx$}
\mcoptionsWide
{$u = \arctan(x)$}
{$u = 1 + x^2$}
{$u = \sqrt{9 - \arctan(x)}$}
{$u = x$}
{$u = 9 - \arctan(x)$} 
{$u = \displaystyle \frac{\arctan(x)}{1+x^2}$}

\newpage

% ================= PAGE 3 =================

% Q3
\mcquestion{Find the following indefinite integral: $\displaystyle \int x^{1/3} \ln x \, dx$}
\mcoptionsWide
{$\displaystyle \frac{3}{4}x^{4/3}\ln x - \frac{9}{16}x^{4/3} + C$} 
{$\displaystyle \frac{3}{4}x^{4/3}\ln x - \frac{3}{16}x^{4/3} + C$}
{$\displaystyle \frac{4}{3}x^{4/3}\ln x - \frac{16}{9}x^{4/3} + C$}
{$\displaystyle \frac{3}{4}x^{4/3}\ln x - \frac{3}{4}x^{4/3} + C$}
{$\displaystyle x^{4/3}\ln x - \frac{4}{3}x^{4/3} + C$}
{$\displaystyle \frac{3}{4}x^{4/3}\ln x + \frac{9}{16}x^{4/3} + C$}
\vspace{0.7cm}

% Q4
\mcquestion{For the integral $\displaystyle \int \frac{dx}{x\sqrt{x^2-49}}$, choose the appropriate trig-substitution from the list provided below:}
\mcoptions
{$\displaystyle x = 7\tan\theta$}
{$\displaystyle x = 7\sin\theta$}
{$\displaystyle x = 7\sec\theta$} 
{$\displaystyle x = 49\sec\theta$}
{$\displaystyle x = \sqrt{7}\sec\theta$}
{$\displaystyle x = 49\tan\theta$}
\vspace{0.7cm}

% Q5
\mcquestion{Find the indefinite integral: $\displaystyle \int \sec^2(x) \sqrt{\tan(x)} \, dx$}
\mcoptions
{$\displaystyle \frac{3}{2}\tan^{2/3}(x) + C$}
{$\displaystyle \frac{2}{3}\sec^{3/2}(x) + C$}
{$\displaystyle 2\tan^{1/2}(x) + C$}
{$\displaystyle \frac{1}{2\sqrt{\tan(x)}} + C$}
{$\displaystyle \frac{3}{2}\tan^{3/2}(x) + C$}
{$\displaystyle \frac{2}{3}\tan^{3/2}(x) + C$} 
\vspace{0.7cm}

% Q6
\mcquestion{Find the form of the partial fraction decomposition of:  $\displaystyle \frac{x^5 - 4x^4 + 2x^3 + 9x - 11}{x^2(x^2+3)(x^2+1)}$}
\mcoptionsWide
{$\displaystyle \frac{A}{x} + \frac{B}{x^2} + \frac{Cx+D}{x^2+3} + \frac{Ex+F}{x^2+1}$} 
{$\displaystyle \frac{A}{x^2} + \frac{B}{x^2+3} + \frac{C}{x^2+1}$}
{$\displaystyle \frac{A}{x} + \frac{Bx+C}{x^2} +  \frac{Dx+E}{x^2+3} + \frac{Fx+G}{x^2+1}$}
{$\displaystyle \frac{A}{x} + \frac{B}{x^2} + \frac{C}{x^2+3} + \frac{D}{x^2+1}$}
{$\displaystyle \frac{A}{x^2} + \frac{Bx+C}{x^2+3} + \frac{Dx+E}{x^2+1}$}
{$\displaystyle \frac{Ax+B}{x^2} + \frac{C}{x^2+3} + \frac{D}{x^2+1}$}

\newpage

% ================= PAGE 4 =================

% Q7
\mcquestion{Find the following indefinite integral: $\displaystyle \int \arctan(2x) \, dx$}
\mcoptionsWide
{$\displaystyle x\arctan(2x) - \frac{1}{2}\ln(1+4x^2) + C$}
{$\displaystyle x\arctan(2x) - \frac{1}{4}\ln(1+4x^2) + C$} 
{$\displaystyle 2x\arctan(2x) - \ln(1+4x^2) + C$}
{$\displaystyle x\arctan(2x) + \frac{1}{4}\ln(1+4x^2) + C$}
{$\displaystyle \frac{2}{1+4x^2} + C$}
{$\displaystyle x\arctan(2x) - \ln(1+4x^2) + C$}
\vspace{0.7cm}

% Q8
\mcquestion{The concentration of a drug in the bloodstream decreases according to $C(t) = \frac{20}{\sqrt{2t+1}}$ mg/L. \\Find the \textbf{average} concentration during the first 2 hours.}\\
\mcoptions
{$\displaystyle 98.89 \text{ mg/L}$}
{$\displaystyle 24.72 \text{ mg/L}$}
{$\displaystyle 12.36 \text{ mg/L}$} 
{$\displaystyle 49.45 \text{ mg/L}$}
{$\displaystyle 1.24 \text{ mg/L}$}
{$\displaystyle 197.78 \text{ mg/L}$}
\vspace{0.7cm}

% Q9
\mcquestion{Use $\displaystyle \int \frac{\sqrt{a^2+u^2}}{u} \, du = \sqrt{a^2+u^2} - a \ln \left| \frac{a + \sqrt{a^2+u^2}}{u} \right| + C$ to find the integral: $\displaystyle \int \sqrt{25 + e^{2x}} \, dx$} \vspace{0.1cm}
\mcoptionsWide
{$\displaystyle \sqrt{25+e^{2x}} + 5 \ln \left| \frac{5 + \sqrt{25+e^{2x}}}{e^x} \right| + C$}
{$\displaystyle \sqrt{25+e^{2x}} - 25 \ln \left| \frac{25 + \sqrt{25+e^{2x}}}{e^x} \right| + C$}
{$\displaystyle \frac{1}{2}\left( \sqrt{25+e^{2x}} - 5 \ln \left| \frac{5 + \sqrt{25+e^{2x}}}{e^x} \right| \right) + C$}
{$\displaystyle \sqrt{25+e^{2x}} - \ln \left| \frac{5 + \sqrt{25+e^{2x}}}{e^x} \right| + C$}
{$\displaystyle \sqrt{25+e^{2x}} - 5 \ln \left| \frac{5 + \sqrt{25+e^{2x}}}{e^x} \right| + C$} 
{$\displaystyle \sqrt{25+e^{2x}} - 5 \ln \left| \frac{\sqrt{25+e^{2x}}}{e^x} \right| + C$}
\vspace{0.7cm}

% Q10
\mcquestion{Evaluate $\displaystyle \int\sin^3 x\cos^2x \hspace{.2em}dx.$}
\mcoptionsWide
{$\displaystyle \frac{1}{5}\cos^5x - \frac{1}{3}\cos^3x + C$} 
{$\displaystyle \cos^4x - \cos^2x + C$}
{$\displaystyle \cos^5x - \cos^3x + C$}
{$\displaystyle -\frac{1}{3}\cos^3 x + C$}
{$\displaystyle \frac{1}{3}\cos^3x  \cdot (\cos x +\frac{1}{3}\cos^3 x)  + C$}
{$\displaystyle \frac{1}{5}\cos^5x + \frac{1}{3}\cos^3x + C$}

\newpage

% ================= PAGE 5 =================

% Q11
\mcquestion{Approximate the integral $\displaystyle \int_{0}^{1} e^{-5x^2} \, dx$ using \textbf{Simpson's Rule} with $n=4$ intervals. The answers are rounded to 7 decimal places.}
\mcoptions
{$0.3957123$}
{$0.3955472$}
{$0.5231420$}
{$0.3955357$} % Correct (D)
{$0.4100231$}
{$0.4000000$}
\vspace{0.7cm}

% Q12
\mcquestion{Suppose $f(x)$ is a positive, strictly increasing, and concave up function on the interval $[a,b]$. Which of the following logical statements is true regarding the numerical approximations of $\displaystyle \int_a^b f(x) \, dx$?}
\mcoptionsOnePerLine
{The Left Endpoint rule is an overestimate and the Trapezoidal Rule is an underestimate.}
{Both the Right Endpoint rule and the Trapezoidal Rule are underestimates.}
{Both the Left Endpoint rule and the Trapezoidal Rule are overestimates.}
{The Right Endpoint rule is an underestimate and the Trapezoidal Rule is an overestimate.}
{The Left Endpoint rule is an overestimate and the Right Endpoint rule is an underestimate.}
{The Left Endpoint rule is an underestimate and the Trapezoidal Rule is an overestimate.} % Correct (F)


\newpage
% ================= SOLUTIONS PAGE =================

\begin{center}
 {\huge \textbf{Solutions}}
\end{center}

\vspace{0.4cm}
\noindent 
\textbf{Multiple Choice}\\
\renewcommand{\arraystretch}{1.6}
\begin{center}
\begin{tabular}{|c|c|c|c|c|c|c|c|c|c|c|c|}
\hline
\textbf{1} & \textbf{2} & \textbf{3} & \textbf{4} & \textbf{5} & \textbf{6} & \textbf{7} & \textbf{8} & \textbf{9} & \textbf{10} & \textbf{11} & \textbf{12} \\
\hline
B & E & A & C & F & A & B & C & E & A & D & F \\
\hline
\end{tabular}
\end{center}

\vspace{0.6cm}
\hrule
\vspace{0.4cm}

\noindent \textbf{Question 13: } 
$$
 \displaystyle \int  \frac{2x^2+2x+3}{(2x+1)(x^2+1)} \, dx = \frac{A}{2x+1} + \frac{Bx+C}{x^2+1}
$$

$$
2x^2+2x+3 = A(x^2+1) + (Bx+C)(2x+1)
$$

$$
\text{Equate coefficients of } x^2: \quad 2 = A + 2B 
$$
$$
\text{Equate coefficients of } x^1: \quad 2 = B + 2C 
$$
$$
\text{Equate coefficients of } x^0: \quad 3 = A + C 
$$

\noindent \text{Solve the system with three equations and three unknowns:}
$$
\quad A = 2-2B  \implies  3=(2-2B)+C  \implies C=1+2B  
$$
$$
\text{Then} \quad 2 = B+2(1+2B) \implies \fbox{\textbf{B=0}}
\implies \fbox{\textbf{A}=2-0=\textbf{2}}
\implies \fbox{\textbf{C}=1+0=\textbf{1}}
$$

$$
 \displaystyle \int  \frac{2x^2+2x+3}{(2x+1)(x^2+1)} \, dx = \int\frac{2}{2x+1} dx+ \int\frac{0x+1}{x^2+1}dx=
 \int \frac{2}{2x+1} \, dx +  \int \frac{1}{x^2+1} \, dx$$
 
 $$= 2\Big[\frac{\ln|\textbf{2} x+1|}{\textbf{2}}\Big] + \arctan(x) + C    \\
$$
\text{Note: substitution } $u = 2x+1$  
$$
{\textbf{Answer:}}    \boxed{\ln|2x+1| + \arctan(x) + C}  
$$

\newpage

\noindent \textbf{Question 14: } 
$$
 v(t) = 9t e^{-3t+9}, \quad t \in [0, 3]
$$

$$
\text{Since } t \ge 0 \text{ and } e^x > 0, \quad v(t) \ge 0 \implies \text{Distance} = \int_{0}^{3} v(t) \, dt
$$

\[
\begin{aligned}
\int_{0}^{3} 9t e^{-3t+9} \, dt \quad & \Bigg| \quad \begin{matrix} u = t & dv = 9e^{-3t+9}dt \\ du = dt & v = -3e^{\textbf{-3}t+9} \end{matrix} \\
&= \Big[ -3t e^{-3t+9} \Big]_{0}^{3} - \int_{0}^{3} -3e^{-3t+9} \, dt \\
&= \Big[ -3t e^{-3t+9} \Big]_{0}^{3} + \int_{0}^{3} 3e^{-3t+9} \, dt \\
&= \Big[ -3t e^{-3t+9} \Big]_{0}^{3} + \Big[ -e^{-3t+9} \Big]_{0}^{3} \\
&= \Big( -3(3)e^0 - 0 \Big) + \Big( -e^0 - (-e^9) \Big) \\
&= -9 - 1 + e^9 \\
&= \boxed{e^9 - 10} \text{ meters } = 8093.0839  \text{ meters}\\
\end{aligned}
\]

\end{document}