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

problems with surfaceScalaField

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

Reply
 
LinkBack Thread Tools Display Modes
Old   January 3, 2014, 15:14
Default problems with surfaceScalaField
  #1
Member
 
ziehjay
Join Date: Jul 2013
Posts: 43
Rep Power: 3
sanjar is on a distinguished road
Hello guys, i am working with DPMFoam based on the Goldschmidt Tutorial. Originally it has a manualInjection but i changed it into a patchInjetction.
After a few errors, which I was able to manage correctly I am realy fighting with the following problem:

Code:
--> FOAM FATAL ERROR: 

    request for surfaceScalarField phi from objectRegistry region0 failed
    available objects of type surfaceScalarField are

3
(
alphaPhic
phic
alphacf
)
Obwiously it is looking for this variable phi in surfaceScalarField.
Actually i dont know how to handle this problem. I tried to change it in my boundary conditions:

Code:
oundaryField
{
    WALL
    {
        type           zeroGradient;
    }
    OUTLET
    {
         type          totalPressure;
    p0        uniform 0;
    U        U;
    psi        none;
    gamma        1;
    phi        phi;
    value        uniform 0;
    }
    EROSIONPLATE
    {
        type            zeroGradient;
    }
    INLET
    {
        type           zeroGradient;
    }
}
sanjar is offline   Reply With Quote

Old   January 7, 2014, 14:42
Default
  #2
Member
 
ziehjay
Join Date: Jul 2013
Posts: 43
Rep Power: 3
sanjar is on a distinguished road
isn't there somebody who could help me...its a pretty serious issue..

thank you guys!
sanjar is offline   Reply With Quote

Old   January 8, 2014, 03:38
Default
  #3
Member
 
Kapa Lilla
Join Date: Mar 2009
Location: Bruxelles, Belgium
Posts: 32
Rep Power: 7
klilla is on a distinguished road
Dear Sanjar,

I do not know the solver you are using, but the error tells you what is the problem. It is looking for the flux field (phi) on the faces, called phi. Now, in your solver you do not have it, but only:

alphaPhic
phic
alphacf

by intuition, most probably phic is your flux, but that you know, I guess.

So what you need to do, instead of defining your flux as phi, change it to phic (or anything else your flux is defined as).

oundaryField
{
WALL
{
type zeroGradient;
}
OUTLET
{
type totalPressure;
p0 uniform 0;
U U;
psi none;
gamma 1;
phi phic;
value uniform 0;
}
EROSIONPLATE
{
type zeroGradient;
}
INLET
{
type zeroGradient;
}
}
I hope this is helping, best,
Lilla
klilla is offline   Reply With Quote

Old   January 8, 2014, 06:42
Default
  #4
Member
 
ziehjay
Join Date: Jul 2013
Posts: 43
Rep Power: 3
sanjar is on a distinguished road
Hey Lilla,

thank you very much for your response. I appreciate it very much.
To keep my answer short: I already changed my phi into phic and also into the other two types of my surfacescalarField.

But the error still exists. Thats why i am still on this post

Thank you at all!!!

Best regards, Sanjar
sanjar is offline   Reply With Quote

Old   January 8, 2014, 07:53
Default
  #5
Member
 
Kapa Lilla
Join Date: Mar 2009
Location: Bruxelles, Belgium
Posts: 32
Rep Power: 7
klilla is on a distinguished road
I see. I went to your solvers code, here you define the pressure earlier in the createField.H file than the phic. So you actually do not yet have phic, while you already want to use it for your BC on p. My idea, is that you need to move the definition of phic between Uc and p.

But this is just a suggestion to try.

Best,
Lilla
klilla is offline   Reply With Quote

Old   January 8, 2014, 08:02
Default
  #6
Member
 
ziehjay
Join Date: Jul 2013
Posts: 43
Rep Power: 3
sanjar is on a distinguished road
Hi Lilla,

thank you for that advice. Actually i dont know what you really mean with "moving". Which steps would you recommend?

BTW: During our conversation here i updated my OF 2.2.x and started again my case with the updated Goldschmidt-tutorial. But is still did not work. (If there is somebody who ha salso the same problem)

Best, Sanjar
sanjar is offline   Reply With Quote

Old   January 8, 2014, 08:07
Default
  #7
Member
 
Kapa Lilla
Join Date: Mar 2009
Location: Bruxelles, Belgium
Posts: 32
Rep Power: 7
klilla is on a distinguished road
Sorry, I was too short. So go to the source code of your solver and open the createFields.H file.

There you have the definition of Uc and p. After the p you have the definition of phic:


Info<< "Reading/calculating continuous-phase face flux field phic\n"
<< endl;


surfaceScalarField phic
(
IOobject
(
"phic",
runTime.timeName(),
mesh,
IOobject::READ_IF_PRESENT,
IOobject::AUTO_WRITE
),
linearInterpolate(Uc) & mesh.Sf()
);

This is the part you need to cut and put between Uc and p definition.

Then save the file and re-compile the solver. I think it should be your problem.
Best,
Lilla
klilla is offline   Reply With Quote

Old   January 8, 2014, 10:26
Default
  #8
Member
 
ziehjay
Join Date: Jul 2013
Posts: 43
Rep Power: 3
sanjar is on a distinguished road
Is it that simple as it seems?
I cut and paste this between p and Uc in my boundary conditions.
But what to do with the values like :

IOobject::READ_IF_PRESENT,
IOobject::AUTO_WRITE

How to handle these?
greetings sanjar
sanjar is offline   Reply With Quote

Old   January 13, 2014, 18:16
Default
  #9
Member
 
ziehjay
Join Date: Jul 2013
Posts: 43
Rep Power: 3
sanjar is on a distinguished road
hello guys, this is a kind of an update as for the ones who are also struggling wih the solver DPMFoam.

Actually i am not an expert but i am lucky that i get advice and help from Lilla, whose help and person i appreciate very much.

so this is the very first step t get a solution for this problem or at least an adviced path, which is basically an answr of Lilla, and which should be provide for the OF-community:

My problem doesnt come from my BC at all. The problem is mre cause by the naming of the variables as UC and phic. So the source code of the DPMFoam solver was analysed and there was that kind of error.

now i am trying to compile it with the following description by Liila:


"First of all, everything I refer to is starting from the DPMFoam directory.

In my company, we have a general installation, so I inserted the _USER_ tag in the ./Make/files file

"EXE=$(FOAM_USER_APPBIN)/DPMFoam"

The same applies to ./dragModels/Make/files

"EXE=$(FOAM_USER_LIBBIN)/libDPMDragModels"

This last line already tells that the dragmodels are a library to link and not a utility or solver. In order to compile it you have to use the:

"wmake libso"

command. Try to compile it.

Now that you have this library, you need to link in. Open the ./Make/options file. You need to add 2 lines. Now, I do not know what exactly, if you have your own compilation, just the way we work here:

"EXE_INC = \
...
-I./dragModels/lnInclude"

"EXE_LIBS = \
...
-L$(FOAM_USER_LIBBIN)"

with that you should be able to compile the solver, without problem."

If there is somebody who is working on DPMFoam too...maybe we can exhange information ...especially for the success of everybdy who is working on it.

Thank you guys, thank you Lilla!
sanjar is offline   Reply With Quote

Old   January 26, 2014, 13:59
Default
  #10
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 7,172
Blog Entries: 32
Rep Power: 70
wyldckat is a jewel in the roughwyldckat is a jewel in the roughwyldckat is a jewel in the rough
Greetings to all!

@sanjar: I was trying to reproduce the problem you had originally reported on this thread, but I don't have enough information to work with. I was doing this because creating a variant of the solver doesn't seem to me to be the best option, but only a workaround.

If possible, can you please provide information on the changes necessary on the tutorial case, so that I can test this as well and can ascertain if there is a bug in OpenFOAM's DPMFoam or not?
The simplest would be for you to:
  1. Change the tutorial "lagrangian/DPMFoam/Goldschmidt" according to what you've done for your case, which reproduces the same reported problem.
  2. Then run foamCleanTutorials inside the modified folder.
  3. Then compress the folder into zip or tar.gz.
  4. Then attach the compressed file on your next post.
Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   January 27, 2014, 19:01
Default
  #11
Member
 
ziehjay
Join Date: Jul 2013
Posts: 43
Rep Power: 3
sanjar is on a distinguished road
hello bruno,

my file size exceeds the size in this forum.
can you give me your email adress. i will send it to you via email

I HAVE A BIG PROBLEM NOW!!!

after i executed the command foamCleanTutorials the terminal worked for a few minutes.i worked also in openfoam 2.2.0 and openfoam 2.2.2. which i had installed.
i was wondering about that and also worried. and my worries became true!!!!!!!

i executed another case with icoUnocupledKinematicPArcelFoam which is very important for me and which runs with openfoam2.2.2

after executing simpleFoam the terminal says:

Code:
sanjar@sanjar-Lenovo-U410:~/OpenFOAM/sanjar-2.2.0/run-1/SA/generic/Box_Turbulent_Stroemung$ simpleFoam
simpleFoam: error while loading shared libraries: libmpi.so.1: cannot open shared object file: No such file or directory
WTF???
nothing works anymore! and i need that for my thesis.

i know that i will have a sleepless night!! what should i do??

PLEASE HELP!!!!
sanjar is offline   Reply With Quote

Old   January 28, 2014, 03:31
Default
  #12
Member
 
chenxizhong
Join Date: Feb 2012
Posts: 30
Rep Power: 4
chenxizh is on a distinguished road
sanjar, the error tells you that something is wrong while loading the mpi library,
you may type :
which mpirun
to get if the mpi work well or not
if you used the openmpi in ThiryParty, you may need to go the Thirypary
dir and run ./Allwmake

Quote:
Originally Posted by sanjar View Post
hello bruno,

my file size exceeds the size in this forum.
can you give me your email adress. i will send it to you via email

I HAVE A BIG PROBLEM NOW!!!

after i executed the command foamCleanTutorials the terminal worked for a few minutes.i worked also in openfoam 2.2.0 and openfoam 2.2.2. which i had installed.
i was wondering about that and also worried. and my worries became true!!!!!!!

i executed another case with icoUnocupledKinematicPArcelFoam which is very important for me and which runs with openfoam2.2.2

after executing simpleFoam the terminal says:

Code:
sanjar@sanjar-Lenovo-U410:~/OpenFOAM/sanjar-2.2.0/run-1/SA/generic/Box_Turbulent_Stroemung$ simpleFoam
simpleFoam: error while loading shared libraries: libmpi.so.1: cannot open shared object file: No such file or directory
WTF???
nothing works anymore! and i need that for my thesis.

i know that i will have a sleepless night!! what should i do??

PLEASE HELP!!!!
chenxizh is offline   Reply With Quote

Old   January 28, 2014, 03:39
Default
  #13
Member
 
ziehjay
Join Date: Jul 2013
Posts: 43
Rep Power: 3
sanjar is on a distinguished road
everything is allright (again)

Last edited by sanjar; January 30, 2014 at 08:09.
sanjar is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problems with rotational cyclic boundaries TReviol OpenFOAM Meshing & Mesh Conversion 8 July 11, 2014 03:45
[ICEM] Flow channel meshing problems StefanG ANSYS Meshing & Geometry 19 May 15, 2012 06:44
[ICEM] Problems with coedge curves and surfaces tommymoose ANSYS Meshing & Geometry 0 August 5, 2011 16:02
Two-phase air water flow problems by activating Wall Lubrication Force challenger85 CFX 5 November 5, 2009 05:44
Help required to solve Hydraulic related problems aero CFX 0 October 30, 2006 11:00


All times are GMT -4. The time now is 05:33.