<div dir="ltr">Hi Jed,<div><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Oct 30, 2014 at 9:22 PM, Jed Brown <span dir="ltr"><<a href="mailto:jed@jedbrown.org" target="_blank">jed@jedbrown.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><span class="">Gautam Bisht <<a href="mailto:gbisht@lbl.gov">gbisht@lbl.gov</a>> writes:<br>
<br>
> All,<br>
><br>
> While running src/ts/examples/tutorials/ex8.c (in PETSc 3.5.1) for TSTYPE<br>
> sundials and pseudo, I noticed that the solver overshoots the final time.<br>
<br>
</span>Is this what you're looking for?<br>
<br>
<a href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/TS/TSSetExactFinalTime.html" target="_blank">http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/TS/TSSetExactFinalTime.html</a></blockquote><div><br></div><div>Yes. But it appears only '-ts_exact_final_time INTERPOLATE' for '-ts_type sundials' does not overshoot the final time.</div><div><br></div><div><div>./ex8 -ts_monitor -ts_type pseudo -ts_final_time 0.01 -ts_exact_final_time STEPOVER</div><div>0 TS dt 0.001 time 0</div><div>1 TS dt 0.0011 time 0.0011</div><div>2 TS dt 0.00122331 time 0.00232331</div><div>3 TS dt 0.00136211 time 0.00368542</div><div>4 TS dt 0.00151873 time 0.00520415</div><div>5 TS dt 0.00169599 time 0.00690014</div><div>6 TS dt 0.00189725 time 0.00879739</div><div>7 TS dt 0.0021266 time 0.010924</div><div>steps 7 (0 rejected, 0 SNES fails), ftime 0.010924, nonlinits 7, linits 7</div><div>step 7 t=1.09239877e-02 h= 2.13e-03 |x|= 1.03e-01 |x_e|= 1.03e-01 |x-x_e|= 7.93e-04</div><div><br></div><div>./ex8 -ts_monitor -ts_type pseudo -ts_final_time 0.01 -ts_exact_final_time MATCHSTEP</div><div>0 TS dt 0.001 time 0</div><div>1 TS dt 0.0011 time 0.0011</div><div>2 TS dt 0.00122331 time 0.00232331</div><div>3 TS dt 0.00136211 time 0.00368542</div><div>4 TS dt 0.00151873 time 0.00520415</div><div>5 TS dt 0.00169599 time 0.00690014</div><div>6 TS dt 0.00189725 time 0.00879739</div><div>7 TS dt 0.0021266 time 0.010924</div><div>steps 7 (0 rejected, 0 SNES fails), ftime 0.010924, nonlinits 7, linits 7</div><div>step 7 t=1.09239877e-02 h= 2.13e-03 |x|= 1.03e-01 |x_e|= 1.03e-01 |x-x_e|= 7.93e-04</div><div><br></div><div>./ex8 -ts_monitor -ts_type pseudo -ts_final_time 0.01 -ts_exact_final_time INTERPOLATE</div><div>0 TS dt 0.001 time 0</div><div>1 TS dt 0.0011 time 0.0011</div><div>2 TS dt 0.00122331 time 0.00232331</div><div>3 TS dt 0.00136211 time 0.00368542</div><div>4 TS dt 0.00151873 time 0.00520415</div><div>5 TS dt 0.00169599 time 0.00690014</div><div>6 TS dt 0.00189725 time 0.00879739</div><div>[0]PETSC ERROR: --------------------- Error Message --------------------------------------------------------------</div><div>[0]PETSC ERROR: No support for this operation for this object type</div><div>[0]PETSC ERROR: pseudo does not provide interpolation</div><div>[0]PETSC ERROR: See <a href="http://www.mcs.anl.gov/petsc/documentation/faq.html">http://www.mcs.anl.gov/petsc/documentation/faq.html</a> for trouble shooting.</div><div>[0]PETSC ERROR: Petsc Release Version 3.5.1, unknown </div><div>[0]PETSC ERROR: ./ex8 on a darwin-gnu-fort-debug named <a href="http://gmbook.dhcp.lbnl.us">gmbook.dhcp.lbnl.us</a> by gbisht Fri Oct 31 09:44:36 2014</div><div>[0]PETSC ERROR: Configure options -with-hdf5-dir=/opt/local/ --with-blas-lapack-lib=/System/Library/Frameworks/Accelerate.framework/Versions/Current/Accelerate --download-parmetis=yes --download-metis=yes --download-sundials=yes --with-mpich=/opt/local --with-cc=/opt/local/bin/mpicc-mpich-gcc48 --with-cxx=/opt/local/bin/mpicxx-mpich-gcc48 --with-fc=/opt/local/bin/mpifort-mpich-gcc48 PETSC_ARCH=darwin-gnu-fort-debug --download-sowing=1</div><div>[0]PETSC ERROR: #1 TSInterpolate() line 2582 in /Users/gbisht/Research/Models/PETSc/petsc3.5.1/src/ts/interface/ts.c</div><div>[0]PETSC ERROR: #2 TSSolve() line 2763 in /Users/gbisht/Research/Models/PETSc/petsc3.5.1/src/ts/interface/ts.c</div><div>[0]PETSC ERROR: #3 main() line 436 in /Users/gbisht/Research/Models/PETSc/petsc3.5.1/src/ts/examples/tutorials/ex8.c</div><div>[0]PETSC ERROR: ----------------End of Error Message -------send entire error message to petsc-maint@mcs.anl.gov----------</div><div>application called MPI_Abort(MPI_COMM_WORLD, 56) - process 0</div><div><br></div><div>./ex8 -ts_monitor -ts_type sundials -ts_final_time 0.01 -ts_exact_final_time STEPOVER</div><div>0 TS dt 0.001 time 0</div><div>1 TS dt 0.0001 time 0.0001</div><div>2 TS dt 0.0001 time 0.0002</div><div>3 TS dt 0.0001 time 0.0003</div><div>4 TS dt 0.000199571 time 0.000499571</div><div>5 TS dt 0.000199571 time 0.000699141</div><div>6 TS dt 0.000199571 time 0.000898712</div><div>7 TS dt 0.000199571 time 0.00109828</div><div>8 TS dt 0.000404911 time 0.00150319</div><div>9 TS dt 0.000804269 time 0.00230746</div><div>10 TS dt 0.00141825 time 0.00372572</div><div>11 TS dt 0.00141825 time 0.00514397</div><div>12 TS dt 0.00141825 time 0.00656222</div><div>13 TS dt 0.00141825 time 0.00798047</div><div>14 TS dt 0.00141825 time 0.00939873</div><div>15 TS dt 0.00193698 time 0.0113357</div><div>steps 15 (0 rejected, 0 SNES fails), ftime 0.0113357, nonlinits 18, linits 18</div><div>step 15 t=1.13357082e-02 h= 1.94e-03 |x|= 1.07e-01 |x_e|= 1.07e-01 |x-x_e|= 2.57e-06</div><div><br></div><div>./ex8 -ts_monitor -ts_type sundials -ts_final_time 0.01 -ts_exact_final_time MATCHSTEP</div><div>0 TS dt 0.001 time 0</div><div>1 TS dt 0.0001 time 0.0001</div><div>2 TS dt 0.0001 time 0.0002</div><div>3 TS dt 0.0001 time 0.0003</div><div>4 TS dt 0.000199571 time 0.000499571</div><div>5 TS dt 0.000199571 time 0.000699141</div><div>6 TS dt 0.000199571 time 0.000898712</div><div>7 TS dt 0.000199571 time 0.00109828</div><div>8 TS dt 0.000404911 time 0.00150319</div><div>9 TS dt 0.000804269 time 0.00230746</div><div>10 TS dt 0.00141825 time 0.00372572</div><div>11 TS dt 0.00141825 time 0.00514397</div><div>12 TS dt 0.00141825 time 0.00656222</div><div>13 TS dt 0.00141825 time 0.00798047</div><div>14 TS dt 0.00141825 time 0.00939873</div><div>15 TS dt 0.00193698 time 0.0113357</div><div>steps 15 (0 rejected, 0 SNES fails), ftime 0.0113357, nonlinits 18, linits 18</div><div>step 15 t=1.13357082e-02 h= 1.94e-03 |x|= 1.07e-01 |x_e|= 1.07e-01 |x-x_e|= 2.57e-06</div><div><br></div><div>./ex8 -ts_monitor -ts_type sundials -ts_final_time 0.01 -ts_exact_final_time INTERPOLATE</div><div>0 TS dt 0.001 time 0</div><div>1 TS dt 0.0001 time 0.0001</div><div>2 TS dt 0.0001 time 0.0002</div><div>3 TS dt 0.0001 time 0.0003</div><div>4 TS dt 0.000199571 time 0.000499571</div><div>5 TS dt 0.000199571 time 0.000699141</div><div>6 TS dt 0.000199571 time 0.000898712</div><div>7 TS dt 0.000199571 time 0.00109828</div><div>8 TS dt 0.000404911 time 0.00150319</div><div>9 TS dt 0.000804269 time 0.00230746</div><div>10 TS dt 0.00141825 time 0.00372572</div><div>11 TS dt 0.00141825 time 0.00514397</div><div>12 TS dt 0.00141825 time 0.00656222</div><div>13 TS dt 0.00141825 time 0.00798047</div><div>14 TS dt 0.00141825 time 0.00939873</div><div>15 TS dt 0.00193698 time 0.01</div><div>steps 15 (0 rejected, 0 SNES fails), ftime 0.01, nonlinits 18, linits 18</div><div>step 15 t=1.00000000e-02 h= 1.94e-03 |x|= 9.52e-02 |x_e|= 9.52e-02 |x-x_e|= 2.11e-06</div><div><br></div></div><div>-Gautam.</div><div> </div></div><br></div></div>