\documentclass[10pt,a4paper]{article}

\usepackage[utf8]{inputenc}
\usepackage[margin=2cm]{geometry}

\usepackage{enumitem}
\setenumerate[1]{label=\arabic*.}
\setenumerate[2]{label=(\alph*)}

% textcomp package is not available everywhere, and we only need the Copyright symbol
% taken from http://tex.stackexchange.com/a/1677/23992
\DeclareTextCommandDefault{\textregistered}{\textcircled{\check@mathfonts\fontsize\sf@size\z@\math@fontsfalse\selectfont R}}

\usepackage{fancyhdr}
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\footrulewidth}{0pt}
\fancyhead{}
\fancyfoot[C]{Copyright {\textcopyright} 2015 Camil Staps}
\pagestyle{fancy}

\usepackage{amsmath}
\usepackage{amsfonts}

\parindent0pt

\title{Calculus en Kansrekenen - assignment 3}
\author{Camil Staps\\\small{s4498062, group Bram}}

\begin{document}

\maketitle
\thispagestyle{fancy}

\begin{enumerate}
    \item \begin{enumerate}
            \item The domain of $\arcsin$ is the range of $\sin$, so $[-1,1]$.
            \item Filling in $x=\sin1$ gives us $x=(2k+\frac12)\cdot\pi$ with $k\in\mathbb Z$. Therefore, $\arcsin(1) = \frac\pi2$; we fill in $k=0$ which is the only $k$ s.t. $(2k+\frac12)\pi \in [-\frac\pi2,\frac\pi2]$.

                Similarly, $x=\sin0$ gives us $x=k\cdot\pi$ with $k\in\mathbb Z$. We fill in $k=0$, so $\arcsin(0) = 0$.

                Finally, we know $x=\sin\frac{\sqrt3}2$ gives $x=(2k+\frac13)\cdot\pi$ or $x=(2k+\frac23)\cdot\pi$ with $k\in\mathbb Z$. The only possible $x$ would then be $(2k+\frac13)\pi$ with $k=0$, so $\arcsin\frac{\sqrt3}2 = \frac\pi3$.
            \item \begin{align*}
                    f'(x) &= \left(\arcsin\frac{2x}{1-x}\right)' \\
                          &= \frac1{\sqrt{1-\left(\frac{2x}{1-x}\right)^2}} \cdot \left(\frac{2x}{1-x}\right)' \\
                          &= \frac1{\sqrt{1-\left(\frac{2x}{1-x}\right)^2}} \cdot \frac{(1-x)\cdot2 - 2x\cdot-1}{(1-x)^2} \\
                          &= \frac2{(1-x)^2\sqrt{1-\left(\frac{2x}{1-x}\right)^2}}.
                \end{align*}
        \end{enumerate}

    \item \begin{enumerate}
            \item We know $\lim_{x\to\infty}\ln(2015x) = \infty = \lim_{x\to\infty} x^3$, so let's try to apply l'Hôpital:
                \begin{align*}
                    (\ln(2015x))' &= (\ln 2015 + \ln x)' = \frac1x.\\
                    (x^3)'        &= 3x^2.\\
                    \lim\limits_{x\to\infty} \frac{\frac1x}{3x^2} &= \lim\limits_{x\to\infty} \frac1{3x^3} = 0.
                \end{align*}

                Since we saw that both numerator and denominator are differentiable and that the fraction of their derivatives has a limit for $x\to\infty$, this limit is equal to the limit of the original fraction.

            \item We know $\lim_{a\to-3}\sin(a\pi) = 0 = \lim_{a\to-3}a^2-9$, so let's try to apply l'Hôpital:
                \begin{align*}
                    (\sin(a\pi))' &= \cos(a\pi)\cdot\pi. \\
                    (a^2-9)'      &= 2a.\\
                    \lim\limits_{a\to-3}\frac{\pi\cdot\cos(a\pi)}{2a} &= \frac\pi6.
                \end{align*}

                Since we saw that both numerator and denominator are differentiable and that the fraction of their derivatives has a limit for $a\to-3$, this limit is equal to the limit of the original fraction.

            \item We know $\lim_{x\to-\infty}e^{3-x} = \infty = \lim_{x\to-\infty}7x^2$, so let's try to apply l'Hôpital:
                \begin{align*}
                    \left(e^{3-x}\right)' &= e^{3-x}\cdot-1 = -e^{3-x}.\\
                    (7x^2)'               &= 14x.\\
                \end{align*}

                Now we know $\lim_{x\to-\infty} -e^{3-x} = -\infty = \lim_{x\to-\infty} 14x$, so to find $\lim_{x\to-\infty}\frac{-e^{3-x}}{14x}$ we can again try to apply l'Hôpital:
                \begin{align*}
                    \left(-e^{3-x}\right)' &= e^{3-x}.\\
                    (14x)'                 &= 14.\\
                    \lim\limits_{x\to-\infty}\frac{e^{3-x}}{14} &= \infty.
                \end{align*}
                
                And since we saw that in both steps numerator and denominator are differentiable, and that the fractions of their derivatives has a limit for $x\to-\infty$, this limit is equal to the limit of the original fraction.
        \end{enumerate}

    \item \begin{enumerate}
            \item $f(x) = \log_32 + \log_3x$. Then $f'(x) = \frac1{x\ln3}$. Then $f''(x) = -\frac{\ln3}{x^2(\ln3)^2} = -\frac1{x^2\ln3}$. Finally $f'''(x) = -\frac{-2\ln3\cdot x}{x^4\cdot(\ln3)^2} = \frac2{x^3\ln3}$.

            \item Let's look at $f(x) = k\cdot\cos(c\cdot x)$. We can find the following derivatives:
                \begin{align*}
                    f^{(1)}(x)  &= k\cdot-\sin(cx)\cdot c = -ck\cdot\sin(cx).\\
                    f^{(2)}(x)  &= -ck\cdot\cos(xc)\cdot c = -c^2k\cdot\cos(cx).\\
                    f^{(3)}(x)  &= -c^2k\cdot-\sin(cx)\cdot c = c^3k\cdot\sin(cx).\\
                    f^{(4)}(x)  &= c^3k\cdot\cos(cx)\cdot c = c^4k\cdot\cos(cx).\\
                \end{align*}
                Note that $f^{(4)}$ is also of the form $k\cdot\cos(c\cdot x)$. We can thus write for any $f$ of that form: $f^{(4n)}(x) = c^{4n}k\cdot\cos(cx)$ with $n\in\mathbb N$.

                If we fill in $f(x) = g(x)$ and $n=\frac{2012}{4}$, we find $g^{(2012)}(x) = 3^{2012}\cos(3x)$. Then from this we find:
                \begin{align*}
                    g^{(2013)}(x)   &= -3^{2013}\sin(3x).\\
                    g^{(2014)}(x)   &= -3^{2014}\cos(3x).\\
                    g^{(2015)}(x)   &= 3^{2015}\sin(3x).
                \end{align*}
        \end{enumerate}

    \item \begin{enumerate}
            \item $x-3$, $x+1$ and $x^2$ are all from $\mathbb R$ to $\mathbb R$. Multiplication is from $\mathbb R\times\mathbb R$ to $\mathbb R$. Therefore, $f : \mathbb R \to \mathbb R$. 

            \item To find the roots we equate $f(x)$ with zero and solve for $x$. That gives $x=-1$ or $x=3$, so we have $(-1,0)$ and $(3,0)$ as roots of $f$.

                To find the y-intercept, we fill in $x=0$ in $f(x)$: $(0+1)^2(0-3)=-3$. This gives $(0,-3)$.

            \item $\lim_{x\to\infty}(x+1)^2(x-3)=\infty$, since the limits of $x\to\infty$ for $(x+1)^2$ and $x-3$ are both $\infty$.

                $\lim_{x\to-\infty}(x+1)^2(x-3)=\lim_{x\to\infty}x^3-x^2-5x-3$. $x^3$ is dominant (because it has the highest exponent), so this limit is $\lim_{x\to-\infty}x^3=-\infty$.

            \item $f'(x) = \left((x+1)^2(x-3)\right)' = \left(x^3-x^2-5x-3\right)' = 3x^2 - 2x - 5$.

                $f''(x) = \left(3x^2 - 2x - 5\right)' = 6x - 2$.

            \item $f'(x) = 3x^2-2x-5 = 0$ gives $x=\frac{2 + \sqrt{4+60}}{6} = \frac53$ or $x=\frac{2 - \sqrt{4+60}}{6} = -1$. This gives the points $(\frac53,0)$ and $(-1,0)$.

                $f''(x) = 6x-2 = 0$ gives $x=\frac13$. This gives $(\frac13,0)$.

            \item We already found the $x$s, namely those $x$ where $f'(x)=0$, i.e. $x=-1$ and $x=\frac53$. We then get the critical points $(-1,f(-1)) = (-1,0)$ and $(\frac53,f(\frac53)) = (\frac53, -4\cdot(\frac43)^3)$.

            \item Again we use those $x$ where $f'(x)=0$.

                For $x=\frac53$ we have $f''(x) = 8 > 0$, therefore this (the critical point with this $x$) is a local minimum.

                For $x=-1$ we have $f''(x) = -8 < 0$, therefore this is a local maximum.

            \item $f''(x) > 0$ leads to $x > \frac13$, so $f$ is convex on $(\frac13,\infty)$. $f''(x) < 0$ leads to $x < \frac13$, so $f$ is concave on $(-\infty,\frac13)$. A point of inflection (the only) would then be $(\frac13, f(\frac13)) = (\frac13, \frac{128}{27})$.
        \end{enumerate}

    \item \begin{enumerate}
            \item The function in the numerator goes from $\mathbb R$ to $\mathbb R$, as does the function in the denominator. However, the fraction requires this denominator to be unequal to zero. We thus find as domain $\{x\in\mathbb R \mid x+2\neq 0\} = \mathbb R\setminus\{-2\}$.
                
            \item For the roots of $f$ we solve $f(x)=0$ for $x$. That gives $(x-2)^2=0$, so $(x-2)=0$ and thus $x=2$. This yields the point $(2,0)$.

                The graph of $f$ intersect the $y$ axis at $x=0$; this gives the point $(0,f(0)) = (0, 2)$.
                
            \item \begin{align*}
                    \lim\limits_{x\to\infty} \frac{(x-2)^2}{x+2} &= \lim\limits_{x\to\infty} \frac{1-\frac4x+\frac4{x^2}}{\frac1x+\frac2{x^2}} = \infty.\\
                    \lim\limits_{x\to-\infty} \frac{(x-2)^2}{x+2} &= \lim\limits_{x\to-\infty} \frac{1-\frac4x+\frac4{x^2}}{\frac1x+\frac2{x^2}} = -\infty.
                  \end{align*}

                  There exists no two-sided limit for $x\to-2$. This can be seen from the graph of $f$: on the right of $x=-2$, $f$ goes to $\infty$, while on the left, $f$ goes to $-\infty$.
                
            \item \begin{align*}
                    f(x)    &= \frac{(x-2)^2}{x+2} = \frac{x^2 - 4x + 4}{x+2}.\\
                    f'(x)   &= \frac{(x+2)(2x-4)-(x^2-4x+4)(1)}{(x+2)^2}\\
                            &= \frac{x^2 + 4x - 12}{(x+2)^2}\\
                            &= \frac{(x-2)(x+6)}{(x+2)^2}\\
                            &= \frac{x^2+4x-12}{x^2+4x+4}.\\
                    f''(x)  &= \frac{(x^2+4x+4)(2x+4)-(x^2+4x-12)(2x+4)}{(x+2)^4}\\
                            &= \frac{32}{(x+2)^3}.
                \end{align*}
                
            \item Again, we solve $f'(x)=0$ and $f''(x)=0$ for $x$:
                \begin{align*}
                    f'(x)   &= 0\\
                    \frac{(x-2)(x+6)}{(x+2)^2} &= 0
                \end{align*}
                This gives $x=2$ or $x=-6$, with the points $(2,0)$ and $(-6,0)$.

                It is obvious at first sight that $f''(x)$ has no zeroes: it numerator can never be equal to zero.
                
            \item We take $\{(x,f(x)) \mid f'(x)=0\} = \{(2,f(2)),(-6,f(-6))\} = \{(2,0),(-6,-16)\}$.
                
            \item At $x=2$ we have $f''(x)=\frac12>0$, so $(2,0)$ is a local minimum. 
                
                At $x=-6$ we have $f''(x)=-\frac12<0$, so $(-6,-16)$ is a local maximum.
                
            \item From $f''(x) > 0$ follows $(x+2)^3 > 0$ and so $x > -2$. Therefore, $f$ is convex on $(-2,\infty)$.

                From $f''(x) < 0$ follows $(x+2)^3 < 0$ and so $x < -2$. Therefore, $f$ is concave on $(-\infty,-2)$.

                On $x=-2$ we could have had a point of inflection (it's the only $x\in\mathbb R$ on which $f$ is neither convex nor concave), however, $-2$ is not in the domain of $f$. Therefore, this function does not have a point of inflection.
                
            \item We have 
                \begin{align*}
                    f(x) - (x-6) &= \frac{x^2-4x+4}{x+2} - \frac{x^2 - 4x + 36}{x+2}\\
                                 &= -\frac{32}{x+2}.
                \end{align*}
                
                Then obviously both limits mentioned in the exercise are equal to zero. Therefore, $y=x-6$ is a slant asymptote of $f$.
                
        \end{enumerate}

    \item \begin{enumerate}
            \item \begin{align*}
                    f'(x)   &= \frac1{\cos(\ln(\cos x))}\cdot\cos(\ln(\cos x))'\\
                            &= \frac1{\cos(\ln(\cos x))}\cdot -\sin(\ln(\cos x))\cdot (\ln(\cos x))'\\
                            &= -\frac{\sin(\ln(\cos x))}{\cos(\ln(\cos x))}\cdot \frac1{\cos x}\cdot (\cos x)'\\
                            &= -\frac{\sin(\ln(\cos x))}{\cos(\ln(\cos x))\cdot\cos x}\cdot -\sin x\\
                            &= \frac{\sin(\ln(\cos x))\cdot\sin x}{\cos(\ln(\cos x))\cdot\cos x}\\
                            &= \tan(\ln(\cos x))\cdot\tan x.
                \end{align*}
                
            \item For example $f(x) = -\frac12\ln(\cos(2x))$ works:
                \begin{align*}
                    f'(x)   &= -\tfrac12\cdot\frac1{\cos(2x)}\cdot(\cos(2x))'\\
                            &= -\tfrac12\cdot\frac1{\cos(2x)}\cdot-\sin(2x)\cdot2\\
                            &= \frac{\sin(2x)}{\cos(2x)}\\
                            &= \tan(2x).
                \end{align*}
                
            \item For example take $f_1(x) = -\frac14\cos(2x)$, then we have the derivative $$f_1'(x) = -\frac14\cdot-\sin(2x)\cdot2 = \frac12\sin(x+x) = \frac12(\sin x\cos x +\sin x\cos x) = \sin x\cos x.$$

                Now we define $f_i(x) = -\frac14\cos(2x) + i - 1$ for all $i \in\mathbb R$, which gives us infinitely many functions with the same derivative.
                
        \end{enumerate}

\end{enumerate}

\end{document}

