Jump to content

Fluid Simulation and Scene Scale


csp

Recommended Posts

For a while I wanted to start a topic dedicated to this relationship between fluid simulation (liquid, smoke, fire ) and the scale of the scene inside Houdini.

The general idea is the closer to the real size the better your simulation, more realistic. But sometimes things just don't work this way when you are working with small values, or maybe I am doing something wrong. For example a FLIP where bottle pouring water to a glass, the particles just don't behave.

How can you cheat? for example scaling your scene 10 times, your simulation will looks like an ocean, big splashes etc. What's the best way to bring your scene in this size? Reducing your Force Scale seams to work, does the Unit Length and Unit Mass in Preferences/Hip File Options will work if your drop them down from Meters to Decimeters?

I am sure there are other issues and I would like us to share experiences, tests, workflows on this topic.

cheers,

Christos

Link to comment
Share on other sites

Hi Christos,

If you can, I'd advise waiting a week and trying some experiments with H13 when it's released. There are a number of simulation quality improvements that help with small-scale simulations. In general smaller scale sims should Just Work, i.e. there's nothing really different about the physics, but in 12.5 there were some simulation issues that existed in all sims but were mostly visible at small scale. In some cases you do get into numerical tolerance issues if dealing with very small scale sims, but a bottle into a glass, for example, should be fine.

If you get a chance to try out H13 and are still seeing problems, please post those issues and I'll have a look. (or submit a bug report if you prefer).

John

  • Like 1
Link to comment
Share on other sites

Hi Christos,

If you can, I'd advise waiting a week and trying some experiments with H13 when it's released. There are a number of simulation quality improvements that help with small-scale simulations. In general smaller scale sims should Just Work, i.e. there's nothing really different about the physics, but in 12.5 there were some simulation issues that existed in all sims but were mostly visible at small scale. In some cases you do get into numerical tolerance issues if dealing with very small scale sims, but a bottle into a glass, for example, should be fine.

If you get a chance to try out H13 and are still seeing problems, please post those issues and I'll have a look. (or submit a bug report if you prefer).

John

Thanks John for the reply, we have a pre-release version of H13 where I work and I would run my test scene over the weekend. Recently and got another problem with FLIP and viscosity, I will test that also in H13.

Link to comment
Share on other sites

Hi Johner,

thanks for the reply on the other post about viscosity. I just wanted to let you know in this post that I tested scale in H13 with the same hip you have from the viscosity issue post and seams that I have the same problems. For example, I have a scale of 100 and everything works ok (besides viscosity issue) although the splashes from the collision of the liquid to the glass looks more to ocean

. But if you scale the scene down to 10, not even 1 which will be the real size, the simulation goes crazy and I am pretty sure that gravity seams to overtake any other force.

You can always play with values and have something that works but I would like to have a simulation that makes more sense as I am more technical.

Maybe I am doing something wrong, but you said the set-up looks ok.

cheers,

Christos

If you get a chance to try out H13 and are still seeing problems, please post those issues and I'll have a look. (or submit a bug report if you prefer).

Link to comment
Share on other sites

  • 2 weeks later...

The general idea is the closer to the real size the better your simulation, more realistic. But sometimes things just don't work this way when you are working with small values, or maybe I am doing something wrong. For example a FLIP where bottle pouring water to a glass, the particles just don't behave.

Hi Christos,

I finally got a chance to look at your file. You should be able to use FLIP to get these kind of small-scale simulations, although the defaults are definitely set up for larger scale sims. There are a few issues here: a few with your setup and a few with the FLIP Solver. I'm assuming you're looking for a "beer pouring in a glass" kind of look. I made a few changes to get that working at a realistic scale.

First your setup:

  • Turned off viscosity for now (more on that below)
  • Turned back on Volume-based collisions on the static cup object. FLIP only works with volume collisions
  • Turned on Fill Interior for the VDB collision object. You don't waste too much memory in this case since it's a thin object, and it makes things like Move Outside Collision work better.
  • Turn off Allow caching to Disk (you're better off flipbooking - .sim files take a long time to write at hi-res)
  • The FLIP Solver's Force Scale parameter should be set at 1 for a liquid simulation (yours was 0.6). That parameter is really only useful when you want to add only a small amount of liquid-behavior to a particle sim. But in this case you want full liquid behavior, and reducing that parameter will only lead to volume loss as the particles behave partially ballistically.
  • Switched back to Particle collision method, as its more accurate at small scales.
  • Increased the number of substeps to 8, as the fluid is moving fast relative to its small particle size.

I also did some tweaking of the emitter, as it was mainly set up for large scale: the velocity was too high, and the Curl noise frequency was the wrong scale. Also the AutoBounds was making way too big a default volume and taking way too long to generate particles.

The FLIP solver settings also need some tweaking at this scale, primarily because at this small scale effects like viscosity and surface tension are an important part of the fluid behavior, unlike at large scale where you can effectively ignore both. That's part of why the fluid looks way too active; water doesn't really have zero viscosity and it looks weird at small scale to act as if it does.

I haven't had a chance to track down the viscosity solver bug that you reported, but in the meantime we can fake a bit of viscosity by increasing the Smoothing a lot and adding a bit of Stick on Collision. Both of these have the effect of calming down the fluid, but they're really just emulating a small amount of viscosity (without the performance hit of the full Viscosity solver). Once I track down the bug with it I'll try again with real viscosity.

I've attached my H13 version of your file at small scale and a flipbook is here:

https://s3.amazonaws..._scale_pour.mp4

(Anyone know why I can't attach .mp4 files?)

flip_test_small_scale_pour.hip

  • Like 5
Link to comment
Share on other sites

  • 2 years later...

I know this is ancient, and maybe there's no chance of getting an answer here, but I'm wondering if I can snag some advice here, too.

I'm new to Houdini, and I'm struggling to get these simulations to work in the first place. cparliaros' original file doesn't seem to be here, so I can't compare his setup with what johner changed.. 

Can you or anyone help guide me through how to set this up from scratch? If possible, something with how to get the collisions to be so clean, too..

 

Thanks, if it can be done :) Thanks, even, if not. This gives me a lead and hope that I can do what I'm wanting~

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...