Suppose I have some function $f(x)$ on the closed interval $[a,b]$.
My goal is to approximate it with a linear spline in a such way, that the maximal deviation is minimal: $$ \min_{spline} \max_{x \in [a,b]} |f(x) - spline(x)| $$ I have the values of $f$ at $N$ points - $f(x_1), \ldots f(x_N)$, where $x_1 < x_2 \ldots x_N \in [a, b]$. At each interval $x$ $$ spline(x) = f(x_i) + \frac{f(x_{i + 1}) - f(x_i)}{x_{i+1}-x_i} (x - x_{i+1}) \qquad x \in (x_i, x_{i+1}) $$ What is the optimal choice of $x_i$ for given $N$?