218/353
\begin{frame}
  \frametitle{Inverse Functions: Graphs}

  We have \quad$f(x) = y \;\iff\; f^{-1}(y) = x$\quad\pause and hence
  \begin{center}
    point $(x,y)$ in the graph of $f$\\
    $\;\;\iff\;\;$ \\
    point $(y,x)$ in the graph of $f^{-1}$
  \end{center}
  \pause\medskip
  
  \begin{minipage}{.49\textwidth}
  \begin{center}
  \scalebox{.7}{
  \begin{tikzpicture}[default,baseline=0cm]
    \diagram{-3}{3}{-3}{3}{1}
    \diagramannotatez
    \node[include=cred] (a) at (.5,2.5) {};
    \node[include=cred] (b) at (2.5,.5) {};
    \node[at=(a.north),anchor=south,xshift=1mm] {$(x,y)$};
    \node[at=(b.east),anchor=west] {$(y,x)$};
    \begin{scope}[ultra thick]
    \mpause[2]{
    \draw[draw=none,fill=cred!20] (1,1) to[out=135,in=135+90] (1,2) to (1.5,1.5) -- cycle;
    \node[scale=.9] at (1.1,1.5) {$90\textdegree$};
    }
    \pause
    \draw[dashed,cred] (-3,-3) -- (3,3);
    \pause
    \draw[dashed,cgreen] (a) -- (b);
    \pause
    \draw[decorate,decoration={brace,amplitude=5pt,raise=5pt}] (a) -- ($(a)!.45!(b)$);
    \node at ($(a)!.25!(b) + (3mm,2mm)$) [anchor=west,rotate=45] {length $d$};
    \draw[decorate,decoration={brace,amplitude=5pt,raise=5pt}] ($(a)!.55!(b)$) -- (b);
    \node at ($(a)!.75!(b) + (3mm,2mm)$) [anchor=west,rotate=45] {length $d$};
%     \draw[cgreen,name path=curve] plot[smooth,domain=-.5:5,samples=300] (\x,{3+.3*\x-.3*pow((\x-2),2)});
    \end{scope}
  \end{tikzpicture}
  }\\[.5ex]
  {\small \mpause[1]{reflected about the line $y = x$}}
  \end{center}    
  \end{minipage}~%
  \mpause[2]{%
  \begin{minipage}{.49\textwidth}
  \begin{center}
  \scalebox{.7}{
  \begin{tikzpicture}[default,baseline=0cm]
    \diagram{-3}{3}{-3}{3}{1}
    \diagramannotatez
    \begin{scope}[ultra thick]
    \draw[dashed,cred] (-3,-3) -- (3,3);
    
    \draw[cgreen,name path=curve] (-2,-1.5) to[out=70,in=-100,looseness=2] node [at end,above] {$f$} (2,3);
    \mpause[3]{
    \draw[cblue,name path=curve] (-1.5,-2) to[out=20,in=45+145,looseness=2] node [at end,right] {$f^{-1}$} (3,2);
    }
    \end{scope}
  \end{tikzpicture}
  }\\[.5ex]
  {\small \vphantom{H} }
  \end{center}    
  \end{minipage}
  }
  
\end{frame}