Lorenz Minder on Thu, 14 May 2009 23:57:32 +0200

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: Another problem with matrix inversion


I'll reply to the other stuff later.

> Ah sorry, I looked at FpM_gauss(). Flm_gauss cannot possibly take a t_COL
> as
> second argument, only a t_VECSMALL. There might be a fix in your code for
> some
> bug still but I could not find it.

Sorry, I was vague there.  In Flm_gauss_sp() the number of columns, bco,
is computed before b is converted to a matrix, which means it's going
to be something wrong if b is a vector, and consequently screw up
everything that involves bco later on.

So the "bco=lg(b)-1;" should be moved after the "if (iscol) b = mkmat(b);"

(As I said, I have not tried to produce a buggy example, but I can't
see how it could possibly work.)

> > > A function named FpM_gauss is not supposed to handle arguments that
> are
> > > not
> > > t_MAT.
> > 
> > Then I think the non-functional support that someone has coded into
> these
> > functions should be removed.
> Agreed. We should really provide FpM_FpC_gauss (etc.) functions instead.

I have now looked at FpM_gauss(), and it looks ok there, so I take back
the "non-functional" comment I made.  It's also in fact used e.g.,
via matsolve(), when the B argument is a t_COL. (Unlike Flm_gauss().)

Neu: GMX FreeDSL Komplettanschluss mit DSL 6.000 Flatrate + Telefonanschluss für nur 17,95 Euro/mtl.!* http://dslspecial.gmx.de/freedsl-surfflat/?ac=OM.AD.PD003K11308T4569a