Class EquationSolverImpl

All Implemented Interfaces:
EquationSolver, Serializable, Remote

public class EquationSolverImpl extends UnicastRemoteObject implements EquationSolver
Instances of this remote class reside in a server JVM and perform the work of solving an equation of the form Ax = b.
See Also:
  • Constructor Details

  • Method Details

    • solve

      public double[] solve(double[][] matrix, double[] constants) throws RemoteException
      Use Cholesky's algorithm to solve a linear system of equations of the Ax = b.
      Specified by:
      solve in interface EquationSolver
      Parameters:
      matrix - The A in Ax = b
      constants - The b in Ax = b
      Throws:
      IllegalArgumentException - The number of rows and columns in the matrix are not the same
      RemoteException - Something went wrong while communicating with the server
    • main

      public static void main(String[] args)
      Main program that creates a new EquationSolverImpl and binds it into the RMI registry under a given name.