I did it but received this Error when I want to change the level of fill for PCILU:
[0]PETSC ERROR: --------------------- Error Message ------------------------------------ [0]PETSC ERROR: Object is in wrong state! [0]PETSC ERROR: Cannot change levels after use! [0]PETSC ERROR: ------------------------------------------------------------------------ On Mon, Oct 31, 2011 at 2:19 PM, Matthew Knepley <knepley at gmail.com> wrote: > On Mon, Oct 31, 2011 at 8:55 AM, behzad baghapour < > behzad.baghapour at gmail.com> wrote: > >> Dear all, >> >> I'm using KSP iteration (for now) to solve my nonlinear problem and >> handling Newton Iterations manually. Here I want to change the PC method >> from some specified KSP iteration. How should I do it correctly in Petsc? >> > > Call PCSetType() and then KSPSetOperators() again in your loop > > Matt > > >> Thanks, B.B. >> >> -- >> ================================== >> Behzad Baghapour >> Ph.D. Candidate, Mechecanical Engineering >> University of Tehran, Tehran, Iran >> https://sites.google.com/site/behzadbaghapour >> Fax: 0098-21-88020741 >> ================================== >> >> > > > -- > What most experimenters take for granted before they begin their > experiments is infinitely more interesting than any results to which their > experiments lead. > -- Norbert Wiener > -- ================================== Behzad Baghapour Ph.D. Candidate, Mechecanical Engineering University of Tehran, Tehran, Iran https://sites.google.com/site/behzadbaghapour Fax: 0098-21-88020741 ================================== -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20111031/e3320300/attachment.htm>