Announcement

Collapse
No announcement yet.

Completely static viscosity

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Completely static viscosity

    I've often been wishing for a viscosity value (2.0?), where there is absolutely no movement of the particles.
    Take a metal fence for example which you want to melt over time: The "wetting" trick won't do it, as the fence only has contact with the ground on a few points (where the vertical poles touch the ground).
    This applies to many objects and makes the melting effect rather limited (i.e. for plastic objects).
    I'm aware of using texture maps to control viscosity, but the viscosity value 1.0 is never truely static. And other workarounds always produce some kind of noise/artifiacts to the original (perfect) mesh object.

  • #2
    Ah, the viscosity works by making the liquid stiffer and stiffer, trying to reach the absolutely solid value, but in practice it can never be reached.

    It's an iterative algorithm, like the fire/smoke Fluidity ("Conservation", also called "pressure projection"), that keeps making things better the more iterations it runs on the fluid, trying to reach that ideal value.

    Allowing for more iterations from the GUI would allow making a liquid a bit more solid at the expense of longer simulation time, but there would always be the factors that battle against the viscosity:
    - Gravity
    - The number of particles in the fluid blob and how close they are
    - Any other external forces pushing the liquid in some direction

    So the viscosity tries to get the liquid back into its original shape after these outside factors deformed it, but the stronger these factors are, the harder it is for the viscosity to achieve that.

    So, way to make Phoenix's viscosity work better, are to actually reduce these factors:
    - Increase the Scene Scale or reduce the gravity, so the liquid would be pulled less by the gravity.
    - Decrease the Grid Resolution, so less connections between the particles will have to be resolved by the viscosity and it would work better.

    I think I can make the viscosity algorithm morph into a hard-body algorithm at higher values, but gotta play with it and see what happens. For sure it wouldn't be able to handle extreme cases where the liquid gets squashed between obstacles or something slices through the liquid at high speed for example, but it would be interesting to see what I can come up with

    Cheers!
    Svetlin Nikolov, Ex Lead Phoenix developer

    Comment


    • #3
      Thanks for the detailed and insightful response Svetlin.
      "viscosity algorithm morph into a hard-body algorithm" sounds exiting, sometimes the unexpected can lead to new insights.

      I'm not keen on reducing Grid Resolution, as this impacts the overall detail of the original hard surface shape.
      But I will try reducing gravity and have a force activated to get gravity back into the scene for parts with lower viscosity. I mean the molten material does need to drip downwards, right?
      Cheers, Guy

      Comment


      • #4
        Oh, force tuning the low viscosity areas sounds very clever!
        Svetlin Nikolov, Ex Lead Phoenix developer

        Comment


        • #5
          I did a mercury thing recently in which I adjusted gravity on the fly to get this exact sort of behaviour. It's very hacky but did appear to work.
          It's not at all predictable of course, which is the problem - but works...seemingly.

          This was always, years ago, something that I couldn't quite understand...why cannot the particles just be told to slowly come to a stop, therefore resitant to all exterior
          forces and their own relative forces. The result was always jittery, as is the nature of them it seems (explained above) but it shouldn't need to be really...there must be a way....

          Of course, what people have always done is either cut before it gets too excitable or transition to a smoothed static version, which doesn't always look great tbh.
          https://www.behance.net/bartgelin

          Comment


          • #6
            fixeighted, yes, you've summed it all up!
            After hearing that zero movement is not possible, I've been hacking away again at this task, starting/stopping influences, animating parameters, re-adjusting texture-maps, as during the sim, the original object-xyz-coordinates don't match anymore, and, and, and...
            I'll post some specific screenshots soon, to further illustrate the topic.

            Comment


            • #7
              Yeah, indeed the nature of the computer solvers is that they focus on the dynamics, but in order to have things become static, the algorithms are not really at home, so the best they could so is some dynamic equilibrium. I believe we could help them a little though...
              Svetlin Nikolov, Ex Lead Phoenix developer

              Comment


              • #8
                I was just thinking of water turning into ice (or vice versa): this is surely a "hot" topic in fluid dynamics research?!?
                I'm aware, that ice isn't truly static (as observable with glaciers, at least those that are still around).
                But hey, ice would surely do the trick in our 15 sec VFX shots to pass as "static"

                Anyway, hope your experiments are going well Svetlin. Maybe you're discovering some breakthroughs with Phoenix, that will revolutionize the status quo of current physics!

                Comment


                • #9
                  To my mind, there should be a way to halt an algorithm's influence on something.
                  Although, caveat; I most probably clearly don't know wtf I'm talking about
                  https://www.behance.net/bartgelin

                  Comment

                  Working...
                  X