Actual source code: stimpl.h

  2: #ifndef _STIMPL
  3: #define _STIMPL

 5:  #include slepceps.h


 10: typedef struct _STOps *STOps;

 12: struct _STOps {
 13:   int          (*setup)(ST);
 14:   int          (*apply)(ST,Vec,Vec);
 15:   int          (*applyB)(ST,Vec,Vec);
 16:   int          (*applynoB)(ST,Vec,Vec);
 17:   int          (*applytrans)(ST,Vec,Vec);
 18:   int          (*setshift)(ST,PetscScalar);
 19:   int          (*setfromoptions)(ST);
 20:   int          (*postsolve)(ST);
 21:   int          (*backtr)(ST,PetscScalar*,PetscScalar*);
 22:   int          (*destroy)(ST);
 23:   int          (*view)(ST,PetscViewer);
 24: };

 26: struct _p_ST {
 27:   PETSCHEADER(struct _STOps);
 28:   /*------------------------- User parameters --------------------------*/
 29:   Mat            A,B;              /* Matrices which define the eigensystem */
 30:   PetscScalar    sigma;            /* Value of the shift */
 31:   STMatMode      shift_matrix;
 32:   STBilinearForm bilinear_form;
 33:   MatStructure   str;          /* whether matrices have the same pattern or not */
 34:   Mat            mat;

 36:   /*------------------------- Misc data --------------------------*/
 37:   KSP          ksp;
 38:   Vec          w;
 39:   void         *data;
 40:   int          setupcalled;
 41:   int          lineariterations;
 42:   int          applys;
 43:   int          innerproducts;
 44:   int          (*checknullspace)(ST,int,const Vec[]);
 45: 
 46:   /*------------------------- Cache Bx product -------------------*/
 47:   PetscInt       xid;
 48:   PetscInt       xstate;
 49:   Vec            Bx;
 50: };

 52: EXTERN PetscErrorCode STRegisterAll(char*);
 53: EXTERN PetscErrorCode STRegister(const char*,const char*,const char*,int(*)(ST));
 54: #if defined(PETSC_USE_DYNAMIC_LIBRARIES)
 55: #define STRegisterDynamic(a,b,c,d) STRegister(a,b,c,0)
 56: #else
 57: #define STRegisterDynamic(a,b,c,d) STRegister(a,b,c,d)
 58: #endif

 60: EXTERN PetscErrorCode STApplyB_Default(ST,Vec,Vec);
 61: EXTERN PetscErrorCode STView_Default(ST,PetscViewer);
 62: EXTERN PetscErrorCode STAssociatedKSPSolve(ST,Vec,Vec);
 63: EXTERN PetscErrorCode STAssociatedKSPSolveTranspose(ST,Vec,Vec);
 64: EXTERN PetscErrorCode STCheckNullSpace_Default(ST,int,const Vec[]);
 65: EXTERN PetscErrorCode STMatShellCreate(ST st,Mat *mat);

 67: #endif