8.0
general documentation
cs_function_default.h File Reference
#include "cs_defs.h"
#include "cs_function.h"
+ Include dependency graph for cs_function_default.h:

Go to the source code of this file.

Enumerations

enum  cs_function_predefined_t { CS_FUNCTION_CELL_RANK_ID , CS_FUNCTION_B_FACE_RANK_ID }
 

Functions

void cs_function_default_define (void)
 Define functions based on code_saturne case setup. More...
 
cs_function_tcs_function_define_mpi_rank_id (cs_mesh_location_type_t location_id)
 Create or access a function for evaluation of element's MPI rank id. More...
 
cs_function_tcs_function_define_refinement_generation (cs_mesh_location_type_t location_id)
 Create or access a function for evaluation of mesh element's refinement generation (i.e. level). More...
 
cs_function_tcs_function_define_boundary_stress (void)
 Define function object for computation of boundary stress. More...
 
cs_function_tcs_function_define_boundary_stress_normal (void)
 Define function object for computation of normal boundary stress. More...
 
cs_function_tcs_function_define_boundary_stress_tangential (void)
 Define function object for computation of tangential boundary stress. More...
 
cs_function_tcs_function_define_boundary_thermal_flux (void)
 Define function object for computation of boundary thermal flux. More...
 
cs_function_tcs_function_define_q_criterion (void)
 Define function for computation of cell Q criterion. More...
 
void cs_function_class_or_zone_id (int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
 Extract optional boundary face class of element zone id. More...
 
void cs_function_field_boundary_nr (int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
 Compute non-reconstructed cell-based field values at boundary. More...
 
void cs_function_boundary_stress (int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
 Compute stress at boundary. More...
 
void cs_function_boundary_stress_normal (int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
 Compute normal stress at boundary. More...
 
void cs_function_boundary_stress_tangential (int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
 Compute tangential stress at boundary. More...
 
cs_function_tcs_function_define_boundary_nusselt (void)
 Define function for computation of boundary layer Nusselt. More...
 
void cs_function_boundary_thermal_flux (int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
 Compute thermal flux at boundary (in $ W\,m^{-2} $),. More...
 
void cs_function_boundary_nusselt (int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
 Compute local Nusselt number near boundary. More...
 
void cs_function_q_criterion (int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
 Compute the Q-criterion from Hunt et. al over each cell of a specified volume region. More...
 

Enumeration Type Documentation

◆ cs_function_predefined_t

Predefined function objects

Enumerator
CS_FUNCTION_CELL_RANK_ID 

cell MPI rank id (integer)

CS_FUNCTION_B_FACE_RANK_ID 

boundary face MPI rank id (integer)

Function Documentation

◆ cs_function_boundary_nusselt()

void cs_function_boundary_nusselt ( int  location_id,
cs_lnum_t  n_elts,
const cs_lnum_t elt_ids,
void *  input,
void *  vals 
)

Compute local Nusselt number near boundary.

This function matches the cs_eval_at_location_t function profile.

Parameters
[in]location_idbase associated mesh location id
[in]n_eltsnumber of associated elements
[in]elt_idsids of associated elements, or NULL if no filtering is required
[in,out]inputignored
[in,out]valspointer to output values (size: n_elts*dimension)

◆ cs_function_boundary_stress()

void cs_function_boundary_stress ( int  location_id,
cs_lnum_t  n_elts,
const cs_lnum_t elt_ids,
void *  input,
void *  vals 
)

Compute stress at boundary.

This function matches the cs_eval_at_location_t function profile.

Parameters
[in]location_idbase associated mesh location id
[in]n_eltsnumber of associated elements
[in]elt_idsids of associated elements, or NULL if no filtering is required
[in,out]inputignored
[in,out]valspointer to output values (size: n_elts*dimension)

◆ cs_function_boundary_stress_normal()

void cs_function_boundary_stress_normal ( int  location_id,
cs_lnum_t  n_elts,
const cs_lnum_t elt_ids,
void *  input,
void *  vals 
)

Compute normal stress at boundary.

This function matches the cs_eval_at_location_t function profile.

Parameters
[in]location_idbase associated mesh location id
[in]n_eltsnumber of associated elements
[in]elt_idsids of associated elements, or NULL if no filtering is required
[in,out]inputignored
[in,out]valspointer to output values (size: n_elts*dimension)

◆ cs_function_boundary_stress_tangential()

void cs_function_boundary_stress_tangential ( int  location_id,
cs_lnum_t  n_elts,
const cs_lnum_t elt_ids,
void *  input,
void *  vals 
)

Compute tangential stress at boundary.

This function matches the cs_eval_at_location_t function profile.

Parameters
[in]location_idbase associated mesh location id
[in]n_eltsnumber of associated elements
[in]elt_idsids of associated elements, or NULL if no filtering is required
[in,out]inputignored
[in,out]valspointer to output values (size: n_elts*dimension)

◆ cs_function_boundary_thermal_flux()

void cs_function_boundary_thermal_flux ( int  location_id,
cs_lnum_t  n_elts,
const cs_lnum_t elt_ids,
void *  input,
void *  vals 
)

Compute thermal flux at boundary (in $ W\,m^{-2} $),.

This function matches the cs_eval_at_location_t function profile.

Parameters
[in]location_idbase associated mesh location id
[in]n_eltsnumber of associated elements
[in]elt_idsids of associated elements, or NULL if no filtering is required
[in,out]inputignored
[in,out]valspointer to output values (size: n_elts*dimension)

◆ cs_function_class_or_zone_id()

void cs_function_class_or_zone_id ( int  location_id,
cs_lnum_t  n_elts,
const cs_lnum_t elt_ids,
void *  input,
void *  vals 
)

Extract optional boundary face class of element zone id.

For boundary faces, if no face classes have been defined by cs_boundary_zone_face_class_id the highest boundary face zone id is

For cells, the highest cell volume zone id is used.

This function matches the cs_eval_at_location_t function profile.

Parameters
[in]location_idbase associated mesh location id
[in]n_eltsnumber of associated elements
[in]elt_idsids of associated elements, or NULL if no filtering is required
[in,out]inputpointer to field
[in,out]valspointer to output values (size: n_elts*dimension)

◆ cs_function_default_define()

void cs_function_default_define ( void  )

Define functions based on code_saturne case setup.

◆ cs_function_define_boundary_nusselt()

cs_function_t* cs_function_define_boundary_nusselt ( void  )

Define function for computation of boundary layer Nusselt.

Returns
pointer to the associated function object in case of success, or NULL in case of error

◆ cs_function_define_boundary_stress()

cs_function_t* cs_function_define_boundary_stress ( void  )

Define function object for computation of boundary stress.

Returns
pointer to the associated function object in case of success, or NULL in case of error

◆ cs_function_define_boundary_stress_normal()

cs_function_t* cs_function_define_boundary_stress_normal ( void  )

Define function object for computation of normal boundary stress.

Returns
pointer to the associated function object in case of success, or NULL in case of error

◆ cs_function_define_boundary_stress_tangential()

cs_function_t* cs_function_define_boundary_stress_tangential ( void  )

Define function object for computation of tangential boundary stress.

Returns
pointer to the associated function object in case of success, or NULL in case of error

◆ cs_function_define_boundary_thermal_flux()

cs_function_t* cs_function_define_boundary_thermal_flux ( void  )

Define function object for computation of boundary thermal flux.

Returns
pointer to the associated function object in case of success, or NULL in case of error

◆ cs_function_define_mpi_rank_id()

cs_function_t* cs_function_define_mpi_rank_id ( cs_mesh_location_type_t  location_id)

Create or access a function for evaluation of element's MPI rank id.

Parameters
[in]location_idbase associated mesh location id
Returns
pointer to the associated function object in case of success, or NULL in case of error

◆ cs_function_define_q_criterion()

cs_function_t* cs_function_define_q_criterion ( void  )

Define function for computation of cell Q criterion.

Returns
pointer to the associated function object in case of success, or NULL in case of error

◆ cs_function_define_refinement_generation()

cs_function_t* cs_function_define_refinement_generation ( cs_mesh_location_type_t  location_id)

Create or access a function for evaluation of mesh element's refinement generation (i.e. level).

Parameters
[in]location_idbase associated mesh location id
Returns
pointer to the associated function object in case of success, or NULL in case of error

◆ cs_function_field_boundary_nr()

void cs_function_field_boundary_nr ( int  location_id,
cs_lnum_t  n_elts,
const cs_lnum_t elt_ids,
void *  input,
void *  vals 
)

Compute non-reconstructed cell-based field values at boundary.

This function matches the cs_eval_at_location_t function profile.

Parameters
[in]location_idbase associated mesh location id
[in]n_eltsnumber of associated elements
[in]elt_idsids of associated elements, or NULL if no filtering is required
[in,out]inputpointer to field
[in,out]valspointer to output values (size: n_elts*dimension)

◆ cs_function_q_criterion()

void cs_function_q_criterion ( int  location_id,
cs_lnum_t  n_elts,
const cs_lnum_t elt_ids,
void *  input,
void *  vals 
)

Compute the Q-criterion from Hunt et. al over each cell of a specified volume region.

\[ Q = \tens{\Omega}:\tens{\Omega} - \deviator{ \left(\tens{S} \right)}:\deviator{ \left(\tens{S} \right)} \]

where $\tens{\Omega}$ is the vorticity tensor and $\deviator{ \left(\tens{S} \right)}$ the deviatoric of the rate of strain tensor.

This function matches the cs_eval_at_location_t function profile.

Parameters
[in]location_idbase associated mesh location id
[in]n_eltsnumber of associated elements
[in]elt_idsids of associated elements, or NULL if no filtering is required
[in,out]inputignored
[in,out]valspointer to output values (size: n_elts*dimension)