Page 1 of 1

Code_Saturne:2.0.3, about filtered velocity for LES

Posted: Mon Oct 22, 2012 3:48 pm
by youngzxlove
Hello,
I use Code_Saturne 2.0.3
I wish to use a subgrid model other than the given ones (dyanmic Smagorinsky model, DSM). The velocity and strain rate tensor with a test-filter is needed to perform my model. However, I cannot find the infomation about how to do a test-filter on a field in the user manual.

My question is if there is a subroutine which can be called to do a test-filter? Otherwise, how could I obtain a test-filtered field?

Regards,
Young

Re: Code_Saturne:2.0.3, about filtered velocity for LES

Posted: Wed Nov 07, 2012 11:10 am
by BLM
Hi Young,

If you want to perform a test-filtering of your field, you can use the 'cfiltr' subroutine. Exemples of usage of this subroutine are in the visdyn.f90 source file which computes the subgrid viscosity for the DSM.

The 'cfiltr' subroutine performs a (volume weighted) averaging of the field on the neighborhood of each cells. To do so, it is preferable to activate the extended neighborhood : neighbor cells are thus all cells sharing a vertex with the considered cell (by default, only the cells sharing a internal face are taken into account).
The extended neighborhood is automatically activated when imrgra = 2 or 3 or iturb = 41 (DSM). Thus, if you want to compute a subgrid viscosity which need a test-filtering on the extended neighborhood, I recommend you to overwrite the visdyn.f90 subroutine and select iturb = 41.

Best regards,
BenoƮt