Lastly, we chose a rational function \(R_{m,n}(x)\) that matches both the derivative and function values at interpolated points. We will explore this through an example. Consider \(f(x)=e^{-x}\) and
\begin{equation*}
\begin{aligned}R_{4,3}(x)\amp = \frac{a_{0}+a_{1} x + a_{2} x^{2} + a_{3} x^{3}+a_{4} x^{4}}{1 + b_{1} x + b_{2} x^{2}+ b_{3} x^{3}}\end{aligned}
\end{equation*}
and we wish to evaluate \(R_{4,3}(x)\) and its derivative at 4 points. Although equally-spaced points can be used, we will use the roots of \(T_{4}(x)\text{,}\) the Chebyshev polynomial. Thus we will take \(x_{0} = -0.9238795325\text{,}\) \(x_{1}= -0.3826834325\text{,}\) \(x_{2}=0.3826834325\text{,}\) and \(x_{3}=0.9238795325\text{.}\) We will solve:
\begin{equation*}
\begin{aligned}R_{4,3}(x_{i})\amp = f(x_{i})\amp R'_{4,3}(x)\amp = f'(x_{i})\end{aligned}
\end{equation*}
and solve for the \(a\) and \(b\) values. Again, this is not easy to do by hand, but using a CAS, it is reasonably easy. The results are:
\begin{equation*}
\begin{aligned}R_{4,3}(x)\amp = \frac{P(x)}{Q(x)}\end{aligned}
\end{equation*}
where
\begin{equation*}
\begin{aligned}P(x)\amp = 1.000000011- 0.5718840492\,x+ 0.1430276148\,{x}^{2}\\\amp - 0.01904667174\,{x}^{3}+ 0.001181046601\,{x}^{4}\\ Q(x)\amp = 1+ 0.4281159555\,x+ 0.07114374318\,{x}^{2}+ 0.004705683520\,{x}^{3}\end{aligned}
\end{equation*}