Exemple #1
0
    @Override
    public int hashCode() {

        int a   = multiplicand.hashCode();
        int b   = (int)scalar.getIndex();

        return 37 * (37 * ( (a ^ (a >>> 31))) + (b ^ (b >>> 31)));

    }
Exemple #2
0
 @Override
 public Set<HasValue> bind( Term value )
     throws PatternMatchException {
     return multiplicand.bind( value );
 }
Exemple #3
0
 @Override
 public Set<Symbol> free() {
     return multiplicand.free();
 }
Exemple #4
0
 @Override
 public Pattern substitute( Term x, Symbol y ) {
     return new TMultiplicative( scalar, multiplicand.substitute( x,y ) );
 }
Exemple #5
0
 @Override
 public Term reduce() throws EvaluationException {
     return new TMultiplicative( scalar, multiplicand.reduce() );
 }
Exemple #6
0
 @Override
 public String toString() {
     return scalar.toString() + "(" + multiplicand.toString() + ")";
 }