numerical-analysis.git
2 years agosrc/Integration/Simpson.hs: fix monomorphism restriction warnings. master
Michael Orlitzky [Fri, 7 Dec 2018 16:04:36 +0000 (11:04 -0500)]
src/Integration/Simpson.hs: fix monomorphism restriction warnings.

2 years agosrc/Integration/Gaussian.hs: fix monomorphism restriction warnings.
Michael Orlitzky [Fri, 7 Dec 2018 15:52:09 +0000 (10:52 -0500)]
src/Integration/Gaussian.hs: fix monomorphism restriction warnings.

2 years agosrc/Integration/Trapezoid.hs: fix monomorphism restriction warning.
Michael Orlitzky [Fri, 7 Dec 2018 15:47:20 +0000 (10:47 -0500)]
src/Integration/Trapezoid.hs: fix monomorphism restriction warning.

2 years agosrc/ODE/IVP.hs: fix monomorphism restriction warning.
Michael Orlitzky [Fri, 7 Dec 2018 15:45:06 +0000 (10:45 -0500)]
src/ODE/IVP.hs: fix monomorphism restriction warning.

2 years agosrc/Linear/QR.hs: fix monomorphism restriction warning.
Michael Orlitzky [Fri, 7 Dec 2018 15:43:58 +0000 (10:43 -0500)]
src/Linear/QR.hs: fix monomorphism restriction warning.

2 years agosrc/FEM/R1.hs: fix monomorphism restriction warnings.
Michael Orlitzky [Fri, 7 Dec 2018 15:41:20 +0000 (10:41 -0500)]
src/FEM/R1.hs: fix monomorphism restriction warnings.

2 years agosrc/Roots/Fast.hs: fix monomorphism restriction warnings.
Michael Orlitzky [Fri, 7 Dec 2018 15:33:43 +0000 (10:33 -0500)]
src/Roots/Fast.hs: fix monomorphism restriction warnings.

2 years agosrc/Roots/Simple.hs: fix monomorphism restriction warning.
Michael Orlitzky [Fri, 7 Dec 2018 15:27:14 +0000 (10:27 -0500)]
src/Roots/Simple.hs: fix monomorphism restriction warning.

2 years agosrc/Polynomials/Orthogonal.hs: fix monomorphism restriction warnings.
Michael Orlitzky [Fri, 7 Dec 2018 15:22:48 +0000 (10:22 -0500)]
src/Polynomials/Orthogonal.hs: fix monomorphism restriction warnings.

2 years agosrc/Misc.hs: fix monomorphism restriction warnings.
Michael Orlitzky [Fri, 7 Dec 2018 15:19:41 +0000 (10:19 -0500)]
src/Misc.hs: fix monomorphism restriction warnings.

2 years agosrc/Linear/Matrix.hs: define "one" in the ring of matrices.
Michael Orlitzky [Fri, 7 Dec 2018 15:08:54 +0000 (10:08 -0500)]
src/Linear/Matrix.hs: define "one" in the ring of matrices.

2 years agosrc/Linear/Matrix.hs: add support for zero-length columns/matrices.
Michael Orlitzky [Fri, 7 Dec 2018 15:07:13 +0000 (10:07 -0500)]
src/Linear/Matrix.hs: add support for zero-length columns/matrices.

2 years agosrc/Normed.hs: combine zero- and nonzero-length implementations.
Michael Orlitzky [Fri, 7 Dec 2018 14:54:28 +0000 (09:54 -0500)]
src/Normed.hs: combine zero- and nonzero-length implementations.

2 years agosrc/Linear/Vector.hs: add a Vec0 type.
Michael Orlitzky [Fri, 7 Dec 2018 14:54:07 +0000 (09:54 -0500)]
src/Linear/Vector.hs: add a Vec0 type.

2 years agosrc: import only instances from Prelude, where appropriate.
Michael Orlitzky [Fri, 7 Dec 2018 14:41:05 +0000 (09:41 -0500)]
src: import only instances from Prelude, where appropriate.

2 years agonumerical-analysis.cabal: add BigFloat to exposed-modules.
Michael Orlitzky [Fri, 7 Dec 2018 14:37:41 +0000 (09:37 -0500)]
numerical-analysis.cabal: add BigFloat to exposed-modules.

2 years agonumerical-analysis.cabal: update fixed-vector and doctest dependencies.
Michael Orlitzky [Fri, 7 Dec 2018 14:32:22 +0000 (09:32 -0500)]
numerical-analysis.cabal: update fixed-vector and doctest dependencies.

7 years agoFix a bug in the relative error.
Michael Orlitzky [Tue, 15 Apr 2014 14:50:14 +0000 (10:50 -0400)]
Fix a bug in the relative error.

7 years agoRemove some commented code from FEM.R1.
Michael Orlitzky [Mon, 14 Apr 2014 03:20:11 +0000 (23:20 -0400)]
Remove some commented code from FEM.R1.

7 years agoAdd relative error functions to FEM.R1.
Michael Orlitzky [Mon, 14 Apr 2014 03:17:35 +0000 (23:17 -0400)]
Add relative error functions to FEM.R1.

7 years agoAdd natural numbers up to N64.
Michael Orlitzky [Mon, 14 Apr 2014 03:17:05 +0000 (23:17 -0400)]
Add natural numbers up to N64.

7 years agoSpeed up the Cholesky factorization with a fold.
Michael Orlitzky [Sun, 13 Apr 2014 19:55:49 +0000 (15:55 -0400)]
Speed up the Cholesky factorization with a fold.

7 years agoAdd column synonyms up to Col32.
Michael Orlitzky [Sun, 13 Apr 2014 18:12:59 +0000 (14:12 -0400)]
Add column synonyms up to Col32.

7 years agoAdd natural numbers up to N32.
Michael Orlitzky [Sun, 13 Apr 2014 18:09:17 +0000 (14:09 -0400)]
Add natural numbers up to N32.

7 years agoFix bugs in big_K, big_M.
Michael Orlitzky [Sun, 13 Apr 2014 08:12:52 +0000 (04:12 -0400)]
Fix bugs in big_K, big_M.

7 years agoAdd Mat6 and Mat7 synonyms.
Michael Orlitzky [Mon, 7 Apr 2014 16:57:37 +0000 (12:57 -0400)]
Add Mat6 and Mat7 synonyms.
Move the example FEM into its own FEM.R1.Exampl1 module.
Use the new example FEM module in the FEM.R1 doctests.

7 years agoRemove solution', because what did it do?
Michael Orlitzky [Mon, 7 Apr 2014 16:16:40 +0000 (12:16 -0400)]
Remove solution', because what did it do?

7 years agoFix a few warnings.
Michael Orlitzky [Mon, 7 Apr 2014 16:09:23 +0000 (12:09 -0400)]
Fix a few warnings.

7 years agoCommit whatever I was working on last and have forgotten about.
Michael Orlitzky [Mon, 7 Apr 2014 15:47:14 +0000 (11:47 -0400)]
Commit whatever I was working on last and have forgotten about.

7 years agoAdd a FEM.R1 example (should be moved into the tree after being cleaned up).
Michael Orlitzky [Wed, 19 Feb 2014 20:36:28 +0000 (15:36 -0500)]
Add a FEM.R1 example (should be moved into the tree after being cleaned up).

7 years agoFinish the FEM.R1 solution for Dirichlet boundary conditions.
Michael Orlitzky [Wed, 19 Feb 2014 20:35:41 +0000 (15:35 -0500)]
Finish the FEM.R1 solution for Dirichlet boundary conditions.

7 years agoRequire a matrix to be nonempty if we're going to QR factorize it.
Michael Orlitzky [Wed, 19 Feb 2014 01:26:13 +0000 (20:26 -0500)]
Require a matrix to be nonempty if we're going to QR factorize it.

7 years agoGeneralize the signature of zipwith2.
Michael Orlitzky [Wed, 19 Feb 2014 01:25:05 +0000 (20:25 -0500)]
Generalize the signature of zipwith2.
Implement the dot product using zipwith2.
Implement matrix multiplication using the dot product.
Implement the frobenius_norm with zipwith2.

7 years agoUse the element_sum2 function to sum the terms in Gaussian integration instead of...
Michael Orlitzky [Wed, 19 Feb 2014 01:22:12 +0000 (20:22 -0500)]
Use the element_sum2 function to sum the terms in Gaussian integration instead of the incorrect 1-norm.

7 years agoFix the type of zip2 to be more general.
Michael Orlitzky [Wed, 19 Feb 2014 00:53:35 +0000 (19:53 -0500)]
Fix the type of zip2 to be more general.

7 years agoUse the Col type synonym in the column Normed instance.
Michael Orlitzky [Wed, 19 Feb 2014 00:52:44 +0000 (19:52 -0500)]
Use the Col type synonym in the column Normed instance.

7 years agoFix the column matrix 1-norm (it was missing the absolute value).
Michael Orlitzky [Wed, 19 Feb 2014 00:51:18 +0000 (19:51 -0500)]
Fix the column matrix 1-norm (it was missing the absolute value).

7 years agoAdd the list_plot' function to Piecewise.
Michael Orlitzky [Wed, 19 Feb 2014 00:50:32 +0000 (19:50 -0500)]
Add the list_plot' function to Piecewise.

7 years agoAdd 'coefficients' to FEM.R1 which solves the desired system.
Michael Orlitzky [Sun, 16 Feb 2014 02:27:34 +0000 (21:27 -0500)]
Add 'coefficients' to FEM.R1 which solves the desired system.

7 years agoAdd a preliminary Piecewise module.
Michael Orlitzky [Sun, 16 Feb 2014 02:27:14 +0000 (21:27 -0500)]
Add a preliminary Piecewise module.

7 years agoDefine Col6...Col9 types in Linear.Matrix.
Michael Orlitzky [Sun, 16 Feb 2014 02:26:46 +0000 (21:26 -0500)]
Define Col6...Col9 types in Linear.Matrix.

7 years agoExport everything from Z to N20 from Naturals.
Michael Orlitzky [Sun, 16 Feb 2014 02:26:19 +0000 (21:26 -0500)]
Export everything from Z to N20 from Naturals.

7 years agoFix the incorrect definition of "minor".
Michael Orlitzky [Wed, 12 Feb 2014 06:52:35 +0000 (01:52 -0500)]
Fix the incorrect definition of "minor".
Add a "preminor" function that does what "minor" used to.
Implement cofactors and a matrix inverse in terms of them.

7 years agoAdd big_K code to FEM.R1.
Michael Orlitzky [Wed, 12 Feb 2014 05:00:27 +0000 (00:00 -0500)]
Add big_K code to FEM.R1.

7 years agoUse a better implementation of backwards_substitute.
Michael Orlitzky [Wed, 12 Feb 2014 01:14:47 +0000 (20:14 -0500)]
Use a better implementation of backwards_substitute.

7 years agoAdd Linear.Matrix.ifoldr2.
Michael Orlitzky [Wed, 12 Feb 2014 00:21:53 +0000 (19:21 -0500)]
Add Linear.Matrix.ifoldr2.

7 years agoImplement forward substitute in terms of a fold.
Michael Orlitzky [Tue, 11 Feb 2014 21:10:53 +0000 (16:10 -0500)]
Implement forward substitute in terms of a fold.

7 years agoAdd Linear.Matrix.set_idx.
Michael Orlitzky [Tue, 11 Feb 2014 21:10:18 +0000 (16:10 -0500)]
Add Linear.Matrix.set_idx.
Loosen constraints on the dot product function.

7 years agoUpdate Integration.Gaussian to use zip2.
Michael Orlitzky [Tue, 11 Feb 2014 20:25:49 +0000 (15:25 -0500)]
Update Integration.Gaussian to use zip2.

7 years agoGeneralize colzip and colzipwith to any matrices.
Michael Orlitzky [Tue, 11 Feb 2014 20:22:35 +0000 (15:22 -0500)]
Generalize colzip and colzipwith to any matrices.
Add zip2three to zip three matrices together.

7 years agoFix backward_substitute.
Michael Orlitzky [Tue, 11 Feb 2014 20:07:53 +0000 (15:07 -0500)]
Fix backward_substitute.
Add 'solve_positive_definite' to Linear.System.
Add tests for everything in Linear.System.

7 years agoAdd reverse2 to Linear.Matrix.
Michael Orlitzky [Tue, 11 Feb 2014 20:07:35 +0000 (15:07 -0500)]
Add reverse2 to Linear.Matrix.

7 years agoAdd Eq constraints throughout Linear.Iteration.
Michael Orlitzky [Tue, 11 Feb 2014 18:16:26 +0000 (13:16 -0500)]
Add Eq constraints throughout Linear.Iteration.

7 years agoAdd another test for 'cholesky'.
Michael Orlitzky [Tue, 11 Feb 2014 18:15:15 +0000 (13:15 -0500)]
Add another test for 'cholesky'.
Improve implementation of upper/lower triangular tests.
Drop some typeclass constraints on upper/lower triangular tests.

7 years agoAdd the imap2 function to Linear.Matrix.
Michael Orlitzky [Sat, 8 Feb 2014 00:33:45 +0000 (19:33 -0500)]
Add the imap2 function to Linear.Matrix.

7 years agoMake safe indexing slower but not dependent on the number of rows/columns.
Michael Orlitzky [Sat, 8 Feb 2014 00:24:14 +0000 (19:24 -0500)]
Make safe indexing slower but not dependent on the number of rows/columns.

7 years agoRemove the "row" function which returned a vector instead of a matrix.
Michael Orlitzky [Sat, 8 Feb 2014 00:10:02 +0000 (19:10 -0500)]
Remove the "row" function which returned a vector instead of a matrix.

7 years agoDrop the 'column' function that returned a vector instead of a matrix.
Michael Orlitzky [Fri, 7 Feb 2014 23:56:21 +0000 (18:56 -0500)]
Drop the 'column' function that returned a vector instead of a matrix.

7 years agoRename matmap to map2.
Michael Orlitzky [Fri, 7 Feb 2014 23:46:51 +0000 (18:46 -0500)]
Rename matmap to map2.

7 years agoMore progress on the 1d FEM, the "big F" vector is now computed correctly.
Michael Orlitzky [Fri, 7 Feb 2014 15:20:26 +0000 (10:20 -0500)]
More progress on the 1d FEM, the "big F" vector is now computed correctly.

7 years agoAdd the 'ifoldl2' function to Linear.Matrix.
Michael Orlitzky [Fri, 7 Feb 2014 15:19:53 +0000 (10:19 -0500)]
Add the 'ifoldl2' function to Linear.Matrix.

7 years agoFix a typo.
Michael Orlitzky [Fri, 7 Feb 2014 15:15:39 +0000 (10:15 -0500)]
Fix a typo.

7 years agoAdd a bunch more natural numbers in the Naturals module.
Michael Orlitzky [Fri, 7 Feb 2014 15:15:11 +0000 (10:15 -0500)]
Add a bunch more natural numbers in the Naturals module.

7 years agoAdd the (in progress) FEM.R1 module.
Michael Orlitzky [Thu, 6 Feb 2014 06:36:45 +0000 (01:36 -0500)]
Add the (in progress) FEM.R1 module.

7 years agoFix some docs in Roots.Simple.
Michael Orlitzky [Thu, 6 Feb 2014 06:36:28 +0000 (01:36 -0500)]
Fix some docs in Roots.Simple.

7 years agoImplement Gaussian quadrature and test it.
Michael Orlitzky [Wed, 5 Feb 2014 20:30:47 +0000 (15:30 -0500)]
Implement Gaussian quadrature and test it.

7 years agoRename zipcol to colzip.
Michael Orlitzky [Wed, 5 Feb 2014 20:30:26 +0000 (15:30 -0500)]
Rename zipcol to colzip.
Add a new function, colzipwith.

7 years agoAdd the Integration.Gaussian.nodes_and_weights function.
Michael Orlitzky [Wed, 5 Feb 2014 01:33:31 +0000 (20:33 -0500)]
Add the Integration.Gaussian.nodes_and_weights function.

7 years agoAdd zipcol and matmap functions in Linear.Matrix.
Michael Orlitzky [Wed, 5 Feb 2014 01:33:09 +0000 (20:33 -0500)]
Add zipcol and matmap functions in Linear.Matrix.

7 years agoAdd the Integration.Gaussian module where we begin to implement Gaussian quadrature.
Michael Orlitzky [Tue, 4 Feb 2014 22:41:19 +0000 (17:41 -0500)]
Add the Integration.Gaussian module where we begin to implement Gaussian quadrature.

7 years agoAdd comments to Linear.QR about non-convergence.
Michael Orlitzky [Tue, 4 Feb 2014 22:40:59 +0000 (17:40 -0500)]
Add comments to Linear.QR about non-convergence.

7 years agoFinish the eigenvectors_symmetric tests.
Michael Orlitzky [Tue, 4 Feb 2014 20:03:56 +0000 (15:03 -0500)]
Finish the eigenvectors_symmetric tests.

7 years agoAdd the eigenvectors_symmetric function and begin writing tests for it.
Michael Orlitzky [Tue, 4 Feb 2014 17:16:52 +0000 (12:16 -0500)]
Add the eigenvectors_symmetric function and begin writing tests for it.

7 years agoImplement the QR algorithm for computing eigenvalues.
Michael Orlitzky [Tue, 4 Feb 2014 07:19:04 +0000 (02:19 -0500)]
Implement the QR algorithm for computing eigenvalues.

7 years agoAdd type synonyms for column/row matrices.
Michael Orlitzky [Tue, 4 Feb 2014 07:18:09 +0000 (02:18 -0500)]
Add type synonyms for column/row matrices.
Add row' and column' functions that do what you'd expect only they return Mats instead of Vecs like their un-prime counterparts.

7 years agoSmall cleanups in Linear.Vector.
Michael Orlitzky [Mon, 3 Feb 2014 06:03:14 +0000 (01:03 -0500)]
Small cleanups in Linear.Vector.
Add 'diagonal' and 'trace' functions to Linear.Matrix.

7 years agoClean up imports everywhere.
Michael Orlitzky [Mon, 3 Feb 2014 02:10:01 +0000 (21:10 -0500)]
Clean up imports everywhere.

7 years agoAdd tolerant versions of is_{upper,lower}_triangular.
Michael Orlitzky [Mon, 3 Feb 2014 01:21:33 +0000 (20:21 -0500)]
Add tolerant versions of is_{upper,lower}_triangular.
Fix the QR factorization code.
Add tests for the QR behavior.

7 years agoAdd a Normed instance for (Vec n a).
Michael Orlitzky [Sun, 2 Feb 2014 23:46:48 +0000 (18:46 -0500)]
Add a Normed instance for (Vec n a).

7 years agoSwitch Linear.Vector to the numeric prelude and add the element_sum function to it.
Michael Orlitzky [Sun, 2 Feb 2014 23:46:05 +0000 (18:46 -0500)]
Switch Linear.Vector to the numeric prelude and add the element_sum function to it.
Use Linear.Vector.element_sum in Linear.Matrix.

7 years agoRemove old comment from Normed.
Michael Orlitzky [Sun, 2 Feb 2014 20:41:58 +0000 (15:41 -0500)]
Remove old comment from Normed.

7 years agoAdd the Frobenius norm to Linear.Matrix.
Michael Orlitzky [Sun, 2 Feb 2014 17:34:42 +0000 (12:34 -0500)]
Add the Frobenius norm to Linear.Matrix.

7 years agoAdd the Linear.QR module and update the ghci/cabal files.
Michael Orlitzky [Sun, 2 Feb 2014 17:12:09 +0000 (12:12 -0500)]
Add the Linear.QR module and update the ghci/cabal files.

7 years agoNew function: Linear.Matrix.identity_matrix.
Michael Orlitzky [Sun, 2 Feb 2014 16:33:03 +0000 (11:33 -0500)]
New function: Linear.Matrix.identity_matrix.

7 years agoFix implementation of Linear.Matrix.construct.
Michael Orlitzky [Sun, 2 Feb 2014 04:16:01 +0000 (23:16 -0500)]
Fix implementation of Linear.Matrix.construct.

7 years agoAdd the Polynomials.Orthogonal module.
Michael Orlitzky [Thu, 30 Jan 2014 21:02:38 +0000 (16:02 -0500)]
Add the Polynomials.Orthogonal module.

7 years agoBump dependencies.
Michael Orlitzky [Thu, 30 Jan 2014 14:19:17 +0000 (09:19 -0500)]
Bump dependencies.

8 years agoAdd the rayleigh_quotient function.
Michael Orlitzky [Thu, 15 Aug 2013 17:11:43 +0000 (13:11 -0400)]
Add the rayleigh_quotient function.

8 years agoAdd Gauss-Seidel and SOR iterative methods.
Michael Orlitzky [Sun, 21 Jul 2013 21:21:12 +0000 (17:21 -0400)]
Add Gauss-Seidel and SOR iterative methods.

8 years agoRename 'diagonal' to 'diagonal_part'.
Michael Orlitzky [Sun, 21 Jul 2013 21:19:35 +0000 (17:19 -0400)]
Rename 'diagonal' to 'diagonal_part'.
Add functions to pull out the (strict) lower/upper triangular parts of a matrix.

8 years agoFix a bunch of hlint warnings.
Michael Orlitzky [Sun, 21 Jul 2013 18:25:30 +0000 (14:25 -0400)]
Fix a bunch of hlint warnings.

8 years agoUpdate ghci/cabal files to load the new module.
Michael Orlitzky [Sun, 21 Jul 2013 14:48:47 +0000 (10:48 -0400)]
Update ghci/cabal files to load the new module.

8 years agoAdd the Linear.Iteration module.
Michael Orlitzky [Sun, 21 Jul 2013 14:48:23 +0000 (10:48 -0400)]
Add the Linear.Iteration module.

8 years agoAdd another example for forward_substitute.
Michael Orlitzky [Sun, 21 Jul 2013 14:14:19 +0000 (10:14 -0400)]
Add another example for forward_substitute.

8 years agoAdd 'diagonal' function.
Michael Orlitzky [Sun, 21 Jul 2013 14:13:50 +0000 (10:13 -0400)]
Add 'diagonal' function.

8 years agoConstrain Normed instance to column vectors (m-by-1 matrices).
Michael Orlitzky [Sun, 21 Jul 2013 14:13:24 +0000 (10:13 -0400)]
Constrain Normed instance to column vectors (m-by-1 matrices).

8 years agoAdd the unit_roundoff function.
Michael Orlitzky [Mon, 1 Jul 2013 20:00:59 +0000 (16:00 -0400)]
Add the unit_roundoff function.

8 years agoUpdate numeric-prelude and fixed-vector.
Michael Orlitzky [Sat, 8 Jun 2013 21:19:36 +0000 (17:19 -0400)]
Update numeric-prelude and fixed-vector.
Use the (!) function from the new fixed-vector.
Add the Fast/Simple trisection method and a test.

8 years agoGet determinants working.
Michael Orlitzky [Sun, 24 Feb 2013 14:55:10 +0000 (09:55 -0500)]
Get determinants working.

8 years agoReplace the whole Matrix implementation with something a little better.
Michael Orlitzky [Sun, 24 Feb 2013 07:41:03 +0000 (02:41 -0500)]
Replace the whole Matrix implementation with something a little better.
Add the Linear.System module.
Get all doctests working again.
Update .ghci/cabal files.