Package edu.pdx.cs410J.rmi
Class EquationSolverImpl
java.lang.Object
java.rmi.server.RemoteObject
java.rmi.server.RemoteServer
java.rmi.server.UnicastRemoteObject
edu.pdx.cs410J.rmi.EquationSolverImpl
- All Implemented Interfaces:
EquationSolver
,Serializable
,Remote
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:
-
Field Summary
Fields inherited from class java.rmi.server.RemoteObject
ref
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
Main program that creates a newEquationSolverImpl
and binds it into the RMI registry under a given name.double[]
solve
(double[][] matrix, double[] constants) Use Cholesky's algorithm to solve a linear system of equations of theAx = b
.Methods inherited from class java.rmi.server.UnicastRemoteObject
clone, exportObject, exportObject, exportObject, exportObject, exportObject, unexportObject
Methods inherited from class java.rmi.server.RemoteServer
getClientHost, getLog, setLog
-
Constructor Details
-
EquationSolverImpl
Creates a newEquationSolverImpl
. InvokesUnicastRemoteObject's
constructor to register this object with the RMI runtime.- Throws:
RemoteException
-
-
Method Details
-
solve
Use Cholesky's algorithm to solve a linear system of equations of theAx = b
.- Specified by:
solve
in interfaceEquationSolver
- Parameters:
matrix
- TheA
inAx = b
constants
- Theb
inAx = b
- Throws:
IllegalArgumentException
- The number of rows and columns in the matrix are not the sameRemoteException
- Something went wrong while communicating with the server
-
main
Main program that creates a newEquationSolverImpl
and binds it into the RMI registry under a given name.
-