Examples of MembershipFunction


Examples of net.sourceforge.jFuzzyLogic.membership.MembershipFunction

    if( debug ) Gpr.debug("Tree: " + tree.toStringTree());
    Value a1 = new Value(tree.getChild(0), this);
    Value c1 = new Value(tree.getChild(1), this);
    Value a2 = new Value(tree.getChild(2), this);
    Value c2 = new Value(tree.getChild(3), this);
    MembershipFunction membershipFunction = new MembershipFunctionDifferenceSigmoidal(a1, c1, a2, c2);
    return membershipFunction;
  }
View Full Code Here

Examples of net.sourceforge.jFuzzyLogic.membership.MembershipFunction

  private MembershipFunction fclTreeFuzzifyTermGauss(Tree tree) {
    if( debug ) Gpr.debug("Tree: " + tree.toStringTree());
    Tree child = tree.getChild(0);
    Value mean = new Value(child, this);
    Value stdev = new Value(tree.getChild(1), this);
    MembershipFunction membershipFunction = new MembershipFunctionGaussian(mean, stdev);
    return membershipFunction;
  }
View Full Code Here

Examples of net.sourceforge.jFuzzyLogic.membership.MembershipFunction

    //---
    // Iterate over each linguistic term
    for( String termName : variable.getLinguisticTerms().keySet() ) {
      LinguisticTerm linguisticTerm = variable.getLinguisticTerm(termName);
      // Get membership function
      MembershipFunction membershipFunction = linguisticTerm.getMembershipFunction();

      // Guess epsilon
      membershipFunction.estimateUniverse();
      double delta = membershipFunction.getUniverseMax() - membershipFunction.getUniverseMin();
      if( delta == 0 ) delta = variable.getUniverseMax() - variable.getUniverseMin();
      epsilon = delta / UNIVERSE_TO_EPSILON_RATIO;

      // Iterate over each membership funciotn's parameter
      for( int i = 0; i < membershipFunction.getParametersLength(); i++ ) {
        String paramName = variable.getName() + "_" + linguisticTerm.getTermName() + "_" + membershipFunction.getName() + "_" + i;
        ParameterMembershipFunction param = new ParameterMembershipFunction(paramName, epsilon, variable, membershipFunction, i);
        parameterList.add(param);
      }
    }
  }
View Full Code Here

Examples of net.sourceforge.jFuzzyLogic.membership.MembershipFunction

    if( debug ) Gpr.debug("Tree: " + tree.toStringTree());
    Tree child = tree.getChild(0);
    Value a = new Value(child, this);
    Value b = new Value(tree.getChild(1), this);
    Value mean = new Value(tree.getChild(2), this);
    MembershipFunction membershipFunction = new MembershipFunctionGenBell(a, b, mean);
    return membershipFunction;
  }
View Full Code Here

Examples of net.sourceforge.jFuzzyLogic.membership.MembershipFunction

   */
  private MembershipFunction fclTreeFuzzifyTermSigmoidal(Tree tree) {
    if( debug ) Gpr.debug("Tree: " + tree.toStringTree());
    Value gain = new Value(tree.getChild(0), this);
    Value t0 = new Value(tree.getChild(1), this);
    MembershipFunction membershipFunction = new MembershipFunctionSigmoidal(gain, t0);
    return membershipFunction;
  }
View Full Code Here

Examples of net.sourceforge.jFuzzyLogic.membership.MembershipFunction

   * @return A new membership function
   */
  private MembershipFunction fclTreeFuzzifyTermSingleton(Tree tree) {
    if( debug ) Gpr.debug("Tree: " + tree.toStringTree());
    Value singleTonValueX = new Value(tree, this);
    MembershipFunction membershipFunction = new MembershipFunctionSingleton(singleTonValueX);
    return membershipFunction;
  }
View Full Code Here

Examples of net.sourceforge.jFuzzyLogic.membership.MembershipFunction

    if( debug ) Gpr.debug("Tree: " + tree.toStringTree());
    Value min = new Value(tree.getChild(0), this);
    Value midLow = new Value(tree.getChild(1), this);
    Value midHigh = new Value(tree.getChild(2), this);
    Value max = new Value(tree.getChild(3), this);
    MembershipFunction membershipFunction = new MembershipFunctionTrapetzoidal(min, midLow, midHigh, max);
    return membershipFunction;
  }
View Full Code Here

Examples of net.sourceforge.jFuzzyLogic.membership.MembershipFunction

  private MembershipFunction fclTreeFuzzifyTermTriangular(Tree tree) {
    if( debug ) Gpr.debug("Tree: " + tree.toStringTree());
    Value min = new Value(tree.getChild(0), this);
    Value mid = new Value(tree.getChild(1), this);
    Value max = new Value(tree.getChild(2), this);
    MembershipFunction membershipFunction = new MembershipFunctionTriangular(min, mid, max);
    return membershipFunction;
  }
View Full Code Here

Examples of net.sourceforge.jFuzzyLogic.membership.MembershipFunction

    FIS fis = new FIS();

    FunctionBlock fb = new FunctionBlock(fis);

    Variable v = new Variable("a", 0.0, 20.0);
    MembershipFunction triangular = new MembershipFunctionTriangular(new Value(0.0000343232), new Value(10.0), new Value(13.0));

    LinguisticTerm t1 = new LinguisticTerm("lt1", triangular);
    LinguisticTerm t2 = new LinguisticTerm("lt2", triangular);

    v.add(t1);
    v.add(t2);

    Variable v_out = new Variable("out", 0.0, 20.0);
    MembershipFunction triangularOut = new MembershipFunctionTriangular(new Value(2.0), new Value(10.0), new Value(13.0));
    v_out.setDefaultValue(2.0);
    v_out.setDefuzzifier(new DefuzzifierCenterOfGravity(v_out));

    fb.setVariable("a", v);
    fb.setVariable("out", v_out);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.