ACU-T: 4001 Water Filling in a Tank

Prerequisites

This tutorial provides instructions for setting up, solving, and viewing results for a transient dam break simulation using the Level Set method. Prior to starting this tutorial, you should have already run through the introductory HyperWorks tutorial, ACU-T: 1000 HyperWorks UI Introduction, and have a basic understanding of HyperWorks CFD, AcuSolve, and HyperView. To run this simulation, you will need access to a licensed version of HyperWorks CFD and AcuSolve.

Prior to running through this tutorial, copy HyperWorksCFD_tutorial_inputs.zip from <Altair_installation_directory>\hwcfdsolvers\acusolve\win64\model_files\tutorials\AcuSolve to a local directory. Extract ACU-T4001_tank2D.x_t from HyperWorksCFD_tutorial_inputs.zip.

Problem Description

The problem to be solved is shown schematically in the figure below. It consists of a half-filled water tank at time t=0. Water is injected through the Inlet at t=0 and as the water fills in through the inlet, the water-air interface can be visualized in a transient simulation.



Figure 1.

Start HyperWorks CFD and Create the HyperMesh Model Database

  1. Start HyperWorks CFD from the Windows Start menu by clicking Start > Altair <version> > HyperWorks CFD.
    When HyperWorks CFD is loaded, the Geometry ribbon is open by default.
  2. Create a new .hm database in one of the following ways:
    • From the menu bar, click File > Save.
    • From the Home tools, Files tool group, click the Save As tool.


      Figure 2.
  3. In the Save File As dialog, navigate to the directory where you would like to save the database.
  4. Enter FillingTank as the name for the database then click Save.
    This will be your problem directory and all the files related to the simulation will be stored in this location.

Import and Validate the Geometry

Import the Geometry

  1. From the menu bar, click File > Import > Geometry Model.
  2. In the Import File dialog, browse to your working directory then select ACU-T4001_tank2D.x_t and click Open.
  3. In the Geometry Import Options dialog, leave all the default options unchanged then click Import.


    Figure 3.


    Figure 4.

Validate the Geometry

  1. From the Geometry ribbon, click the Validate tool.


    Figure 5.
    The Validate tool scans through the entire model, performs checks on the surfaces and solids, and flags any defects in the geometry, such as free edges, closed shells, intersections, duplicates, and slivers.

    The current model doesn’t have any of the issues mentioned above. Alternatively, if any issues are found, they are indicated by the number in the brackets adjacent to the tool name.

    Observe that a blue check mark appears on the top-left corner of the Validate icon. This indicates that the tool found no issues with the geometry model.


    Figure 6.
  2. Press Esc or right-click in the modeling window and select Exit from the context menu to exit the tool.
  3. Save the database.

Set Up the Problem

Set Up the Simulation Parameters and Solver Settings

  1. From the Flow ribbon, click the Physics tool.


    Figure 7.
    The Setup dialog opens.
  2. Click the Time setting and select Transient.
  3. Set the Time step size to 0.01 and the Final time to 3.0
  4. Make sure the Final time termination option is active.


    Figure 8.
  5. Click the Flow setting then select Laminar.
  6. Activate the Include gravitational acceleration option and set the gravity to -9.81 m/sec2 in the y-direction.


    Figure 9.
  7. Click the Multifluid setting, set the Multifluid type to Immiscible, and the Immiscible material to Air-Water.


    Figure 10.
  8. Click the Solver Controls setting and set the Maximum stagger iterations to 4.


    Figure 11.
  9. Exit the dialog and save the database.

Assign Material Properties

  1. From the Flow ribbon, click the Material tool.


    Figure 12.
  2. Click anywhere on the dam geometry.
  3. In the microdialog, select Air-Water from the Material drop-down.


    Figure 13.
  4. On the guide bar, click to execute the command and exit the tool.
  5. Save the database.

Define Flow Boundary Conditions

  1. From the Flow ribbon, click the Slip tool.


    Figure 14.
  2. Select the right most face on the positive z-axis, as shown in the figure below.


    Figure 15.
  3. In the Boundaries legend, double-click on Slip, rename it to z_pos and press Enter.
  4. On the guide bar, click to execute the command and remain in the tool.
  5. Rotate the model and select the opposite face.
  6. In the Boundaries legend, rename Slip to z_neg.
  7. On the guide bar, click to execute the command and exit the tool.
  8. Click the Constant tool.


    Figure 16.
  9. Select the inlet surface shown in the figure below.


    Figure 17.
  10. In the microdialog,
    1. Set the Inflow velocity type to Normal.
    2. Set the Normal velocity to 1.5 m/s.
    3. Select Water as the incoming immiscible fluid.
  11. On the guide bar, click to execute the command and exit the tool.
  12. Click the Outlet tool.


    Figure 18.
  13. Select the outlet surface shown in the figure below.


    Figure 19.
  14. In the microdialog, activate Hydrostatic pressure.
  15. On the guide bar, click to execute the command and exit the tool.
  16. Save the database.

Generate the Mesh

In this step, first you will create a surface mesh using the Interactive meshing tool; then, you will specify a global mesh size and growth rate for the model and generate the volume mesh using the Batch tool in the Mesh ribbon.

Create Surface Mesh

  1. From the Mesh ribbon, click the Interactive tool.


    Figure 20.
    By default, the Create should be selected from the secondary ribbon.
  2. Click on the guide bar to open the options menu, then make the following changes:
    1. Set the Element size to 0.01.
    2. Set the Element type to R-Trias.
    3. Expand Adaptive mesh and activate the Curvature based refinement option.
      Leave the remaining settings unchanged.


    Figure 21.
  3. On the guide bar, change the entity selector to Solids then select the solid in the modeling window.
  4. Click Mesh in either the microdialog or on the guide bar to generate the surface mesh.
  5. Once the surface mesh is created, press Esc to exit out of the tool.

Generate Volume Mesh

  1. From the Mesh ribbon, click the Batch tool.


    Figure 22.
    The Meshing Operations dialog opens.
  2. Verify that the Mesh size option is set to Average size.
  3. Set the Average element size to 0.02.
  4. Set the Mesh growth rate to 1.0.


    Figure 23.
  5. Click Mesh.
    The Run Status dialog opens. Once the run is complete, the status is updated and you can close the dialog.
    Tip: Right-click on the mesh job and select View log file to view a summary of the meshing process.

Define Nodal Outputs and Nodal Initial Conditions

In this step, you will define the nodal output frequency and then specify the nodal initial conditions for the water column.

Define Nodal Output Frequency

  1. From the Solution ribbon, click the Field tool.


    Figure 24.
    The Field Output dialog opens.
  2. Click the Solution variables setting.
  3. Activate the Write initial conditions option.
  4. Verify that the Write results at time step interval option is active.
  5. Set the Time step interval to 1.


    Figure 25.

Define the Nodal Initial Conditions

  1. From the Solution ribbon, click the Plane tool.


    Figure 26.
  2. Click on the tank solid and verify the selection on the guide bar.


    Figure 27.
  3. Click Plane on the guide bar then click anywhere near the center of the solid.
  4. In the microdialog, click in the top-left corner, select Fluid, then click in empty space in the dialog.
  5. Change the Value field to Water.


    Figure 28.
  6. Click in the top-right corner to orient the plane with the Vector tool.
  7. In the plane definition microdialog, verify that the normal orientation is along the negative y-axis (i.e. 0, -1, 0).


    Figure 29.
  8. Click , set the coordinates to (0, 0, 0), then press Enter.


    Figure 30.
  9. On the guide bar, click to execute the command and exit the tool.
  10. Save the database.

Run AcuSolve

  1. From the Solution ribbon, click the Run tool.


    Figure 31.
    The Launch AcuSolve dialog opens.
  2. Set the Parallel processing option to Intel MPI.
  3. Optional: Set the number of processors to 4 or 8 based on availability.
  4. Deactivate the Automatically define pressure reference option.
  5. Expand the Default initial conditions tab and deactivate the Pre-compute flow option.
  6. Set the x-velocity to 0.
  7. Set the Immiscible fluid to Air (if not already set).
  8. Leave the remaining options as default and click Run to launch AcuSolve.


    Figure 32.
    The Run Status dialog opens. Once the run is complete, the status is updated and you can close the dialog.
    Tip: While AcuSolve is running, right-click on the AcuSolve job in the Run Status dialog and select View Log File to monitor the AcuSolve solution process.

Post-Process the Results With HyperView

Open HyperView and Load the Model and Results

  1. Start HyperView from the Windows Start menu by clicking Start > All Programs > Altair <version> > HyperView.
    Once the HyperView window is loaded, the Load model and results panel should be open by default. If you do not see the panel, click File > Open > Model.
  2. In the Load model and results panel, click next to Load model.
  3. In the Load Model File dialog, navigate to your working directory and select the AcuSolve .Log file for the solution run that you want to post-process. In this example, the file to be selected is FillingTank.1.Log.
  4. Click Open.
  5. Click Apply in the panel area to load the model and results.
    The model is colored by geometry after loading.

Create the Water Flow Animation

In this step, you will create an animation of the water flow as it fills in through the inlet.

  1. Orient the display to the xy-plane by clicking on the Standard Views toolbar.
  2. Click the Section Cut icon on the HV-Display toolbar.
  3. In the panel area, click Add to create a new section cut.
  4. In the Define plane section, set the axis to Z-Axis then click Apply.
  5. In the Display options section, change the option from Clipping plane to Cross section.
  6. Click Gridline. In the Gridline Options dialog, deactivate the Show option then click OK.


    Figure 33.
  7. Click on the Results toolbar to open the Contour panel.
  8. Select Volume_fraction-2-Water (s) as the Result type.
  9. Click Apply to display the volume fraction contour at the first time step.
  10. Click the Legend tab then click Edit Legend.
  11. In the Edit Legend dialog, change the Number of levels to 2 and the Numeric format to Fixed then click OK.


    Figure 34.
  12. On the Animation toolbar, click the Animation Controls icon .
  13. Drag the Max frame Rate slider to 50 fps.
  14. Click the Start/Pause Animation icon to play the animation in the graphics area.

Save the Animation

  1. In the menu area, select Preferences > Export Settings > AVI.
  2. In the Export Settings AVI dialog, set the Frame rate to 50 fps and click OK.
  3. On the ImageCapture toolbar, make sure that the Save Image to File option is On.


  4. Click the Capture Graphics Area Video icon .
    The Save Graphics Area Video As dialog opens.
  5. Navigate to the location where you want to save the file, enter a name of your choice, and click Save.

Summary

In this tutorial, you successfully learned how to set up and solve a multiphase flow tank filling problem using HyperWorks CFD and AcuSolve. You started by importing the geometry and then completed the flow set up. Once the volume meshing was done, you specified the field initial conditions for the water column using the plane initialization tool. Once the solution was computed, you post-processed the results in HyperView where you generated an animation of the water flow.