What algorithm does Blender use to simulate the interaction between fluid and object? For research purpose, I need to implement the interaction between fluid and object. And I found that Blender is able to do this interaction (as shown in the picture).

My questions are:


What algorithm does Blender use to implement this interaction?
Can I add some additional force terms into the equations of this interaction in Blender, so I can change the behaviour of the fluid? (Not just change the parameters in the panels, but add some new force terms)
The wanted information were found by both googling the keywords "blender fluid simulation" which leads to this page of the 2.4 documentation and some grep in the source code of Blender.

In this doc page, you can see a "technical details" chapter which indicates three algorithms :


Lattice Boltzmann Method (LBM)
Navier-Stokes (NS)
Smoothed Particle Hydrodynamics (SPH). SPH seems to be approximations to the Lagrangian formulation of the Navier-Stokes equations


From that, I did only grep in the Visual Studio solution (don't imagine a minute I know anything more about all that...). For instance :



To summarize :


LBM is in simulation_object.cpp
SPH is in particle_system.c