User functions for boundary condition definitions. More...
#include "cs_defs.h"
#include <assert.h>
#include <math.h>
#include <stdio.h>
#include <string.h>
#include "cs_headers.h"
Functions | |
void | cs_user_boundary_conditions_setup (cs_domain_t *domain) |
Set boundary conditions to be applied. More... | |
void | cs_user_boundary_conditions (cs_domain_t *domain, int bc_type[]) |
User definition of boundary conditions. More... | |
void | cs_user_boundary_conditions_ale (cs_domain_t *domain, int bc_type[], int ale_bc_type[], int impale[]) |
User definition of boundary conditions for ALE. More... | |
User functions for boundary condition definitions.
void cs_user_boundary_conditions | ( | cs_domain_t * | domain, |
int | bc_type[] | ||
) |
User definition of boundary conditions.
[in,out] | domain | pointer to a cs_domain_t structure |
[in,out] | bc_type | boundary face types |
The icodcl and rcodcl arrays are pre-initialized based on default and GUI-defined definitions, and may be modified here.
For a given variable field f, and a given face "face_id", these arrays may be used as follows:
For vector or tensor fields, these arrays are not interleaved, so for a given face "face_id" and field component "comp_id", access is as follows (where n_b_faces is domain->mesh->n_b_faces):
f->bc_coeffs->rcodcl1[n_b_faces*comp_id + face_id]
f->bc_coeffs->rcodcl2[n_b_faces*comp_id + face_id]
f->bc_coeffs->rcodcl3[n_b_faces*comp_id + face_id]
Only the icodcl code values from the first component are used in the case of vector or tensor fields, so the icodcl values can be defined as for a scalar.
void cs_user_boundary_conditions_ale | ( | cs_domain_t * | domain, |
int | bc_type[], | ||
int | ale_bc_type[], | ||
int | impale[] | ||
) |
User definition of boundary conditions for ALE.
See Boundary conditions for ALE (Arbitrary Lagrangian Eulerian) for additional details.
[in,out] | domain | pointer to a cs_domain_t structure |
[in,out] | bc_type | boundary face types |
[in,out] | ale_bc_type | boundary face types for mesh velocity (see cs_boundary_ale_subtype_bits_t) |
[in] | impale | indicator for prescribed node displacement (0 or 1) |
The icodcl and rcodcl arrays are pre-initialized based on default and GUI-defined definitions, and may be modified here.
For a given variable field f, and a given face "face_id", these arrays may be used as follows:
For vector or tensor fields, these arrays are not interleaved, so for a given face "face_id" and field component "comp_id", access is as follows (where n_b_faces is domain->mesh->n_b_faces):
f->bc_coeffs->rcodcl1[n_b_faces*comp_id + face_id]
f->bc_coeffs->rcodcl2[n_b_faces*comp_id + face_id]
f->bc_coeffs->rcodcl3[n_b_faces*comp_id + face_id]
Only the icodcl code values from the first component are used in the case of vector or tensor fields, so the icodcl values can be defined as for a scalar.
void cs_user_boundary_conditions_setup | ( | cs_domain_t * | domain | ) |
Set boundary conditions to be applied.
This function is called just before cs_user_finalize_setup, and boundary conditions can be defined in either of those functions, depending on whichever is considered more readable or practical for a given use.
[in,out] | domain | pointer to a cs_domain_t structure |