File: cs_user_les_inflow.h

package info (click to toggle)
code-saturne 5.3.2%2Brepack-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 76,868 kB
  • sloc: ansic: 338,582; f90: 118,487; python: 65,227; makefile: 4,429; cpp: 3,826; xml: 3,078; sh: 1,205; lex: 170; yacc: 100
file content (147 lines) | stat: -rw-r--r-- 5,746 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
/*============================================================================
 * Code_Saturne documentation page
 *============================================================================*/

/*
  This file is part of Code_Saturne, a general-purpose CFD tool.

  Copyright (C) 1998-2018 EDF S.A.

  This program is free software; you can redistribute it and/or modify it under
  the terms of the GNU General Public License as published by the Free Software
  Foundation; either version 2 of the License, or (at your option) any later
  version.

  This program is distributed in the hope that it will be useful, but WITHOUT
  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
  details.

  You should have received a copy of the GNU General Public License along with
  this program; if not, write to the Free Software Foundation, Inc., 51 Franklin
  Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/

/*-----------------------------------------------------------------------------*/

/*!
  \page les_inflow Generation of synthetic turbulence at LES inlets
 
  \section cs_user_les_infow_intro Introduction

  This example contains 3 subroutines : 
  - cs_user_les_inflow_init: definition of global caracteristics of synthetic turbulence inlets
  - cs_user_les_inflow_define: definition of the caracteristics of the synthetic turbulence 
  - cs_user_les_inflow_advanced: accurate definition of target statistics at inlet


  \section cs_user_les_inflow_init Global caracteristics of synthetic turbulence inlets

  \subsection cs_user_les_inflow_purpose Purpose

  Generation of synthetic turbulence at LES inlets.
  Definition of global caracteristics of synthetic turbulence inlets:
  nent and isuisy might be defined.

  - nent = Number of inlets
  - isuisy = 1: Reading of the LES inflow module restart file
  - isuisy = 0: not activated (synthetic turbulence reinitialized)


  \subsection cs_user_les_inflow_loc_var_dec1 Local variables declaration

  No local variable.


  \subsection cs_user_les_inflow_init1 Initializations
  \snippet cs_user_les_inflow-base.f90 init_1


  \section cs_user_les_inflow_define Caracteristics of one specific inlet

  \subsection cs_user_les_inflow_purpose_base Purpose

  Generation of synthetic turbulence at LES inlets
  Definition of the caracteristics of the synthetic turbulence inlet 'nument'
  For each LES inlet, the following parameters might be defined:
   -# Data relatve to the method employed
      - typent indicates the synthetic turbulence method:
          - 0 : laminar, no turbulent fluctations
          - 1 : random gaussian noise
          - 2 : Batten method, based on Fourier mode decomposition
          - 3 : Synthetic Eddy Method (SEM)
      - nelent indicates the number of "entities" relative to the method
        (useful only for the Batten method and the SEM):
          - for Batten : number of Fourier modes of the turbulent fluctuations
          - for SEM    : number of synthetic eddies building the fluctuations
      - iverbo indicates the verbosity level (listing)
          - = 0  no specific output
          - > 0 additionnal output (only for SEM)
   -# Data relative to the LES inflow boundary faces
       - nfbent: number of boundary faces of the LES inflow
       - lfbent: list of boundary faces of the LES inflow
   -# Data relative to the flow
       - vitent(3): reference mean velocity vector
       - enrent: reference turbulent kinetic energy
       - dspent: reference dissipation rate
       - Note:
         - dspent useful only for typent = 2 (Batten) or typent = 3 (SEM).
         - Strictly positive values are required for enrent and dspent.
         - Accurate specification of the statistics of the flow at LES inlet
           can be made via the user subroutine cs_user_les_inflow_advanced.

  \subsection cs_user_les_inflow_loc_var_dec2 Local variables declaration

  No local variable.

  \subsection cs_user_les_inflow_init2 Initializations

  First synthetic turbulence inlet: the Batten Method is used
  for boundary faces of color '1'.

  \snippet cs_user_les_inflow-base.f90 init_21

  Second synthetic turbulence inlet: the Synthetic Eddy Method is used
  for the boundary faces verifying a geometric criterion.

  \snippet cs_user_les_inflow-base.f90 init_22


  \section cs_user_les_inflow_advanced Accurate specification of target statistics at inlet

  \subsection cs_user_les_inflow_purpose_advanced Purpose

  Generation of synthetic turbulence at LES inlets.
  Accurate definition of mean velocity, Reynolds stresses and dissipation
  rate for each boundary faces of the synthetic turbulence inlet 'nument'. 

  Usage:
   - uvwent(ndim,nfbent) : mean velocity vector
   - rijent(   6,nfbent) : Reynolds stresses!
   - epsent(     nfbent) : dissipation rate


  \subsection cs_user_les_inflow_loc_var_dec3 Local variables declaration

  \snippet cs_user_les_inflow-base.f90 loc_var_dec3

  \subsection cs_user_les_inflow_example_1 Example 1

  Mean velocity, Reynolds stresses an dissipation are deduced from a wall law for
  the first synthetic turbulence inlet, 
  - no refining of the statistics of the flow 
  is provided for the second synthetic turbulence inlet.
  
  \snippet cs_user_les_inflow-base.f90 example_1
  
  \subsection cs_user_les_inflow_example_2 Example 2

   Reynolds stresses and dissipation at the inlet are computed
   using the turbulence intensity and standard laws for
   a circular pipe for the first synthetic turbulence inlet,
   - no refining of the statistics of the flow is provided for the
   other synthetic turbulence inlet.
  
  \snippet cs_user_les_inflow-base.f90 example_2
  
*/