funkySetFields
Hi,
I discovered the lib funkySetFields to define nonconformal initial conditions. I would like to know, if it is possible to set for one zone of the mesh a initial condition with fixed value (k=0) with funkySetFields. Therby I want to define a porous zone as a laminar zone. If you have an other idea to define a laminar zone without using mutliRegion, I would be glad about. Best regards Chrisi |
Quote:
Bernhard |
Thank you,
I understood right, it is possible to define fixed values as initial conditon, but k=0 is bad? Would mut=0 be a better definition? Regards Chrisi |
Quote:
k=0 anywhere usually results in a divisionByZero-error (try it). Quote:
|
Hi Chrisi,
if you only want your porous zones to be treated as laminar, I would suggest to use mut=0 is this region. Because can't be done directly, I'd suggest the following workaround. Just replace your UEqn Code:
tmp<fvVectorMatrix> UEqn Code:
volScalarField muEff = turbulence->muEff(); Regards, Stefan |
Hi,
Thank you for your suggestion. I tried solving with this, but I did not get a laminar zone. Perhabs I have to define somewhere in the code you gave me the name of my porous zone, haven't I? I tried solving with exactly your posted code. Or should I personalize your code in a different way for my case? Thanks in advance! Regards Chrisi |
Hi Chrisi,
yes indeed, you might add some code at Code:
//if this is a porous zone One more thing I have forgotten: You will have to do the same thing for alphaEff used in hEqn, because the changes in mut are not reported back to the turbulence model and therefore won't effect calculation of alphaEff from mut. BTW: Maybe there is still a more elegant way to solve your problem. Keep on trying... Regards, Stefan |
Hi Herbert,
thanks for your efforts. But I 'm sorry I dont know how to put in this if statement. Because I have only one porous zone inside my mesh, it would be easier not to exclude all other zones I think. How can I make an if statement to call different cell zones. Can you translate your code for me? That would be so nice of you. Regards Chrisi |
Hi Chrisi,
I thought about something like this: Code:
forAll(mesh.cellZones(), iZone) //loop over all cellZones Regards, Stefan |
Hi,
thank you again. At the moment your suggestions did not change really much, but it can be right anyhow. So now why what I want to do: I want to find an equivalent for the laminar zone for porous regions like in Fluent. That there are no turbulent swirls in my porous zone. I must check with an other case, if your code allow exactly this. Best regards Chrisi |
Hi,
Is it possible to call setFields during the calculation to overwirte mut only in my porous zone with zero in every time step? Regards Chrisi |
All times are GMT -4. The time now is 10:00. |