Generated on Tue Dec 16 13:34:02 2008 for ell-3.0.0 by doxygen 1.5.1

src/ell/spinglass/S_SG_NPP.hh

Go to the documentation of this file.
00001 #ifndef S_SG_NPP_HH_
00002 #define S_SG_NPP_HH_
00003 
00004 #include "ell/spinglass/S_SG_Ising.hh"
00005 #include <vector>
00006 
00007 namespace ell
00008 {
00009     
00012     class S_SG_NPP : public S_SG_Ising
00013     {
00014     public:
00015         typedef std::vector<double> WeightType;
00016         
00018         static const std::string ID;
00019         
00020     protected:
00021         
00023         using S_SG_Ising::spin;
00025         const WeightType* weights;
00028         double symmShift;
00029         
00030     public:
00031 
00039         S_SG_NPP(   const WeightType* weights
00040                     , const bool random = true
00041                     , const double symmShift = 0.0 );
00042 
00049         S_SG_NPP(   const WeightType* weights
00050                     , const std::string& spinStr
00051                     , const double symmShift = 0.0 );
00052 
00053         S_SG_NPP(const S_SG_NPP& s2);
00054         
00056         virtual ~S_SG_NPP();
00057 
00063         virtual const std::string& getID( void ) const;
00064     
00065         virtual bool    operator== (const State& state2) const;
00066         virtual bool    operator!= (const State& state2) const;
00067 
00068         virtual void    operator= (const S_SG_NPP& sg2);
00069 
00074         virtual double      getEnergy() const;
00075 
00083         virtual S_SG_NPP* clone(State* toFill = NULL) const;
00084         
00087         virtual State* fromString(const std::string& stringRep) const;          
00088 
00092         virtual State* getRandomNeighbor(State* inPlaceNeigh = NULL) const;
00093 
00100         virtual State* getNeighbor(const size_t index, State* neigh) const;
00101         
00111         virtual State* applyNeighborChange(const size_t index, State* const neigh) const;
00112 
00121         virtual State* uncompress(const CSequence& cseq, State* toFill) const;
00122         
00123         
00126         virtual const double getSymmShift(void) const;
00127         
00130         virtual const WeightType* const getWeights(void) const;
00131         
00132     };
00133 
00134 
00135 } // namespace ell
00136 
00137 #endif /*S_SG_NPP_HH_*/