If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Main content
Current time:0:00Total duration:2:07

Video transcript

hey welcome back you probably notice that the ping-pong ball simulator looks a little more like sand than water for instance the balls can pile up on each other like this we use the simulation much like this in finding dory for instance the sand in this shot and the East Australian current in this shot to create more water like simulation we need to remove the hard boundary of the balls they don't just bounce off like ping-pong balls and kind of smush together to create a soft collision the smooth collisions are an approximation of the pressure forces that water normally experiences there is a fancy name for this kind of simulation it's called smooth particle hydrodynamics or SPH for short hydrodynamics literally means the motion of fluids now let's look at how lots of smooth particles interact we can control how the particles collide using this parameter called collision softness okay so this is getting pretty close another parameter we can control is called viscosity viscosity is a measure of how easily things flow fluids with low viscosity like water flow pretty freely as we see here fluids with high viscosity like honey flow more slowly like this the more particles you add the more computation is needed and the slower the program responds here's an example of SPH from Finding Nemo it takes place inside the mouth of a whale we've drawn the particles as balls here so you can watch their motion in the next exercise you'll get some practice experimenting with these different parameters to get a wide range of behaviors see you soon