[Paraview] Animation. Second view of a field variable. How to format the file.

Christer Gustafsson gustaf at powertech.no
Tue Sep 16 03:15:09 EDT 2008


Hi Dave,

Thank you for your second response on the 12th of September in which you 
pointed out that it is very easy to get the file formats wrong. You also 
sent a full vts example which I copied to a vts file and let ParaView 
display in a 3D window. OK.

Therefore I followed your example and wrote my vts as follows: the 
fileddata (which represents an integrated variable of the system) is now 
put before the first <Piece Extent> in every one of the vts files. This 
takes me a step further, but there is still something that I have not 
got correctly because this is what happens in ParaView:

File/Open/pvd/Apply ---> OK. I see my geometry in the 3D view.
Split Vertical ---> Empty window opens
SpreadSheet View ---> OK
Click eye      ---> Some table opens in second window
Display FieldData ---> OK I see my FieldData in second window
animate ---> OK FieldData value changes

But it is an animated xyPlot that I wish, so I try the xyplot now in 
ParaView:

File/Open/pvd/Apply ---> 3D view opens correctly
Split Vertical ---> Empty window opens
xyPlot View ---> NO EYE

 From here I cannot proceed and I conclude I still do something wrong.  
Now, you also wrote "... make sure you copy the point and cell centred 
data across too". Is this where I fail?

Christer



My vts file(s) as they look now:

<?xml version="1.0"?>
<VTKFile type="StructuredGrid" version="0.1" byte_order="LittleEndian"
         compressor="vtkZLibDataCompressor">
 <StructuredGrid WholeExtent="0 1 0 40 0 91">
  <FieldData>
   <DataArray type="Float32" Name="SF1" NumberOfTuples="1" format="ascii"
              RangeMin="5.204563E+04" RangeMax="5.204563E+04">
    5.204563E+04
   </DataArray>
  </FieldData>
  <Piece Extent="0 1 0 40 0 45">
   <PointData Scalars="Temperature">
    <DataArray type="Float32" Name="Temperature" format="ascii">
  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  
1  1  1  1  1  1  1
  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  
1  1  1  1  1  1  1
[snip]

David E DeMarle wrote:
> You could save K(t) as field data. Then you can extract the zero'th
> entry in the K array (which has just one element) and plot that over
> time. A vts file with field data in it looks something like this...
>
> <VTKFile type="StructuredGrid" [snip]
> <StructuredGrid WholeExtent=[snip]>
> <FieldData>
> <DataArray type="Float64" Name="MyField" NumberOfTuples="1" format="ascii"
> RangeMin="26.1" RangeMax="26.1">
> 26.1
> </DataArray>
> </FieldData>
> [snip]
>
> On Mon, Sep 8, 2008 at 12:30 AM, Christer Gustafsson
> <gustaf at powertech.no> wrote:
>> Hi All,
>>
>> The data (x_i(t),y_i(t),z_i(t)) is formatted as one pvd and many vts 
>> file.
>> The animation runs fine in one 3D view.
>>
>> In addition there is an associated time-varying function (t,K(t)) 
>> (e.g. the
>> kinetic energy of the system). I would like to create a second view and
>> herein animate K(t) along with the 3D view.
>>
>> In what file format (example?) would the (t,K(t)) be cast in order to 
>> make
>> the animations in two views be possible? (The ParaView Guide talks about
>> `unaligned data items' in connection with `Time' in Chapter 10, section
>> 10.3, but from that point on I find no more path).
>>
>> Thanks,
>> ChG
>>
>> _______________________________________________
>> ParaView mailing list
>> ParaView at paraview.org
>> http://www.paraview.org/mailman/listinfo/paraview
>>
>



More information about the ParaView mailing list