# Finding where f is well conditioned

I am looking for help with part b. I'm not sure where f is well conditioned in a relative sense given that $$\kappa(x)$$ is a constant. Is f merely well condition at this point ($$\frac13$$)? If so, how do I know this? Is $$\kappa(x)$$ of "moderate size"? I'm not sure how to interpret this constant. For C(x) I can input a value and see how this effects the output but for $$\kappa(x)$$ this isn't possible. Any help would be much appreciated!

Let $$f(x) = \sqrt{x^3}$$

(a) Find the absolute and relative condition numbers of f.

(b) Where is f well conditioned in an absolute sense? In a relative sense?

(c) Suppose $$x=10^{-17}$$ is replaced by $$x=10^{-16}$$. Using the absolute condition number of f, how much of a change is expected in f due to this change in the argument?

(a)$$f(x) = x^{1/3}$$, $$f'(x)=\frac13x^{-2/3}$$

absolute condition number = $$C(x) =\frac13x^{-2/3}$$

relative condition number = $$\kappa(x) = xf(x)/f'(x)$$ = $$\frac{x \frac13 x^{-2/3}}{x^{1/3}}=\frac13$$

(b) f is well conditioned in an absolute sense as x approaches infinity as large values of x produce a small change in f.

• You are missing some absolute value signs which matter very little for this example. More importantly, exactly how have the condition numbers been defined in your class? Where you given an abstract definition from which these formula were systematically derived or where the formulas derived using energetic hand waving? Oct 14, 2020 at 19:59
• $|(y-\hat{y})|=|f(x)-f(\hat{x})| = |\frac{f(x) - f(\hat{x})}{x-\hat{x}}| |(x-\hat{x})|$ $\approx|f'(x)||x-\hat{x}|$ Thus $C(x) = |f'(x)|$, where $x \approx \hat{x}$ This is the absolute codition number. Similarly, $|\frac{y-\hat{y}}{y}|$ = $|\frac{xf(x)-f(\hat{x})}{x-\hat{x}}||\frac{x}{f(x)}||\frac{x-\hat{x}}{x}|$ Thus, $|\frac{y-\hat{y}}{y}| \approx|\frac{xf'(x)}{f(x)}||\frac{x-\hat{x}}{x}|$ $\approx |\frac{xf'(x)}{f(x)}|= \kappa({x})$where $x \approx \hat{x}$ This is the relative condition number. Oct 15, 2020 at 0:57

## 1 Answer

In general, conditions numbers represent the limiting behavior of the worst case scenario. If the condition number is small, then the function is insensitive to sufficiently small changes of input. If the condition number is large, then it is possible to find a small change of the input, which will change the output dramatically.

To be precise, let us consider the proper definition of the relative condition number $$\kappa_f(x)$$ for a function $$f : \mathbb{R} \rightarrow \mathbb{R}$$ at a point $$x \in \mathbb{R}$$.

We begin by defining an auxiliary function $$\kappa$$ given by $$$$\kappa_f( x, \delta) = \sup \left\{ \left| \frac{f(x) - f(y)}{f(x)} \right| \big{/} \left| \frac{x-y}{x} \right| \: : \: 0 < |x-y| < \delta|x| \right\}.$$$$

It is straightforward to verify that $$\delta \rightarrow \kappa_f(x,\delta)$$ is a nonnegative and nondecreasing function of $$\delta$$. This implies that the limit $$$$\underset{\delta \rightarrow 0_+}{\lim} \kappa_f(x,\delta)$$$$ exists and is nonnegative. Since we are primarily interested in small values of $$|x-y|/|x|$$ we will use this limit to characterize the sensitivity of $$f(x)$$ to perturbations of $$x$$ which are small relative to $$x$$. This is why we formally define $$\kappa_f(x) = \underset{\delta \rightarrow 0_+}{\lim} \kappa_f(x,\delta).$$

We will now discuss how the relative condition number imposes a hard limit on the accuracy which can be achieved when using $$f(y)$$ to approximate $$f(x)$$. Let $$\delta > 0$$ and let $$y \in \mathbb{R}$$ be any number such that $$0 < |x-y| < \delta|x|$$. Then $$$$\left|\frac{f(x) - f(y)}{f(x)} \right| \leq \kappa_f(x,\delta)\left|\frac{x-y}{x} \right| \leq \kappa_f(x,\delta) \delta.$$$$ Moreover, if $$\delta$$ is sufficiently small, then $$$$\kappa_f(x,\delta) \approx \kappa_f(x)$$$$ is a good approximation. It follows that we cannot expect that the relative error is smaller than $$$$\left| \frac{f(x) - f(y)}{f(x)}\right| \approx \kappa_f(x)\left|\frac{x-y}{x}\right|.$$$$ It is painful to compute the condition number directly from the definition. However, if $$f$$ is also differentiable, then $$\kappa_f(x) = \left| \frac{xf'(x)}{f(x)} \right|.$$ In particular, if $$f : (0,\infty) \rightarrow \mathbb{R}$$ is given by $$f(x) = x^p,$$ where $$p \ge 0$$, then $$\forall x \in (0, \infty) \: : \: \kappa_f(x) = p.$$ In the case of $$p \in [0,1)$$ we see that the application of $$f$$ diminishes the relative error on the input and produces output which is more accurate than the input. This is as good as it gets and such a function $$f$$ certainly deserves to be classified as well-conditioned in the relative sense.

• Thanks so much Carl! This is really good stuff! I'd buy you a pint if I could:) Oct 16, 2020 at 15:42
• @user551155 Thank you very much for your kind words. The abstract approach extends to absolute case as well as vector functions of multiple variables. It gets more technical, but the core idea is preserved, i.e., condition numbers measure the limit of the worst case behavior. This is an answer to a question on normwise condition numbers for vector functions of multiple variables. It gives the two best reference that I know. Oct 16, 2020 at 17:07