Package net.sf.tweety.logics.pl.analysis
Class FbInconsistencyMeasure
- java.lang.Object
-
- net.sf.tweety.logics.commons.analysis.BeliefSetInconsistencyMeasure<PlFormula>
-
- net.sf.tweety.logics.pl.analysis.FbInconsistencyMeasure
-
- All Implemented Interfaces:
PostulateEvaluatable<PlFormula>
,InconsistencyMeasure<BeliefSet<PlFormula,?>>
public class FbInconsistencyMeasure extends BeliefSetInconsistencyMeasure<PlFormula>
Implements the forgetting-based inconsistency measure from [Besnard. Forgetting-based Inconsistency Measure. SUM 2016] The implementation is a brute-force search approach without much optimization.- Author:
- Matthias Thimm
-
-
Field Summary
-
Fields inherited from interface net.sf.tweety.logics.commons.analysis.InconsistencyMeasure
MEASURE_TOLERANCE
-
-
Constructor Summary
Constructors Constructor Description FbInconsistencyMeasure()
-
Method Summary
Modifier and Type Method Description private boolean
hasDuplicate(java.util.Set<Triple<Proposition,java.lang.Integer,SpecialFormula>> current)
Checks whether the selection of substitutions is consistent (no proposition to be replaced by + and - at the same time).java.lang.Double
inconsistencyMeasure(java.util.Collection<PlFormula> formulas)
This method measures the inconsistency of the given set of formulas.private java.util.List<Triple<Proposition,java.lang.Integer,SpecialFormula>>
order(java.util.Set<Triple<Proposition,java.lang.Integer,SpecialFormula>> current)
Orders the substitutions in decreasing order.-
Methods inherited from class net.sf.tweety.logics.commons.analysis.BeliefSetInconsistencyMeasure
inconsistencyMeasure
-
-
-
-
Method Detail
-
inconsistencyMeasure
public java.lang.Double inconsistencyMeasure(java.util.Collection<PlFormula> formulas)
Description copied from class:BeliefSetInconsistencyMeasure
This method measures the inconsistency of the given set of formulas.- Specified by:
inconsistencyMeasure
in classBeliefSetInconsistencyMeasure<PlFormula>
- Parameters:
formulas
- a collection of formulas.- Returns:
- a Double indicating the degree of inconsistency.
-
hasDuplicate
private boolean hasDuplicate(java.util.Set<Triple<Proposition,java.lang.Integer,SpecialFormula>> current)
Checks whether the selection of substitutions is consistent (no proposition to be replaced by + and - at the same time).- Parameters:
current
- current substitutions- Returns:
- true iff the selection of substitutions is consistent
-
order
private java.util.List<Triple<Proposition,java.lang.Integer,SpecialFormula>> order(java.util.Set<Triple<Proposition,java.lang.Integer,SpecialFormula>> current)
Orders the substitutions in decreasing order.- Parameters:
current
- current substitutions- Returns:
- ordered list of current substitutions
-
-