|
[Sponsors] |
[General] vtu file: first point is always set to zero |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
May 30, 2016, 11:58 |
vtu file: first point is always set to zero
|
#1 |
New Member
Join Date: May 2016
Posts: 2
Rep Power: 0 |
Dear Paraview users,
I wrote following vtu-file with python. It should generate two triangles. The problem is, when paraview reads the data, the coordinates of the first point (here: 25.0,25.0,0.0) are always set to zero, although the values are obviously not zero. Here is my vtu-file: Code:
<?xml version="1.0"?> <VTKFile type="UnstructuredGrid" version="0.1"> <UnstructuredGrid> <Piece NumberOfPoints=" 4 " NumberOfCells=" 2 "> <Points> <DataArray type="Float64" Name="nodes" NumberOfComponents=" 3" Format="ascii"> 2.5000000000005555E+01 2.5000000000005555E+01 0.0000000000000000E+00 -2.5000000000000000E+01 2.5000000000000000E+01 0.0000000000000000E+00 2.5000000000000000E+01 -2.5000000000000000E+01 0.0000000000000000E+00 -2.5000000000000000E+01 -2.5000000000000000E+01 0.0000000000000000E+00 </DataArray> </Points> <Cells> <DataArray type="Int32" Name="connectivity" NumberOfComponents=" 1" Format="ascii"> 1 2 4 4 3 1 </DataArray> <DataArray type="Int32" Name="offsets" NumberOfComponents=" 1" Format="ascii"> 3 6 </DataArray> <DataArray type="UInt8" Name="types" NumberOfComponents=" 1" Format="ascii"> 5 5 </DataArray> </Cells> <PointData> <DataArray type="Float64" Name="disp" NumberOfComponents=" 3" Format="ascii"> 5.0000000000000000E+00 -9.3750000000000000E-01 0.0000000000000000E+00 7.4459136479107816E-31 -3.4074520243048574E-31 0.0000000000000000E+00 5.0000000000000000E+00 9.3750000000000000E-01 0.0000000000000000E+00 5.5528848500075809E-31 3.4074520243048574E-31 0.0000000000000000E+00 </DataArray> </PointData> <CellData> </CellData> </Piece> </UnstructuredGrid> </VTKFile> Erik |
|
May 31, 2016, 10:28 |
|
#2 |
New Member
Join Date: May 2016
Posts: 2
Rep Power: 0 |
Problem solved.
My error was, in connectivity-array, I started counting from 1, not 0. |
|
Tags |
paraview, vtu |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[swak4Foam] groovyBC in openFOAM-2.0 for parabolic velocity bc | ofslcm | OpenFOAM Community Contributions | 25 | March 6, 2017 11:03 |
Problem compiling a custom Lagrangian library | brbbhatti | OpenFOAM Programming & Development | 2 | July 7, 2014 12:32 |
[snappyHexMesh] determining displacement for added points | CFDnewbie147 | OpenFOAM Meshing & Mesh Conversion | 1 | October 22, 2013 10:53 |
friction forces icoFoam | ofslcm | OpenFOAM | 3 | April 7, 2012 11:57 |
DxFoam reader update | hjasak | OpenFOAM Post-Processing | 69 | April 24, 2008 02:24 |