Hello,
I would like to save my mesh into # vtk DataFile Version 2.0 , is this possible? when I save in legacy vtk i dont get the option to save in specific version (similar export to the one of gmsh)
thanks in advance.
Indeed, you cannot.
But 2.0 is a pretty old version of a legacy format, I would not advise to use it anymore. Can’t you use another file format?
Sadly it is a library that reads in that format. So I need that exact format
Well, VTK format 2.0 version is obsolete since january 2000, even before the first release of ParaView …
So I think you should ask community from your other lib about which other file format are available, or about they create such files nowadays.
Also, as it is a textual file format, you can maybe find some doc and write that by your own ?
I did already (well in Salome python instead of paraview) but I thought that if the function was available in paraview it would be much much more efficient than mine as I have not the same level of programing as you
Thanks in any case!
FWIW, OpenFOAM v2412 sampling still outputs in that format. An example below is obtained by sampling the velocity across a line in an OpenFOAM simulation.
# vtk DataFile Version 2.0
time='0.00138462'
ASCII
DATASET POLYDATA
FIELD FieldData 1
TimeValue 1 1 float
0.00138462
POINTS 20 float
5 -3 0.1 5 -2.68421 0.1 5 -2.36842 0.1 5 -2.05263 0.1 5 -1.73684 0.1 5 -1.42105 0.1 5 -1.10526 0.1 5 -0.789474 0.1 5 -0.473684 0.1 5 -0.157895 0.1 5 0.157895 0.1 5 0.473684 0.1 5 0.789474 0.1 5 1.10526 0.1 5 1.42105 0.1 5 1.73684 0.1 5 2.05263 0.1 5 2.36842 0.1 5 2.68421 0.1 5 3 0.1 POINT_DATA 20 FIELD FieldData 1 U 3 20 float 7.01593 0.0299716 1.31712e-22 7.01191 0.032542 -1.05369e-23 7.0074 0.0344083 1.11786e-23 7.00239 0.0356011 7.16873e-25 6.99685 0.0359133 4.09175e-24 6.99122 0.035258 3.66502e-24 6.9856 0.0335462 -2.95632e-22 6.98025 0.0306781 1.31733e-22 6.97549 0.0267164 4.33298e-22 6.97158 0.0218567 2.16204e-22 6.96868 0.0163384 1.50871e-23 6.96691 0.0103733 4.48036e-25 6.96646 0.00421344 -1.48477e-23 6.96743 -0.00182494 -2.31256e-22 6.96972 -0.00738835 1.29976e-21 6.97306 -0.0122105 -3.10159e-22 6.97727 -0.0161784 -2.12576e-22 6.98187 -0.0188964 1.88847e-22 6.98667 -0.0205251 -1.03502e-22 6.99146 -0.0210504 9.1733e-23
I’m able to load this file in ParaView 5.13.2 without any issues.