Subversion Repositories slepc-dev

Rev

Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2808 Rev 2815
Line 135... Line 135...
  *newps      = ps;
  *newps      = ps;
  ps->state   = PS_STATE_RAW;
  ps->state   = PS_STATE_RAW;
  ps->method  = 0;
  ps->method  = 0;
  ps->nmeth   = 1;
  ps->nmeth   = 1;
  ps->compact = PETSC_FALSE;
  ps->compact = PETSC_FALSE;
 
  ps->refined = PETSC_FALSE;
  ps->ld      = 0;
  ps->ld      = 0;
  ps->l       = 0;
  ps->l       = 0;
  ps->n       = 0;
  ps->n       = 0;
  ps->k       = 0;
  ps->k       = 0;
  for (i=0;i<PS_NUM_MAT;i++) {
  for (i=0;i<PS_NUM_MAT;i++) {
Line 414... Line 415...
{
{
  PetscFunctionBegin;
  PetscFunctionBegin;
  PetscValidHeaderSpecific(ps,PS_CLASSID,1);
  PetscValidHeaderSpecific(ps,PS_CLASSID,1);
  PetscValidPointer(comp,2);
  PetscValidPointer(comp,2);
  *comp = ps->compact;
  *comp = ps->compact;
 
  PetscFunctionReturn(0);
 
}
 
 
 
#undef __FUNCT__  
 
#define __FUNCT__ "PSSetRefined"
 
/*@
 
   PSSetRefined - Sets a flag to indicate that refined vectors must be
 
   computed.
 
 
 
   Logically Collective on PS
 
 
 
   Input Parameter:
 
+  ps  - the projected system context
 
-  ref - a boolean flag
 
 
 
   Notes:
 
   Normally the vectors returned in PS_MAT_X are eigenvectors of the
 
   projected matrix. With this flag activated, PSVectors() will return
 
   the right singular vector of the smallest singular value of matrix
 
   \tilde{A}-theta*I, where \tilde{A} is the extended (n+1)xn matrix
 
   and theta is the Ritz value. This is used in the refined Ritz
 
   approximation.
 
 
 
   The default is PETSC_FALSE.
 
 
 
   Level: advanced
 
 
 
.seealso: PSVectors(), PSGetRefined()
 
@*/
 
PetscErrorCode PSSetRefined(PS ps,PetscBool ref)
 
{
 
  PetscFunctionBegin;
 
  PetscValidHeaderSpecific(ps,PS_CLASSID,1);
 
  PetscValidLogicalCollectiveBool(ps,ref,2);
 
  ps->refined = ref;
 
  PetscFunctionReturn(0);
 
}
 
 
 
#undef __FUNCT__  
 
#define __FUNCT__ "PSGetRefined"
 
/*@
 
   PSGetRefined - Gets the refined vectors flag.
 
 
 
   Not Collective
 
 
 
   Input Parameter:
 
.  ps - the projected system context
 
 
 
   Output Parameter:
 
.  comp - the flag
 
 
 
   Level: advanced
 
 
 
.seealso: PSSetRefined()
 
@*/
 
PetscErrorCode PSGetRefined(PS ps,PetscBool *ref)
 
{
 
  PetscFunctionBegin;
 
  PetscValidHeaderSpecific(ps,PS_CLASSID,1);
 
  PetscValidPointer(ref,2);
 
  *ref = ps->refined;
  PetscFunctionReturn(0);
  PetscFunctionReturn(0);
}
}
 
 
#undef __FUNCT__  
#undef __FUNCT__  
#define __FUNCT__ "PSSetFromOptions"
#define __FUNCT__ "PSSetFromOptions"