nrc.fuzzy
Class GaussianFuzzySet

java.lang.Object
  |
  +--nrc.fuzzy.FuzzySet
        |
        +--nrc.fuzzy.LRFuzzySet
              |
              +--nrc.fuzzy.GaussianFuzzySet
All Implemented Interfaces:
java.lang.Cloneable, java.io.Serializable

public class GaussianFuzzySet
extends LRFuzzySet
implements java.io.Serializable

Used to build specialized FuzzySets that have a 'gaussian' shape with a 0 at the left and right edges of the curve and a 1 in the middle section. The diagram below shows a couple of GaussianFuzzySets, one where the left and right sides of the curve meet at a single point and one where the left and right sides are separated.



Note that the Constructors have been defined to make the generation of such curves as simple as possible. Only the middle point(s) and the standard deviation(s) of the curve need be specified (with optional constructor(s) that allow the number of points on the curve approximation to be specified if necessary -- or use the default number of points for a leftGaussianFuzzySet and rightGaussianFuzzySet; this is controlled by parameters in the leftGaussianFunction and rightGaussianFunction classes).

Note that this is a specialization of the LRFuzzySet with specific functions used to determine the shape of the left (leftGaussianFunction) and right (rightGaussianFunction) sides. The left and right shapes may or may not join at the same point.
The curves are defined by the following equation:



where a is the mean and sigma is the standard deviation.

See Also:
FuzzySet, LRFuzzySet, leftGaussianFunction, rightGaussianFunction, Serialized Form

Nested Class Summary
 
Nested classes inherited from class nrc.fuzzy.FuzzySet
FuzzySet.UITools
 
Field Summary
 
Fields inherited from class nrc.fuzzy.FuzzySet
BFALSE, BTRUE, COLLINEAR_OR_PARALLEL, INCREMENT, INTERSECTION, MAX_INITIAL_POINTS, MAXMIN, NO_INTERSECTION, numPoints, set, simplified, SUM, tool, toStringPrecision, UNION
 
Constructor Summary
GaussianFuzzySet(double center, double standardDeviation)
          Generate a FuzzySet with a 'gaussian' shape.
GaussianFuzzySet(double leftCenter, double leftStandardDeviation, double rightCenter, double rightStandardDeviation)
          Generate a FuzzySet with a 'gaussian' shape.
GaussianFuzzySet(double leftCenter, double leftStandardDeviation, double rightCenter, double rightStandardDeviation, int numPoints)
          Generate a FuzzySet with a 'gaussian' shape.
GaussianFuzzySet(double center, double standardDeviation, int numPoints)
          Generate a FuzzySet with a 'gaussian' shape.
 
Methods inherited from class nrc.fuzzy.LRFuzzySet
checkParameters
 
Methods inherited from class nrc.fuzzy.FuzzySet
appendSetPoint, appendSetPoint, centerOfAreaDefuzzify, checkXValueOrder, checkYValueRange, concat, concat, confineToXBounds, copyFuzzySet, equals, findMaxYOverlapValue, fuzzyComplement, fuzzyEqual, fuzzyIntersection, fuzzyIntersection, fuzzyIntersectionUnion, fuzzyNormalize, fuzzyScale, fuzzySum, fuzzySum, fuzzyUnion, fuzzyUnion, getAlphaCut, getArea, getArea, getMaxY, getMembership, getMinY, getPoint, getSupport, getUITools, getX, getXforMembership, getY, goingDown, goingUp, horizontalIntersection, horizontalIntersectionUnion, horizontalUnion, incrementArrayLength, incrementArrayLength, insertSetPoint, insertSetPoint, isConvex, isEmpty, isNormal, isSimplified, maximumDefuzzify, maximumOfIntersection, maximumOfIntersection, momentDefuzzify, noIntersectionTest, nonIntersectionTest, plotFuzzySet, plotFuzzySets, removeSetPoint, removeSetPoint, sameDirection, sameSign, setToStringPrecision, shiftArrayLeft, shiftArrayRight, simplifySet, size, testArrayLength, toString, trimToSize, weightedAverageDefuzzify
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GaussianFuzzySet

public GaussianFuzzySet(double center,
                        double standardDeviation)
                 throws XValuesOutOfOrderException
Generate a FuzzySet with a 'gaussian' shape.

Parameters:
center - the center of the curve with a membership value of 1
standardDeviation - the standard deviation for the gaussian curve
Throws:
XValuesOutOfOrderException - if the parameters determine an illegal arrangement (such as a negative width)

GaussianFuzzySet

public GaussianFuzzySet(double center,
                        double standardDeviation,
                        int numPoints)
                 throws XValuesOutOfOrderException
Generate a FuzzySet with a 'gaussian' shape.

Parameters:
center - the center of the curve with a membership value of 1
standardDeviation - the standard deviation for the gaussian curve
numPoints - the number of points to use to approximate each side of the shape
Throws:
XValuesOutOfOrderException - if the parameters determine an illegal arrangement (such as a negative width)

GaussianFuzzySet

public GaussianFuzzySet(double leftCenter,
                        double leftStandardDeviation,
                        double rightCenter,
                        double rightStandardDeviation,
                        int numPoints)
                 throws XValuesOutOfOrderException
Generate a FuzzySet with a 'gaussian' shape. The left part of the shape may have a different standard deviation from the right part of the shape and the left and right shapes may not meet at the same point.

Parameters:
leftStandardDeviation - the standard deviation for the left half of the gaussian curve
rightStandardDeviation - the standard deviation for the right half of the gaussian curve
numPoints - the number of points to use to approximate each side of the shape
Throws:
XValuesOutOfOrderException - if the parameters determine an illegal arrangement (such as a negative width)

GaussianFuzzySet

public GaussianFuzzySet(double leftCenter,
                        double leftStandardDeviation,
                        double rightCenter,
                        double rightStandardDeviation)
                 throws XValuesOutOfOrderException
Generate a FuzzySet with a 'gaussian' shape. The left part of the shape may have a different standard deviation from the right part of the shape and the left and right shapes may not meet at the same point.

Parameters:
leftStandardDeviation - the standard deviation for the left half of the gaussian curve
rightStandardDeviation - the standard deviation for the right half of the gaussian curve
Throws:
XValuesOutOfOrderException - if the parameters determine an illegal arrangement (such as a negative width)