fuzzydl

## Class TriangularFuzzyNumber

- java.lang.Object
- - fuzzydl.Concept
  - - fuzzydl.FuzzyConcreteConcept
    - - fuzzydl.TriangularConcreteConcept
      - - fuzzydl.TriangularFuzzyNumber

-     public class TriangularFuzzyNumber
      extends TriangularConcreteConcept

  Fuzzy number defined with a triangular function.
  Author:
    Fernando Bobillo

- - ### Field Summary

    - ### Fields inherited from class fuzzydl.Concept

      `ALL, AND, AT_LEAST_VALUE, AT_MOST_VALUE, ATOMIC, BOTTOM, CHOQUET_INTEGRAL, COMPLEMENT, CONCEPT_BOTTOM, CONCEPT_TOP, CONCRETE, CONCRETE_COMPLEMENT, DEFAULT_NAME, EXACT_VALUE, EXT_NEG_THRESHOLD, EXT_POS_THRESHOLD, FUZZY_NUMBER, FUZZY_NUMBER_COMPLEMENT, G_AND, G_IMPLIES, G_OR, HAS_VALUE, L_AND, L_OR, LOOSE_LOWER_APPROX, LOOSE_UPPER_APPROX, LOWER_APPROX, MODIFIED, MODIFIED_COMPLEMENT, NEG_THRESHOLD, NOT_AT_LEAST_VALUE, NOT_AT_MOST_VALUE, NOT_CHOQUET_INTEGRAL, NOT_EXACT_VALUE, NOT_EXT_NEG_THRESHOLD, NOT_EXT_POS_THRESHOLD, NOT_G_IMPLIES, NOT_HAS_VALUE, NOT_NEG_THRESHOLD, NOT_OWA, NOT_POS_THRESHOLD, NOT_QUANTIFIED_OWA, NOT_QUASI_SUGENO_INTEGRAL, NOT_SELF, NOT_SUGENO_INTEGRAL, NOT_W_MAX, NOT_W_MIN, NOT_W_SUM, NOT_W_SUM_ZERO, NOT_WEIGHTED, NOT_Z_IMPLIES, OR, OWA, POS_THRESHOLD, QUANTIFIED_OWA, QUASI_SUGENO_INTEGRAL, SELF, SOME, SUGENO_INTEGRAL, TIGHT_LOWER_APPROX, TIGHT_UPPER_APPROX, TOP, UPPER_APPROX, W_MAX, W_MIN, W_SUM, W_SUM_ZERO, WEIGHTED, Z_IMPLIES`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `TriangularFuzzyNumber(double a, double b, double c)`
    `TriangularFuzzyNumber(java.lang.String name, double a, double b, double c)`
    `TriangularFuzzyNumber(java.lang.String name, int type, double a, double b, double c)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static TriangularFuzzyNumber` | `add(TriangularFuzzyNumber t1, TriangularFuzzyNumber t2)` Adds two triangular fuzzy numbers.
    `Concept` | `complement()` Gets the complement of the concept.
    `static TriangularFuzzyNumber` | `dividedBy(TriangularFuzzyNumber t1, TriangularFuzzyNumber t2)` Divides two triangular fuzzy numbers.
    `boolean` | `equals(TriangularFuzzyNumber t)` Indicates whether some other fuzzy number is "equal to" this one.
    `double` | `getBestNonFuzzyPerformance()` Gets the Best Non fuzzy Performance (BNP) of the fuzzy number.
    `static boolean` | `hasDefinedRange()` Checks if the range of the fuzzy numbers has been defined.
    `static TriangularFuzzyNumber` | `minus(TriangularFuzzyNumber t1, TriangularFuzzyNumber t2)` Subtracts two triangular fuzzy numbers.
    `static void` | `setRange(double minRange, double maxRange)` Sets the range of the fuzzy numbers.
    `static TriangularFuzzyNumber` | `times(TriangularFuzzyNumber t1, TriangularFuzzyNumber t2)` Multiplies two triangular fuzzy numbers.
    `java.lang.String` | `toString()` Gets a printable name of the concept.

    - ### Methods inherited from class fuzzydl.TriangularConcreteConcept

      `getA, getB, getC, getMembershipDegree, getName, solveAssertion`

    - ### Methods inherited from class fuzzydl.FuzzyConcreteConcept

      `computeName, setK1, setK2, solveComplementAssertion`

    - ### Methods inherited from class fuzzydl.Concept

      `all, and, and, atLeastValue, atMostValue, complement, containsNegatedSubconcept, containsSubconcept, equals, exactValue, extendedNegThreshold, extendedPosThreshold, gAnd, gAnd, getAtomicConceptNames, getAtomicConcepts, getRole, getType, getValue, getWeight, getWeightVar, gImplies, gOr, gOr, hasNominals, hasValue, hasValue, isAtomic, isComplementedAtomic, isConcrete, kdImplies, lAnd, lAnd, lImplies, looseLowerApprox, looseUpperApprox, lOr, lOr, lowerApprox, nAry, negThreshold, newAtomicConcept, notHasValue, or, or, posThreshold, removeElement, replace, self, setName, setType, setValue, some, tightLowerApprox, tightUpperApprox, upperApprox, weightedConcept, zImplies`

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### TriangularFuzzyNumber

          public TriangularFuzzyNumber(java.lang.String name,
                                       int type,
                                       double a,
                                       double b,
                                       double c)
                                throws FuzzyOntologyException

      Throws:
        `FuzzyOntologyException`

    - #### TriangularFuzzyNumber

          public TriangularFuzzyNumber(java.lang.String name,
                                       double a,
                                       double b,
                                       double c)
                                throws FuzzyOntologyException

      Throws:
        `FuzzyOntologyException`

    - #### TriangularFuzzyNumber

          public TriangularFuzzyNumber(double a,
                                       double b,
                                       double c)
                                throws FuzzyOntologyException

      Throws:
        `FuzzyOntologyException`

  - ### Method Detail

    - #### add

          public static TriangularFuzzyNumber add(TriangularFuzzyNumber t1,
                                                  TriangularFuzzyNumber t2)
                                           throws FuzzyOntologyException

      Adds two triangular fuzzy numbers.
      Parameters:
        `t1` - A triangular fuzzy numbers.
        `t2` - Another triangular fuzzy numbers.
      Returns:
        Sum of the fuzzy numbers.
      Throws:
        `FuzzyOntologyException` - fuzzy ontology exception.

    - #### minus

          public static TriangularFuzzyNumber minus(TriangularFuzzyNumber t1,
                                                    TriangularFuzzyNumber t2)
                                             throws FuzzyOntologyException

      Subtracts two triangular fuzzy numbers.
      Parameters:
        `t1` - Subject of the subtraction.
        `t2` - Object of the subtraction.
      Returns:
        Subtraction of the fuzzy numbers.
      Throws:
        `FuzzyOntologyException` - fuzzy ontology exception.

    - #### times

          public static TriangularFuzzyNumber times(TriangularFuzzyNumber t1,
                                                    TriangularFuzzyNumber t2)
                                             throws FuzzyOntologyException

      Multiplies two triangular fuzzy numbers.
      Parameters:
        `t1` - A triangular fuzzy numbers.
        `t2` - Another triangular fuzzy numbers.
      Returns:
        Product of the fuzzy numbers.
      Throws:
        `FuzzyOntologyException` - fuzzy ontology exception.

    - #### dividedBy

          public static TriangularFuzzyNumber dividedBy(TriangularFuzzyNumber t1,
                                                        TriangularFuzzyNumber t2)
                                                 throws FuzzyOntologyException

      Divides two triangular fuzzy numbers.
      Parameters:
        `t1` - Subject of the division.
        `t2` - Object of the division.
      Returns:
        Division of the fuzzy numbers.
      Throws:
        `FuzzyOntologyException` - fuzzy ontology exception.

    - #### hasDefinedRange

          public static boolean hasDefinedRange()

      Checks if the range of the fuzzy numbers has been defined.
      Returns:
        true if the range of the fuzzy numbers has been defined; false otherwise.

    - #### setRange

          public static void setRange(double minRange,
                                      double maxRange)

      Sets the range of the fuzzy numbers.
      Parameters:
        `minRange` - Lower bound of the range.
        `maxRange` - Upper bound of the range.

    - #### getBestNonFuzzyPerformance

          public double getBestNonFuzzyPerformance()

      Gets the Best Non fuzzy Performance (BNP) of the fuzzy number.
      Returns:
        BNP of the fuzzy number.

    - #### equals

          public boolean equals(TriangularFuzzyNumber t)

      Indicates whether some other fuzzy number is "equal to" this one.
      Parameters:
        `t` - The reference object with which to compare.
      Returns:
        true if this object is the same as the argument; false otherwise.

    - #### complement

          public Concept complement()

      Description copied from class: `FuzzyConcreteConcept`
      Gets the complement of the concept.
      Overrides:
        `complement` in class `TriangularConcreteConcept`
      Returns:
        The complement of the concept.

    - #### toString

          public java.lang.String toString()

      Description copied from class: `Concept`
      Gets a printable name of the concept.
      Overrides:
        `toString` in class `FuzzyConcreteConcept`
      Returns:
        Name of the concept.