CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (http://www.cfd-online.com/Forums/openfoam-solving/)
-   -   LES of a confined impinging jet reactor.. (http://www.cfd-online.com/Forums/openfoam-solving/68581-les-confined-impinging-jet-reactor.html)

vishwa September 24, 2009 11:00

LES of a confined impinging jet reactor..
 
Hi Guys,
I am very very new to Openfoam. I have been using fluent to perform LES simulation for a some time now.

I have been trying to understand the tutorial files and it has not been that easy.

Here is what I did to get the case running.
  1. used fleunt3dtofoam and it worked well on the .cas file so long as i had not adapted the grid using fluent. is there a way to get it to work when the grid has been adapted?
  2. in fluent i used dynamic smagorinsky model. I couldn't find a template from the tutorials where this particular one has been used. so, i tried with oneEqeddy model in the pitzDaily folder. Even here I have a few problems
    1. how do you figure out what files are needed in the initial condition folder based on the model you choose. For the oneEqmodel, i saw the files B, k, p,U,nuSgs, nutilda..
    2. as to the type in those files like inletoutlet, turbulentinlet etc.where do i find a list of all available things that i could use and their description..I tried to look up the source code files and I am not too familiar with C++ :(.. In fluent, I say the inlet to be like plug flow and the outlet condition to be outflow. how do i specify that in the files?
    3. I finally managed to get it to run with a time step of 1e-6 seconds and it ran for like 10 steps wherein, the max courant number was like 0.19 and then from then onwards, the courant number kept increasing and in a matter a few more timesteps the courant number for 1e6 and the simulation stopped. Not sure why and what to check for.
    4. I then changed to model to dynSmagorinsky in the LES properties file and ran the case, at which point it gave a error about the filter.. I didn't know where to include that info for the solver. Fortunately, I had O1.5 installed as well. in the LES properties file there was inclusion for the filter. I included those lines in my LESproperties file and started the case and it is running now.. Not sure for how long it will run.
  3. Assuming that it will run without any issues, I need to get turbulent statistics like urms, vrms, wrms, tke etc..etc..on the midplane. How do I accomplish that?. I am not sure if this is relevant, but I am running this on a cluster.
As to the solve settings, I am just using the settings of pitzDaily with the LESmodel being dynSmagorinsky.

Sorry for the long posting..

Hope to hear from you guys soon and thanks a tonne in advance..

Vishwa

philippebv September 28, 2009 17:18

Hi Vishwa,

I'll try to give you some answers so you can go on with your simulations:

1. I don't know what you mean by "adapting the grid" in Fluent, but I usually use fluentMeshToFoam from a .msh file and it works fine. After, be sure to change the types of boundaries in constant/polymesh/boundary.

2.1 Look at the constructor in the .C file of the model you want to use. When MUST_READ is specified, this variable is needed.

2.2 You can refer to the manual for boundary conditions types. I'm not really sure about plug flow, but it sounds like a fixedValue for U (uniform inlet). You can set your outlet as zeroGradient for U and fixedValue for p.

2.3 For your courant number, I suggest you add some correctors for your Piso loop (2 or 3).

2.4 ...

3. For calculating values at each timestep, you can build a functionObject (refer to OpenFOAM-1.5/src/postProcessing/). You can also monitor variables using probes.

Good luck with your simulations and don't give up on OpenFOAM, it's well worth the effort!

Regards,

Philippe

grandgo December 4, 2010 16:23

dynSmagorinsky specifications
 
hello!

i'm very new in OF.....

i've been looking for "must-read" entries in dynSmagorinsky.C file but i can't find any.....
i still do not know, what this model needs:

1) which files i have to supply
2) how i can choose a filter
3) where i can specify a heat transfer model
4) the near wall treatment....

??

every tutorial case in OF 1.7.1 is using the "oneEqEddy" model. so i have no pattern...

can someone help me? or tell me, where i can find help?

thanks

best regards

alberto December 5, 2010 18:21

Quote:

Originally Posted by grandgo (Post 286014)
1) which files i have to supply

Clone a tutorial. It does not matter if you have additional files. Smagorinsky models do not need B and k, for example.

Quote:

2) how i can choose a filter
In the LESProperties dictionary, with something like

Code:

dynSmagorinskyCoeffs
{
    filter simple;
}

Quote:

3) where i can specify a heat transfer model
The energy equation is solved only in compressible LES solvers.

Quote:

4) the near wall treatment....
What wall treatment are you looking for?

Best,

grandgo December 5, 2010 18:36

hi alberto!

first, thanks for your replying.

1) you said, i can copy a tutorial case. but how do i know, which files a certain model needs? for example, the "oneEqEddy" model needs the "B" and "k" files, apparently. "dynSmagorinsky" doesn't need these files and they don't bother. but maybe it needs other files like "C" or "D"... so how do i get to know, WHICH files are needed IF needed?

4) i meant a near wall model. but after reading the user guide, i think this is specified in the 0/nut file....

best regards

alberto December 5, 2010 23:37

Hi,

Quote:

Originally Posted by grandgo (Post 286100)
1) you said, i can copy a tutorial case. but how do i know, which files a certain model needs? for example, the "oneEqEddy" model needs the "B" and "k" files, apparently. "dynSmagorinsky" doesn't need these files and they don't bother. but maybe it needs other files like "C" or "D"... so how do i get to know, WHICH files are needed IF needed?

You either read the code to see, or OpenFOAM will complain if an input file is missing.

Quote:

4) i meant a near wall model. but after reading the user guide, i think this is specified in the 0/nut file....
A "near wall model" for what? In 0/nut you can specify the wall-functions for nuSGS, and if you want a fully resolved LES at walls, do not specify the wall-function, but set zeroGradient.

P.S. Are you using the dynamic Smagorinsky model? If so, search for another thread I posted today on this topic. You might find my piece of code useful.

Best,

grandgo December 6, 2010 08:06

hi alberto,

i wanted to use the dynSmagorinsky model.
but there are two problems, i think:

1) i need a turbulence model that corresponds to the paper of germano et al (1991). and i read before, that dynSmagorinsky model doesnt match germano fully.

2) i need to use a heat transfer model. but you told me, that i have to use a compressible solver to do so. i could take the rhoPisoFoam solver, but there is no dynSmagorinsky model for compressible solvers (OF user guide 1.7.1).

do you have a solution?

i'm going to read your other posts now :)

thanks,
best regards

alberto December 6, 2010 11:53

Quote:

Originally Posted by grandgo (Post 286190)
hi alberto,

i wanted to use the dynSmagorinsky model.
but there are two problems, i think:

1) i need a turbulence model that corresponds to the paper of germano et al (1991). and i read before, that dynSmagorinsky model doesnt match germano fully.

Correct. The dynSmagorinsky model is implemented averaging coefficients on the whole domain, which is correct in the case of homogeneous turbulence.

You can pull an implementation that uses local values of the coefficients from my git repository:

git clone git://github.com/AlbertoPa/dynLocalAverageSmagorinsky.git

Test it before using it however.

Quote:

2) i need to use a heat transfer model. but you told me, that i have to use a compressible solver to do so. i could take the rhoPisoFoam solver, but there is no dynSmagorinsky model for compressible solvers (OF user guide 1.7.1).
The solution depends on your need. Do you need heat transfer in an incompressible code, or do you need a compressible code? :-)

If you need an incompressible code, simply add the energy equation to pisoFoam. If you need a compressible code, you will have to implement the compressible version of the dynamic model (not the one from Germano's paper, which does not provide closures for the energy equation).

Best,

grandgo December 7, 2010 19:11

hi alberto,

thanks for your support und patience...

can you explain me, how i can insert the energy equation:

{
solve
(
fvm::ddt(rho, h) (--> remove, right?)
+ fvm::div(phi, h)
- fvm::laplacian(turbulence->alphaEff(), h)
==
DpDt
);

thermo.correct();
}


in the pisoFoam.C file? copy and paste this and thats it??
i'm even worse in C++ than in OpenFoam....sorry

best regards
grandgo


All times are GMT -4. The time now is 01:45.