/[escript]/trunk/escript/py_src/linearPDEs.py
ViewVC logotype

Diff of /trunk/escript/py_src/linearPDEs.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3402 by gross, Tue Dec 7 07:36:12 2010 UTC revision 3431 by gross, Fri Jan 7 01:19:21 2011 UTC
# Line 411  class SolverOptions(object): Line 411  class SolverOptions(object):
411          """          """
412          return self.__coarsening          return self.__coarsening
413                
414      def setMinCoarseMatrixSize(self,size=500):      def setMinCoarseMatrixSize(self,size=5000):
415          """          """
416          Sets the minumum size of the coarsest level matrix in AMG or AMLI          Sets the minumum size of the coarsest level matrix in AMG or AMLI
417    
# Line 707  class SolverOptions(object): Line 707  class SolverOptions(object):
707          :rtype: ``int``          :rtype: ``int``
708          """          """
709          return self.__sweeps          return self.__sweeps
710      def setNumPreSweeps(self,sweeps=2):      def setNumPreSweeps(self,sweeps=1):
711          """          """
712          Sets the number of sweeps in the pre-smoothing step of a multi level solver or preconditioner          Sets the number of sweeps in the pre-smoothing step of a multi level solver or preconditioner
713    
# Line 725  class SolverOptions(object): Line 725  class SolverOptions(object):
725          :rtype: ``int``          :rtype: ``int``
726          """          """
727          return self.__pre_sweeps          return self.__pre_sweeps
728      def setNumPostSweeps(self,sweeps=2):      def setNumPostSweeps(self,sweeps=1):
729          """          """
730          Sets the number of sweeps in the post-smoothing step of a multi level solver or preconditioner          Sets the number of sweeps in the post-smoothing step of a multi level solver or preconditioner
731    
# Line 1022  class SolverOptions(object): Line 1022  class SolverOptions(object):
1022      def setMinCoarseMatrixSparsity(self,sparsity=0.05):      def setMinCoarseMatrixSparsity(self,sparsity=0.05):
1023         """         """
1024         Sets the minimum sparsity on the coarsest level. Typically         Sets the minimum sparsity on the coarsest level. Typically
        a direct solver is used when the sparsity becomes bigger than  
        the set limit.  
         
        :param sparsity: minimual sparsity  
        :type sparsity: ``float``  
        """  
        sparsity=float(sparsity)  
        if factor<0:  
      raise ValueError,"sparsity must be non-negative."  
        if factor>1:  
            raise ValueError,"sparsity must be less than 1."  
        self.__min_sparsity=factor  
     def setMinCoarseMatrixSparsity(self,sparsity=0.05):  
        """  
        Sets the minimum sparsity on the coarsest level. Typically  
1025         a direct solver is used when the sparsity becomes bigger than         a direct solver is used when the sparsity becomes bigger than
1026         the set limit.         the set limit.
1027                

Legend:
Removed from v.3402  
changed lines
  Added in v.3431

  ViewVC Help
Powered by ViewVC 1.1.26