It looks like you are hitting the floating point limits someplace. The first thing to notice is that just because you ask for an rtol of 1.e-200 does not mean that you are going to get it. Use -ksp_monitor to see what you are really getting.
On Oct 1, 2012, at 5:06 PM, Chetan Jhurani <chetan.jhurani at gmail.com> wrote: > Hi, > > I'm using petsc-dev to solve the 1D heat equation > > u_t = u_xx in [-1,1] > > with zero boundary conditions and u_initial = sin(pi x). > The exact solution decays to 0. The exact > log10(norm_inf(u)) is a linear function of t. > > I use the standard 1D hat basis functions on a uniform > mesh to discretize. The mass matrix remains tri-diagonal. > > When using TS with TSTHETA (or TSBEULER) and exact linear > solves (PCLU), the FEM log10(norm_inf(u)) follows the exact > curve for around 4500 time steps and then gradually, > over a few hundred time-steps, changes slope. > > See attached figure. x axis is step number. The code is > attached too. > > The results were obtained using > -ksp_type preonly -pc_type lu -ksp_atol 1e-200 -ksp_rtol 1e-200 > > The 1e-200 tolerances were added just to be way below the > norm scales in the problem above. > > Questions: > > Is it a bug in my code or is there another good explanation? > > Do I need to turn on some tolerance related option to see > the exact convergence behavior for more time steps? > > Chetan > > <ts_test.cpp><log_u_inf.png>
