Class ThreeValuedWorld

java.lang.Object
org.tweetyproject.commons.AbstractInterpretation<PlBeliefSet,PlFormula>
org.tweetyproject.logics.translators.adfconditional.ThreeValuedWorld
All Implemented Interfaces:
Interpretation<PlBeliefSet,PlFormula>

public class ThreeValuedWorld extends AbstractInterpretation<PlBeliefSet,PlFormula>
This class models a three-valued interpretation for propositional logic Formulas are interpreted using completions Every atom is assigned one of the three truth values: TRUE, FALSE, UNDECIDED.
Author:
Jonas Schumacher
  • Constructor Details

    • ThreeValuedWorld

      public ThreeValuedWorld()
      Creates an empty 3-valued world
    • ThreeValuedWorld

      public ThreeValuedWorld(ThreeValuedWorld other)
      Creates a new world which is a copy of the given world
      Parameters:
      other - some other world
  • Method Details

    • set

      public void set(Proposition p, ThreeValuedWorld.TruthValue val)
      Sets the value of the given proposition.
      Parameters:
      p - some proposition.
      val - some truth value.
    • get

      Returns the truth value of the given proposition.
      Parameters:
      p - a proposition
      Returns:
      a truth value.
    • getSignature

      public PlSignature getSignature()
      Returns the signature of this world.
      Returns:
      the signature of this world.
    • getTwoValuedSet

      public Collection<PossibleWorld> getTwoValuedSet()
      This method calculates a collection of 2-valued worlds based on this 3-valued world UNDECIDED atoms are replaced by FALSE or TRUE
      Returns:
      Collection of 2-valued worlds
    • satisfies

      public boolean satisfies(PlFormula formula)
      Description copied from interface: Interpretation
      Checks whether this interpretation satisfies the given formula.
      Parameters:
      formula - a formula .
      Returns:
      "true" if this interpretation satisfies the given formula.
    • satisfies3VL

      public ThreeValuedWorld.TruthValue satisfies3VL(PlFormula formula)
      Determines the 3-valued truth value of the given formula.
      Parameters:
      formula - : some propositional formula
      Returns:
      the 3-valued truth value of the formula.
    • satisfies

      public boolean satisfies(PlBeliefSet beliefBase) throws IllegalArgumentException
      Description copied from interface: Interpretation
      Checks whether this interpretation satisfies the given knowledge base.
      Parameters:
      beliefBase - a knowledge base.
      Returns:
      "true" if this interpretation satisfies the given knowledge base.
      Throws:
      IllegalArgumentException - IllegalArgumentException if the knowledgebase does not correspond to the expected language.
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object