# nutRoughWallFunction v1.6

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

 August 21, 2009, 04:30 nutRoughWallFunction v1.6 #1 Member   Julien Schaguene Join Date: Apr 2009 Location: France Posts: 55 Rep Power: 10 Hi all, testing some "new" features given by v1.6, I found this one quite different from previous version, and want to use it. My issue is the understanding of some pieces of code. First, these two lines in function calcNut(): tmp tnutw(new scalarField(patch().size(), 0.0)); scalarField& nutw = tnutw(); I understand it initialise a scalarField nutw, uniform 0 value, with the size of the patch I'm dealing with. But the two things I do not get are: - dummy question: what does tmp stand for? temporary? - does it initialise this scalarField at each time step? in this case, this boundary type would seem quite useless regarding the calculation of nutw that follows. It might seem dummy questions, but I have to begin to understand one day or another. Thanks for answers! Regards, Julien

 October 1, 2009, 05:44 #2 New Member   John O\'Sullivan Join Date: Mar 2009 Location: Auckland, New Zealand Posts: 7 Rep Power: 10 Hi Julien, I'm looking at the same thing and have come to the same conclusion. I had written my own rough wall function in version 1.5 and was surprised when version 1.6 gave me different results today when I started testing it. I have 1-D simulations I use to generate profiles and they have a single cell at the ground which makes them pretty easy to debug. I've found the same thing as you, namely that nutw is set to 0 every time step. This means that scalar limitingNutw = max(nutw[faceI], nuw[faceI]); always returns limitingNutw = nuw[faceI]. This in turn means that nutw[faceI] = max ( min ( nuw[faceI] *(yPlus*kappa_/log(max(Edash*yPlus, 1+1e-4)) - 1), 2*limitingNutw ), 0.5*limitingNutw ); always returns nutw[faceI] = 2*limitingNutw To test the rest of the code I hard coded a known value for limitingNutw and everything works fine. I admit my OpenFOAM C++ is not fantastic so I'm not really sure what nutw should be initialised to? Probably the value from the previous time step? I think it probably shouldn't be initialised to 0 initially either but should be read from the nut file? This is the first potential bug I've stumbled across and I'm not sure what the procedure is for submitting it for someone to have a look at. Advice anyone? Thanks! John

 October 1, 2009, 16:28 #3 Super Moderator   Mattijs Janssens Join Date: Mar 2009 Posts: 1,419 Rep Power: 18 To report bugs: http://www.opencfd.co.uk/openfoam/bugs.html If applicable also provide a testcase.

 Thread Tools Display Modes Linear Mode

 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 OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post bruce OpenFOAM Bugs 7 December 16, 2011 15:37 Gavin OpenFOAM 9 October 23, 2009 04:16 bruce OpenFOAM Running, Solving & CFD 1 August 7, 2009 13:15 Schag OpenFOAM Bugs 2 July 28, 2009 13:41

All times are GMT -4. The time now is 13:54.