edu.jhu.cs.cisst.algorithms.optimize.fmg.solver
Class SolverThroughSmoother

java.lang.Object
  extended by edu.jhu.cs.cisst.algorithms.optimize.fmg.solver.SolverThroughSmoother
All Implemented Interfaces:
Solver

public final class SolverThroughSmoother
extends java.lang.Object
implements Solver

Solve a PDE by iteratively applying a smoothing (i.e. relaxation) algorithm.

Author:
Gerald Loeffler (Gerald.Loeffler@univie.ac.at)

Constructor Summary
SolverThroughSmoother(Smoother smoother, double error)
          construct from smoother and allowed error.
 
Method Summary
 BoundaryGrid solve(ConstBoundaryGrid u, ConstNoBoundaryGrid f)
          implements method from Solver.
 void solveProper(ConstBoundaryGrid gOld, ConstBoundaryGrid gNew, int myNum, int totalNum)
          implements the parallel part of solve().
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SolverThroughSmoother

public SolverThroughSmoother(Smoother smoother,
                             double error)
construct from smoother and allowed error.

Parameters:
smoother - the object supplying the smoothing algorithm
error - the allowed error for the solution as a fraction of the true solution (0 < error < 1)
Method Detail

solve

public BoundaryGrid solve(ConstBoundaryGrid u,
                          ConstNoBoundaryGrid f)
implements method from Solver.

Specified by:
solve in interface Solver
Parameters:
u - the u
f - the f
Returns:
the boundary grid
See Also:
Solver.solve(edu.jhu.cs.cisst.algorithms.optimize.fmg.grid.ConstBoundaryGrid, edu.jhu.cs.cisst.algorithms.optimize.fmg.grid.ConstNoBoundaryGrid)

solveProper

public void solveProper(ConstBoundaryGrid gOld,
                        ConstBoundaryGrid gNew,
                        int myNum,
                        int totalNum)
implements the parallel part of solve().

Parameters:
gOld - the g old
gNew - the g new
myNum - the my num
totalNum - the total num