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

simpleFoam change, k field

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By nimasam

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 31, 2013, 07:44
Default simpleFoam change, k field
  #1
Member
 
Reza
Join Date: Feb 2012
Posts: 67
Rep Power: 14
gooya_kabir is on a distinguished road
Hi friends,

I have changed the PDE models in simpleFoam and removed the turbulence part in the UEqn.H and I added: laplacian (nu, U) instead of that. When I start to run, it works, but after 50 steps (means first writeInterval which is 50), below error appears.
It means that? Also, I turned the RASmodel to laminar in constant/RASmodel. Even I put k and epsilon in my initial directory, still this error appears.

Thank you for your comments.

streamLine : seeded 0 particles.
[3] [1]
[1]
[1] --> FOAM FATAL ERROR:
[1] Cannot find field k
Valid scalar fields are:
3
(
pPrevIter
nu
p
)

Valid vector fields are:1(U)
[1]
[1] From function streamLine::execute()
[1] in file streamLine/streamLine.C at line 197.
[1]
FOAM parallel run exiting

Last edited by gooya_kabir; October 31, 2013 at 09:21.
gooya_kabir is offline   Reply With Quote

Old   October 31, 2013, 09:23
Exclamation error in tutorial
  #2
Member
 
Reza
Join Date: Feb 2012
Posts: 67
Rep Power: 14
gooya_kabir is on a distinguished road
It's interesting that if I change RASmodel to laminar in pitzDaily Tutorial and solve it with simpleFoam, the same error appears. So something is wrong with this solver?
gooya_kabir is offline   Reply With Quote

Old   October 31, 2013, 09:46
Default
  #3
Senior Member
 
Nima Samkhaniani
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,266
Blog Entries: 1
Rep Power: 24
nimasam is on a distinguished road
Quote:
streamLine : seeded 0 particles.
[3] [1]
[1]
[1] --> FOAM FATAL ERROR:
[1] Cannot find field k
Valid scalar fields are:
3
(
pPrevIter
nu
p
)

Valid vector fields are:1(U)
[1]
[1] From function streamLine::execute()
[1] in file streamLine/streamLine.C at line 197.
[1]
FOAM parallel run exiting
Dear Reza
it relates to streamLine function which may address in controlDict, if you disable it, then it would run smoothly
__________________
My Personal Website (http://nimasamkhaniani.ir/)
Telegram channel (https://t.me/cfd_foam)
nimasam is offline   Reply With Quote

Old   October 31, 2013, 10:06
Default ControlDict
  #4
Member
 
Reza
Join Date: Feb 2012
Posts: 67
Rep Power: 14
gooya_kabir is on a distinguished road
Thank you very much
My controlDict is as usual, but just there is a extra part at the end !!! which is:
functions
{
streamLines
{
type streamLine;

// Where to load it from (if not already in solver)
functionObjectLibs ("libfieldFunctionObjects.so");

// Output every
outputControl outputTime;
// outputInterval 10;

setFormat vtk; //gnuplot;//xmgr;//raw;//jplot;//csv;//ensight;

// Velocity field to use for tracking.
UName U;

// Tracked forwards (+U) or backwards (-U)
trackForward true;

// Names of fields to sample. Should contain above velocity field!
fields (p k U);

// Steps particles can travel before being removed
lifeTime 10000;

// Number of steps per cell (estimate). Set to 1 to disable subcycling.
nSubCycle 5;

// Cloud name to use
cloudName particleTracks;

// Seeding method. See the sampleSets in sampleDict.
seedSampleSet uniform; //cloud;//triSurfaceMeshPointSet;

uniformCoeffs
{
type uniform;
axis x; //distance;

start (-0.0205 0.001 0.00001);
end (-0.0205 0.0251 0.00001);
nPoints 10;
}
}
}

I should remove all of that?
gooya_kabir is offline   Reply With Quote

Old   October 31, 2013, 10:13
Talking
  #5
Member
 
Reza
Join Date: Feb 2012
Posts: 67
Rep Power: 14
gooya_kabir is on a distinguished road
I removed all of that. and now it is working )))))))))))))))))))))

Many thanks
gooya_kabir is offline   Reply With Quote

Old   October 31, 2013, 10:45
Default
  #6
Senior Member
 
Nima Samkhaniani
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,266
Blog Entries: 1
Rep Power: 24
nimasam is on a distinguished road
Quote:
functions
{
streamLines
{
type streamLine;

// Where to load it from (if not already in solver)
functionObjectLibs ("libfieldFunctionObjects.so");

// Output every
outputControl outputTime;
// outputInterval 10;

setFormat vtk; //gnuplot;//xmgr;//raw;//jplot;//csv;//ensight;

// Velocity field to use for tracking.
UName U;

// Tracked forwards (+U) or backwards (-U)
trackForward true;

// Names of fields to sample. Should contain above velocity field!
fields (p k U);

// Steps particles can travel before being removed
lifeTime 10000;

// Number of steps per cell (estimate). Set to 1 to disable subcycling.
nSubCycle 5;

// Cloud name to use
cloudName particleTracks;

// Seeding method. See the sampleSets in sampleDict.
seedSampleSet uniform; //cloud;//triSurfaceMeshPointSet;

uniformCoeffs
{
type uniform;
axis x; //distance;

start (-0.0205 0.001 0.00001);
end (-0.0205 0.0251 0.00001);
nPoints 10;
}
}
}
you just need to remove k :P, however if you dont need that function , you can easily remove all
gooya_kabir likes this.
__________________
My Personal Website (http://nimasamkhaniani.ir/)
Telegram channel (https://t.me/cfd_foam)
nimasam 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
Laminar simpleFoam and inviscid simpleFoam herenger OpenFOAM Running, Solving & CFD 7 July 11, 2013 06:27
simpleFoam: strange error samiam1000 OpenFOAM 7 December 11, 2012 03:52
where is the calculation of the temperature field Tobi OpenFOAM 1 July 30, 2012 10:40
How to change turbulence model in InterFoam Gildeh OpenFOAM Running, Solving & CFD 4 March 28, 2012 12:04
Dimension change in solver like simpleFoam booz OpenFOAM Running, Solving & CFD 2 August 21, 2008 11:35


All times are GMT -4. The time now is 06:31.