double result = 0.0;
double dm = 0.0;
FzyPremise premise = (FzyPremise) aRule.getPremise();
FzyClauseComponent pGoal = premise.getComponent();
FzyConsequent conseq = (FzyConsequent) aRule.getConsequent();
infosapient.system.FzyAttribClause conseqClause = conseq.getConsequentGoal();
try {
revisedPGoal = evaluateComponent(pGoal);
dm = revisedPGoal.getSolutionDOM();
if (dm > 0.0d) {
//
// Correlate the consequent to the premise using the correlation method specified.
//
corrSet = corrMth.applyCorrelation(dm, (FzySet) conseqClause.getGoal());
//
// Add the correlated set to the solution set using the implication method.
//
implicMth.applyImplicationMethod(corrSet, conseqClause.getSolutionSet());
result = defuzzMth.resolveToScalar(conseqClause.getSolutionSet());
conseqClause.getSolutionSet().setSolution(result);
conseqClause.getAttribute().setCurrentDomainValue(result);
}
if ((conseq.getAltConseqGoal() != null) && (dm < 1.0d)) {
infosapient.system.FzyAttribClause conseqAltGoalClause =
conseq.getAltConseqGoal();
//
// Correlate the consequent to the premise using the correlation method specified.
//
corrSet =
corrMth.applyCorrelation((1.0 - dm), (FzySet) conseqAltGoalClause.getGoal());