[prev in list] [next in list] [prev in thread] [next in thread] 

List:       koffice-devel
Subject:    Re: patch for missing function
From:       Stefan Nikolaus <stefan.nikolaus () kdemail ! net>
Date:       2006-12-14 15:38:25
Message-ID: 200612141638.29502.stefan.nikolaus () kdemail ! net
[Download RAW message or body]

[Attachment #2 (multipart/signed)]


Hi Sascha,

On Wednesday 13 December 2006 19:04, Sascha Pfau wrote:
> i am very new to koffice. i've take a look into your todo's. i think
> implementing missing function isn't very difficult. so i sat down ans wrote
> IMLOG2 and IMLOG10 functioncs

Great! We always need people willing to help. :)

> , but now i don't know about how to commit my 
> patch.

This is the right way for the first.

> i hope you take a look at it and commit it to trunk.

I had a look at your patch. You've multiplied the natural logarithm value with 
M_LOG2El (log_2(e)) and M_LOG10El (log_10(e)), respectively. This looked 
strange to me, so I grabbed my old Bronstein and found
log_a(z) = ln(z) / ln(a)
It has to be a division by M_LN2l and M_LN10l, respectively.
More detailed:
z=r*exp(i*phi)
ln(z)=ln(r)+i*phi*ln(e)=ln(r)+i*phi
log2(z)=ln(z)/ln(2)=ln(r)/ln(2)+(i*phi)/ln(2)

Besides that the patch looks good. :) Your examples are correct though. ;) 
Committed with the above changes.

If you're interested in implementing more functions, I'd like to point you to 
the OpenFormula work. The latest spec could be found at: 
http://www.oasis-open.org/apps/org/workgroup/office-formula/documents.php.
To figure out which functions KSpread still lacks of, you should create a test 
document out of the latest spec. The test doc generator could be found at 
http://wiki.oasis-open.org/office/Test_Suite_Generator.
Just follow the simple instructions and open the generated test doc in 
KSpread. This would give you a hint which functions need to be implemented.
But you can also ask for the functions. ;-)

If you're heading for something different, let us know. Either here on 
koffice-devel or on IRC #koffice.

Regards,
Stefan

[Attachment #5 (application/pgp-signature)]

_______________________________________________
koffice-devel mailing list
koffice-devel@kde.org
https://mail.kde.org/mailman/listinfo/koffice-devel


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic