Examples of TruthValue


Examples of jmathexpr.bool.TruthValue

        if (evaluated instanceof TruthValue) {
            return evaluated;
        } else {
            Expression reduced =
                    new Subtraction(((Equality) evaluated).lhs(), ((Equality) evaluated).rhs()).evaluate();
            TruthValue isZero = isZero(reduced);
           
            if (isZero != null) {
                return isZero;
            }
        }
View Full Code Here

Examples of jmathexpr.bool.TruthValue

   
    private static TruthValue isZero(Expression expr) {
        if (expr instanceof ANumber) {
            return TruthValue.valueOf(((ANumber) expr).isZero());
        } else if (expr instanceof Multiplication) {
            TruthValue leftIsZero = isZero(((Multiplication) expr).lhs());
            TruthValue rightIsZero = isZero(((Multiplication) expr).rhs());
           
            if (leftIsZero == TruthValue.True) {
                return TruthValue.True;
            } else if (rightIsZero == TruthValue.True) {
                return TruthValue.True;
View Full Code Here

Examples of jmathexpr.bool.TruthValue

    private FiniteSet(FiniteSet set) {
        this(set.elements);
    }
   
    public final TruthValue add(Expression element) {
        TruthValue contained = contains(element);
       
        if (contained == TruthValue.False) {
            elements.add(element);
        }
       
View Full Code Here

Examples of org.apache.ctakes.smokingstatus.util.TruthValue

          ssClass = Const.CLASS_UNKNOWN;
        } else {
          throw new Exception("Invalid truth value for line:" + line);
        }

        TruthValue tVal = (TruthValue) iv_truthMap.get(recordID);
        if (tVal == null) {
          tVal = new TruthValue();
          tVal.iv_sentenceList = new ArrayList<String>();
          tVal.iv_classification = ssClass;
        }

        tVal.iv_sentenceList.add(sentence);
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.