nl.uu.cs.ape.models.sltlxStruc.SLTLxXOR Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of APE Show documentation
Show all versions of APE Show documentation
APE is a command line tool and an API for the automated exploration of possible computational pipelines (workflows) from large collections of computational tools.
The newest version!
package nl.uu.cs.ape.models.sltlxStruc;
import java.util.Set;
import nl.uu.cs.ape.solver.minisat.SATSynthesisEngine;
/**
* Structure used to model XOR relation ("a xor b" is the same as "not a
* <=> b") in SLTLx.
*
* @author Vedran Kasalica
*
*/
public class SLTLxXOR extends SLTLxFormula {
private SLTLxFormula firstArg;
private SLTLxFormula secondArg;
public SLTLxXOR(SLTLxFormula firstArg, SLTLxFormula secondArg) {
super();
this.firstArg = firstArg;
this.secondArg = secondArg;
}
@Override
public Set getCNFEncoding(int stateNo, SLTLxVariableSubstitutionCollection variableMapping,
SATSynthesisEngine synthesisEngine) {
return new SLTLxEquivalence(firstArg, secondArg).getNegatedCNFEncoding(stateNo, variableMapping,
synthesisEngine);
}
@Override
public Set getNegatedCNFEncoding(int stateNo, SLTLxVariableSubstitutionCollection variableMapping,
SATSynthesisEngine synthesisEngine) {
return new SLTLxEquivalence(firstArg, secondArg).getCNFEncoding(stateNo, variableMapping, synthesisEngine);
}
}