Class ShapleyCulpabilityMeasure<S extends Formula,​T extends BeliefSet<S,​?>>

  • Type Parameters:
    S - the type of formulas
    T - the type of belief sets
    All Implemented Interfaces:
    CulpabilityMeasure<S,​T>

    public class ShapleyCulpabilityMeasure<S extends Formula,​T extends BeliefSet<S,​?>>
    extends java.lang.Object
    implements CulpabilityMeasure<S,​T>
    This class implements the Shapley culpability measure.
    Author:
    Matthias Thimm
    • Method Summary

      Modifier and Type Method Description
      java.lang.Double culpabilityMeasure​(T beliefSet, S formula)
      Returns the degree of responsibility of the given formula to cause inconsistency in the given belief set (NOTE: the formula should be in the given belief set).
      private java.util.Set<Pair<java.util.Collection<S>,​java.util.Collection<S>>> getSubsets​(T kb, S f)
      Computes all pairs (k,k') of knowledge bases k,k'\subseteq kb, such that k = k' \cup {pc}.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • archive

        private java.util.Map<Pair<T extends BeliefSet<S,​?>,​S extends Formula>,​java.lang.Double> archive
        Stores previously computed culpability values.
    • Constructor Detail

      • ShapleyCulpabilityMeasure

        public ShapleyCulpabilityMeasure​(BeliefSetInconsistencyMeasure<S> inconsistencyMeasure)
        Creates a new Shapley culpability measure that bases on the given inconsistency measure.
        Parameters:
        inconsistencyMeasure - an inconsistency measure.
    • Method Detail

      • culpabilityMeasure

        public java.lang.Double culpabilityMeasure​(T beliefSet,
                                                   S formula)
        Description copied from interface: CulpabilityMeasure
        Returns the degree of responsibility of the given formula to cause inconsistency in the given belief set (NOTE: the formula should be in the given belief set).
        Specified by:
        culpabilityMeasure in interface CulpabilityMeasure<S extends Formula,​T extends BeliefSet<S,​?>>
        Parameters:
        beliefSet - a belief set.
        formula - a formula
        Returns:
        a Double indicating the degree of inconsistency (NOTE: if the given formula does not appear in the given belief set the degree is defined to be zero).
      • getSubsets

        private java.util.Set<Pair<java.util.Collection<S>,​java.util.Collection<S>>> getSubsets​(T kb,
                                                                                                      S f)
        Computes all pairs (k,k') of knowledge bases k,k'\subseteq kb, such that k = k' \cup {pc}.
        Parameters:
        kb - a knowledge base.
        f - a formula.
        Returns:
        a set of pairs of knowledge bases.