\documentclass[a4paper,12pt]{article} % Load the ou-tma package with a common set of options \usepackage[pdfbookmark,roman,cleveref]{ou-tma} % [roman] numbers questions in the form 1(ii)(c) % the default, [alph] numbers in the form 1(b)(iii) % Define who is answering this TMA \myname{Peter McFarlane}% Obviously your own name \mypin{A1234567} % Your actual OU personal identity number % find it on Student Home if you are unsure % Define which module and TMA is being answered. \mycourse{\LaTeX 101} % normally your module, like: \mycourse{M208} \mytma{sample} % normally your TMA number: \mytma{01} or \mytma{02}... \date{30 Sep, 2025} % If you want a specific date to appear, use this % otherwise the data of compilation is used. % Three extra packages used during the descriptions in this text. \usepackage[most]{tcolorbox} \usepackage{cancel} \usepackage{xcolor} \renewcommand{\CancelColor}{\color{red}} % Setup stuff for the noteboxes used for descriptions in this text. \tcbset{ notebox/.style={ colback=cyan!10, colframe=cyan!30, width=0.5\linewidth, arc=3mm, auto outer arc, boxrule=3pt, enhanced, } } \newtcolorbox{notebox}[1][]{notebox,#1, before=\begin{center}, after=\end{center},} \begin{document} \maketitle \hfill\fbox{Update for 2025/09/30 v1.21} %% Notes for the latest update \begin{notebox}[width=\linewidth] This document is provided as an example of how to use the \textsf{ou-tma} package. With the 7\nth\,April 2025 version of the package there has been an update to the name of the package. Gone is \cancel{\textsf{tma}} and in comes \textsf{ou-tma}. The reason for the change is twofold. Firstly there are many internal changes to make the package more in line with the conventions of the \LaTeX3\ project, and secondly the introduction of the package into the CTAN archive. In presenting to the CTAN archive, the regular stylesheet has been wrapped up in a \LaTeX\ document file---a \verb|.dtx| file. The beauty of the \verb|.dtx| file is that the \verb|.sty| and source for it's documentation ship together in a single file. A second simple \verb|.ins| file is also needed to extract the \verb|.sty|, but that is unlikely to change and can be created simply on the fly if needed. To use the options start your document with: \begin{verbatim} \documentclass[a4paper,12pt]{article} \usepackage[OPTION]{ou-tma} \myname{...} \mypin{...} \mycourse{...} \mytma{...} \date{...} \begin{document} \maketitle ... \end{verbatim} Where \textsf{OPTION} is one of the following \begin{itemize} \item {[roman]} \item {[alph]} \emph{Default} \item {[cleveref]} \item {[pdfbookmark]} \item {[legacy]} \end{itemize} See the \verb|ou-tma.pdf| file for further details of available options. \end{notebox} \pagebreak \begin{notebox} As we begin this example, we can use a new command \verb|\setquestionstring| to change the default `Q 1', `Q 2', etc to something else. In this case we will use \verb|\setquestionstring{Question}| to make the questions separators display as `Question 1', `Question 2', etc. \end{notebox} \setquestionstring{Question} \begin{question} \qpart % (i) We have $1=10^0$ and $1+2+3+4=10^1$. Prove that there are no other powers of ten which are the sum of the first $n$ integers. We have: \begin{gather*} \sum_{i=1}^n i=\frac{(n)(n+1)}{2} \intertext{Let} \frac{(n)(n+1)}{2}=10^x\\ \Rightarrow (n)(n+1)=2^{x+1}5^x \end{gather*} Now, either $n$ is odd, or $n+1$ is odd. Consider the case where $n$ is odd:\\ By the Fundamental Theorem of Arithmetic, $n$ can only have the prime factors 2 or 5. Since it is odd, it can only be a perfect power of 5. Now, $n+1$ also can only have the prime factors of 2 or 5. If $n$ is divisible by 5, then $n+1$ is not divisible by 5. Therefore $n+1$ is a perfect power of 2. Therefore: \begin{gather*} n=5^x\qquad \text{and}\qquad n+1=2^{x+1}\\ \Rightarrow x=0 \intertext{(for any higher $x$, $5^x\gg 2^{x+1}$)}\\ \Rightarrow n=1 \end{gather*} Now consider the case where $n+1$ is odd:\\ By similar arguments to above, $n+1$ must be a perfect power of 5 and $n$ must be a perfect power of 2. \begin{gather*} n=2^{x+1}\qquad \text{and}\qquad n+1=5^{x}\\ \Rightarrow x=1 \intertext{(for any higher $x$, $5^x\gg 2^{x+1}$)}\\ \Rightarrow n=4 \end{gather*} Therefore $n=1$ and $n=4$ are the only solutions to the original problem. \hfill \qed\\[1cm] \qpart[3] % forced to (iii) skipping (ii) \qsubpart % (iii)(a) Show that: \begin{gather*} \sum_{x=1}^{n}x(x+1)=\frac{n(n+1)(n+2)}{3}\\ \end{gather*} Let \begin{gather*} f(n)=\frac{n(n+1)(n+2)}{3}\\ \end{gather*} Now, adding the n+1 term to the above \begin{gather}\notag \begin{aligned} f(n)+(n+1)(n+2)&=\frac{n(n+1)(n+2)}{3}+(n+1)(n+2)\\ &=\frac{\left(n^3+3n^2+2n+\right)}{3}+n^2+3n+2\\ &=\frac{\left(n^3+6n^2+11n+6\right)}{3}\\ &=\frac{\left((n+1)(n+2)(n+3)\right)}{3}\\ &=f(n+1) \end{aligned} \end{gather} Therefore, if $f(n)$ is valid, then so is $f(n+1)$. Since $1\times2=2=\frac{1\times2\times3}{3}=f(1)$, then $f(n)$ is valid for all $n\geq1$. \hfill \qed\\[1cm] \qsubpart (iii)(b) Show that: \begin{gather*} \sum_{x=1}^{n}x^4=\frac{n(n+1)(2n+1)(3n^2+3n-1)}{30}\\ \end{gather*} Let \begin{gather*} f(n)=\frac{n(n+1)(2n+1)(3n^2+3n-1)}{30}\\ \end{gather*} Now, adding the n+1 term to the above \begin{align} f(n)+(n+1)^4&=\frac{n(n+1)(2n+1)(3n^2+3n-1)}{30}+(n+1)^4\notag \\ &=\frac{1}{30}(6n^5+15n^4+10n^3-n)+(n^4+4n^3+6n^2+4n+1)\notag \\ &=\frac{1}{30}(6n^5+15n^4+10n^3-n+30n^4+120n^3+180n^2+120n+30)\notag \\ &=\frac{1}{30}(6n^5+45n^4+130n^3+180n^2+119n+30)\label{a} \end{align} Now, \begin{align} f(n+1)&=\frac{(n+1)\big((n+1)+1\big)\big(2(n+1)+1\big)\big(3(n+1)^2+3(n+1)-1\big)}{30}\notag \\ &=\frac{1}{30}(n+1)(n+2)(2n+3)(3n^2+9n+5)\notag \\ &=\frac{1}{30}(6n^5+45n^4+130n^3+180n^2+119n+30)\label{b} \end{align} Comparing equation~\eqref{a} with equation~\eqref{b} we see that \begin{gather}\notag f(n)+(n+1)^4=f(n+1) \end{gather} Therefore, if $f(n)$ is valid, then so is $f(n+1)$. Since $1^4=1=\frac{1\times2\times3\times5}{30}=f(1)$, then $f(n)$ is valid for all $n\geq1$.\hfill \qed \end{question} % End of question 1 \begin{notebox} \centering Note that by using\\ \verb|\begin{question}[3]|\\ at this point, we can skip question 2 from the numbering. \end{notebox} \begin{question}[3] Find the general solution of the equation \begin{equation} \label{e} 3\deriv{^2y}{x^2}+4\deriv{y}{x}+y=x^2 \end{equation} The auxillary equation is \begin{equation} 3\lambda^2+4\lambda+1=0 \end{equation} which factorises to \begin{equation} (\lambda+1)(3\lambda+1)=0 \end{equation} and so has solutions \begin{equation} \lambda=-1 \mbox{\ and\ }\lambda=-\frac{1}{3} \end{equation} As both roots are real and distinct, the complementary function is \begin{equation} \label{d} y_c=C\e^{-x}+D\e^{-\frac{1}{3}x} \end{equation} Now, let us find the particular integral. As the right hand side of equation \ref{e} is $x^2$, our trial solution is the polynomial \begin{equation} y_p=px^2+qx+r \end{equation} \begin{equation} \Rightarrow \deriv{y_p}{x}=2px+q \end{equation} \begin{equation} \Rightarrow \deriv{^2y_p}{x^2}=2p \end{equation} Substituting the trial particular integral into equation \ref{e} \begin{equation} 6p+8px+4q+px^2+qx+r=x^2 \end{equation} \begin{equation} \Rightarrow px^2+(8p+q)x+(6p+4q+r)=x^2 \end{equation} \begin{equation} \Rightarrow p=1,\ \ q=-8,\ \ r=26 \end{equation} Thus the particular integral is \begin{equation} \label{c} y_p=x^2-8x+26 \end{equation} and combining equation \ref{d} with equation \ref{c}, by the rule of superposition, we get the general solution of equation \ref{e} to be \begin{equation} y=C\e^{-x}+D\e^{-\frac{1}{3}x}+x^2-8x+26 \end{equation} \end{question} % End of whole document, all questions should be included before this point. \end{document}