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

Setting up atmBoundaryLayerInletVelocity

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 5, 2015, 06:28
Default Setting up atmBoundaryLayerInletVelocity
  #1
New Member
 
Zulfadli
Join Date: Sep 2015
Posts: 3
Rep Power: 10
zulfadli555 is on a distinguished road
Hi guys,

this is my first post here! Anyways I am trying to set up a case where the inlet is a log profile using the function: atmBoundaryLayerInletVelocity

here is my U:

FoamFile
{
version 2.0;
format ascii;
class volVectorField;
object U;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions [0 1 -1 0 0 0 0];

internalField uniform (1 0 0);

boundaryField
{
x_
{
type atmBoundaryLayerInletVelocity;
Uref 5.0;
Href 0.12;
z (0 0 1);
n (1 0 0);
z0 uniform 0.01;
zGround uniform 0.0;
value $internalField;
}

_x
{
type zeroGradient;
}

y_
{
type slip;

}
_y
{
type slip;
}

_z
{
type slip;
}

building_medb15
{
type fixedValue;
value uniform (0 0 0);
}

ground_wall
{
type fixedValue;
value uniform (0 0 0);
}

"proc.*"
{
type processor;
}

".*"
{
type fixedValue;
value uniform (0 0 0);
}
}

// ************************************************** *********************** //

Using "uniform" i get the error:
wrong token type - expected Scalar, found on line 30 the word 'uniform'
Using "constant" i get the same error:
wrong token type - expected Scalar, found on line 30 the word 'constant'

While just typing:

x_
{
type atmBoundaryLayerInletVelocity;
Uref 5.0;
Href 0.12;
z (0 0 1);
n (1 0 0);
z0 0.01;
zGround 0.0;
value $internalField;
}
I get the error:

--> FOAM Warning :
From function Field<Type>::Field(const word& keyword, const dictionary&, const label)
in file /home/zbbong/build/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/Field.C at line 262
Reading "/gpfs/home/zulfadli001/15b5-grid3TestABLinlet/0/U::boundaryField::x_" from line 25 to line 31
expected keyword 'uniform' or 'nonuniform', assuming deprecated Field format from Foam version 2.0.
Reading/calculating face flux field phi

I manage to get it running with this but pimpleFoam tends to diverge and whatever data I've compiled so far, there is no such indication of any inlet velocity.





Also, can somebody tell me if I need to indicate "value"? I had added it in after getting another foam error while decomposePar:
--> FOAM FATAL IO ERROR:

Cannot find 'value' entry on patch x_ of field U in file "/gpfs/home/zulfadli001/15b5-grid3TestABLinlet/0/U"
which is required to set the values of the generic patch field.
(Actual type atmBoundaryLayerInletVelocity)

Please add the 'value' entry to the write function of the user-defined boundary-condition


file: /gpfs/home/zulfadli001/15b5-grid3TestABLinlet/0/U::boundaryField::x_ from line 25 to line 31.





I can't just copy the turbine siting files from the tutorial as I am running the case on the school server and it uses version 2.1.0.

Any help would be appreciated.

Cheers

Last edited by zulfadli555; October 6, 2015 at 22:30.
zulfadli555 is offline   Reply With Quote

Old   October 5, 2015, 20:06
Default
  #2
Member
 
Goncalo Pedro
Join Date: Nov 2009
Location: Victoria, British Columbia
Posts: 30
Rep Power: 16
gonpe is on a distinguished road
You are missing a semi colon when specifying the x_ boundary condition.

x_
{
type atmBoundaryLayerInletVelocity;
Uref 5.0;
Href 0.12;
z (0 0 1);
n (1 0 0);
z0 uniform 0.01;
zGround uniform 0.0;
value $internalField
}


Should read

x_
{
type atmBoundaryLayerInletVelocity;
Uref 5.0;
Href 0.12;
z (0 0 1);
n (1 0 0);
z0 uniform 0.01;
zGround uniform 0.0;
value $internalField;
}
gonpe is offline   Reply With Quote

Old   October 6, 2015, 00:19
Default
  #3
New Member
 
Zulfadli
Join Date: Sep 2015
Posts: 3
Rep Power: 10
zulfadli555 is on a distinguished road
Hi gonpe,

thanks for pointing it out. I have double checked, I prolly hit a backspace when i copied it over. I am still facing the same errors.

Appreciate if anyone can provide some advice!
zulfadli555 is offline   Reply With Quote

Old   October 6, 2015, 13:59
Default
  #4
Member
 
Goncalo Pedro
Join Date: Nov 2009
Location: Victoria, British Columbia
Posts: 30
Rep Power: 16
gonpe is on a distinguished road
Quote:
Using "uniform" i get the error:
wrong token type - expected Scalar, found on line 30 the word 'uniform'
Using "constant" i get the same error:
wrong token type - expected Scalar, found on line 30 the word 'constant'
The input files changed between versions 2.0 and later versions (maybe 2.1 ... not sure). There was probably a change in how the z0 and zGround was specified between the 2 solvers.

I am a bit confused ... you mention that the case runs but diverges at one point in your post but then say that it doesn't decompose properly.

If you can't decompose a case, odds are you wouldn't be able to run it.
gonpe is offline   Reply With Quote

Old   October 6, 2015, 22:37
Default
  #5
New Member
 
Zulfadli
Join Date: Sep 2015
Posts: 3
Rep Power: 10
zulfadli555 is on a distinguished road
Hi gonpe,

Thank you for your reply and sorry for the confusion.

Im able to run it if i have:
"x_
{
type atmBoundaryLayerInletVelocity;
Uref 5.0;
Href 0.12;
z (0 0 1);
n (1 0 0);
z0 0.01;
zGround 0.0;
value $internalField;
}

But yeah I get the error:

"--> FOAM Warning :
From function Field<Type>::Field(const word& keyword, const dictionary&, const label)
in file /home/zbbong/build/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/Field.C at line 262
Reading "/gpfs/home/zulfadli001/15b5-grid3TestABLinlet/0/U::boundaryField::x_" from line 25 to line 31
expected keyword 'uniform' or 'nonuniform', assuming deprecated Field format from Foam version 2.0.
Reading/calculating face flux field phi"

I'm running LES with pimpleFoam and the deltaT keeps getting smaller be it i assign 100 or 200 iterations. And after reconstructing and foamToVTK whatever data I have, viewing in paraview reveals no other velocity but the internalField with velocity of 1

:/

Thanks!
zulfadli555 is offline   Reply With Quote

Old   October 8, 2015, 13:34
Default
  #6
Member
 
Goncalo Pedro
Join Date: Nov 2009
Location: Victoria, British Columbia
Posts: 30
Rep Power: 16
gonpe is on a distinguished road
Hi

The message is not really an error but a warning. Since you are running OF2.1 , it expects:

x_
{
type atmBoundaryLayerInletVelocity;
Uref 5.0;
Href 0.12;
z (0 0 1);
n (1 0 0);
z0 uniform 0.01;
zGround uniform 0.0;
value $internalField;
}

but it assumes you were trying to set a uniform value to those parameters.

In terms of the run .. .are you able to run it with a RANS solver? Steady state?
gonpe is offline   Reply With Quote

Reply


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
using chemkin JMDag2004 OpenFOAM Pre-Processing 2 March 8, 2016 22:38
[snappyHexMesh] determining displacement for added points CFDnewbie147 OpenFOAM Meshing & Mesh Conversion 1 October 22, 2013 09:53
Residual level setting of Fluent lhlh ANSYS 2 November 17, 2012 21:35
Cells with t below lower limit Purushothama Siemens 2 May 31, 2010 21:58
Warning 097- AB Siemens 6 November 15, 2004 04:41


All times are GMT -4. The time now is 18:42.