My Project
programmer's documentation
Functions
cs_user_radiative_transfer_bcs.c File Reference
#include "cs_defs.h"
#include <assert.h>
#include <string.h>
#include <math.h>
#include "bft_mem.h"
#include "bft_error.h"
#include "bft_printf.h"
#include "cs_1d_wall_thermal.h"
#include "cs_base.h"
#include "cs_boundary_zone.h"
#include "cs_fan.h"
#include "cs_field.h"
#include "cs_gui_util.h"
#include "cs_field_pointer.h"
#include "cs_field_operator.h"
#include "cs_math.h"
#include "cs_mesh.h"
#include "cs_mesh_location.h"
#include "cs_mesh_quantities.h"
#include "cs_halo.h"
#include "cs_halo_perio.h"
#include "cs_log.h"
#include "cs_multigrid.h"
#include "cs_notebook.h"
#include "cs_parameters.h"
#include "cs_physical_constants.h"
#include "cs_physical_properties.h"
#include "cs_prototypes.h"
#include "cs_rotation.h"
#include "cs_sles.h"
#include "cs_sles_it.h"
#include "cs_time_moment.h"
#include "cs_time_step.h"
#include "cs_turbomachinery.h"
#include "cs_selector.h"
#include "cs_rad_transfer.h"
#include "cs_thermal_model.h"
#include "cs_post.h"
Include dependency graph for cs_user_radiative_transfer_bcs.c:

Functions

void cs_user_radiative_transfer_bcs (int nvar, const int bc_type[], int icodcl[], int isothp[], cs_real_t *tmin, cs_real_t *tmax, cs_real_t *tx, const cs_real_t dt[], cs_real_t rcodcl[], const cs_real_t thwall[], const cs_real_t qincid[], cs_real_t hfcnvp[], cs_real_t flcnvp[], cs_real_t xlamp[], cs_real_t epap[], cs_real_t epsp[], cs_real_t textp[], cs_real_t tintp[])
 User definition of radiative transfer boundary conditions. More...
 

Function Documentation

◆ cs_user_radiative_transfer_bcs()

void cs_user_radiative_transfer_bcs ( int  nvar,
const int  bc_type[],
int  icodcl[],
int  isothp[],
cs_real_t tmin,
cs_real_t tmax,
cs_real_t tx,
const cs_real_t  dt[],
cs_real_t  rcodcl[],
const cs_real_t  thwall[],
const cs_real_t  qincid[],
cs_real_t  hfcnvp[],
cs_real_t  flcnvp[],
cs_real_t  xlamp[],
cs_real_t  epap[],
cs_real_t  epsp[],
cs_real_t  textp[],
cs_real_t  tintp[] 
)

User definition of radiative transfer boundary conditions.

See Examples of data settings for radiative transfers for examples.

Warning
the temperature unit here is the Kelvin

Zone definitions

For each boundary face face_id, a specific output (logging and postprocessing) class id may be assigned. This allows realizing balance sheets by treating them separately for each zone. By default, the output class id is set to the general (input) zone id associated to a face.

To access output class ids (both for reading and modifying), use the cs_boundary_zone_face_class_id function. The zone id values are arbitrarily chosen by the user, but must be positive integers; very high numbers may also lead to higher memory consumption.

Wall characteristics

The following face characteristics must be set:

  • isothp(face_id) boundary face type = itpimp -> Gray wall with fixed inside temperature = ipgrno -> Gray wall with fixed outside temperature = iprefl -> Reflecting wall with fixed outside temperature = ifgrno -> Gray wall with fixed conduction flux = ifrefl -> Reflecting wall with fixed conduction flux
  • tintp(face_id) inside wall temperature (Kelvin) initialize thwall at the first time step. If isothp = itpimp, the value of thwall is fixed to tintp In the other case, tintp is only for initialization.

Depending on the value of isothp, other values may also need to be set:

  • rcodcl = conduction flux
  • epsp = emissivity
  • xlamp = conductivity (W/m/K)
  • epap = thickness (m)
  • textp = outside temperature (K)
Parameters
[in]nvartotal number of variable BC's
[in]bc_typeboundary face types
[in]icodclboundary face code
  • 1 -> Dirichlet
  • 2 -> convective outlet
  • 3 -> flux density
  • 4 -> sliding wall and u.n=0 (velocity)
  • 5 -> friction and u.n=0 (velocity)
  • 6 -> roughness and u.n=0 (velocity)
  • 9 -> free inlet/outlet (velocity) inflowing possibly blocked
[in]isothpboundary face type for radiative transfer
  • itpimp -> Gray wall with fixed inside temp
  • ipgrno -> Gray wall with fixed outside temp
  • iprefl -> Reflecting wall with fixed outside temp
  • ifgrno -> Gray wall with fixed conduction flux
  • ifrefl -> Reflecting wall with fixed conduction flux
[out]tminmin allowed value of the wall temperature
[out]tmaxmax allowed value of the wall temperature
[in]txrelaxation coefficient (0 < tx < 1)
[in]dttime step (per cell)
[in]rcodclboundary condition values rcodcl(3) = flux density value (negative for gain) in W/m2
[in]thwallinside current wall temperature (K)
[in]qincidradiative incident flux (W/m2)
[in]hfcnvpconvective exchange coefficient (W/m2/K)
[in]flcnvpconvective flux (W/m2)
[out]xlampconductivity (W/m/K)
[out]epapthickness (m)
[out]epspemissivity (>0)
[out]textpoutside temperature (K)
[out]tintpinitial inside temperature (K)