Roger Hui wrote:
> As Joey Tuttle observed yesterday, in J you have
> the option of switching into extended precision
> to get exact answers. (Or, if the original numbers
> are not rational, to get more exact answers.)
>
> A=:2 2 $ 1 1.0000001 1 1
> b=:2.0000001 2
>
> b %. A
> 0.911182 1.08882
> b %.&x: A
> 1 1
Alternatively, you can apply some sort of pivoting, and stay with floating
point. For example,
require '~system/packages/math/linear.ijs'
{:"1 gauss_jordan A,.b
1 1
Best wishes,
John
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm