|
[Sponsors] |
[General] Changing particle color if certain condition is reached |
![]() |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
![]() |
![]() |
#1 |
New Member
Bruno Guerrero
Join Date: Aug 2014
Posts: 4
Rep Power: 12 ![]() |
In order to introduce you a little bit my problem, I am working with a molecular dynamics simulation. To visualize the system with Paraview, I read the position and velocity of each particle from a .vtk file like was made in http://diffusionht.blogspot.com/2012...aview-vtk.html. And in order to color the particles I use the sphere glyph filter and I use the "Color by" option following a physical criterion (i.e temperature).
Now my question is: How can I change the color of the particle who reachs certain condition (i.e if x-position is less than certain value, or if force on particle exceed some value)?. I you consider necessary any extra detail or information I could provide you. Some suggestion or idea? Thanks in advance |
|
![]() |
![]() |
![]() |
![]() |
#2 |
New Member
Bruno Guerrero
Join Date: Aug 2014
Posts: 4
Rep Power: 12 ![]() |
The only viable option to me was add an additional scalar field with 0/1 values for each point, and color following this scalar. The caveat is that I need to modify my .vtk first before perform the visualization
|
|
![]() |
![]() |
![]() |
![]() |
#3 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128 ![]() ![]() ![]() ![]() ![]() ![]() |
Quick answer: ParaView has a filter named "Programmable Filter", which requires ParaView to be built with Python integration. This would enable you to create a field on-the-fly. Examples: http://www.paraview.org/Wiki/Python_Programmable_Filter
|
|
![]() |
![]() |
![]() |
Tags |
conditional if statement, paraview, particle color |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Periodic Condition for Particle Tracking in DPM | vagaikwa | FLUENT | 2 | May 22, 2017 05:14 |
Check particle impaction with User Fortran | Julian K. | CFX | 3 | January 12, 2012 10:46 |
Changing Boundary Condition | David Baker | FLUENT | 4 | July 12, 2011 11:01 |
Changing the boundary condition | vijay | FLUENT | 3 | April 14, 2008 11:17 |
Help Urgent about changing boundary condition | Anjum Naveed | FLUENT | 7 | August 14, 2006 13:25 |