public class RpclProbabilityDistribution extends ProbabilityDistribution<HerbrandInterpretation>
Modifier and Type | Field and Description |
---|---|
private RpclSemantics |
semantics
The semantics used for this probability distribution.
|
Constructor and Description |
---|
RpclProbabilityDistribution(RpclSemantics semantics,
FolSignature signature)
Creates a new probability distribution for the given signature.
|
Modifier and Type | Method and Description |
---|---|
RpclProbabilityDistribution |
convexCombination(double d,
RpclProbabilityDistribution other)
Computes the convex combination of this P1 and the
given probability distribution P2 with parameter d, i.e.
|
RpclSemantics |
getSemantics()
Returns the semantics of this distribution.
|
static RpclProbabilityDistribution |
getUniformDistribution(RpclSemantics semantics,
FolSignature signature)
Returns the uniform distribution on the given signature.
|
Probability |
probability(FolFormula f)
Gets the probability of the given closed formula, i.e.
|
Probability |
probability(RelationalConditional re)
Gets the probability of the given closed relational conditional "re", 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.
|
clear, conditionalProbability, containsKey, containsValue, convexCombination, convexCombination, entropy, entrySet, get, getSignature, getUniformDistribution, isEmpty, keySet, linearCombination, normalize, probability, probability, put, putAll, remove, size, toString, values
satisfies
private RpclSemantics semantics
public RpclProbabilityDistribution(RpclSemantics semantics, FolSignature signature)
signature
- a fol signature.public RpclSemantics getSemantics()
public boolean satisfies(Formula formula) throws java.lang.IllegalArgumentException
Interpretation
satisfies
in interface Interpretation
satisfies
in class ProbabilityDistribution<HerbrandInterpretation>
formula
- a formula .java.lang.IllegalArgumentException
- if the formula does not correspond
to the expected language.public boolean satisfies(BeliefBase beliefBase) throws java.lang.IllegalArgumentException
Interpretation
satisfies
in interface Interpretation
satisfies
in class ProbabilityDistribution<HerbrandInterpretation>
beliefBase
- a knowledge base.java.lang.IllegalArgumentException
- IllegalArgumentException if the knowledgebase does not correspond
to the expected language.public Probability probability(FolFormula f)
f
- a closed fol formula.public Probability probability(RelationalConditional re)
re
- a closed relational conditional.public RpclProbabilityDistribution convexCombination(double d, RpclProbabilityDistribution other)
d
- a doubleother
- a probability distributionjava.lang.IllegalArgumentException
- if either d is not in [0,1] or this and
the given probability distribution are not defined on the same set of interpretations.public static RpclProbabilityDistribution getUniformDistribution(RpclSemantics semantics, FolSignature signature)
semantics
- the semantics for the distribution.signature
- a fol signature