ppotentials
Class SRPotential

java.lang.Object
  extended by nenok.va.semiring.SRValuation
      extended by nenok.va.semiring.RegularSRValuation
          extended by nenok.va.semiring.ScaledSRValuation
              extended by ppotentials.SRPotential
All Implemented Interfaces:
Serializable, Cloneable, Predictability, Regularity, Scalability, Valuation

public class SRPotential
extends ScaledSRValuation

Probability potential are an example of a scaled semiring induced valuation algebra and this class offers a possible implementation by extending the ScaledSRValuation class. The variables used within this class are of type PP_Variable.

Version:
1.1
Author:
Marc Pouly
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface nenok.va.Scalability
Scalability.Implementor
 
Field Summary
 
Fields inherited from class nenok.va.semiring.SRValuation
configurations, elements
 
Constructor Summary
SRPotential()
          Constructor:
SRPotential(PP_Variable variable, double[] probabilities)
          Constructor:
SRPotential(PP_Variable variable, PP_Variable[] conditionals, double[] probabilities)
          Constructor:
 
Method Summary
 JPanel displayChart()
          Displays the current potential as a chart.
 boolean equals(Potential p)
          Comparaison between the two implementation of probability potentials.
protected  Configuration[] getConfigurations()
           
 Element[] getElements()
           
 
Methods inherited from class nenok.va.semiring.ScaledSRValuation
scale
 
Methods inherited from class nenok.va.semiring.RegularSRValuation
inverse
 
Methods inherited from class nenok.va.semiring.SRValuation
combine, displayConfigurations, equals, label, marginalize, predictor, toString, weight
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface nenok.va.Regularity
inverse
 
Methods inherited from interface nenok.va.Valuation
combine, label, marginalize, weight
 

Constructor Detail

SRPotential

public SRPotential()
Constructor:


SRPotential

public SRPotential(PP_Variable variable,
                   double[] probabilities)
Constructor:

Parameters:
variable - The main variable of this potential.
probabilities - The probability for each possible configuration.

SRPotential

public SRPotential(PP_Variable variable,
                   PP_Variable[] conditionals,
                   double[] probabilities)
Constructor:

Parameters:
variable - The main variable of this potential.
conditionals - The conditional variables of this potential.
probabilities - The probability for each possible configuration.
Method Detail

displayChart

public JPanel displayChart()
Displays the current potential as a chart.

Returns:
The current potential as a chart.

equals

public boolean equals(Potential p)
Comparaison between the two implementation of probability potentials.

Parameters:
p - The probability potential to compare.
Returns:
true, if the two objects are equal by value.

getElements

public Element[] getElements()
Returns:
The array of semiring values that belongs to this potential.

getConfigurations

protected Configuration[] getConfigurations()
Returns:
The array of configurations within this potential.