Ejemplo n.º 1
0
    def __init__(self,
                 keep_htpsit=True,
                 blocksize=None,
                 niter=3,
                 rtol=1e-16,
                 limit_lambda=False,
                 use_rayleigh=False,
                 trial_step=0.1):
        """Initialize RMM-DIIS eigensolver.

        Parameters:

        limit_lambda: dictionary
            determines if step length should be limited
            supported keys:
            'absolute':True/False limit the absolute value
            'upper':float upper limit for lambda
            'lower':float lower limit for lambda

        """

        Eigensolver.__init__(self, keep_htpsit, blocksize)
        self.niter = niter
        self.rtol = rtol
        self.limit_lambda = limit_lambda
        self.use_rayleigh = use_rayleigh
        if use_rayleigh:
            1 / 0
            self.blocksize = 1
        self.trial_step = trial_step
        self.first = True
Ejemplo n.º 2
0
 def __init__(self, niter=1, smin=None, normalize=True):
     Eigensolver.__init__(self)
     self.niter = niter
     if not smin is None:
         raise NotImplementedError("See https://trac.fysik.dtu.dk/projects/gpaw/ticket/248")
     self.smin = smin
     self.normalize = normalize
     self.orthonormalization_required = False
Ejemplo n.º 3
0
    def __init__(self, niter=1, smin=None, normalize=True):
        Eigensolver.__init__(self)
        self.niter = niter
        self.smin = smin
        self.normalize = normalize

        if smin is not None:
            raise NotImplementedError(
                'See https://trac.fysik.dtu.dk/projects/gpaw/ticket/248')

        self.orthonormalization_required = False
Ejemplo n.º 4
0
    def __init__(self, niter=4, rtol=0.30):
        """Construct conjugate gradient eigen solver.

        parameters:

        niter: int
            Maximum number of conjugate gradient iterations per band
        rtol: float
            If change in residual is less than rtol, iteration for band is
            not continued

        """
        Eigensolver.__init__(self)
        self.niter = niter
        self.rtol = rtol
        if extra_parameters.get('PK', False):
            self.orthonormalization_required = True
        else:
            self.orthonormalization_required = False
Ejemplo n.º 5
0
    def __init__(self, niter=4, rtol=0.30):
        """Construct conjugate gradient eigen solver.

        parameters:

        niter: int
            Maximum number of conjugate gradient iterations per band
        rtol: float
            If change in residual is less than rtol, iteration for band is
            not continued

        """
        Eigensolver.__init__(self)
        self.niter = niter
        self.rtol = rtol
        if extra_parameters.get('PK', False):
            self.orthonormalization_required = True
        else:
            self.orthonormalization_required = False
Ejemplo n.º 6
0
    def __init__(self, keep_htpsit=True, blocksize=10, niter=3, rtol=1e-16,
                 limit_lambda=False, use_rayleigh=False, trial_step=0.1):
        """Initialize RMM-DIIS eigensolver.

        Parameters:

        limit_lambda: dictionary
            determines if step length should be limited
            supported keys:
            'absolute':True/False limit the absolute value
            'upper':float upper limit for lambda
            'lower':float lower limit for lambda

        """

        Eigensolver.__init__(self, keep_htpsit, blocksize)
        self.niter = niter
        self.rtol = rtol
        self.limit_lambda = limit_lambda
        self.use_rayleigh = use_rayleigh
        if use_rayleigh:
            self.blocksize = 1
        self.trial_step = trial_step
        self.first = True
Ejemplo n.º 7
0
 def __init__(self, niter=4):
     Eigensolver.__init__(self)
     self.niter = niter
Ejemplo n.º 8
0
 def __init__(self, keep_htpsit=True, blocksize=10, fixed_trial_step=None):
     self.fixed_trial_step = fixed_trial_step
     Eigensolver.__init__(self, keep_htpsit, blocksize)
Ejemplo n.º 9
0
 def __init__(self, keep_htpsit=True, blocksize=1):
     Eigensolver.__init__(self, keep_htpsit, blocksize)
Ejemplo n.º 10
0
 def __init__(self, keep_htpsit=True, blocksize=10,
              fixed_trial_step=None):
     self.fixed_trial_step = fixed_trial_step
     Eigensolver.__init__(self, keep_htpsit, blocksize)
Ejemplo n.º 11
0
    def __init__(self, keep_htpsit=False):
        """Initialize direct eigensolver. """

        Eigensolver.__init__(self, keep_htpsit)