<div dir="ltr"><div><div><div><div><div>Cory,<br><br></div>As a follow up.  Can I ask if it would be possible to do all that is suggested on Scott's page:<br><span class="gmail-im"><a href="https://www.paraview.org/Wiki/Advanced_Tips_and_Tricks#Animating_a_static_vector_field" rel="noreferrer" target="_blank">https://www.paraview.org/Wiki/<wbr>Advanced_Tips_and_Tricks#<wbr>Animating_a_static_vector_<wbr>field</a><br><br></span></div><span class="gmail-im">Along with all of your additional steps below from your last post (be great to add these to Scott's page), entirely in pvpython or pvbatch?  I make use of the anaconda version from here: <a href="https://anaconda.org/conda-forge/paraview">https://anaconda.org/conda-forge/paraview</a><br><br></span></div><span class="gmail-im">Would it be possible do you think to script all of this? I have not tired it yet I should add just checking for show stoppers before I begin.<br></span></div><span class="gmail-im">Thanks,<br></span></div><span class="gmail-im">Andy<br></span></div><div class="gmail_extra"><br><div class="gmail_quote">On 19 January 2018 at 13:18, Cory Quammen <span dir="ltr"><<a href="mailto:cory.quammen@kitware.com" target="_blank">cory.quammen@kitware.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Andrew,<br>
<br>
Responses inlined below:<br>
<span class=""><br>
On Fri, Jan 19, 2018 at 6:27 AM, Andrew Parker via ParaView<br>
<<a href="mailto:paraview@paraview.org">paraview@paraview.org</a>> wrote:<br>
> Dear all,<br>
><br>
> Sorry to post onto an old thread. I have been reading this thread and the<br>
> related write up here:<br>
> <a href="https://www.paraview.org/Wiki/Advanced_Tips_and_Tricks#Animating_a_static_vector_field" rel="noreferrer" target="_blank">https://www.paraview.org/Wiki/<wbr>Advanced_Tips_and_Tricks#<wbr>Animating_a_static_vector_<wbr>field</a><br>
><br>
> This thread (and the tips and tricks post) is really close to what I want to<br>
> do, but I have a few follow-up questions.  I too have a steady-state<br>
> solution field. I want to trace particles from the inlet of my domain to the<br>
> exit, following the steady-state velocity field, and report for each<br>
> particle the temperature-time history (or any other scalar from my<br>
> simulation) that the particle sees.  In additional and crucially, the time<br>
> the particle has within the domain: a residence time.  The residence time<br>
> would be the maximum value or IntegrationTime each particle attains before<br>
> it leaves the domain.<br>
><br>
> I see that if I follow the notes I can plot (using Glyphs) the temperature<br>
> as it varies across my domain as the particles are animated down the<br>
> streamlines: this is working.  What I do not seem to be able to find<br>
> however, is the IntegrationTime.  It appears as point-field data after the<br>
> streamlines are created, but vanishes after the contour filter is applied.<br>
> I guess the contour filter is computing a singular value for all values of<br>
> the IntegrationTime from T=0 to T=N with a specific level of granularity.<br>
<br>
</span>By default, the Contour filter does not copy the scalar field used to<br>
determine the contour surface since it will always be the same value.<br>
You can tell it to copy the scalar field by enabling the Compute<br>
Scalars option.<br>
<span class=""><br>
> However, I can't seem to extract the specific value of IntegrationTime (the<br>
> contour value) when I stop the simulation at any given point.  Do you know<br>
> how to do that?  The "time" scale in the VCR window always goes from 0->1<br>
> not from 0->(max value of IntegrationTime in seconds).  Can the actual value<br>
> of time be backed out or animated? If so how do I do that, or am I applying<br>
> the Contour filter wrongly: as per the post, I am only using the default<br>
> values in the Counter filter panel.<br>
<br>
</span>Instead of using the Sequence animation mode, use Real Time. Then, set<br>
the Start Time to the minimum IntegrationTime value and End Time to<br>
the maximum IntegrationTime value. You can see these listed either in<br>
the Information tab of the StreamTracer filter in the Pipeline Browser<br>
or under the Contour filter's Property tab under the Isosurfaces<br>
section (Value Range). To show the current time in the render view,<br>
use an Annotate Time source, available in the Sources menu.<br>
<span class=""><br>
> Finally, and importantly for me, while the Glyphs move across the screen<br>
> following the streamlines, and render via the temperature field, how to I<br>
> actually extract information from this pseudo time series to perform<br>
> analysis?  For example, the min and max temperature seen by a particle as it<br>
> moved across the streamline for instance?  I'm actually hoping to plot<br>
> offline (as a function of IntegrationTime) the min and max temperature<br>
> obtained for each particle: I can then take the min and max of that set for<br>
> the quickest and slowest particles.<br>
<br>
</span>You can run the Connectivity filter on the StreamTracer output to<br>
assign a unique value to each streamline. This unique value will be<br>
called RegionId. It starts at 0 and ends at the number of stream lines<br>
minus 1. Selecting each stream line can be done with the Threshold<br>
filter in ParaView using the RegionId as the threshold array, then you<br>
can see the min/max of your temperature and IntegrationTime variables<br>
in the Information tab. Iterating over all stream lines and saving the<br>
min/max of the different scalar fields is possible using ParaView's<br>
Python scripting capabilities. However, you may find it faster to<br>
export the data to a tool with which you are more familiar.<br>
<br>
To do that, I would suggest saving the Connectivity filter output to a<br>
.csv file. The CSV file will contain all the scalar fields in<br>
different columns, including the aforementioned RegionId field. Simply<br>
filter on the RegionId field using your favorite software/plotting<br>
tool to find the min and max temperature and max IntegrationTime of<br>
the particle along the stream line.<br>
<br>
HTH,<br>
Cory<br>
<div><div class="h5"><br>
<br>
> Using the latest stock version of paraview.<br>
><br>
> Cheers,<br>
> Andy<br>
><br>
> On 6 June 2014 at 20:30, Scott, W Alan <<a href="mailto:wascott@sandia.gov">wascott@sandia.gov</a>> wrote:<br>
>><br>
>> Ken and Jean, excellent idea!  I liked it so much that I wrote it up in<br>
>> the SNL ParaView tutorials, tips and tricks page.  It is located here:<br>
>> <a href="http://www.paraview.org/Wiki/Advanced_Tips_and_Tricks" rel="noreferrer" target="_blank">http://www.paraview.org/Wiki/<wbr>Advanced_Tips_and_Tricks</a><br>
>><br>
>><br>
>><br>
>> Alan<br>
>><br>
>><br>
>><br>
>> From: ParaView [mailto:<a href="mailto:paraview-bounces@paraview.org">paraview-bounces@<wbr>paraview.org</a>] On Behalf Of<br>
>> Moreland, Kenneth<br>
>> Sent: Friday, June 06, 2014 11:43 AM<br>
>> To: David E DeMarle; minh hien<br>
>> Cc: <a href="mailto:paraview@paraview.org">paraview@paraview.org</a><br>
>><br>
>><br>
>> Subject: [EXTERNAL] Re: [Paraview] Make animation from steady state result<br>
>><br>
>><br>
>><br>
>> Here's a more expanded list of steps outlining the solution David gave in<br>
>> case you are not very familiar with the contour filter and animation<br>
>> controls in ParaView.<br>
>><br>
>><br>
>><br>
>> 1. Create the streamlines as you normally would.<br>
>><br>
>><br>
>><br>
>> 2. Add a Contour filter to the streamline (third toolbar, second button<br>
>> from the left).<br>
>><br>
>> 2.a. Change the Contour By property to IntegrationTime.<br>
>><br>
>> 2.b. Press Apply.<br>
>><br>
>> This little trick will create a point on each streamline at a particular<br>
>> time in the particle advection simulation that created the streamlines.<br>
>><br>
>><br>
>><br>
>> 3. Open the Animation View (View -> Animation View)<br>
>><br>
>> 3.a. On the bottom row, select the contour filter in the first chooser box<br>
>> and Isosurfaces in the second chooser box. Then hit the blue plus button at<br>
>> the left.<br>
>><br>
>> 3.b. Make sure Mode is set to Sequence and change No. Frames to 100.<br>
>><br>
>> 3.c. Hit the play button in the VCR controls (green triangle in the top<br>
>> toolbar). You will see the dots animate over the streamlines.<br>
>><br>
>> 3.d. You can adjust the speed of the animation by changing the No. Frames.<br>
>><br>
>><br>
>><br>
>> 4. If you want to see glyphs instead of dots, just add the glyph filter to<br>
>> the output of the contour filter.<br>
>><br>
>><br>
>><br>
>> BTW, props to Jean Favre for originally posting this solution to the<br>
>> ParaView mailing list (<a href="http://markmail.org/message/ms57z7jjubh2pzjg" rel="noreferrer" target="_blank">http://markmail.org/message/<wbr>ms57z7jjubh2pzjg</a>).<br>
>><br>
>><br>
>><br>
>> -Ken<br>
>><br>
>><br>
>><br>
>> From: David E DeMarle <<a href="mailto:dave.demarle@kitware.com">dave.demarle@kitware.com</a>><br>
>> Date: Thursday, June 5, 2014 8:07 AM<br>
>> To: minh hien <<a href="mailto:minh.cfd@gmail.com">minh.cfd@gmail.com</a>><br>
>> Cc: "<a href="mailto:paraview@paraview.org">paraview@paraview.org</a>" <<a href="mailto:paraview@paraview.org">paraview@paraview.org</a>><br>
>> Subject: [EXTERNAL] Re: [Paraview] Make animation from steady state result<br>
>><br>
>><br>
>><br>
>> Make an isocontour of the streamlines' integrationTime variable.<br>
>><br>
>> Then in animation view, make a track for the isocontour value.<br>
>><br>
>><br>
>> David E DeMarle<br>
>> Kitware, Inc.<br>
>> R&D Engineer<br>
>> 21 Corporate Drive<br>
>> Clifton Park, NY 12065-8662<br>
>> Phone: <a href="tel:518-881-4909" value="+15188814909">518-881-4909</a><br>
>><br>
>><br>
>><br>
>> On Thu, Jun 5, 2014 at 9:52 AM, minh hien <<a href="mailto:minh.cfd@gmail.com">minh.cfd@gmail.com</a>> wrote:<br>
>><br>
>> Hi all,<br>
>><br>
>><br>
>><br>
>> I got steady state solution for my problem. After plotting streamlines at<br>
>> steady state, I would like to make animation showing moving of spheres<br>
>> (resulted from Glyph filter) on the streamlines, the spheres' velocity<br>
>> should be defined by the flow velocity. How can I make this?<br>
>><br>
>> Any suggestion would be very much appreciated.<br>
>><br>
>><br>
>><br>
>> Thank you in advance.<br>
>><br>
>><br>
>><br>
>> Minh<br>
>><br>
>><br>
>> ______________________________<wbr>_________________<br>
>> Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
>><br>
>> Visit other Kitware open-source projects at<br>
>> <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/<wbr>opensource/opensource.html</a><br>
>><br>
>> Please keep messages on-topic and check the ParaView Wiki at:<br>
>> <a href="http://paraview.org/Wiki/ParaView" rel="noreferrer" target="_blank">http://paraview.org/Wiki/<wbr>ParaView</a><br>
>><br>
>> Follow this link to subscribe/unsubscribe:<br>
>> <a href="http://www.paraview.org/mailman/listinfo/paraview" rel="noreferrer" target="_blank">http://www.paraview.org/<wbr>mailman/listinfo/paraview</a><br>
>><br>
>><br>
>><br>
>><br>
>> ______________________________<wbr>_________________<br>
>> Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
>><br>
>> Visit other Kitware open-source projects at<br>
>> <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/<wbr>opensource/opensource.html</a><br>
>><br>
>> Please keep messages on-topic and check the ParaView Wiki at:<br>
>> <a href="http://paraview.org/Wiki/ParaView" rel="noreferrer" target="_blank">http://paraview.org/Wiki/<wbr>ParaView</a><br>
>><br>
>> Follow this link to subscribe/unsubscribe:<br>
>> <a href="http://www.paraview.org/mailman/listinfo/paraview" rel="noreferrer" target="_blank">http://www.paraview.org/<wbr>mailman/listinfo/paraview</a><br>
>><br>
><br>
><br>
> ______________________________<wbr>_________________<br>
> Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
><br>
> Visit other Kitware open-source projects at<br>
> <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/<wbr>opensource/opensource.html</a><br>
><br>
> Please keep messages on-topic and check the ParaView Wiki at:<br>
> <a href="http://paraview.org/Wiki/ParaView" rel="noreferrer" target="_blank">http://paraview.org/Wiki/<wbr>ParaView</a><br>
><br>
</div></div>> Search the list archives at: <a href="http://markmail.org/search/?q=ParaView" rel="noreferrer" target="_blank">http://markmail.org/search/?q=<wbr>ParaView</a><br>
<span class="">><br>
> Follow this link to subscribe/unsubscribe:<br>
</span>> <a href="https://paraview.org/mailman/listinfo/paraview" rel="noreferrer" target="_blank">https://paraview.org/mailman/<wbr>listinfo/paraview</a><br>
><br>
<span class="HOEnZb"><font color="#888888"><br>
<br>
<br>
--<br>
Cory Quammen<br>
Staff R&D Engineer<br>
Kitware, Inc.<br>
</font></span></blockquote></div><br></div>