ometah-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[oMetah-devel] ometah/problem itsProblem.cpp itsProblem.hpp


From: Johann
Subject: [oMetah-devel] ometah/problem itsProblem.cpp itsProblem.hpp
Date: Sun, 06 Mar 2005 06:55:28 -0500

CVSROOT:        /cvsroot/ometah
Module name:    ometah
Branch:         
Changes by:     Johann <address@hidden> 05/03/06 11:55:28

Modified files:
        problem        : itsProblem.cpp itsProblem.hpp 

Log message:
        * replace "range" by "bounds"

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/ometah/ometah/problem/itsProblem.cpp.diff?tr1=1.3&tr2=1.4&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/ometah/ometah/problem/itsProblem.hpp.diff?tr1=1.5&tr2=1.6&r1=text&r2=text

Patches:
Index: ometah/problem/itsProblem.cpp
diff -u ometah/problem/itsProblem.cpp:1.3 ometah/problem/itsProblem.cpp:1.4
--- ometah/problem/itsProblem.cpp:1.3   Sat Mar  5 22:43:34 2005
+++ ometah/problem/itsProblem.cpp       Sun Mar  6 11:55:28 2005
@@ -1,5 +1,5 @@
 /***************************************************************************
- *  $Id: itsProblem.cpp,v 1.3 2005/03/05 22:43:34 nojhan Exp $
+ *  $Id: itsProblem.cpp,v 1.4 2005/03/06 11:55:28 nojhan Exp $
  *  Copyright 2005 Université Paris 12 Val-de-Marne
  *  Author : Johann Dréo <address@hidden>
  ****************************************************************************/
@@ -34,8 +34,8 @@
   
   setDimension(1);
 
-  setRangeMaximaAll(0);
-  setRangeMinimaAll(0);
+  setBoundsMaximaAll(0);
+  setBoundsMinimaAll(0);
 
   itsPoint optim();
   optim.setSolution(vector<double> sol);
@@ -85,8 +85,8 @@
 {
   this->dimension = dimension;
 
-  // reinitialization of range
-  setRangeMinima(-1);
+  // reinitialization of bounds
+  setBoundsMinima(-1);
 }
 
 
@@ -113,14 +113,14 @@
     this->optima = optima;
 }
 
-vector<vector<double> > itsProblem::getRange()
+vector<vector<double> > itsProblem::getBounds()
 {
-    vector<vector<double> > range;
+    vector<vector<double> > bounds;
     range.reserve(getDimension());
 
     for(unsigned int i=0, i < getDimension(); i++) {
-        double mini = getRangeMinima()[i];
-        double maxi = getRangeMaxima()[i];
+        double mini = getBoundsMinima()[i];
+        double maxi = getBoundsMaxima()[i];
         vector<double> v; 
         v.reserve(2);
         v.push_back(mini);
@@ -131,7 +131,7 @@
     return range;
 }
 
-void itsProblem::setRange(vector<vector<double> > range)
+void itsProblem::setBounds(vector<vector<double> > range)
 {
     vector<double> mins, maxs;
     mins.reserve(getDimension());
@@ -142,16 +142,16 @@
         maxs.push_back(range[i][1]);
     }
     
-    setRangeMinima(mins);
-    setRangeMaxima(maxs);
+    setBoundsMinima(mins);
+    setBoundsMaxima(maxs);
 }
 
-vector<double> itsProblem::getRangeMinima()
+vector<double> itsProblem::getBoundsMinima()
 {
     return this->rangeMinima;
 }
 
-void itsProblem::setRangeMinima(vector<double> minima)
+void itsProblem::setBoundsMinima(vector<double> minima)
 {
     if(minima.size() != getDimension() ) {
         throw "ErrorSize";
@@ -160,12 +160,12 @@
     }
 }
 
-vector<double> itsProblem::getRangeMaxima()
+vector<double> itsProblem::getBoundsMaxima()
 {
     return this->rangeMaxima;
 }
 
-void itsProblem::setRangeMaxima(vector<double> maxima)
+void itsProblem::setBoundsMaxima(vector<double> maxima)
 {
     if(maxima.size() != getDimension() ) {
         throw "ErrorSize";
@@ -174,7 +174,7 @@
     }
 }
   
-void itsProblem::setRangeMinimaAll(double min)
+void itsProblem::setBoundsMinimaAll(double min)
 {
     // empty vector
     vector<double> v;
@@ -186,10 +186,10 @@
     }
 
     // update
-    setRangeMinima(v);
+    setBoundsMinima(v);
 }
 
-void itsProblem::setRangeMaximaAll(double max)
+void itsProblem::setBoundsMaximaAll(double max)
 {
     vector<double> v;
     v.reserve(getDimension());
@@ -197,5 +197,5 @@
     for(unsigned int i=0; i < getDimension(); i++ ) {
         v.push_back(max);
     }
-    setRangeMaxima(v);
+    setBoundsMaxima(v);
 }
Index: ometah/problem/itsProblem.hpp
diff -u ometah/problem/itsProblem.hpp:1.5 ometah/problem/itsProblem.hpp:1.6
--- ometah/problem/itsProblem.hpp:1.5   Sat Mar  5 22:43:34 2005
+++ ometah/problem/itsProblem.hpp       Sun Mar  6 11:55:28 2005
@@ -1,5 +1,5 @@
 /***************************************************************************
- *  $Id: itsProblem.hpp,v 1.5 2005/03/05 22:43:34 nojhan Exp $
+ *  $Id: itsProblem.hpp,v 1.6 2005/03/06 11:55:28 nojhan Exp $
  *  Copyright 2005 Université Paris 12 Val-de-Marne
  *  Author : Johann Dréo <address@hidden>
  ****************************************************************************/
@@ -67,19 +67,19 @@
   */
   vector<itsPoint> optima;
   
-  //! Search space range minima
+  //! Search space bounds minima
   /*!
     This vector is of the form :
       [ min_1, min_2, ... , min_n ]
   */
-  vector<double> rangeMinima;
+  vector<double> boundsMinima;
   
-  //! Search space range maxima
+  //! Search space bounds maxima
   /*!
     This vector is of the form :
       [ max_1, max_2, ... , max_n ]
   */
-  vector<double> rangeMaxima;
+  vector<double> boundsMaxima;
   
   
 public:
@@ -117,7 +117,7 @@
   //! Change the informations about the global optima
   void setOptima(vector<itsPoint> optima);
   
-  //! Return the search space range
+  //! Return the search space bounds
   /*!
     Return a matrix of the form :
       [
@@ -127,25 +127,25 @@
        [ min_n, max_n ],
       ]
   */
-  vector<vector<double> > getRange();
-  //! Change the whole search space range
-  void setRange(vector<vector<double> > range);
-  
-  //! Return the search space range minima
-  vector<double> getRangeMinima();
-  //! Change the search space range minima
-  void setRangeMinima(vector<double> minima);
-  
-  //! Search space range maxima
-  vector<double> getRangeMaxima();
-  //! Search space range maxima
-  void setRangeMaxima(vector<double> maxima);
+  vector<vector<double> > getBounds();
+  //! Change the whole search space bounds
+  void setBounds(vector<vector<double> > bounds);
+  
+  //! Return the search space bounds minima
+  vector<double> getBoundsMinima();
+  //! Change the search space bounds minima
+  void setBoundsMinima(vector<double> minima);
+  
+  //! Search space bounds maxima
+  vector<double> getBoundsMaxima();
+  //! Search space bounds maxima
+  void setBoundsMaxima(vector<double> maxima);
   
-  //! Change all the range minima to the same value
-  void setRangeMinimaAll(double min);
+  //! Change all the bounds minima to the same value
+  void setBoundsMinimaAll(double min);
   
-  //! Change all the range maxima to the same value
-  void setRangeMaximaAll(double max);
+  //! Change all the bounds maxima to the same value
+  void setBoundsMaximaAll(double max);
   
   //@}
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]