H19.5 SOP FLIP - How to vary viscosity with particle age

   999   4   2
User Avatar
Member
8 posts
Joined: July 2015
Offline
Hello

Context: SOP FLIP. I am able to set a fixed viscosity at say 2000
Issue: I would like to vary the viscosity with the age of particle
What I have tried: adding an Attribute Wrangle node between the source object and the fourth input to the flipsource (Flip Boundary). I have checked and unchecked the "Varying Viscosity" check box in the FLIP Container. In the attribute wrangle I have: f@viscosity = 2000.0+(100.0*f@age);

When I view the viscosity attribute in the geometry

Any help is welcome.
User Avatar
Member
2548 posts
Joined: June 2008
Online
What you have to do is dive into the solver and add a geometry wrangle to the force output that fetches the animated value and assign the viscosity inside the solver. Use the Inputs tab of the geometry wrangle to reference the value from SOP. I often just drop a NULL and name it ATTRIBS so I can quickly reference it.
Edited by Enivob - Aug. 24, 2023 12:24:02
Using Houdini Indie 20.0
Windows 11 64GB Ryzen 16 core.
nVidia 3050RTX 8BG RAM.
User Avatar
Member
8 posts
Joined: July 2015
Offline
Hello, thank you for responding. Is your message "...wrangle to the fore output..." an autocorrect misspelling of what you mean. If not, I do not understand what you mean by "fore". The Solver Network is in the below image. The closest I can find to what I think you are writing about is the "For..Each" loop. Can you please elaborate for me? Thank you

Attachments:
Capture.PNG (53.6 KB)

User Avatar
Member
60 posts
Joined: Nov. 2021
Offline
he meant the force output inside the solver, not foreach, that way the viscosity attribute gets fetched every timestep of the sim
User Avatar
Member
8 posts
Joined: July 2015
Offline
After a bit of trial and error it worked. I'll try to post a screen shot later of what I changed in case it is useful for others. Thank you for your help, much appreciated.
  • Quick Links