CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Help with modification needed

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   December 28, 2008, 01:22
Default Hi, I modified the built-in
  #1
Member
 
Daniel Harlacher
Join Date: Mar 2009
Location: Davis, CA, United States
Posts: 60
Rep Power: 17
harly is on a distinguished road
Hi,

I modified the built-in kEpsilon model of OpenFoam according to a paper. unfortunately the results are not at all what we expected.

I used the standard kEpsilon Model and turbFoam to produce vortex shedding behind a square cylinder (Re = 20000) and then wanted to restart with my modified model.

The paper states (results with an proprietary code) that the effect should be almost instantly - considering I practically change C1_ in the code that makes sense to me.

But nothing happens the drag and lift coefficients are (periodic) exactly the same as before.

I tried a lot and I can rule out a wrong formula - what I can't rule out is the accidental misuse of variables while coding - therefore I hope you can take a look at my modification and check if I do something what should not be done.

Here is the important extract of my modified file:

RASModel::correct();

volScalarField G = nut_*2*magSqr(symm(fvc::grad(U_)));
volVectorField dU = fvc::ddt(U_);
volScalarField dUx = dU.component(0);
volScalarField dUy = dU.component(1);
volScalarField Gstar = 0.5*magSqr(U_)+k_;

volScalarField C1star = C1_+C1_*0.38*k_/epsilon_*1.0/(Gstar)
* mag(U_.component(vector::X)*dUx + U_.component(vector::Y)*dUy + fvc::ddt(k_));

Info << "Using modified kEpsilon model" << endl;

# include "wallFunctionsI.H"

// Dissipation equation
tmp<fvscalarmatrix> epsEqn
(
fvm::ddt(epsilon_)
+ fvm::div(phi_, epsilon_)
- fvm::Sp(fvc::div(phi_), epsilon_)
- fvm::laplacian(DepsilonEff(), epsilon_)
==
C1star*G*epsilon_/k_
- fvm::Sp(C2_*epsilon_/k_, epsilon_)
);
epsEqn().relax();


And here is the Link to the complete File: (I am sorry if your browser is showing a blue text between the code - just save the file to disk and it should be fine)

http://harly.de.vu/www/kEpsilonMod.C

Hope you find something
- harly
harly is offline   Reply With Quote

Old   December 28, 2008, 11:47
Default Harly, what paper you used as
  #2
New Member
 
Nikola Mirkov
Join Date: Mar 2009
Location: Belgrade, Serbia
Posts: 18
Rep Power: 17
nikola_m is on a distinguished road
Harly, what paper you used as your reference?
__________________
www.laturbolenza.com
nikola_m is offline   Reply With Quote

Old   December 28, 2008, 12:25
Default Hey no problem: http://harl
  #3
Member
 
Daniel Harlacher
Join Date: Mar 2009
Location: Davis, CA, United States
Posts: 60
Rep Power: 17
harly is on a distinguished road
Hey no problem:

http://harly.de.vu/www/Paper.pdf

I am implementing the formulation (15) in the kEpsilonMod.C.

I am using the same mesh (described in the paper) and also Re = 20000

please don't distribute the paper - thanks

- harly
harly is offline   Reply With Quote

Old   December 28, 2008, 12:46
Default Thanks - I asked you because I
  #4
New Member
 
Nikola Mirkov
Join Date: Mar 2009
Location: Belgrade, Serbia
Posts: 18
Rep Power: 17
nikola_m is on a distinguished road
Thanks - I asked you because I plan to do a similar thing. I was involved in simulating atmospheric boundary layer with modified two- equation models of turbulence (I'll send you a paper if you're interested) so I wanted to implement such "Atmospheric Boundary Layer k-e" here.

I'll take a look at your modification and see if I can help something.

Nikola
__________________
www.laturbolenza.com
nikola_m is offline   Reply With Quote

Old   January 5, 2009, 15:28
Default Hi, I am back from the hol
  #5
Member
 
Daniel Harlacher
Join Date: Mar 2009
Location: Davis, CA, United States
Posts: 60
Rep Power: 17
harly is on a distinguished road
Hi,

I am back from the holidays and still can't find my mistake. So please if someone has an idea I am open for everything.

@Nikola: Did you have time to take a look at my code? - and yes please send me the paper of your modification.

- harly
harly is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
modification of UDF ammi FLUENT 2 January 18, 2007 22:35
Fluent GUI modification Tuomas FLUENT 20 November 6, 2006 16:58
KIVA Modification Gede Main CFD Forum 0 May 10, 2006 23:06
modification for CFX? caty CFX 5 May 19, 2005 19:48
UDF modification merac FLUENT 4 March 1, 2001 07:42


All times are GMT -4. The time now is 07:35.