This solution is similar to that by @percusse and @Altermundus in that control points are computed using the slope at the given points. One small benefit of the method proposed here is that it is extensible to more than just three points, and at each point a unique value of <delta x> can be specified so that one can have more control the behavior at that point
To start the curve use
\ExtrapolateStart{<delta x>}{<x>}{<y>}{<y'>}
All the points following (except the last) are specified with
\Extrapolate{<delta x>}{<x>}{<y>}{<y'>}
and the last point is specified with
\ExtrapolateEnd{<delta x>}{<x>}{<y>}{<y'>}
Here is the output with various settings:

The control points are shown in blue for debugging purposes, but that part of the code can be commented out if that is not needed.
Here is an example where the x, y, and y' values are specified for 5 points with:
\ExtrapolateStart{\DeltaXStart}{-2}{0}{3.0}% delta x, x, y, y'
\Extrapolate{\DeltaXMiddle}{-1}{2}{1}
\Extrapolate{\DeltaXMiddle}{0}{1}{-2}
\Extrapolate{\DeltaXMiddle}{1}{-1}{-0.5}
\ExtrapolateEnd{\DeltaXEnd}{2}{1}{2.0}

Notes:
- While I was trying to come up with a decent graphs for the 5 point solution I observed various kinks in the lines, but now am no longer able to reproduce that problem. Not sure how this problem was magically fixed. The only thing I can think of is that perhaps the values I was providing for the coordinates and the derivative did not make sense and hence resulted in the strange graphs, but this needs further investigation.
Code:
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{calc}
\newcommand{\ExtrapolateStart}[4]{%
($(#2,#3)-(#1, #1#4)$) --%
(#2,#3) .. controls%
($(#2,#3)+(#1, #1#4)$)%
}%
\newcommand{\Extrapolate}[4]{%
and%
($(#2,#3)-(#1, #1#4)$) ..%
(#2,#3) .. controls%
($(#2,#3)+(#1, #1#4)$)%
}%
\newcommand{\ExtrapolateEnd}[4]{%
and%
($(#2,#3)-(#1, #1#4)$) ..%
(#2,#3) --%
($(#2,#3)+(#1, #1#4)$)%
}%
%--------- For debugging use only
\newcommand{\ShowPoints}[4]{%
\filldraw [blue, opacity=0.5]%
(#2,#3) circle (2pt)%
($(#2,#3)-(#1, #1#4)$) circle (1pt) --%
($(#2,#3)+(#1, #1#4)$) circle (1pt)%
}%
\newcommand*{\AddLabel}[2][]{%
\node [draw,shape=rectangle,fill=white,#1] at (-1,2.5) {#2};
}
%
\begin{document}
\noindent
Example using 3 points where $x$, $f(x)$ and $f^\prime(x)$ are given for various $\Delta x$:
\bigskip\par\noindent
\begin{tikzpicture}
\newcommand{\DeltaXStart}{0.5}%
\newcommand{\DeltaXMiddle}{0.5}%
\newcommand*{\DeltaXEnd}{0.5}%
%
\draw [thin, gray, opacity=0.5] (-3,-3) grid (3,3);
\edef\MyPath{
\ExtrapolateStart{\DeltaXStart}{-2}{-1}{1}
\Extrapolate{\DeltaXMiddle}{0}{-1}{0}
\ExtrapolateEnd{\DeltaXEnd}{2}{2}{-1}
}
\draw [ultra thick, red, smooth] \MyPath;
% Following for debugging use only:
\ShowPoints{\DeltaXStart}{-2}{-1}{1};
\ShowPoints{\DeltaXMiddle}{0}{-1}{0};
\ShowPoints{\DeltaXEnd}{2}{2}{-1};
%
\AddLabel{$\Delta x = \DeltaXMiddle$};
\end{tikzpicture}
%
\begin{tikzpicture}
\newcommand{\DeltaXStart}{1.0}%
\newcommand{\DeltaXMiddle}{1.0}%
\newcommand*{\DeltaXEnd}{1.0}%
%
\draw [thin, gray, opacity=0.5] (-3,-3) grid (3,3);
\edef\MyPath{
\ExtrapolateStart{\DeltaXStart}{-2}{-1}{1}
\Extrapolate{\DeltaXMiddle}{0}{-1}{0}
\ExtrapolateEnd{\DeltaXEnd}{2}{2}{-1}
}
\draw [ultra thick, red, smooth] \MyPath;
% Following for debugging use only:
\ShowPoints{\DeltaXStart}{-2}{-1}{1};
\ShowPoints{\DeltaXMiddle}{0}{-1}{0};
\ShowPoints{\DeltaXEnd}{2}{2}{-1};
%
\AddLabel{$\Delta x = \DeltaXMiddle$};
\end{tikzpicture}
%
\begin{tikzpicture}
\newcommand{\DeltaXStart}{0.4}%
\newcommand{\DeltaXMiddle}{1.0}%
\newcommand*{\DeltaXEnd}{0.6}%
%
\draw [thin, gray, opacity=0.5] (-3,-3) grid (3,3);
\edef\MyPath{
\ExtrapolateStart{\DeltaXStart}{-2}{-1}{1}
\Extrapolate{\DeltaXMiddle}{0}{-1}{0}
\ExtrapolateEnd{\DeltaXEnd}{2}{2}{-1}
}
\draw [ultra thick, red, smooth] \MyPath;
% Following for debugging use only:
\ShowPoints{\DeltaXStart}{-2}{-1}{1};
\ShowPoints{\DeltaXMiddle}{0}{-1}{0};
\ShowPoints{\DeltaXEnd}{2}{2}{-1};
%
\AddLabel{$\Delta x = \DeltaXStart,\DeltaXMiddle,\DeltaXEnd$};
\end{tikzpicture}
\newpage\noindent
Example using 5 points where $x$, $f(x)$ and $f^\prime(x)$ are given:
\bigskip
\par\noindent
\begin{tikzpicture}
\newcommand{\DeltaXStart}{0.5}%
\newcommand{\DeltaXMiddle}{0.3}%
\newcommand*{\DeltaXEnd}{0.5}%
%
\draw [thin, gray, opacity=0.5] (-3,-3) grid (3,3);
\edef\MyPath{
\ExtrapolateStart{\DeltaXStart}{-2}{0}{3.0}
\Extrapolate{\DeltaXMiddle}{-1}{2}{1}
\Extrapolate{\DeltaXMiddle}{0}{1}{-2}
\Extrapolate{\DeltaXMiddle}{1}{-1}{-0.5}
\ExtrapolateEnd{\DeltaXEnd}{2}{1}{2.0}
}
\draw [ultra thick, red, smooth] \MyPath;
% Following for debugging use only:
\ShowPoints{\DeltaXStart}{-2}{0}{3.0};
\ShowPoints{\DeltaXMiddle}{-1}{2}{1};
\ShowPoints{\DeltaXMiddle}{0}{1}{-2};
\ShowPoints{\DeltaXMiddle}{1}{-1}{-0.5};
\ShowPoints{\DeltaXEnd}{2}{1}{2.0};
%
\AddLabel[xshift=2cm]{$\Delta x = \DeltaXStart,\DeltaXMiddle,\DeltaXEnd$};
\end{tikzpicture}
%
\begin{tikzpicture}
\newcommand{\DeltaXStart}{0.5}%
\newcommand{\DeltaXMiddle}{0.3}%
\newcommand*{\DeltaXEnd}{0.5}%
%
\draw [thin, gray, opacity=0.5] (-3,-3) grid (3,3);
\edef\MyPath{
\ExtrapolateStart{\DeltaXStart}{-2}{-1}{1}
\Extrapolate{\DeltaXMiddle}{-1}{-2}{0}
\Extrapolate{\DeltaXMiddle}{0}{1.5}{0}
\Extrapolate{\DeltaXMiddle}{1}{-2}{0}
\ExtrapolateEnd{\DeltaXEnd}{2}{2}{-2}
}
\draw [ultra thick, red, smooth] \MyPath;
% Following for debugging use only:
\ShowPoints{\DeltaXStart}{-2}{-1}{1};
\ShowPoints{\DeltaXMiddle}{-1}{-2}{0};
\ShowPoints{\DeltaXMiddle}{0}{1.5}{0};
\ShowPoints{\DeltaXMiddle}{1}{-2}{0};
\ShowPoints{\DeltaXEnd}{2}{2}{-2};
%
\AddLabel{$\Delta x = \DeltaXStart,\DeltaXMiddle,\DeltaXEnd$};
\end{tikzpicture}
\end{document}