You can do it with the command line option "-options_left 0"

2017-07-31 12:27 GMT+03:00 Guido Giuntoli <[email protected]>:

> Hi, I have a program with the following structure
>
> ...
> PETSC_COMM_WORLD = WORLD_COMM;
> ierr = PetscInitialize(&argc,&argv,(char*)0,help);
> ierr = PetscOptionsGetBool(NULL, NULL, "-flag", &flag, &set);
> CHKERRQ(ierr);
> ...
> ierr = PetscFinalize();
> PETSC_COMM_WORLD = ANOTHER_COMM;
> ierr = PetscInitialize(&argc,&argv,(char*)0,help);
> ...
> ierr = PetscFinalize();
> ...
>
> The problem I want to avoid is PETSc to print
>
> "WARNING! There are options you set that were not used!"
>
> In the first part I use some options of the command line and in the second
> I am going to use others like the -ksp_xxxx. Which is the good way of
> avoiding that without touching petsc code ?
>
> Thanks, Guido.
>



-- 
Stefano

Reply via email to