12,746,572 members (28,972 online)

#### Stats

79.7K views
9.6K downloads
175 bookmarked
Posted 27 Jan 2011

# Fuzzy Framework

, 27 Jan 2011 CPOL
In the following article, we briefly introduce Fuzzy Framework library which supports calculations based on fuzzy logic in .NET.
 FuzzyFramework_demo1 FuzzyFramework.dll PolyLib.dll ReallySimpleExample.toRemameBackToExe FuzzyFramework_demo2 FuzzyFramework.dll FuzzyFramework.Graphics.dll PolyLib.dll SampleProject.toRemameBackToExe FuzzyFramework FruitExample Properties FuzzyFramework FuzzyFramework.Graphics Properties Resources defuzzification.gif defuzzificationOutput.gif dimensionContinuous.gif dimensionContinuousUnknown.gif dimensionDiscrete.gif dimensionDiscreteUnknown.gif dimensions.gif dimensionType.gif Function.gif fuzzySet.gif Graph.gif nodeFuzzyRelation.gif Sample.gif spacer.gif spacerWhite.gif subrelations.gif ToManyDimensions.gif Defuzzification Dimensions Graphics Intervals Members Operators PolyLib bin Debug PolyLib.dll PolyLib.pdb Release PolyLib.dll PolyLib.pdb Polynomial.dll Polynomial.pdb obj Debug DesignTimeResolveAssemblyReferencesInput.cache PolyLib.dll PolyLib.pdb TempPE Release DesignTimeResolveAssemblyReferencesInput.cache PolyLib.dll PolyLib.pdb TempPE PolyLib.csproj.user Properties Properties Sets FuzzySets.cd ReallySimpleExample Properties SampleProject Properties ```﻿using System; using System.Collections.Generic; using System.Linq; using System.Text; using FuzzyFramework.Operators; namespace FuzzyFramework { /// /// Represents a fuzzy relation. /// Note that fuzzy set is a special (terminal, leaf) case of fuzzy relation. /// We consider fuzzy relation a relation of two other fuzzy relations by means of operator. If more than two subrelations required, simply concatenate them: /// ((subrelation1 operator subrelation 2) operator subrelation3) ... operator subrelation n). /// /// We don't expect particular subrelations being especially prioritized. Once using parenthesis in an expression definyng the relation, the tree will be automatically built in the proper order. /// public interface IFuzzyRelation { /// /// Specifies whether the relation is actually an ordinary fuzzy set, i.e. there are no subrelations. Terminal, leaf relation /// bool Terminal {get;} /// /// First operand. Null if terminal relation /// IFuzzyRelation Subrelation1 { get; } /// /// Secod operand. Null if terminal relation or if an unary operator used /// IFuzzyRelation Subrelation2 { get; } /// /// -Binary operator over Subrelation1 and Subrelation2 /// -Unary operator over Subrelation1 (whereas Subrelation2 is null) /// -null if terminal relation /// IOperator Operator { get; } //All distinct dimensions used throughout the relation (including nested levels). IDimension[] Dimensions { get; } /// /// Returns lowest value where the membership function > 0 for the specified dimension. /// Suitable for painting a graph, for example, if we want to avoid to draw it for the whole univesre. /// If more than one fuzzy set for the single dimension used in the relation (E.g. in expression "temperature hot or temperature cold"), than the result will be minimum for all these sets. /// /// Dimension to return the boundaries for /// the lower boundary System.Decimal GetLowerSupportBound(IDimension dimension); System.Decimal GetUpperSupportBound(IDimension dimension); } } ```

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

## License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

## About the Author

 Student Czech Republic
No Biography provided

## You may also be interested in...

Permalink | Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.170215.1 | Last Updated 27 Jan 2011
Article Copyright 2011 by Václav Slavíček
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid