4
$\begingroup$

I want to be able to model an opaque liquid being dropped into a transparent liquid with sufficient velocity to cause turbulence and the resulting chaotic mixing. Assuming the two liquids are of the same density and viscosity, how could I model this?

This doesn't need to be rendered in real time. I would like the turbulent flow to gradually settle down as the two fluids mix, but it will not be required to interact with other objects.

I've tried modelling an expanding interface between the two fluids, and accelerating the vertices of the interface based on the local curvature, adding new vertices as they move apart. This seemed to work in the early stages, giving a constant exaggeration of small surface imperfections to create at least the appearance of turbulence, but it ran into problems very early which seemed to result from the interface self-intersecting. I've been trying to think of ways to redirect vertices that are near to causing a surface self-intersection, but I wonder if I would be better off starting from scratch with a more amenable method.

$\endgroup$
  • 1
    $\begingroup$ While certainly interesting, I don't think we want to be flooded with plain "How do I achieve effect X?" type questions later on. So: What have you tried? $\endgroup$ – Martin Ender Aug 10 '15 at 22:00
  • 3
    $\begingroup$ I think the question is fine up to the title, but the body is kind of vague. There should be more context like if it's meant for real-time of offline use, level of detail and scale required, etc. The current answer for example assumes the scale to be able to give a more specific answer taking into account possible tradeoffs, which I think is an important part of a good answerable question. $\endgroup$ – yuriks Aug 11 '15 at 0:06
  • 1
    $\begingroup$ @yuriks Yes, the question could use more detail as well, but I think the "What have you tried?" part is important. We should set ourselves similar quality standards as other SE sites like Stack Overflow and expect question authors to show some effort on their part. Otherwise, we'll just become a site where people go to have others do their work for them. $\endgroup$ – Martin Ender Aug 11 '15 at 8:22
  • 1
    $\begingroup$ Relevant meta discussion. $\endgroup$ – Martin Ender Aug 11 '15 at 8:57
10
$\begingroup$

Simulating drops of ink is probably one of the best applications of the Vorton Method.

Unlike fluid solvers based on the velocity form of the Navier-Stokes equations, which track the density and velocity of a fluid, the Vorton Method tracks vorticity instead. It does so by simulating a large number of vortons, each carrying a small amount of vorticity; you can think of a vorton as being a tiny particle that induces a small spinning vortex around itself. The sum of velocities caused by each vortex defines a velocity field in the fluid, which is used to in turn advect the vortons themselves.

Vorton methods are difficult to combine with boundary conditions and have a few efficiency caveats, but for fluid flow where intricate turbulance is the key feature and boundaries can be avoided, the Vorton method far outshines e.g. Eulerian grid solvers, which would need a large resolution to simulate turbulence at a comparable scale.

Michael Gourlay has a very accessible article series on the vorton method. Although his articles are targeted at video games, they hold up similarly for off-line simulation. Here's also an example video of a drop of ink simulated using the vorton method.

$\endgroup$
  • $\begingroup$ Nice explanation and great links... Your video should be visible in this answer :) $\endgroup$ – Armfoot Aug 11 '15 at 14:04
0
$\begingroup$

As an alternative you could also check Jon Stam's paper "Stable Fluids", that method is usually called the semi-Lagrangian approach to fluid simulations. You can find several implementations of it. You said that you don't need it to be real time, so this might do the work.

$\endgroup$
  • 1
    $\begingroup$ It would be great if you could contain some information about this method within the answer to make it more self-contained. $\endgroup$ – Martin Ender Aug 11 '15 at 9:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.