Permalink
Browse files

Merge pull request #12872 from fdkong/petsc_external_app_petsc_3.6.x

Make ExternalPetscSolverApp compile with PETSc-3.6.x
  • Loading branch information...
permcody committed Feb 8, 2019
2 parents 638bd3a + 3140f51 commit 34faf5272d5ef6e1f676c4d226492e628be51a5f
Showing with 6 additions and 0 deletions.
  1. +6 −0 modules/external_petsc_solver/src/petscsolver/PETScDiffusionFDM.C
@@ -100,9 +100,15 @@ externalPETScDiffusionFDMSolve(TS ts, Vec u, PetscReal dt, PetscReal time)
ierr = TSGetDM(ts, &da);
CHKERRQ(ierr);

#if !PETSC_VERSION_LESS_THAN(3, 7, 0)
PetscOptionsSetValue(NULL, "-ts_monitor", NULL);
PetscOptionsSetValue(NULL, "-snes_monitor", NULL);
PetscOptionsSetValue(NULL, "-ksp_monitor", NULL);
#else
PetscOptionsSetValue("-ts_monitor", NULL);
PetscOptionsSetValue("-snes_monitor", NULL);
PetscOptionsSetValue("-ksp_monitor", NULL);
#endif

/*ierr = TSSetMaxTime(ts,1.0);CHKERRQ(ierr);*/
ierr = TSSetExactFinalTime(ts, TS_EXACTFINALTIME_STEPOVER);

0 comments on commit 34faf52

Please sign in to comment.