KTH framework for Nek5000 toolboxes; testing version
0.0.1
|
Turbulence at inlet generated with divergence-free synthetic eddy method. More...
Files | |
file | gSyEM.f |
Generalised Synthetic Eddy Method. | |
Functions | |
subroutine | gsyem_register () |
Register gSyEM module. More... | |
subroutine | gsyem_init () |
Initilise gSyEM module. More... | |
logical function | gsyem_is_initialised () |
Check if module was initialised. More... | |
subroutine | gsyem_main |
Main gSyEM interface. More... | |
subroutine | gsyem_rst_write |
Create checkpoint. More... | |
subroutine | gsyem_rst_read |
Read from checkpoint. More... | |
subroutine | gsyem_mesh_setup () |
Generate mesh dependent information. More... | |
subroutine | gsyem_fam_setup (npoint, poff, rpos, umean, tke, dss) |
Generate family information. More... | |
subroutine | gsyem_prof_read (npoint, poff, rpos, umean, tke, dss) |
Read profiles for all familes. More... | |
subroutine | gsyem_face_prof (nfam, poff, rpos, umean, tke, dss, iel, ifc, ifn, dist) |
Generate profile information for given family face. More... | |
subroutine | gsyem_gen_elist (elist, neddy, nfam, ifinit) |
Generate eddies from the list for a given family. More... | |
subroutine | gsyem_gen_eall (nfam) |
Inital generation of all eddies (gsyem_mode.eq.1) for a given family. More... | |
subroutine | gsyem_adv_eddy (nfam) |
Advect/recycle eddies (gsyem_mode.eq.1) for a given family. More... | |
subroutine | gsyem_gen_mall (nfam) |
Inital generation of all modes (gsyem_mode.eq.3) for a given family. More... | |
subroutine | gsyem_evolve () |
Time evolution of eddies. More... | |
subroutine | gsyem_iso (nfam) |
Fill velocity array with eddies; ISO. More... | |
subroutine | gsyem_dairay (nfam) |
Fill velocity array with eddies; Dairay. More... | |
Turbulence at inlet generated with divergence-free synthetic eddy method.
This set of routines generating set of vortices at the computational domain inlet. The method is based on [6].
This module requires runtime parameters defined by Checkpointing routines module to properly perform restart operations. User defined routine (usr_gen_eddy) provides the rules for generating a single vortex. It allows the user to specify vertex distribution on the face (e.g. within a circle or a rectangular region) and a given vortex orientation. An example provided in this directory gives random position within a circle (random rho and theta variables) assuming the face is normal to Z axis. Two different options are considered depending on (ifinit) flag. The first one corresponsd to a simulation initialisation where the vortices fill the whole testing volume. In the second one the vortives are placed on at the inflow position only. Next a vortex position is rotated to match a real face position in the computational domain. The final step is definition of the vortex orinetation with an integer array. In addition the user has to provide a radial distribution of a mean velocity (U_mean), a turbulence kinetic energy (k) and a dissipation rate (eps). U_mean, k and eps have to be given in a text file "gsyem_prof_###.txt" containing three header lines:
# point number in a profile
187
# r U_mean k eps
followed by the data set for each point in the profile. The scend line in the header gives the number of radial positions in the profile, and the data set consists of four real numbers: radial position (r), U_mean, k and eps.
Varaible | Type | Runtime parameter | Default value | Description |
---|---|---|---|---|
gsyem_mode | integer | _gsyem:mode | 1 | gSyEM mode |
gsyem_nfam | integer | _gsyem:nfam | 1 | Family number |
gsyem_neddy(il) | integer | _gsyem:neddy'il' | 10 | Numer of eddies of 'il' family |
gsyem_fambc(il) | integer | _gsyem:fambc'il' | 10 | Boundarry index of 'il' family |
gsyem_famasig(il) | real | _gsyem:famasig'il' | 0.025 | Max eddy size of 'il' family |
gsyem_famisig(il) | real | _gsyem:famisig'il' | 0.025 | Min eddy size of 'il' family |
gsyem_famdirx(il) | real | _gsyem:famdirx'il' | 0.025 | X normal component of 'il' family |
gsyem_famdiry(il) | real | _gsyem:famdiry'il' | 0.025 | X normal component of 'il' family |
gsyem_famdirz(il) | real | _gsyem:famdirz'il' | 0.025 | X normal component of 'il' family |
subroutine gsyem_adv_eddy | ( | integer | nfam | ) |
Advect/recycle eddies (gsyem_mode.eq.1) for a given family.
[in] | nfam | family number |
Definition at line 1360 of file gSyEM.f.
References gsyem_gen_elist(), and mntr_logi().
subroutine gsyem_dairay | ( | integer | nfam | ) |
subroutine gsyem_evolve |
Time evolution of eddies.
Definition at line 1453 of file gSyEM.f.
References gsyem_adv_eddy(), gsyem_dairay(), and gsyem_iso().
subroutine gsyem_face_prof | ( | integer | nfam, |
integer, dimension(gsyem_nfam_max+1) | poff, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | rpos, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | umean, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | tke, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | dss, | ||
integer | iel, | ||
integer | ifc, | ||
integer | ifn, | ||
real, dimension(lx1,lz1) | dist | ||
) |
Generate profile information for given family face.
[in] | nfam | family number |
[in] | poff | family profile array offset |
[in] | rpos | position in a profile |
[in] | umean | profile mean velocity |
[in] | tke | profile turbulence kinetic energy |
[in] | dss | profile dissipation rate |
[in] | iel | local element number |
[in] | ifc | face number |
[in] | ifn | face position in gsyem_sigma,gsyem_umean,gsyem_intn arrays |
[in] | dist | point distance form the edge |
Definition at line 1150 of file gSyEM.f.
References cmult(), col3(), and copy().
subroutine gsyem_fam_setup | ( | integer, dimension(gsyem_nfam_max) | npoint, |
integer, dimension(gsyem_nfam_max+1) | poff, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | rpos, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | umean, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | tke, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | dss | ||
) |
Generate family information.
This routine generates family information including bounding box size, average coordinates, normal vector
Definition at line 687 of file gSyEM.f.
References cfill(), cmult(), ftovec(), gop(), gsyem_face_prof(), math_etovec(), math_rot3da(), mntr_abort(), mntr_log(), mntr_logi(), mntr_logr(), and rzero().
subroutine gsyem_gen_eall | ( | integer | nfam | ) |
Inital generation of all eddies (gsyem_mode.eq.1) for a given family.
[in] | nfam | family number |
Definition at line 1324 of file gSyEM.f.
References gsyem_gen_elist(), and mntr_logi().
subroutine gsyem_gen_elist | ( | integer, dimension(neddy) | elist, |
integer | neddy, | ||
integer | nfam, | ||
logical | ifinit | ||
) |
Generate eddies from the list for a given family.
[in] | elist | list of eddies to be geneated |
[in] | neddy | number of eddies |
[in] | nfam | family number |
[in] | ifinit | intial distribution |
Definition at line 1255 of file gSyEM.f.
References bcast(), copy(), icopy(), mntr_check_abort(), mntr_log(), and mntr_logi().
subroutine gsyem_gen_mall | ( | integer | nfam | ) |
Inital generation of all modes (gsyem_mode.eq.3) for a given family.
[in] | nfam | family number |
Definition at line 1410 of file gSyEM.f.
References bcast(), and mntr_logi().
subroutine gsyem_init |
Initilise gSyEM module.
Definition at line 116 of file gSyEM.f.
References gsyem_gen_eall(), gsyem_gen_mall(), gsyem_mesh_setup(), gsyem_prof_read(), gsyem_rst_read(), math_zbqlini(), mntr_abort(), mntr_check_abort(), mntr_mod_is_name_reg(), mntr_tmr_add(), mntr_warn(), rprm_rp_get(), rprm_rp_is_name_reg(), and rprm_sec_is_name_reg().
logical function gsyem_is_initialised |
subroutine gsyem_iso | ( | integer | nfam | ) |
Fill velocity array with eddies; ISO.
[in] | nfam | family number |
Definition at line 1482 of file gSyEM.f.
References cfill(), cmult(), col2(), copy(), ftovec(), gop(), izero(), rzero(), subcol3(), vectof(), and vectof_add().
subroutine gsyem_main |
Main gSyEM interface.
Definition at line 299 of file gSyEM.f.
References gsyem_evolve(), gsyem_rst_write(), and mntr_tmr_add().
subroutine gsyem_mesh_setup |
Generate mesh dependent information.
Definition at line 596 of file gSyEM.f.
References gsyem_fam_setup(), izero(), mntr_abort(), and mntr_check_abort().
subroutine gsyem_prof_read | ( | integer, dimension(gsyem_nfam_max) | npoint, |
integer, dimension(gsyem_nfam_max+1) | poff, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | rpos, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | umean, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | tke, | ||
real, dimension(gsyem_npoint_max*gsyem_nfam_max) | dss | ||
) |
Read profiles for all familes.
[out] | npoint | number of points in profile per family |
[out] | poff | family profile array offset |
[out] | rpos | position in a profile |
[out] | umean | profile mean velocity |
[out] | tke | profile turbulence kinetic energy |
[out] | dss | profile dissipation rate |
Definition at line 1058 of file gSyEM.f.
References bcast(), io_file_freeid(), mntr_check_abort(), mntr_log(), mntr_log_local(), and rzero().
subroutine gsyem_register |
Register gSyEM module.
Definition at line 13 of file gSyEM.f.
References mntr_abort(), mntr_mod_is_name_reg(), mntr_mod_reg(), mntr_tmr_add(), mntr_tmr_is_name_reg(), mntr_tmr_reg(), mntr_warn(), rprm_rp_reg(), rprm_sec_reg(), and rprm_sec_set_act().
subroutine gsyem_rst_read |
Read from checkpoint.
In current inplementation all data is duplicated over all nodes, so only master performs I/O
Definition at line 456 of file gSyEM.f.
References bcast(), blank(), byte_close, byte_open, byte_read, byte_reverse, copy(), mntr_check_abort(), and mntr_log().
subroutine gsyem_rst_write |
Create checkpoint.
In current inplementation all data is duplicated over all nodes, so only master performs I/O
Definition at line 335 of file gSyEM.f.
References blank(), byte_close, byte_open, byte_write, chkpt_get_fset(), copy(), mntr_check_abort(), mntr_get_step_delay(), mntr_log(), mntr_tmr_add(), and nekgsync().