Compute weighted average of nearby particle velocities

   843   2   0
User Avatar
Member
18 posts
Joined: 7月 2018
オフライン
Hi Everyone

I'm studying the FLIP solver a bit in depth in my free time, going node by node and reading a bit of theory. However, there is a part that I can't understand and I hope you can help me understand the logic. I often read in the literature that in transferring velocities from Lagrangian particles (v@v attribute) to Eulerian grids (v@vel field) a sort of weighted average is made taking into account the velocities of the nearby particles.

Example: https://nccastaff.bournemouth.ac.uk/jmacey/MastersProject/MSc12/Ioannidis/Thesis.pdf [nccastaff.bournemouth.ac.uk] (page 43), here an abstract:






In other more detailed cases the kernel functions are described numerically, for example:

https://nccastaff.bournemouth.ac.uk/jmacey/MastersProject/MSc16/01/thesis.pdf [nccastaff.bournemouth.ac.uk] (page 12)




Or http://alexey.stomakhin.com/research/siggraph2013_snow.pdf [alexey.stomakhin.com]






Given this, let's say I have a point cloud with certain attributes (v@v, @mass, @pscale), my main questions are:

- Does the Gas Particle to Field, when rasterizing the velocities of a point cloud, already perform a weighted average taking into account the velocities of nearby particles like described in above abstracts?

- If so, how and what are the mathematical operations behind each option? For example, reading the houdini documentation, does the Accumulated option take into account these kernel functions:



- What could be a code/pseudo-code to compute the weighted average of the contribution of nearby particles based on their mass, their distance from the current evaluated cell using a kernel function of a specified radius?

- If I wanted to "build" a Gas Particle to Field from scratch, for example to implement the functions and methods proposed in the literature (like the ones proposed above) in which language would it be possible to do it? VEX, Python, OpenCL, C++?



Any information will be really useful, thank you very much everyone.

Attachments:
abstract_ioannidis_01.jpg (202.1 KB)
abstract_thesis_01.jpg (64.2 KB)
abstract_stom_01.jpg (191.6 KB)
gasparticletofield_01.jpg (33.1 KB)

User Avatar
Member
18 posts
Joined: 7月 2018
オフライン
Seriously, no one?

The question is simple after all.. Does the Gas Particle to Field already do a weighted trilinear interpolation when it splats the particles onto the grid?
User Avatar
Member
58 posts
Joined: 8月 2014
オフライン
Heh, it's fairly rare to get properly-technical (how does this node work) questions answered on here I find :-)

As I understand it Gas Particle to Field does at least that - I assume it sums a linear interpolation of the velocity and weights between the 8 cells each particle is closest to, then divides one by the other. Not sure if it can do/does more elaborate kernels, or keeps it simple for speed.

(Ah, although I just remembered it extrapolates velocities into unoccupied cells too, so I guess it's a bit more complex than that)

I'm not sure anyone besides SideFX themselves could say what the maths behind microsolvers is. Might be worth reaching out to them directly...
Edited by VortexVFX - 2025年4月11日 14:04:44
Dan Wood
Vortex VFX Ltd
  • Quick Links