ufpGetExtData()
Get the array of extended flow data.
Syntax
data = ufpGetExtData ( ufpHd, dataName ) ;
Type
AcuSolve User-Defined Function Flow Routine.
Parameters
- ufpHd (pointer)
- The opaque handle which was passed to the user function.
- dataName (integer)
- Name of the requested data.
Return Value
The return value is a pointer to a one dimensional real array.
The size of the array depends on the value of dataName. You are responsible for ensuring that the requested data is available in the AcuSolve database. dataName must be specified in the extended_flow_variables parameter of the FLOW_FIELD command in the trace input file.
Description
This routine returns the array of extended flow data at the current particle location and time.
To access material_viscosity in a user defined function,
material_viscosity must first be specified in the
extended_flow_variables parameter in the trace input
file:
FLOW_FIELD {
...
extended_flow_variables =
{
material_viscosity,
...
}
...
}
In the C source file, the code may be written
as:
Real* data;
Real material_viscosity ;
data = ufpGetExtData( ufpHd, "material_viscosity" ) ;
material_viscosity = data[0] ;
Errors
This routine expects valid ufpHd and dataName as arguments; invalid arguments return an error.