Hydrofoil Cavitation Example
This tutorial will cover the basics of setting up and running the fluid problem of a cavitating flow over a hydrofoil. Additionally, a comparison of Loci-Stream results will be presented. Files for running the case yourself can be found here: LOCI-STREAM RUN FILES.
The Hord cavitation problem is used to validate cavitation models because it is one of the few empirical studies with the reported data from instrumentation that can be easily replicated in a simulation. The flow is cryogenic oxygen that passes over a hydrofoil as it sits in a closed channel. The reduction in area for the flow to move as it encounters the hydrofoil results in a drop in the pressure, and the pressure falls below the saturation vapor of the oxygen. This results in a bubble of oxygen vapor forming and attaching itself to the leading edge of the hydrofoil.
The domain is 3D which is created from an extrusion of a 2D geometry.
The flow inlet is prescribed using the Loci-Stream syntax: subsonicInlet(T=537.0 R, v=41.7096 m/s, k=0.00097, omega=5091) .
To see the Loci-Stream control file with the remaining boundary information & numerics info, click HERE.
Running the Code
Loci-Stream is an MPI based parallel code, so execution of the code is started with a call to mpirun. A template call is shown below where the terms in brackets(<>) are replaced by the specifics of your case.
mpirun -np <np> <path_to_stream_exec> --scheduleoutput -q solution <casename> <restart> > /dev/null >run.out 2>&1 &
For this example the call is:
mpirun -np 16 /home/user/Loci-Stream/bin/stream --scheduleoutput -q solution backstep > /dev/null >run.out 2>&1 &
The results from the Loci-Stream simulation of the backstep flow problem are compared to experimental data for the problem as well as simulation data from a different NASA CFD code(CFL3D). Four locations along the streamwise(horizontal) direction are sampled and data collected along the vertical direction.
A note about the data presented below, the left plot appears to not have data from Loci-Stream, but all data sets are presented. They overlap considerably in the velocity space(circle data points can be seen near the top of the plot). The discrepancy between CFL3D and Loci-Stream is somewhat more pronounced for the stress plot on the right.
The 'extract' utility is used to view the results of a simulation. For this case we view the simulation at the 10,000th time step. In the run directory extract the solution using: extract -vtk backstep 10000 P v . This will generate a solution directory with files in the Paraview VTK format which can be opened by Paraview. The case name is 'backstep' and the timestep is '10000', and the variables to extract are the pressure(P) and velocity(v).