Browse Source

quantile-common: Adapt OpRelBound to multi-threshold

accumulation-v4.7
Joachim Klein 8 years ago
committed by Joachim Klein
parent
commit
eb2e84b40f
  1. 2
      prism/src/parser/ast/ExpressionProb.java
  2. 2
      prism/src/parser/ast/ExpressionReward.java
  3. 2
      prism/src/parser/ast/ExpressionSS.java
  4. 10
      prism/src/prism/OpRelOpBound.java

2
prism/src/parser/ast/ExpressionProb.java

@ -97,7 +97,7 @@ public class ExpressionProb extends ExpressionQuant
throw new PrismLangException("Invalid probability bound " + boundVal + " in P operator");
return new OpRelOpBound("P", minMax, getRelOp(), boundVal);
} else {
return new OpRelOpBound("P", minMax, getRelOp(), null);
return new OpRelOpBound("P", minMax);
}
}

2
prism/src/parser/ast/ExpressionReward.java

@ -208,7 +208,7 @@ public class ExpressionReward extends ExpressionQuant
double boundValue = getBound().evaluateDouble(constantValues);
return new OpRelOpBound("R", minMax, getRelOp(), boundValue);
} else {
return new OpRelOpBound("R", minMax, getRelOp(), null);
return new OpRelOpBound("R", minMax);
}
}

2
prism/src/parser/ast/ExpressionSS.java

@ -82,7 +82,7 @@ public class ExpressionSS extends ExpressionQuant
throw new PrismException("Invalid probability bound " + boundValue + " in P operator");
return new OpRelOpBound("S", minMax, getRelOp(), boundValue);
} else {
return new OpRelOpBound("S", minMax, getRelOp(), null);
return new OpRelOpBound("S", minMax);
}
}

10
prism/src/prism/OpRelOpBound.java

@ -40,6 +40,16 @@ public class OpRelOpBound
protected boolean numeric;
protected double bound;
/** Constructor, no bound */
public OpRelOpBound(String op, MinMax minMax)
{
this.op = op;
this.minMax = minMax;
this.relOp = RelOp.COMPUTE_VALUES;
numeric = true;
}
/** Constructor, with relOp and bound */
public OpRelOpBound(String op, MinMax minMax, RelOp relOp, Double boundObject)
{
this.op = op;

Loading…
Cancel
Save