public class PriestWorld extends AbstractInterpretation
Modifier and Type | Class and Description |
---|---|
static class |
PriestWorld.TruthValue
The three truth values.
|
Modifier and Type | Field and Description |
---|---|
private java.util.Map<Proposition,PriestWorld.TruthValue> |
values
The truth values of the propositions.
|
Constructor and Description |
---|
PriestWorld()
Creates a new world where all propositions get the truth value FALSE.
|
Modifier and Type | Method and Description |
---|---|
PriestWorld.TruthValue |
get(Proposition p)
Returns the truth value of the given proposition.
|
java.util.Collection<Proposition> |
getBinarybase()
Returns the binary base of this world, i.e.
|
java.util.Collection<Proposition> |
getConflictbase()
Returns the conflict base of this world, i.e.
|
boolean |
satisfies(BeliefBase beliefBase)
Checks whether this interpretation satisfies the given knowledge base.
|
boolean |
satisfies(Formula formula)
Checks whether this interpretation satisfies the given formula.
|
PriestWorld.TruthValue |
satisfies3VL(Formula formula)
Determines the 3-valued truth value of the given formula.
|
void |
set(Proposition p,
PriestWorld.TruthValue val)
Sets the value of the given proposition.
|
java.lang.String |
toString() |
satisfies
private java.util.Map<Proposition,PriestWorld.TruthValue> values
public PriestWorld()
public void set(Proposition p, PriestWorld.TruthValue val)
p
- some proposition.val
- some truth value.public PriestWorld.TruthValue get(Proposition p)
p
- a propositionpublic boolean satisfies(Formula formula) throws java.lang.IllegalArgumentException
Interpretation
formula
- a formula .java.lang.IllegalArgumentException
- if the formula does not correspond
to the expected language.public PriestWorld.TruthValue satisfies3VL(Formula formula) throws java.lang.IllegalArgumentException
formula
- some formulajava.lang.IllegalArgumentException
public java.util.Collection<Proposition> getBinarybase()
public java.util.Collection<Proposition> getConflictbase()
public boolean satisfies(BeliefBase beliefBase) throws java.lang.IllegalArgumentException
Interpretation
beliefBase
- a knowledge base.java.lang.IllegalArgumentException
- IllegalArgumentException if the knowledgebase does not correspond
to the expected language.public java.lang.String toString()
toString
in class java.lang.Object