{
CmpVertex mergedRed = merged.findVertex(pair.getR());
if (mergedRed == null)
throw new IllegalArgumentException("failed to find the red state in the merge result");
PTASequenceEngine engine = new PTASequenceEngine();
engine.init(original.new NonExistingPaths());
PTASequenceEngine.SequenceSet paths = engine.new SequenceSet();
PTASequenceEngine.SequenceSet initp = engine.new SequenceSet();initp.setIdentity();
merged.pathroutines.computePathsSBetween(merged.getInit(),mergedRed, initp, paths);
Collection<Label> inputsToMultWith = new LinkedList<Label>();
for(Entry<Label,CmpVertex> loopEntry:merged.transitionMatrix.get(mergedRed).entrySet())
if (loopEntry.getValue() == mergedRed)
{// Note an input corresponding to any loop in temp can be followed in the original machine, since
// a loop in temp is either due to the merge or because it was there in the first place.
inputsToMultWith.add(loopEntry.getKey());
}
paths.unite(paths.crossWithSet(inputsToMultWith));// the resulting path does a "transition cover" on all transitions leaving the red state.
merged.questions.buildQuestionsFromPair_Compatible(mergedRed, paths);
return engine.getData();
}