TriMF.h

Go to the documentation of this file.
00001 
00022 #ifndef         TRIMF_H_
00023 # define        TRIMF_H_
00024 
00025 #include "MembershipFn.h"   // for MembershipFn
00026 
00027 namespace IRIS {
00028 
00029   using namespace std;
00030 
00031   namespace Fuzzy {
00032 
00046     class TriMF : public MembershipFn
00047     {
00048 
00049       public:
00050 
00052         static const unsigned NUM_PARMS = 3;
00053 
00054     //  CONSTRUCTORS  /////////////////////////////////////////////////////
00055 
00062         TriMF( double a=0 , double b=0 , double c=0 );
00072         TriMF( const string& name , 
00073                double   a=0 , double   b=0 , double c=0 ,
00074                double min=0 , double max=0                );
00078         TriMF( const MembershipFn::parm_list& parm );
00079 
00080     //  DESTRUCTORS  //////////////////////////////////////////////////////
00081 
00083         ~TriMF( );
00084 
00085     //  SET MEMBER FUNCTIONS (MUTATORS)  //////////////////////////////////
00086 
00092         void set ( double a=0 , double b=0 , double c=0 );
00093 
00094         // implemented virtual functions from IRIS::Fuzzy::Numeric
00095         virtual void discretize( unsigned degree );
00096 
00097     //  GET MEMBER FUNCTIONS (ACCESSORS)  /////////////////////////////////
00098 
00103         void get ( double &a , double &b , double &c );
00104 
00105         // implemented virtual functions from IRIS::Fuzzy::Numeric
00106         virtual double eval( double x ) const;
00107         virtual double operator() ( double val ) const;
00108 
00109         // implemented virtual functions from IRIS::Fuzzy::Set
00110         virtual void draw() const;
00111 
00112     }; // end of TriMF class
00113 
00114   } // end of Fuzzy namespace
00115 
00116 } // end of IRIS namespace
00117 
00118 #endif      /* !TRIMF_H_ */
00119 

Generated on Tue Dec 12 13:41:39 2006 for IRIS Intelligent Systems Tools by  doxygen 1.4.6