public class WeightedGroundArithmeticRule extends AbstractGroundArithmeticRule implements WeightedGroundRule
atoms, coefficients, comparator, constant, rule
Modifier | Constructor and Description |
---|---|
protected |
WeightedGroundArithmeticRule(WeightedArithmeticRule rule,
float[] coefficients,
GroundAtom[] atoms,
FunctionComparator comparator,
float constant) |
protected |
WeightedGroundArithmeticRule(WeightedArithmeticRule rule,
List<Float> coefficients,
List<GroundAtom> atoms,
FunctionComparator comparator,
float constant) |
Modifier and Type | Method and Description |
---|---|
GeneralFunction |
getFunctionDefinition() |
double |
getIncompatibility()
Returns the incompatibility of the truth values of this GroundRule's GroundAtoms.
|
double |
getIncompatibility(GroundAtom replacementAtom,
float replacementValue)
Returns the incompatibility of the truth values of this GroundRule's GroundAtoms given
the replacment of a single atom's value with another value.
|
WeightedRule |
getRule() |
double |
getWeight()
Returns the Weight of this WeightedGroundRule.
|
boolean |
isSquared() |
void |
setWeight(double weight)
Sets a weight for this WeightedGroundRule.
|
String |
toString() |
baseToString, getAtoms, getCoefficients, getComparator, getConstant, getOrderedAtoms, negate
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
baseToString, getAtoms, negate
protected WeightedGroundArithmeticRule(WeightedArithmeticRule rule, List<Float> coefficients, List<GroundAtom> atoms, FunctionComparator comparator, float constant)
protected WeightedGroundArithmeticRule(WeightedArithmeticRule rule, float[] coefficients, GroundAtom[] atoms, FunctionComparator comparator, float constant)
public WeightedRule getRule()
getRule
in interface GroundRule
getRule
in interface WeightedGroundRule
getRule
in class AbstractGroundArithmeticRule
Rule
public boolean isSquared()
isSquared
in interface WeightedGroundRule
public double getWeight()
WeightedGroundRule
getWeight
in interface WeightedGroundRule
public void setWeight(double weight)
WeightedGroundRule
setWeight
in interface WeightedGroundRule
public GeneralFunction getFunctionDefinition()
getFunctionDefinition
in interface WeightedGroundRule
public double getIncompatibility()
WeightedGroundRule
getIncompatibility
in interface WeightedGroundRule
public double getIncompatibility(GroundAtom replacementAtom, float replacementValue)
WeightedGroundRule
getIncompatibility
in interface WeightedGroundRule
public String toString()
toString
in class AbstractGroundArithmeticRule
Copyright © 2020 University of California, Santa Cruz. All rights reserved.