Interface SolverInterface

All Known Implementing Classes:
ModularSolver, ParallelSolver, SimpleSolver, Solver

public interface SolverInterface
Interface for classes which define several methods every LinearSystemSolver object must support.
Author:
Michail Makaronidis, 2010
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the Timer object corresponding to this particular Solver.
    void
    goToULevel(int level)
    Sets matrices A and cleanA equal to the original A used during initialisation plus "level" increments in the positions needed.
    void
    Initialises the solver object.
    void
    initialise(BigRational[][] A, List<Tuple<Integer,Integer>> UList, Set<Integer> uncomputables)
    Initialises the solver object, taking into account a list of positions of A that may need to be updated when requested.
    Gaussian elimination linear system solver with partial pivoting.
  • Method Details

    • initialise

      void initialise(BigRational[][] A) throws OperationNotSupportedException
      Initialises the solver object.
      Parameters:
      A - The matrix A of the linear system Ax = b
      Throws:
      OperationNotSupportedException - Thrown when the matrix A is not square
    • initialise

      void initialise(BigRational[][] A, List<Tuple<Integer,Integer>> UList, Set<Integer> uncomputables) throws OperationNotSupportedException
      Initialises the solver object, taking into account a list of positions of A that may need to be updated when requested. This is needed by the MoM algorithm.
      Parameters:
      A - The matrix A of the linear system Ax = b
      UList - The list containing these positions as Tuple objects
      uncomputables - Set of the indices of possible zero-columns of A
      Throws:
      OperationNotSupportedException - Thrown when the matrix A is not square
    • goToULevel

      void goToULevel(int level)
      Sets matrices A and cleanA equal to the original A used during initialisation plus "level" increments in the positions needed. See how the MoM algorithm updates A during the iterations.
      Parameters:
      level - The number of applications with regard to the original A
    • solve

      Gaussian elimination linear system solver with partial pivoting.
      Parameters:
      b - The vector b of the linear system Ax = b
      Returns:
      A vector containing the solutions of the linear system
      Throws:
      OperationNotSupportedException - Thrown when the system cannot be solved due to bad vector b size
      InconsistentLinearSystemException - Thrown when the system cannot failed due to singularity.
      InternalErrorException - Thrown when an unrecoverable internal error has been detected by the solver.
    • getTimer

      Timer getTimer()
      Returns the Timer object corresponding to this particular Solver.
      Returns:
      The Timer object