[Libreoffice] Help concerning code style and documentation

Kohei Yoshida kyoshida at novell.com
Wed Nov 3 06:39:07 PDT 2010


Hi Regina,

On Wed, 2010-11-03 at 10:35 +0100, Regina Henschel wrote:
> Hi Kohei,
> 
> Kohei Yoshida schrieb:
> > Hi Regina,
> >
> > On Sun, 2010-10-24 at 18:13 +0200, Regina Henschel wrote:
> >> Hi all,
> >>
> >> I'm currently working on LINEST and have attached a draft to issue
> >> http://www.openoffice.org/issues/show_bug.cgi?id=115189
> >>
> >> There is no mathematical problem, but I'm uncertain about coding style.
> >> The algorithms work on matrices. They have a lot of parts which are
> >> nearly identical but the matrices are transposed. How to handle that?
> >
> > If one algorithm traverses matrix row-wise, and another column-wise,
> > then I would just leave them as-is.  There isn't much we could do to
> > reduce code side in that situation, and I don't think it would be worth
> > the effort.
> >
> > If we really wanted, we could try templates as Thorsten suggested, but
> > we can try that after your initial code gets integrated with some test
> > cases to verify calculations.
> 
> I have attached a true patch and some test cases to 
> http://www.openoffice.org/issues/show_bug.cgi?id=115189

Excellent!  Thanks.  I'll take a look at that.

> 
> Do you have already any other test cases around?

No, unfortunately not. We will have to work on beefing up our test
cases, for sure.

> >
> > FYI, I'm planning to integrate a major refactoring of the guts of
> > ScMatrix, to push most of its implementation out to an external library
> > and to allow different base values (numerical-0 vs empty elements).  It
> > should not affect ScInterpreter code as the change should be transparent
> > to the users of ScMatrix, but I thought I would mention.
> >
> > And I would probably be the one to maintain your code, unless you want
> > to maintain it yourself. ;-)
> 
> You know, that I work on it in my spare time, so response time might be 
> long. You should tell me, whether the mathematics I used are clear from 
> the code or you want me to write a description.

Understood.  We certainly want you to do it at your own pace. :-)

As for documentation of the mathematics used behind the calculations, if
you could write up some overview of it, it would certainly help us
maintain it in the future.  Speaking for myself, I'm not too familiar
with the math involved there, so....

Thanks a lot!

Kohei

-- 
Kohei Yoshida, LibreOffice hacker, Calc
<kyoshida at novell.com>



More information about the LibreOffice mailing list