What I meant was that when I was using cout to print my solution vector, it was printed to 6 or 7 decimal only. I had a feeling that deal.ii was evaluating the results accurately to machine precision but it was truncating it to 6 or 7 decimals, when writing it to the vtk file or outputting it on the terminal. So I used set precision function when using the cout to print the solution vector. With setprecision, the values are printed accurately to machine precision. However, I was still unable to write the values accurately upto machine precision, to a vtk file. I will have a look at vtu format. Hope it will work.
Thanks Wasim Niyaz On Mon, 10 Oct, 2022, 7:22 pm Wolfgang Bangerth, <[email protected]> wrote: > On 10/10/22 07:48, Wasim Niyaz Munshi ce21d400 wrote: > > > > I used the setprecision function to output the result to desired > accuracy. > > Can you show how you actually do that? I don't think that deal.II > overrides > what you do, though I may be wrong. > > > > However, I noticed that deal.ii writes the output to vtk file only upto > > certain precision(6). > > Is there a way to write output to the vtk file according to required > precision? > > The easiest way may be to just use the VTU file format instead of the VTK > format. It is binary and so outputs as many digits as there are in a > 32-bit > floating point number. > > Best > W. > > > -- > ------------------------------------------------------------------------ > Wolfgang Bangerth email: [email protected] > www: http://www.math.colostate.edu/~bangerth/ > > -- > The deal.II project is located at http://www.dealii.org/ > For mailing list/forum options, see > https://groups.google.com/d/forum/dealii?hl=en > --- > You received this message because you are subscribed to a topic in the > Google Groups "deal.II User Group" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/dealii/8Ud1gkzUbNQ/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/dealii/9cddced1-732c-a340-2b8e-ea40b4747363%40colostate.edu > . > -- The deal.II project is located at http://www.dealii.org/ For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en --- You received this message because you are subscribed to the Google Groups "deal.II User Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/dealii/CAM8ps5CmC%3DDWDhC%3DiAha1Pgk1HFPSCSmtkiNEE5Yd22LmzSK8g%40mail.gmail.com.
