Class TrialPoint

java.lang.Object
xal.extension.solver.TrialPoint
Direct Known Subclasses:
MutableTrialPoint

public class TrialPoint extends Object
TrialPoint is a collection of variables and values for those variables.
Author:
ky6, t6p
  • Field Details

    • values

      protected final Map<Variable,Number> values
      A table of trial values keyed by variable
  • Constructor Details

    • TrialPoint

      public TrialPoint(Map<Variable,Number> values)
      Primary constructor.
      Parameters:
      values - The new values used to map trial points
    • TrialPoint

      public TrialPoint(TrialPoint trialPoint)
      Copy constructor.
      Parameters:
      trialPoint - the trial point to copy
  • Method Details

    • getValue

      public double getValue(Variable variable)
      Get the value corresponding to the specified variable.
      Parameters:
      variable - The variable for which to fetch the value.
      Returns:
      The value of the specified variable.
    • getValueMap

      public Map<Variable,Number> getValueMap()
      Get the map of variable/value pairs.
      Returns:
      the map of variable/value pairs.
    • toString

      public String toString()
      A string for displaying a trial point. The string consist of the values for the trial point.
      Overrides:
      toString in class Object
      Returns:
      The string representation of a trial point.