<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">&nbsp;&nbsp;<div>&nbsp;&nbsp; Run with -ts_view &nbsp; it is likely running with the default explicit method Euler which requires no solver and hence no preconditioner. You need to use an implicit method if you want to use it with a preconditioner.</div><div><br></div><div>&nbsp;&nbsp; &nbsp;Barry</div><div><br><div><div>On Jun 28, 2010, at 3:27 PM, Xuan YU wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On Jun 28, 2010, at 4:17 PM, Barry Smith wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div><br>On Jun 28, 2010, at 3:13 PM, Xuan YU wrote:<br><br><blockquote type="cite"><br></blockquote><blockquote type="cite">On Jun 28, 2010, at 3:47 PM, Barry Smith wrote:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"> Do you have a TSSetFromOptions() or a SNESSetFromOptions() or a KSPSetFromOptions() or a PCSetFromOptions(). If not then the option never gets processed and used.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite">I only have &nbsp;ierr = TSSetFromOptions(ts);CHKERRQ(ierr).<br></blockquote><br> &nbsp;&nbsp;That is fine, that calls PCSetFromOptions() and should process your option. Perhaps you set a prefix for the TS that you need in setting the preconditioner type.<br><br></div></blockquote>This is the petsc code:<br><div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSCreate(PETSC_COMM_WORLD,&amp;ts);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSSetProblemType(ts,TS_NONLINEAR);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSMonitorSet(ts,Monitor,&amp;appctx,PETSC_NULL);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSSetSolution(ts,CV_Y);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSSetRHSFunction(ts,f,&amp;appctx);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSSetInitialTimeStep(ts,0,1.0);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSSetDuration(ts,cData.EndTime,cData.EndTime);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSSetFromOptions(ts);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSSetUp(ts);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSStep(ts,&amp;its,&amp;ftime);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = VecDestroy(CV_Y);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = TSDestroy(ts);CHKERRQ(ierr);</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;ierr = PetscFinalize();CHKERRQ(ierr);</div><div><br></div></div><div><br></div><br><blockquote type="cite"><div> &nbsp;&nbsp;Barry<br><br><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><blockquote type="cite"> Barry<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">On Jun 28, 2010, at 2:24 PM, Xuan YU wrote:<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Hi,<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">I run my code by ./xxx -pc_type icc<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">But it says:<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">WARNING! There are options you set that were not used!<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">WARNING! could be spelling mistake, etc!<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Option left: name:-pc_type value: icc<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Could you please tell me what happened?<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Xuan YU<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><a href="mailto:xxy113@psu.edu">xxy113@psu.edu</a><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><br><br></div></blockquote></div><br><div apple-content-edited="true"> <div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>Xuan YU (<span class="Apple-style-span" style="font-family: arial; font-size: 16px; white-space: pre; ">俞烜<span class="Apple-style-span" style="font-family: Helvetica; font-size: medium; white-space: normal; ">)</span></span></div><div><a href="mailto:xxy113@psu.edu">xxy113@psu.edu</a></div><div><br></div></div></span><br class="Apple-interchange-newline"></div><br class="Apple-interchange-newline"> </div><br></div></blockquote></div><br></div></body></html>