TakagiSugenoTerm.h 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. /* Copyright 2010 Juan Rada-Vilela
  2. Licensed under the Apache License, Version 2.0 (the "License");
  3. you may not use this file except in compliance with the License.
  4. You may obtain a copy of the License at
  5. http://www.apache.org/licenses/LICENSE-2.0
  6. Unless required by applicable law or agreed to in writing, software
  7. distributed under the License is distributed on an "AS IS" BASIS,
  8. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  9. See the License for the specific language governing permissions and
  10. limitations under the License.
  11. */
  12. /*
  13. * File: TakagiSugenoTerm.h
  14. * Author: jcrada
  15. *
  16. * Created on March 10, 2010, 7:28 PM
  17. */
  18. #ifndef FL_TAKAGISUGENOTERM_H
  19. #define FL_TAKAGISUGENOTERM_H
  20. #include "SingletonTerm.h"
  21. namespace fl{
  22. class TakagiSugenoTerm : public SingletonTerm{
  23. private:
  24. flScalar _weight;
  25. public:
  26. TakagiSugenoTerm();
  27. TakagiSugenoTerm(const std::string& name, flScalar value = NAN, flScalar weight = 1.0);
  28. TakagiSugenoTerm(const FuzzyOperator& fuzzy_op, const std::string& name,
  29. flScalar value = NAN, flScalar weight = 1.0);
  30. virtual ~TakagiSugenoTerm();
  31. virtual void setWeight(flScalar weight);
  32. virtual flScalar weight() const;
  33. virtual TakagiSugenoTerm* clone() const;
  34. virtual eMembershipFunction type() const;
  35. virtual std::string toString() const;
  36. };
  37. }
  38. #endif /* FL_TAKAGISUGENOTERM_H */