|
- Method resolution order:
- Trapez
- fuzzy.set.Polygon.Polygon
- fuzzy.set.Set.Set
- __builtin__.object
Methods defined here:
- __init__(self, m1=-0.5, m2=0.5, alpha=0.5, beta=0.5, y_max=1.0, y_min=0.0)
- Initialize a trapezoid-shaped fuzzy set.
@param y_max: y-value at top of the trapezoid (1.0)
@param y_min: y-value outside the trapezoid (0.0)
@param m1: x-value of left top of trapezoid (-0.5)
@param m2: x-value of right top of trapezoid (0.5)
@param alpha: distance of left corner to m1 (0.5)
@param beta: distance of right corner to m2 (0.5)
- __repr__(self)
- Return representation of instance.
@return: representation of instance
@rtype: string
- add(self, x, y, where=1)
- Don't let anyone destroy our trapezoid.
- clear(self)
- Don't let anyone destroy our trapezoid.
- remove(self, x, where=1)
- Don't let anyone destroy our trapezoid.
Data descriptors defined here:
- alpha
- distance of left corner to m1
@type: float
- beta
- distance of right corner to m2
@type: float
- m1
- x-value of left top of trapezoid
@type: float
- m2
- x-value of right top of trapezoid
@type: float
- y_max
- y-value at top of the trapezoid
@type: float
- y_min
- y-value outside the trapezoid
@type: float
Methods inherited from fuzzy.set.Polygon.Polygon:
- __call__(self, x)
- Get membership of value x.
- getCOG(self)
- Return center of gravity.
- getValuesX(self)
- Return sequence of x-values for set.
- getValuesXY(self, flat=True)
- Return sequence of (x,y)-values for set.
In case of vertical slopes, y is a tuple of y-values for flat = False.
Otherwise several (x,y)-values will be generated having identical x-values.
Data descriptors inherited from fuzzy.set.Polygon.Polygon:
- points
- points of the polygon.
@type: list of 2-tuple (x,y)
Data and other attributes inherited from fuzzy.set.Polygon.Polygon:
- BEGIN = 0
- END = 1
- X = 0
- Y = 1
Data descriptors inherited from fuzzy.set.Set.Set:
- __dict__
- dictionary for instance variables (if defined)
- __weakref__
- list of weak references to the object (if defined)
|