diff options
Diffstat (limited to 'packages/base')
-rw-r--r-- | packages/base/CHANGELOG | 219 | ||||
-rw-r--r-- | packages/base/INSTALL.md | 117 | ||||
-rw-r--r-- | packages/base/THANKS.md | 157 | ||||
-rw-r--r-- | packages/base/hmatrix.cabal (renamed from packages/base/hmatrix-base.cabal) | 2 |
4 files changed, 495 insertions, 0 deletions
diff --git a/packages/base/CHANGELOG b/packages/base/CHANGELOG new file mode 100644 index 0000000..99a6845 --- /dev/null +++ b/packages/base/CHANGELOG | |||
@@ -0,0 +1,219 @@ | |||
1 | 0.16.0.0 | ||
2 | -------- | ||
3 | |||
4 | * created hmatrix-base | ||
5 | |||
6 | * Added more organized reexport modules: | ||
7 | Numeric.HMatrix, Numeric.HMatrix.Data, Numeric.HMatrix.Devel | ||
8 | (The documentation is hidden for the other modules, | ||
9 | but they continue to be exposed and are not deprecated) | ||
10 | |||
11 | * added support for empty arrays | ||
12 | |||
13 | * join deprecated, use vjoin | ||
14 | |||
15 | * dot now conjugates the first input vector | ||
16 | * added udot (unconjugated dot product) | ||
17 | |||
18 | * (<.>) overloaded to matrix and dot products | ||
19 | * added Monoid instance for Matrix using matrix product | ||
20 | |||
21 | * improved build and konst | ||
22 | |||
23 | * improved linspace | ||
24 | |||
25 | * improved error messages | ||
26 | * more usage examples | ||
27 | |||
28 | * simplified LSDiv | ||
29 | * Plot functions moved to Numeric.LinearAlgebra.Util | ||
30 | * removed (!) (use (¦)), added (——) | ||
31 | |||
32 | 0.15.2.0 | ||
33 | -------- | ||
34 | |||
35 | * general pinvTol and improved pinv | ||
36 | |||
37 | 0.15.1.0 | ||
38 | -------- | ||
39 | |||
40 | * One-dimensional minimization | ||
41 | |||
42 | * Doubly-adaptive quadrature for difficult integrands | ||
43 | |||
44 | 0.15.0.0 | ||
45 | -------- | ||
46 | |||
47 | * Data.Packed.Foreign (additional FFI helpers) | ||
48 | |||
49 | * NFData instance of Matrix | ||
50 | |||
51 | * Unidimensional root finding | ||
52 | |||
53 | * In Numeric.LinearAlgebra.Util: | ||
54 | pairwise2D, rowOuters, null1, null1sym, size, unitary, mt, (¦), (?), (¿) | ||
55 | |||
56 | * diagBlock | ||
57 | |||
58 | * meanCov moved to Container | ||
59 | |||
60 | 0.14.1.0 | ||
61 | -------- | ||
62 | |||
63 | * In Numeric.LinearAlgebra.Util: | ||
64 | convolution: corr, conv, corr2, conv2, separable, corrMin | ||
65 | kronecker: vec, vech, dup, vtrans | ||
66 | |||
67 | 0.14.0.0 | ||
68 | -------- | ||
69 | |||
70 | * integration over infinite intervals | ||
71 | |||
72 | * msadams and msbdf methods for ode | ||
73 | |||
74 | * Numeric.LinearAlgebra.Util | ||
75 | |||
76 | * (<\>) extended to multiple right-hand sides | ||
77 | |||
78 | * orth | ||
79 | |||
80 | 0.13.0.0 | ||
81 | -------- | ||
82 | |||
83 | * tests moved to new package hmatrix-tests | ||
84 | |||
85 | 0.11.2.0 | ||
86 | -------- | ||
87 | |||
88 | * geigSH' (symmetric generalized eigensystem) | ||
89 | |||
90 | * mapVectorWithIndex | ||
91 | |||
92 | 0.11.1.0 | ||
93 | -------- | ||
94 | |||
95 | * exported Mul | ||
96 | |||
97 | * mapMatrixWithIndex{,M,M_} | ||
98 | |||
99 | 0.11.0.0 | ||
100 | -------- | ||
101 | |||
102 | * flag -fvector default = True | ||
103 | |||
104 | * invlndet (inverse and log of determinant) | ||
105 | |||
106 | * step, cond | ||
107 | |||
108 | * find | ||
109 | |||
110 | * assoc, accum | ||
111 | |||
112 | 0.10.0.0 | ||
113 | -------- | ||
114 | |||
115 | * Module reorganization | ||
116 | |||
117 | * Support for Float and Complex Float elements (excluding LAPACK computations) | ||
118 | |||
119 | * Binary instances for Vector and Matrix | ||
120 | |||
121 | * optimiseMult | ||
122 | |||
123 | * mapVectorM, mapVectorWithIndexM, unzipVectorWith, and related functions. | ||
124 | |||
125 | * diagRect admits diagonal vectors of any length without producing an error, | ||
126 | and takes an additional argument for the off-diagonal elements. | ||
127 | |||
128 | * different signatures in some functions | ||
129 | |||
130 | 0.9.3.0 | ||
131 | -------- | ||
132 | |||
133 | * flag -fvector to optionally use Data.Vector.Storable.Vector | ||
134 | without any conversion. | ||
135 | |||
136 | * Simpler module structure. | ||
137 | |||
138 | * toBlocks, toBlocksEvery | ||
139 | |||
140 | * cholSolve, mbCholSH | ||
141 | |||
142 | * GSL Nonlinear Least-Squares fitting using Levenberg-Marquardt. | ||
143 | |||
144 | * GSL special functions moved to separate package hmatrix-special. | ||
145 | |||
146 | * Added offset of Vector, allowing fast, noncopy subVector (slice). | ||
147 | Vector is now identical to Roman Leshchinskiy's Data.Vector.Storable.Vector, | ||
148 | so we can convert from/to them in O(1). | ||
149 | |||
150 | * Removed Data.Packed.Convert, see examples/vector.hs | ||
151 | |||
152 | 0.8.3.0 | ||
153 | -------- | ||
154 | |||
155 | * odeSolve | ||
156 | |||
157 | * Matrix arithmetic automatically replicates matrix with single row/column | ||
158 | |||
159 | * latexFormat, dispcf | ||
160 | |||
161 | 0.8.2.0 | ||
162 | -------- | ||
163 | |||
164 | * fromRows/fromColumns now automatically expand vectors of dim 1 | ||
165 | to match the common dimension. | ||
166 | fromBlocks also replicates single row/column matrices. | ||
167 | Previously all dimensions had to be exactly the same. | ||
168 | |||
169 | * display utilities: dispf, disps, vecdisp | ||
170 | |||
171 | * scalar | ||
172 | |||
173 | * minimizeV, minimizeVD, using Vector instead of lists. | ||
174 | |||
175 | 0.8.1.0 | ||
176 | -------- | ||
177 | |||
178 | * runBenchmarks | ||
179 | |||
180 | 0.8.0.0 | ||
181 | -------- | ||
182 | |||
183 | * singularValues, fullSVD, thinSVD, compactSVD, leftSV, rightSV | ||
184 | and complete interface to [d|z]gesdd. | ||
185 | Algorithms based on the SVD of large matrices can now be | ||
186 | significantly faster. | ||
187 | |||
188 | * eigenvalues, eigenvaluesSH | ||
189 | |||
190 | * linearSolveLS, rq | ||
191 | |||
192 | 0.7.2.0 | ||
193 | -------- | ||
194 | |||
195 | * ranksv | ||
196 | |||
197 | 0.7.1.0 | ||
198 | -------- | ||
199 | |||
200 | * buildVector/buildMatrix | ||
201 | |||
202 | * removed NFData instances | ||
203 | |||
204 | 0.6.0.0 | ||
205 | -------- | ||
206 | |||
207 | * added randomVector, gaussianSample, uniformSample, meanCov | ||
208 | |||
209 | * added rankSVD, nullspaceSVD | ||
210 | |||
211 | * rank, nullspacePrec, and economy svd defined in terms of ranksvd. | ||
212 | |||
213 | * economy svd now admits zero rank matrices and return a "degenerate | ||
214 | rank 1" decomposition with zero singular value. | ||
215 | |||
216 | * added NFData instances for Matrix and Vector. | ||
217 | |||
218 | * liftVector, liftVector2 replaced by mapVector, zipVector. | ||
219 | |||
diff --git a/packages/base/INSTALL.md b/packages/base/INSTALL.md new file mode 100644 index 0000000..ef51167 --- /dev/null +++ b/packages/base/INSTALL.md | |||
@@ -0,0 +1,117 @@ | |||
1 | # [hmatrix][hmatrix2] installation | ||
2 | |||
3 | This package requires the [Glasgow Haskell Compiler](http://www.haskell.org/ghc/index.html) ghc >= 6.10, and [cabal-install](http://www.haskell.org/haskellwiki/Cabal-Install), conveniently available in the [Haskell Platform](http://hackage.haskell.org/platform), and the development packages for [GSL](http://www.gnu.org/software/gsl) and BLAS/[LAPACK](http://www.netlib.org/lapack). (The graphical functions also require **gnuplot** and **imagemagick**.) | ||
4 | |||
5 | [hmatrix]: http://code.haskell.org/hmatrix | ||
6 | [hmatrix2]: http://perception.inf.um.es/hmatrix | ||
7 | |||
8 | |||
9 | ## Linux ################################################## | ||
10 | |||
11 | |||
12 | Ubuntu/Debian: | ||
13 | |||
14 | $ sudo apt-get install libgsl0-dev liblapack-dev | ||
15 | $ cabal install hmatrix | ||
16 | |||
17 | Arch Linux: If the automatic installation from Hackage fails, install atlas-lapack and gsl, unpack the source, change the build-type to Simple in hmatrix.cabal (line 28) and add extra-libraries: gsl lapack (line 194). | ||
18 | |||
19 | Other distributions may require additional libraries. They can be given in a **--configure-option**. | ||
20 | |||
21 | ## Mac OS/X ############################################### | ||
22 | |||
23 | |||
24 | GSL must be installed via Homebrew or MacPorts. | ||
25 | |||
26 | Via Homebrew: | ||
27 | |||
28 | $ brew install gsl | ||
29 | $ cabal install hmatrix | ||
30 | |||
31 | Via MacPorts: | ||
32 | |||
33 | $ sudo port install gsl +universal | ||
34 | $ cabal install hmatrix | ||
35 | |||
36 | (Contributed by Heinrich Apfelmus, Torsten Kemps-Benedix and Ted Fujimoto). | ||
37 | |||
38 | ## Windows ############################################### | ||
39 | |||
40 | We use this [GSL binary](http://www.miscdebris.net/blog/2009/04/20/mingw-345-binaries-of-gnu-scientific-library-112-for-use-with-mingw-and-visual-c/), and blas/lapack dlls built with g77 (contributed by Gilberto Camara). All required files are in [gsl-lapack-windows.zip][winpack]. | ||
41 | |||
42 | (Due to [issue 21](https://github.com/albertoruiz/hmatrix/issues/21) we need hmatrix-0.13.1.0.) | ||
43 | |||
44 | 1) Install the Haskell Platform (tested on 2011.2.0.1) | ||
45 | |||
46 | > cabal update | ||
47 | |||
48 | 2) Download and unzip the following file into a stable folder %GSL% | ||
49 | |||
50 | http://perception.inf.um.es/hmatrix/gsl-lapack-windows.zip | ||
51 | |||
52 | 3.a) In a msys shell the installation should be fully automatic: | ||
53 | |||
54 | $ cabal install hmatrix-0.13.1.0 --extra-lib-dir=${GSL} --extra-include-dir=${GSL} | ||
55 | |||
56 | 3.b) Alternatively, in a normal windows cmd: | ||
57 | |||
58 | > cabal unpack hmatrix-0.13.1.0 | ||
59 | |||
60 | Edit hmatrix.cabal, in line 28 change build-type to "Simple", and then | ||
61 | |||
62 | > cabal install --extra-lib-dir=%GSL% --extra-include-dir=%GSL% | ||
63 | |||
64 | It may be necessary to put the dlls in the search path. | ||
65 | |||
66 | |||
67 | NOTE: The examples using graphics do not yet work in windows. | ||
68 | |||
69 | [install]: http://code.haskell.org/hmatrix/INSTALL | ||
70 | [install2]: http://patch-tag.com/r/aruiz/hmatrix/snapshot/current/content/pretty/INSTALL | ||
71 | [winpack2]: http://perception.inf.um.es/hmatrix/gsl-lapack-windows.zip | ||
72 | [winpack]: https://github.com/downloads/AlbertoRuiz/hmatrix/gsl-lapack-windows.zip | ||
73 | |||
74 | ## Tests ############################################### | ||
75 | |||
76 | After installation we must verify that the library works as expected: | ||
77 | |||
78 | $ cabal install hmatrix-tests --enable-tests | ||
79 | $ ghci | ||
80 | > Numeric.LinearAlgebra.Tests.runTests 20 | ||
81 | OK, passed 100 tests. | ||
82 | OK, passed 100 tests. | ||
83 | ... etc... | ||
84 | |||
85 | If you get any failure please run lapack's own tests to confirm that your version is not broken. For instance, in ubuntu 9.04, **libatlas-sse2** does not work (see this [bug report](https://bugs.launchpad.net/ubuntu/+source/atlas/+bug/368478)). If your lapack library is ok but hmatrix's tests fail please send a bug report! | ||
86 | |||
87 | |||
88 | ## Optimized BLAS/LAPACK ########################################## | ||
89 | |||
90 | I have successfully tested ATLAS and MKL on Linux. | ||
91 | |||
92 | ### [ATLAS](http://math-atlas.sourceforge.net/) #################### | ||
93 | |||
94 | In Ubuntu >= 9.04 we need: | ||
95 | |||
96 | $ sudo apt-get install libatlas-base-dev | ||
97 | |||
98 | In older Ubuntu/Debian versions we needed: | ||
99 | |||
100 | $ sudo apt-get install refblas3-dev lapack3-dev atlas3-base-dev | ||
101 | |||
102 | We may use a version (sse2, 3dnow, etc.) optimized for the machine. | ||
103 | |||
104 | ### Intel's MKL ############################################### | ||
105 | |||
106 | There is a free noncommercial download available from Intel's website. To use it I have added the following lines in my .bashrc configuration file: | ||
107 | |||
108 | export LD_LIBRARY_PATH=/path/to/mkl/lib/arch | ||
109 | export LIBRARY_PATH=/path/to/mkl/lib/arch | ||
110 | |||
111 | where arch = 32 or em64t. | ||
112 | |||
113 | The library must be installed with the -fmkl flag: | ||
114 | |||
115 | $ cabal install hmatrix -fmkl | ||
116 | |||
117 | |||
diff --git a/packages/base/THANKS.md b/packages/base/THANKS.md new file mode 100644 index 0000000..b1417a6 --- /dev/null +++ b/packages/base/THANKS.md | |||
@@ -0,0 +1,157 @@ | |||
1 | I thank Don Stewart, Henning Thielemann, Bulat Ziganshin, Heinrich Apfelmus, | ||
2 | and all the people in the Haskell mailing lists for their help. | ||
3 | |||
4 | I am particularly grateful to Vivian McPhail for his excellent | ||
5 | contributions: improved configure.hs, Binary instances for | ||
6 | Vector and Matrix, support for Float and Complex Float elements, | ||
7 | module reorganization, monadic mapVectorM, and many other improvements. | ||
8 | |||
9 | - Nico Mahlo discovered a bug in the eigendecomposition wrapper. | ||
10 | |||
11 | - Frederik Eaton discovered a bug in the design of the wrappers. | ||
12 | |||
13 | - Eric Kidd has created a wiki page explaining the installation on MacOS X: | ||
14 | http://www.haskell.org/haskellwiki/GSLHaskell_on_MacOS_X | ||
15 | |||
16 | - Fawzi Mohamed discovered a portability bug in the lapack wrappers. | ||
17 | |||
18 | - Pedro E. López de Teruel fixed the interface to lapack. | ||
19 | |||
20 | - Antti Siira discovered a bug in the plotting functions. | ||
21 | |||
22 | - Paulo Tanimoto helped to fix the configuration of the required libraries. | ||
23 | He also discovered the segfault of minimize.hs in ghci. | ||
24 | |||
25 | - Xiao-Yong Jin reported a bug on x86_64 caused by the assumptions in f2c.h, | ||
26 | which are wrong for this architecture. | ||
27 | |||
28 | - Jason Schroeder reported an error in the documentation. | ||
29 | |||
30 | - Bulat Ziganshin gave invaluable help for the ST monad interface to | ||
31 | in-place modifications. | ||
32 | |||
33 | - Don Stewart fixed the implementation of the internal data structures | ||
34 | to achieve excellent, C-like performance in Haskell functions which | ||
35 | explicitly work with the elements of vectors and matrices. | ||
36 | |||
37 | - Dylan Alex Simon improved the numeric instances to allow optimized | ||
38 | implementations of signum and abs on Vectors. | ||
39 | |||
40 | - Pedro E. López de Teruel discovered the need of asm("finit") to | ||
41 | avoid the wrong NaNs produced by foreign functions. | ||
42 | |||
43 | - Reiner Pope added support for luSolve, based on (d|z)getrs. | ||
44 | Made Matrix a product type and added changes to improve the code generated | ||
45 | by hmatrix-syntax. | ||
46 | |||
47 | - Simon Beaumont reported the need of QuickCheck<2 and the invalid | ||
48 | asm("finit") on ppc. He also contributed the configuration options | ||
49 | for the accelerate framework on OS X. | ||
50 | |||
51 | - Daniel Schüssler added compatibility with QuickCheck 2 as well | ||
52 | as QuickCheck 1 using the C preprocessor. He also added some | ||
53 | implementations for the new "shrink" method of class Arbitrary. | ||
54 | |||
55 | - Tracy Wadleigh improved the definitions of (|>) and (><), which now | ||
56 | apply an appropriate 'take' to the given lists so that they may be | ||
57 | safely used on lists that are too long (or infinite). | ||
58 | |||
59 | - Chris Waterson improved the configure.hs program for OS/X. | ||
60 | |||
61 | - Erik de Castro Lopo added buildVector and buildMatrix, which take a | ||
62 | size parameter(s) and a function that maps vector/matrix indices | ||
63 | to the values at that position. | ||
64 | |||
65 | - Jean-Francois Tremblay discovered an error in the tutorial. | ||
66 | |||
67 | - Gilberto Camara contributed improved blas and lapack dlls for Windows. | ||
68 | |||
69 | - Heinrich Apfelmus fixed hmatrix.cabal for OS/X. He also tested the package | ||
70 | on PPC discovering a problem in zgesdd. | ||
71 | |||
72 | - Felipe Lessa tested the performance of GSL special function bindings | ||
73 | and contributed the cabal flag "safe-cheap". | ||
74 | |||
75 | - Ozgur Akgun suggested better symbols for the Bound constructors in the | ||
76 | Linear Programming package. | ||
77 | |||
78 | - Tim Sears reported the zgesdd problem also in intel mac. | ||
79 | |||
80 | - Max Suica simplified the installation on Windows and improved the instructions. | ||
81 | |||
82 | - John Billings first reported an incompatibility with QuickCheck>=2.1.1 | ||
83 | |||
84 | - Alexey Khudyakov cleaned up PRAGMAS and fixed some hlint suggestions. | ||
85 | |||
86 | - Torsten Kemps-Benedix reported an installation problem in OS/X. | ||
87 | |||
88 | - Stefan Kersten fixed hmatrix.cabal for 64-bit ghc-7 in OS/X | ||
89 | |||
90 | - Sacha Sokoloski reported an installation problem on Arch Linux and | ||
91 | helped with the configuration. | ||
92 | |||
93 | - Carter Schonwald helped with the configuration for Homebrew OS X and | ||
94 | found a tolerance problem in test "1E5 rots". He also discovered | ||
95 | a bug in the signature of cmap. | ||
96 | |||
97 | - Duncan Coutts reported a problem with configure.hs and contributed | ||
98 | a solution and a simplified Setup.lhs. | ||
99 | |||
100 | - Mark Wright fixed the import of vector >= 0.8. | ||
101 | |||
102 | - Bas van Dijk fixed the import of vector >= 0.8, got rid of some | ||
103 | deprecation warnings, used more explicit imports, and updated to ghc-7.4. | ||
104 | |||
105 | - Tom Nielsen discovered a problem in Config.hs, exposed by link problems | ||
106 | in Ubuntu 11.10 beta. | ||
107 | |||
108 | - Daniel Fischer reported some Haddock markup errors. | ||
109 | |||
110 | - Danny Chan added support for integration over infinite intervals, and fixed | ||
111 | Configure.hs using platform independent functions. | ||
112 | |||
113 | - Clark Gaebel removed superfluous thread safety. | ||
114 | |||
115 | - Jeffrey Burdges reported a glpk link problem on OS/X | ||
116 | |||
117 | - Jian Zhang reported the Windows installation problem due to new ODE interface. | ||
118 | |||
119 | - Mihaly Barasz and Ben Gamari fixed mapMatrix* and mapMatrixWithIndex | ||
120 | |||
121 | - Takano Akio fixed off-by-one errors in gsl-aux.c producing segfaults. | ||
122 | |||
123 | - Alex Lang implemented uniRoot and uniRootJ for one-dimensional root-finding. | ||
124 | |||
125 | - Mike Ledger contributed alternative FFI helpers for matrix interoperation with C | ||
126 | |||
127 | - Stephen J. Barr suggested flipping argument order in the double integral example | ||
128 | |||
129 | - Greg Horn fixed the bus error on ghci 64-bit. | ||
130 | |||
131 | - Kristof Bastiaensen added bindings for one-dimensional minimization. | ||
132 | |||
133 | - Matthew Peddie added bindings for gsl_integrate_cquad doubly-adaptive quadrature | ||
134 | for difficult integrands. | ||
135 | |||
136 | - Ben Gamari exposed matrixFromVector for Development. | ||
137 | |||
138 | - greg94301 reported tolerance issues in the tests. | ||
139 | |||
140 | - Clemens Lang updated the MacPort installation instructions. | ||
141 | |||
142 | - Henning Thielemann reported the pinv inefficient implementation. | ||
143 | |||
144 | - bdoering reported the problem of zero absolute tolerance in the integration functions. | ||
145 | |||
146 | - Alexei Uimanov replaced fromList by Vector.fromList. | ||
147 | |||
148 | - Adam Vogt updated the code for ghc-7.7 | ||
149 | |||
150 | - Mike Meyer (mwm) added freeBSD library configuration information. | ||
151 | |||
152 | - tfgit updated the OSX installation instructions via Homebrew | ||
153 | |||
154 | - "yokto" and "ttylec" reported the problem with the dot product of complex vectors. | ||
155 | |||
156 | - Samium Gromoff reported a build failure caused by a size_t - int mismatch. | ||
157 | |||
diff --git a/packages/base/hmatrix-base.cabal b/packages/base/hmatrix.cabal index 91dc0db..5f3c48e 100644 --- a/packages/base/hmatrix-base.cabal +++ b/packages/base/hmatrix.cabal | |||
@@ -15,6 +15,8 @@ cabal-version: >=1.8 | |||
15 | 15 | ||
16 | build-type: Simple | 16 | build-type: Simple |
17 | 17 | ||
18 | extra-source-files: THANKS.md INSTALL.md CHANGELOG | ||
19 | |||
18 | extra-source-files: src/C/lapack-aux.h | 20 | extra-source-files: src/C/lapack-aux.h |
19 | 21 | ||
20 | library | 22 | library |