Adjusting Liquid Simulation attributes
 
 
 

One of the main characteristics of water is that its volume uniformly fills the area inside a holding vessel or container. To give nParticles this volume characteristic, there needs to be space between individual particles. Be aware that having too much space can hinder the fluidity of the particles, which is another important characteristic of a liquid simulation.

Using the Liquid Radius Scale attribute, you can control the amount of space between nParticles.

Adjusting the liquid’s volume

To set Liquid Radius Scale

  1. In the Outliner, select nParticle_Water.
  2. In the Attribute Editor, click the nParticle_WaterShape tab.
  3. In the Liquid Simulation section, ensure that Enable Liquid Simulation is on.
  4. Set Liquid Radius Scale to 2.0.
  5. Play the simulation.

    The nParticles are now stacked on top of each other, creating more volume in the pitcher.

    For this liquid simulation, you want the nParticles to fill one-third of the pitcher. You can add more volume to the nParticles by adjusting the Nucleus solver Substeps and Max Collision Iterations.

  6. Set Substeps and Max Collision Iterations by doing the following:
    • In the Attribute Editor, click the nucleus1 tab.
    • In the Solver Attributes settings, set Substeps to 10.
    • Set Max Collision Iterations to 15.
  7. Play the simulation.

    The nParticles now fill the water pitcher, and when the pitcher tilts to pour, the nParticles have enough volume to exit and fill the glass. Notice that some nParticles fall outside of the glass. This problem will be fixed in later sections of the lesson by setting Incompressibility and Viscosity.

More about Liquid Radius Scale

Be aware that Liquid Radius Scale can be affected by other nParticle attributes such as Radius and Collide Width Scale. For example, Liquid Radius Scale uses the nParticle object's Radius to determine how nParticles overlap, and any change in the nParticle Radius affects how nParticles overlap in the liquid simulation.

Adjusting the Nucleus solver Substeps and Max Collision Iterations also affects the volume that is generated by the Liquid Radius Scale value. You can experiment by changing the Substeps and Max Collision Iterations values and observe how your liquid simulation is affected.

For more information about how nParticle attributes affect liquid simulations, see Liquid Simulations in the nDynamics guide.

In the next section of this lesson, you adjust nParticle Collide Scale Width and Incompressibility attributes to add fluidity to your simulation.