2
$\begingroup$

Given a function $1/\sqrt{x^2 -k^2}$ where k is a constant with a small imaginary part, how do you go about constructing a rational approximation? I am interested in the L_p (p=2 or $\infty$) norm of the difference being small on the real line. Both the theoretical and the practical implementation is of interest.

$\endgroup$
2
  • $\begingroup$ What do you mean by rational? Isn't your function rational? $\endgroup$ Commented Oct 5, 2013 at 17:36
  • $\begingroup$ Sorry, forgot a square root. Updated. $\endgroup$
    – Steven
    Commented Oct 5, 2013 at 17:48

2 Answers 2

1
$\begingroup$

By translation and scaling, we may assume WLOG $k = i$, i.e. your function is $1/\sqrt{x^2 + 1}$. Moreover, by symmetry we may assume the approximating function is even. So taking $x^2 = t$, we want to approximate $1/\sqrt{t+1}$ by rational functions of $t$ on $[0,\infty)$.

Now Maple's {\tt minimax} can approximate by rational functions, but it requires a bounded interval. So we map $[0,\infty)$ to $[0,1]$ by $1/(t+1) = s$. Thus we take $f(s) = 1/\sqrt{1/s} = \sqrt{s}$ on $[0,1]$. Now e.g. for a best uniform approximation of that by polynomials of degrees $5$ on $[0,1]$, we take

g:= numapprox:-minimax(sqrt(s),s=0..1,5,1,'maxerror');

Due to a possible bug, this produces an error in Maple 17. In Maple 15 I got

$$ g := 0.0278445029+(4.753636971+(-20.64608236+(47.77480263+(-49.59144735+18.70909011 s)s)s)s)s$$

with maximum error of $ 0.02784459798$. Substutute $s = 1/(1+x^2)$ to get a rational function of $x$ approximating $1/\sqrt{1+x^2}$ on $(-\infty,\infty)$ with this same error.

$\endgroup$
2
  • $\begingroup$ I am interested when $x$ is real so I can only rescale by reals and translate by reals. Therefore I do not see how I can take without loss of generality $k=i$. Could you explain this? $\endgroup$
    – Steven
    Commented Oct 6, 2013 at 18:58
  • $\begingroup$ Oh, sorry, wrong function. I seem to have assumed it was $1/\sqrt{(x-a)^2 + b^2}$. $\endgroup$ Commented Oct 6, 2013 at 19:34
1
$\begingroup$

Eleven years too late.

Using @Robert Israel's approach, the $[n,n]$ Padé approximants $P_n$ $$\sqrt s =\frac{1}{\sqrt{2}}\,\frac {1+\sum_{i=1}^n a_i\,\left(s-\frac{1}{2}\right)^i} {1+\sum_{i=1}^n b_i\,\left(s-\frac{1}{2}\right)^i}+O\left(\left(s-\frac{1}{2}\right)^{2n+1}\right) $$ can easily be built starting from the infinite series $$\sqrt s=\sum_{i=1}^\infty 2^{i-\frac{1}{2}} \binom{\frac{1}{2}}{i}\left(s-\frac{1}{2}\right)^i$$

The table below reports, for a given $n$ the coefficients as well as the norm $$\Phi_n=\int_0^1 \big[\sqrt s-P_n\big]^2\,ds$$ $$\left( \begin{array}{cccc} n & a_i & b_i & \Phi_n \\ 1 & \left\{\frac{3}{2}\right\} & \left\{\frac{1}{2}\right\} & 9.6\times 10^{-4} \\ 2 & \left\{\frac{5}{2},\frac{5}{4}\right\} & \left\{\frac{3}{2},\frac{1}{4}\right\} & 1.35\times 10^{-4} \\ 3 & \left\{\frac{7}{2},\frac{7}{2},\frac{7}{8}\right\} & \left\{\frac{5}{2},\frac{3}{2},\frac{1}{8}\right\} & 3.62\times 10^{-5} \\ 4 & \left\{\frac{9}{2},\frac{27}{4},\frac{15}{4},\frac{9}{16}\right\} & \left\{\frac{7}{2},\frac{15}{4},\frac{5}{4},\frac{1}{16}\right\} & 1.34\times 10^{-5} \\ 5 & \left\{\frac{11}{2},11,\frac{77}{8},\frac{55}{16},\frac{11}{32 }\right\} & \left\{\frac{9}{2},7,\frac{35}{8},\frac{15}{16},\frac{1}{32}\right\} & 6.05\times 10^{-6} \\ \end{array} \right)$$

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .