CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Community Contributions

[swak4Foam] groovyBC in openFOAM-2.0 for parabolic velocity bc

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

Like Tree1Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 26, 2013, 05:27
Default
  #21
Senior Member
 
Illya Shevchuk
Join Date: Aug 2009
Location: Darmstadt, Germany
Posts: 176
Rep Power: 16
linch is on a distinguished road
The version was 0.2.3 (next to last according to Swak4Foam-Wiki) and suitable to OF up to 2.2 (2.1 is the one I use).

Now I've got v0.2.4 (release, available via svn, must be the latest one), but the errors are still there.

There are also a couple of other error related to openmpi (see attachment for the full log)
Code:
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Waitall'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Abort'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `ompi_mpi_double'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Get_count'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Init'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Probe'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Send'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Allreduce'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `ompi_mpi_packed'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Buffer_detach'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Bsend'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `ompi_mpi_byte'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Irecv'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Recv'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `ompi_mpi_comm_world'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Get_processor_name'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Test'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Isend'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Finalize'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `ompi_mpi_op_sum'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Buffer_attach'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Comm_size'
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Comm_rank'
. Somehow, swak is looking for the "OF-internal" openmpi, while an external is used. I think I'm missing something.

Best regards,
Ilya
Attached Files
File Type: gz log.Allwmake.gz (14.6 KB, 5 views)
linch is offline   Reply With Quote

Old   August 26, 2013, 08:02
Default
  #22
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by linch View Post
The version was 0.2.3 (next to last according to Swak4Foam-Wiki) and suitable to OF up to 2.2 (2.1 is the one I use).

Now I've got v0.2.4 (release, available via svn, must be the latest one), but the errors are still there.

There are also a couple of other error related to openmpi (see attachment for the full log)
Code:
/home/shevchuk/OpenFOAM/OpenFOAM-2.1.x/platforms/linux64GccDPOpt/lib/openmpi-system/libPstream.so: undefined reference to `MPI_Waitall'
. Somehow, swak is looking for the "OF-internal" openmpi, while an external is used. I think I'm missing something.

Best regards,
Ilya
Have you ever tried compiling other software than swak with that installation? Because it seems that this is a problem with the installation, not swak. swak doesn't specify which MPI to use but uses the options that wmake automatically generates (have a look for instance at Utilities/replayTransientBC/Make/options - that is one of the links that is failing and it uses only standard-options).

What version of Linux are you using?
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request
gschaider is offline   Reply With Quote

Old   August 26, 2013, 12:06
Default
  #23
Senior Member
 
Illya Shevchuk
Join Date: Aug 2009
Location: Darmstadt, Germany
Posts: 176
Rep Power: 16
linch is on a distinguished road
Thanks Bernhard,

the problem was indeed somewhere else. I was looking for it for a while with our admin, who takes care of the cluster. Finally, his conclusion was that the openmpi installed on the cluster was compiled with intel compiler while OF uses gcc. However, compiling ThirdPartys and src's caused no errors, these errors occurred only while compiling some application and swak4foam. After recompiling the openmpi with gcc, everything was ok.

Nevertheless, the warnings
Quote:
could not open file [...] for source file [...]
are still there. But since there are no errors, I think it's ok.

Thank you for the hints and best regards,
Ilya
linch is offline   Reply With Quote

Old   July 10, 2015, 10:44
Default groovyBC problems
  #24
New Member
 
Join Date: Jul 2015
Posts: 2
Rep Power: 0
bufs is on a distinguished road
Hi guys,


it's my first time using groovyBC and I'm trying to set up a parabolic profile of inlet velocity. What I'm doing is editing the U file to have the following code for inlet

Code:
inlet
    {
        type               groovyBC;
    variables          "yp = pts().y; minY = min(yp); maxY = max(yp); rad = 0.5*(maxY - minY); vavg = 0.23;";
    valueExpression    "2.0*vavg*(1.0-pow(pos().y/rad, 2))*normal()";
    value              uniform (10 0 0);
    }
and also I edited the controlDict file in system to include

Code:
libs ("libOpenFOAM.so"
      "libsimpleSwakFunctionObjects.so"
      "libswakFunctionObjects.so"
      "libgroovyBC.so"
);
But, when I run the case I get the following message

Code:
Create time

Create mesh for time = 0

Selecting dynamicFvMesh dynamicMotionSolverFvMesh
Selecting motion solver: displacementSBRStress
Selecting motion diffusion: inverseDistance
Reading field p

Reading field U

Reading/calculating face flux field phi

Selecting incompressible transport model Newtonian
Selecting turbulence model type laminar
Reading field rAU if present

No field sources present


PIMPLE: no residual control data found. Calculations will employ 2 corrector loops


Starting time loop

Courant Number mean: 0.00054139691 max: 0.023902054
deltaT = 0.00011990408
Time = 0.00011990408

DICPCG:  Solving for cellDisplacementx, Initial residual = 0, Final residual = 0, No Iterations 0
DICPCG:  Solving for cellDisplacementy, Initial residual = 0, Final residual = 0, No Iterations 0
word::stripInvalid() called for word yp
    For debug level (= 2) > 1 this is considered fatal
Aborted (core dumped)
Anyone knows what I'm doing wrong?
bufs is offline   Reply With Quote

Old   August 23, 2015, 23:41
Default
  #25
New Member
 
Xavier Pivan
Join Date: May 2015
Posts: 10
Rep Power: 10
Navip is on a distinguished road
Hi Bernhard,

I use openfoam/2.3.0 on a virtual machine (MASSIVE). I try to implement a zero flux condition via swaf4foam. I have swak4foam/2.3.0. I guess it is well installed as the answer to the command module show swak4foam/2.3.0

-------------------------------------------------------------------
/usr/local/Modules/modulefiles/swak4foam/2.3.0:

conflict swak4foam
module load openfoam/2.3.0
module load bison
module-whatis An OpenFOAM library that combines the functionality of groovyBC (boundary conditions) and funkySetFields (set fields) (v2.3.0)
prepend-path LD_LIBRARY_PATH /usr/local/swak4foam/2.3.0/lib
prepend-path PATH /usr/local/swak4foam/2.3.0/bin
prepend-path MANPATH /usr/local/swak4foam/2.3.0/man
setenv GCONV_PATH /usr/lib64/gconv/
setenv SWAK4FOAM_SRC /usr/local/swak4foam/2.3.0/Libraries
-------------------------------------------------------------------





So the installation seems to be complete. When I try to set up the path of the plug-in

libs (
"libgroovyBC.so"
);

I have a FOAM:WARNING

--> FOAM Warning :
From function dlOpen(const fileName&, const bool)
in file POSIX.C at line 1179
dlopen error : libgroovyBC.so: cannot open shared object file: No such file or directory
--> FOAM Warning :
From function dlLibraryTable:pen(const fileName&, const bool)
in file db/dynamicLibrary/dlLibraryTable/dlLibraryTable.C at line 99
could not load "libgroovyBC.so"

The foam warning doesn't stop the program as this isn't a fatal error. But I need to use this groovyBC for my boundary condition. My boundary condition is:

upperWall
{
type groovyBC;
value uniform (0 0 0);
valueExpression "0.001*T-DT*fvc::snGrad(T)"
}

And as expected I now have a fatal error:

--> FOAM FATAL IO ERROR:
Unknown patchField type groovyBC for patch type patch

Valid patchField types are :.......


Do you have any idea how I can solve this problem? Why do I receive a foam warning for the .so file while swak4foam is apparently well installed.
Navip is offline   Reply With Quote

Old   March 6, 2017, 11:03
Default groovyBC or codedfixedValue
  #26
New Member
 
Sachin
Join Date: Sep 2016
Location: Poitiers,France
Posts: 17
Rep Power: 9
smodh is on a distinguished road
Hello Foamers,

I want to implement a boundary condition at electrode.

N_P= K * Efield * N_P

I am solving following equation with modified pisoFoam.

(fvm::ddt(N_P)) + (fvm::div(phi+(K*Efield), N_P))

and for the electrode, I have to implent following BC, N_P = K * Efield * N_P.
so my BC condition will change with every time step.

In this equation N_P and Efield " need to be taken from electrode at previous time step and K is dimensionedScalar fix value 1.

Should I have to used codedfixed BC or some other BC? I have also trying groovyBC but I am failed.
is there anyone know how to implemrnt this BC?
Thanks in advance.
smodh is offline   Reply With Quote

Reply

Tags
boundary conditions, groovybc, velocity inlet

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
Map of the OpenFOAM Forum - Understanding where to post your questions! wyldckat OpenFOAM 10 September 2, 2021 06:29
[swak4Foam] groovyBC in openFoam 230 imani OpenFOAM Community Contributions 19 April 6, 2015 08:25
[swak4Foam] Power law inlet velocity using groovyBC aviator OpenFOAM Community Contributions 3 November 13, 2013 11:50
[swak4Foam] Velocity waveform with groovyBC bcgooder OpenFOAM Community Contributions 3 December 5, 2012 14:45
Terrible Mistake In Fluid Dynamics History Abhi Main CFD Forum 12 July 8, 2002 10:11


All times are GMT -4. The time now is 01:30.