Read vtk files (created from paraview) into Matlab
193 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Ying Wu
el 4 de Dic. de 2022
Comentada: Ying Wu
el 4 de Dic. de 2022
Hi, I have many vtk files storing the velocity field information, which is created in Paraview. Now I want to import them into Matlab to do the proper orthogonal decomposition, so I need to convert the data into matrix. Is there any way to read the raw data files with the format of VTK into Matlab? Thanks!!
File format is unsupported for uploading, but it has the following structure:
# vtk DataFile Version 2.0
sampleSurface
ASCII
DATASET POLYDATA
POINTS 65994 double
-8.48e-09 -0.494167 2.49037e-18
-0.020125 -0.493765 -7.0605e-18
0.020125 -0.493765 -4.2448e-18
-0.0402182 -0.492564 3.31633e-18
0.0402182 -0.492564 2.02627e-18
-0.0602486 -0.490573 6.79711e-18
....
POLYGONS 130656 522624
3 62271 62194 62506
3 62398 62506 62194
3 62562 62341 62387
3 62562 62387 62506
3 62271 62387 62341
...
POINT_DATA 65994
FIELD attributes 1
vorticity 3 65994 float
-3.96689e-21 -1.08047e-19 6.97702
8.57664e-19 -2.68243e-19 7.95412
-6.37119e-19 -2.19501e-19 6.03446
-3.00809e-19 -1.42912e-19 8.96011
....
0 comentarios
Respuesta aceptada
Walter Roberson
el 4 de Dic. de 2022
See https://www.mathworks.com/matlabcentral/fileexchange/106610-vtk-read-and-write-package or https://www.mathworks.com/matlabcentral/fileexchange/94993-vtktoolbox for an interface to the official VTK library
Más respuestas (0)
Ver también
Categorías
Más información sobre Point Cloud Processing en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!