Date: 2015-09-03T15:06:20+00:00

Actual source code: rgimpl.h
slepc-3.6.1 2015-09-03
Report Typos and Errors

      1: /*
      2:    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
      3:    SLEPc - Scalable Library for Eigenvalue Problem Computations
      4:    Copyright (c) 2002-2015, Universitat Politecnica de Valencia, Spain

      6:    This file is part of SLEPc.

      8:    SLEPc is free software: you can redistribute it and/or modify it under  the
      9:    terms of version 3 of the GNU Lesser General Public License as published by
     10:    the Free Software Foundation.

     12:    SLEPc  is  distributed in the hope that it will be useful, but WITHOUT  ANY
     13:    WARRANTY;  without even the implied warranty of MERCHANTABILITY or  FITNESS
     14:    FOR  A  PARTICULAR PURPOSE. See the GNU Lesser General Public  License  for
     15:    more details.

     17:    You  should have received a copy of the GNU Lesser General  Public  License
     18:    along with SLEPc. If not, see <http://www.gnu.org/licenses/>.
     19:    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
     20: */

     22: #if !defined(_RGIMPL)
     23: #define _RGIMPL

     25: #include <slepcrg.h>
     26: #include <slepc/private/slepcimpl.h>

     28: PETSC_EXTERN PetscBool RGRegisterAllCalled;
     29: PETSC_EXTERN PetscErrorCode RGRegisterAll(void);

     31: typedef struct _RGOps *RGOps;

     33: struct _RGOps {
     34:   PetscErrorCode (*istrivial)(RG,PetscBool*);
     35:   PetscErrorCode (*computecontour)(RG,PetscInt,PetscScalar*,PetscScalar*);
     36:   PetscErrorCode (*checkinside)(RG,PetscReal,PetscReal,PetscInt*);
     37:   PetscErrorCode (*setfromoptions)(PetscOptions*,RG);
     38:   PetscErrorCode (*view)(RG,PetscViewer);
     39:   PetscErrorCode (*destroy)(RG);
     40: };

     42: struct _p_RG {
     43:   PETSCHEADER(struct _RGOps);
     44:   PetscBool   complement;    /* region is the complement of the specified one */
     45:   PetscReal   sfactor;       /* scaling factor */
     46:   void        *data;
     47: };

     49: /* show an inf instead of PETSC_MAX_REAL */
     50: #define RGShowReal(r) (double)((PetscAbsReal(r)>=PETSC_MAX_REAL)?10*(r):(r))

     52: #endif