changeset 1878:aa2bcaefbc5a

[project @ 1996-02-05 16:21:31 by jwe]
author jwe
date Mon, 05 Feb 1996 16:21:53 +0000
parents 6f70b6929cc1
children 1b43d3c06c04
files liboctave/Bounds.cc liboctave/NLEqn.cc
diffstat 2 files changed, 4 insertions(+), 15 deletions(-) [+]
line wrap: on
line diff
--- a/liboctave/Bounds.cc	Sun Feb 04 14:01:38 1996 +0000
+++ b/liboctave/Bounds.cc	Mon Feb 05 16:21:53 1996 +0000
@@ -51,7 +51,6 @@
       return *this;
     }
 
-  nb = l.capacity ();
   lb = l;
   ub = u;
 
@@ -61,7 +60,7 @@
 Bounds&
 Bounds::set_lower_bounds (const ColumnVector l)
 {
-  if (nb != l.capacity ())
+  if (ub.capacity () != l.capacity ())
     {
       error ("inconsistent size for lower bounds");
       return *this;
@@ -75,7 +74,7 @@
 Bounds&
 Bounds::set_upper_bounds (const ColumnVector u)
 {
-  if (nb != u.capacity ())
+  if (lb.capacity () != u.capacity ())
     {
       error ("inconsistent size for upper bounds");
       return *this;
--- a/liboctave/NLEqn.cc	Sun Feb 04 14:01:38 1996 +0000
+++ b/liboctave/NLEqn.cc	Mon Feb 05 16:21:53 1996 +0000
@@ -59,18 +59,6 @@
   (*current_liboctave_error_handler) ("fatal NLEqn error: %s", msg);
 }
 
-void
-NLEqn::set_states (const ColumnVector& xvec)
-{
-  if (xvec.capacity () != n)
-    {
-      error ("dimension error");
-      return;
-    }
-
-  x = xvec;
-}
-
 // Other operations
 
 int
@@ -146,6 +134,8 @@
 {
   ColumnVector retval;
 
+  int n = x.capacity ();
+
   if (n == 0)
     {
       error ("equation set not initialized");