Apache OpenOffice (AOO) Bugzilla – Issue 25478
Proposition of a new approch of regression.
Last modified: 2017-05-20 11:11:51 UTC
Hello ! I propose a new approch to compute regression of function. You will find the program test.cxx, which give some vision of the begining of my works. I have many ideas to improve this. By compiling, you will obtain this message : $ g++ test.cxx -o test vector.hxx: In member function `T1 linearAlgebra::Vector<T1, T2>::operator[](T2) const [with T1 = double, T2 = unsigned char]': matrix.hxx:846: instantiated from `linearAlgebra::Vector<T1, T2> linearAlgebra::Matrix<T1, T2>::operator*(const linearAlgebra::Vector<T1, T2>&) const [with T1 = double, T2 = unsigned char]' fit.hxx:66: instantiated from `linearAlgebra::Vector<T1, T2> fit(const linearAlgebra::Matrix<T1, T2>&, const linearAlgebra::Vector<T1, T2>&, T2, T1) [with T1 = double, T2 = unsigned char]' fit.hxx:90: instantiated from `linearAlgebra::Vector<T1, T2> linearRegression(const T1*, const linearAlgebra::Vector<T1, T2>&, T2, T1) [with T1 = double, T2 = unsigned char]' test.cxx:39: instantiated from here vector.hxx:358: warning: comparison is always true due to limited range of data type matrix.hxx: In member function `T1* linearAlgebra::Matrix<T1, T2>::operator[](T2) const [with T1 = double, T2 = unsigned char]': matrix.hxx:302: instantiated from `T1 linearAlgebra::Matrix<T1, T2>::columnNorm(const linearAlgebra::Matrix<T1, T2>&) const [with T1 = double, T2 = unsigned char]' matrix.hxx:517: instantiated from `linearAlgebra::Matrix<T1, T2> linearAlgebra::Matrix<T1, T2>::inverse(T1) const [with T1 = double, T2 = unsigned char]' fit.hxx:66: instantiated from `linearAlgebra::Vector<T1, T2> fit(const linearAlgebra::Matrix<T1, T2>&, const linearAlgebra::Vector<T1, T2>&, T2, T1) [with T1 = double, T2 = unsigned char]' fit.hxx:90: instantiated from `linearAlgebra::Vector<T1, T2> linearRegression(const T1*, const linearAlgebra::Vector<T1, T2>&, T2, T1) [with T1 = double, T2 = unsigned char]' test.cxx:39: instantiated from here matrix.hxx:881: warning: comparison is always true due to limited range of data type Don't be affraid, it's allright, you can execute test. Best regards. Yoann LE BARS, alias Le Farfadet Spatial
Created attachment 13116 [details] Fitting library
Created attachment 13117 [details] The licence text.
Created attachment 13118 [details] A matrix library.
Created attachment 13119 [details] testing program
Created attachment 13120 [details] A vector library.
Adding myself to CC.
adding myself to cc
Hi Farfadet on linear regression pertubating the couple (-3.5,1) of constants with various modificators lead to convergency when the modfications tend to 0 Great Job Laurent
adding me to cc - Sophie
I am sorry, I did not found a correct mime type for C++ sources, so I used patch type, which is not precissly the good one.
Yoann, Sounds interesting, but before we can even consider to use your code we need a signed JCA from you, see http://www.openoffice.org/contributing.html only LGPL for incorporated code would not be sufficient. Eike
I have sign the JCA, the previous LGPL-only doesn't apply anymore to the code.
Thanks, I'll take care of further proceeding. Discussion takes place on the dev@sc.openoffice.org mailing list.
Accepting self-declared responsibility..
Eike, Yoann's JCA is listed now. Thanks, Yoann.
Created attachment 14839 [details] New code, hoping it solve memory problems.
The file fit.tar.bz2 is an archive compressed into bz2 format. It give a new code. When unpacked, type make and the run testfit. The Makefile had been tested with GNU/Linux and gcc. There is no warning message, the options are -g and -Wall. I have still some problems with polynomial regression, I am working on it.
Created attachment 15324 [details] New version, solving several problems.
fit05182004.tar.bz2 give a new version of the fitting stuff. Please test it.
Created attachment 20143 [details] New version, improved precision.
fit-12062004.tar.bz2 give a new version of the code, with improved precision. Computation times are much longuer too. To use it, please read readme.sxw or readme.pdf.
Created attachment 20599 [details] New version, improved computation time.
Created attachment 20748 [details] New version, improved memory gestion.
Created attachment 21034 [details] Some minors improvments.
Adding bm (working on charts) to CC
Bjoern, This may have gone overlooked during the new chart implementation. Did you use these algorithms? Eike
Reset assigne to the default "issues@openoffice.apache.org".