1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
|
\begin{center}\begin{minipage}{15cm}\begin{Verbatim}[frame=single]
> restart;
The tool has been restarted.
> prec=50;
The precision has been set to 50 bits.
> f=cos(2*exp(x));
> d=[-1/8;1/8];
> p=remez(f,2,d);
> derivativeZeros = dirtyfindzeros(diff(p-f),d);
> derivativeZeros = inf(d).:derivativeZeros:.sup(d);
> maximum=0;
> for t in derivativeZeros do {
r = evaluate(abs(p-f), t);
if r > maximum then { maximum=r; argmaximum=t; };
};
> print("The infinity norm of", p-f, "is", maximum, "and is reached at", argmaxi
mum);
The infinity norm of -3.89710727796949e-2 * x^2 + -1.79806720921853 * x + (-0.41
62655728752966) - cos(2 * exp(x)) is 8.6306594443227e-4 and is reached at 6.6635
5088071379e-2
\end{Verbatim}
\end{minipage}\end{center}
|