On Thu, Jun 10, 2010 at 4:06 PM, R.E. Boss <[email protected]> wrote:
> The first problem, extrapolating a polynomial (of degree k) through k
> points, can be done as follows.
>
> pol=: (+/ . *~[: %.@:|: (^"_ 0 (i...@#)))/
...
> This extrapolating is much more efficient.
However, it is not necessarily as accurate:
(i.9) (p.~ pol) (,: i...@#)0 1 4
1.27676e_15 1 4 9 16 25 36 49 64
(Using differences, the first element of the result would be zero.)
--
Raul
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm