From: Subramanya Gautam Sadasiva <ssadasiv@pu...>  20130225 20:40:32

Hi, I am trying to use SNESSetPrefix to set a name to the solver to set options for the solver. I do this by deriving from TransientNonlinearImplicitSystem and I do PetscDMNonlinearSolver<Number>* petsc_solver = new PetscDMNonlinearSolver<Number> (*this); // Attach the R & J calculation object petsc_solver>residual_object = this; petsc_solver>jacobian_object = this; // Attach the bounds calculation object petsc_solver>bounds_object = this; // Get a petsc error . this is an alias for a integer PetscErrorCode ierr; petsc_solver>PetscNonlinearSolver<Number>::init(); // The prefix is ch_solve_. I need to figure out how to // put it into the documentation ierr = SNESSetOptionsPrefix(petsc_solver>_snes,"ch_solve_"); in the constructor. This setting lasts for the first call to solve(). However  when I call the solver the second time, all the options are lost. Am I doing something wrong? Do I need to do something else to prevent the solver from being completely reinitialized. Thanks, Subramanya Sadasiva "But memory eventually fades. Turbulences damp out, internal strains yield to plastic flow, concentration inhomogeneities diffuse to uniformity. Systems tend to subside to very simple states,independent of their specific history." Herbert Callen . Thermodynamics and an Introduction to Thermostatics. 