COIN-OR::LEMON - Graph Library

Changeset 2242:16523135943d in lemon-0.x for lemon/simann.h


Ignore:
Timestamp:
10/14/06 17:26:05 (18 years ago)
Author:
Balazs Dezso
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2991
Message:

New random interface
Switching to the new interface

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lemon/simann.h

    r2229 r2242  
    258258    bool accept() {
    259259      double cost_diff = simann->getCurrCost() - simann->getPrevCost();
    260       return (rnd.getReal() <= exp(-(cost_diff / temp)));
     260      return (rnd() <= exp(-(cost_diff / temp)));
    261261    }
    262262    /// \brief Destructor.
     
    366366      else {
    367367        double cost_diff = simann->getCurrCost() - simann->getPrevCost();
    368         return (rnd.getReal() <= exp(-(cost_diff / temp)));
     368        return (rnd() <= exp(-(cost_diff / temp)));
    369369      }
    370370    }
Note: See TracChangeset for help on using the changeset viewer.