Opus5
Class ScalesBalancingProblem

java.lang.Object
  |
  +--Opus5.ScalesBalancingProblem

public class ScalesBalancingProblem
extends java.lang.Object

Represents a scales balancing problem.

Version:
$Id: ScalesBalancingProblem.java,v 3.2 1998/07/28 20:03:35 brpreiss Exp $
Author:
Bruno R. Preiss, P.Eng.

Inner Class Summary
protected  class ScalesBalancingProblem.Node
          A node in the solution space of a scales balancing problem.
 
Field Summary
protected  int numberOfWeights
          The number of weights.
protected  int[] weight
          The array of weights.
 
Constructor Summary
ScalesBalancingProblem(int[] weight)
          Constructs a ScalesBalancingProblem for the specified array of weights.
 
Method Summary
 Solution solve(Solver solver)
          Solves this scales-balancing problem using the specified solver.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

numberOfWeights

protected int numberOfWeights
The number of weights.

weight

protected int[] weight
The array of weights.
Constructor Detail

ScalesBalancingProblem

public ScalesBalancingProblem(int[] weight)
Constructs a ScalesBalancingProblem for the specified array of weights.
Parameters:
weight - An array of weights.
Method Detail

solve

public Solution solve(Solver solver)
Solves this scales-balancing problem using the specified solver.
Parameters:
solver - The solver to use.
Returns:
The solution to this scales-balancing problem.