Changeset 6858


Ignore:
Timestamp:
12/29/10 18:46:37 (14 years ago)
Author:
Eric.Larour
Message:

Starting migration towards petsc solver options of version 3. Almost done with mumps.

Location:
issm/trunk/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/c/modules/Solverx/Solverx.cpp

    r6852 r6858  
    3232
    3333        #if _PETSC_VERSION_ == 3
    34         const MatType type;
     34        char ksp_type[50];
     35        PetscTruth flg;
    3536        #endif
    3637
     
    4748        /*Now, check that we are not getting an initial guess to the solver, if we are running a direct solver: */
    4849        #if _PETSC_VERSION_ == 3
    49         MatGetType(Kff,&type);
    50         if (strcmp(type,"mpidense")==0)uf0=NULL;
     50        PetscOptionsGetString(PETSC_NULL,"-ksp_type",ksp_type,49,&flg);
     51        if (strcmp(ksp_type,"preonly")==0)uf0=NULL;
    5152        #endif
    5253       
  • issm/trunk/src/m/model/solvers/mumpsoptions.m

    r6855 r6858  
    1515end
    1616if PETSC_VERSION==3,
    17 options={{'mat_type','mpidense'},{'ksp_type','preonly'},{'pc_type','lu'},{'mat_mumps_icntl_14',120},{'pc_factor_shift_positive_definite','true'}};
     17        options={{'mat_type','mpiaij'},{'ksp_type','preonly'},{'pc_type','lu'},{'pc_factor_mat_solver_package','mumps'},{'mat_mumps_icntl_14',120},{'pc_factor_shift_positive_definite','true'}};
     18
    1819end
    1920
Note: See TracChangeset for help on using the changeset viewer.