Browse Source

Bugfix: in detection of whether there is room for DRA DD vars before row/col.

git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@758 bbc10eb1-c90d-0410-af57-cb519fbb1720
master
Dave Parker 18 years ago
parent
commit
5a13c4cf57
  1. 6
      prism/src/prism/LTLModelChecker.java

6
prism/src/prism/LTLModelChecker.java

@ -146,7 +146,7 @@ public class LTLModelChecker
// and whether there is room to put them before rather than after the existing vars
n = (int) Math.ceil(PrismUtils.log2(dra.size()));
before = true;
if (allDDRowVars.getMinVarIndex() - ((NondetModel) model).getAllDDNondetVars().getMaxVarIndex() < 2 * n) {
if ((allDDRowVars.getMinVarIndex() - ((NondetModel) model).getAllDDNondetVars().getMaxVarIndex()) - 1 < 2 * n) {
before = false;
}
@ -191,9 +191,9 @@ public class LTLModelChecker
newAllDDRowVars.addVars(draDDRowVars);
newAllDDColVars.addVars(draDDColVars);
}
newVarList = (VarList)varList.clone();
newVarList = (VarList) varList.clone();
newVarList.addVar(before ? 0 : varList.getNumVars(), draVar, 0, dra.size() - 1, 0, 1, Expression.INT);
// Extra references (because will get derefed when new model is done with)
// TODO: tidy this up, make it corresond to model.clear()
allDDRowVars.refAll();

Loading…
Cancel
Save