]> gitweb.michael.orlitzky.com - octave.d.git/commitdiff
**/*.m: load the statistics package for unifrnd
authorMichael Orlitzky <michael@orlitzky.com>
Mon, 9 Mar 2026 12:59:13 +0000 (08:59 -0400)
committerMichael Orlitzky <michael@orlitzky.com>
Mon, 9 Mar 2026 12:59:13 +0000 (08:59 -0400)
The unifrnd() function was moved to the statistics package in
Octave 4.4:

  https://octave.org/NEWS-4.4.html

We add "pkg load statistics;" where necessary, and now implicitly
depend on the statistics package.

random_positive_definite_matrix.m
tests/conjugate_gradient_method_tests.m
tests/preconditioned_conjugate_gradient_method_tests.m
tests/steepest_descent_tests.m

index 9b3f0f06b8625bcd8ffe3d8f8d807b0bd7427481..164cb33853791b7af132563274b032db41b3ba9b 100644 (file)
@@ -19,6 +19,10 @@ function A = random_positive_definite_matrix(integerN, max_entry = realmax)
   %
   %   - ``A`` -- A symmetric, positive definite matrix.
   %
+
+  % provides unifrnd()
+  pkg load statistics;
+
   U = random_orthogonal_matrix(integerN);
   d = unifrnd(eps, max_entry, 1, integerN);
   D = diag(d);
index 3f068ae9f6c93cc678b6db038650d9772deda6b8..bdc34bad9939d341fe25cfc7e90893b6265713c3 100644 (file)
@@ -1,3 +1,6 @@
+## provides unifrnd()
+pkg load statistics;
+
 ## Used throughout. The CGM uses the infinity norm as the stopping
 ## condition, so we had better also.
 max_iterations = 10000;
index a27d3e206b4de1ebe4e48f77fe9cae6d55e6c27b..d30be5e57a0981d37f6900f78d71c9833766eb27 100644 (file)
@@ -1,3 +1,6 @@
+## provides unifrnd()
+pkg load statistics;
+
 ## Used throughout. The PCGM uses the infinity norm as the stopping
 ## condition, so we had better also.
 max_iterations = 10000;
index d6de1ccaf4b013539d45833a70c3e293bb0ad6b6..5ded0e06d6c0474e18f5e093e7c4c99f871395b6 100644 (file)
@@ -1,3 +1,6 @@
+## provides unifrnd()
+pkg load statistics;
+
 ## We can use the steepest descent method to solve Qx=b as in the
 ## conjugate gradient method. Like we did there, we test that the
 ## steepest descent method agrees with Octave's PCGM and our CGM.