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

bug while forcing boundedness

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 1, 2011, 12:14
Default bug while forcing boundedness
  #1
Member
 
Laurent Orgogozo
Join Date: Mar 2011
Location: Toulouse
Posts: 33
Rep Power: 15
Orgogozo is on a distinguished road
Dear Foamers,

I'm a beginners in the use of OF and I try to make a 3D parallel resolution of a solute transport problem in a flow cell partly occupied by a fluid phase flowing, with convection and diffusion of the solute, and by an immobile phase in which there is only diffusive transport and a first order reaction of consumption. The flowfield is computed previously and is introduced by the use of mapFields.

I am implementing a user modified solver, in which I try to force the boundedness of the solute concentration between 0 and the concentration of injection; the use of limitedVanLeer schemes, bounded snGradSchemes, etc improve the boundedness but it is not totally efficient. So additionnaly I write directly in the source code (fully shown at the end of this message) something like :

D = alpha1*cinj+(1-alpha1)*cinj;

Ads = alpha1*0+(1-alpha1)*0;

c = min(max(c,Ads),D);

just after my solve command, in which Ads and D are volScalarFields containing the minimum and maximum desired concentration.

I manage to compile my solver (called bioFoam2), but when I run it in my case by typing

mpirun -np 4 bioFoam2 -parallel

, it gives me the error message written below. And when the three lines for forcing boundedness shown above are not written in the source code, it runs, but it diverges quite quickly.

Does anyone have an idea of what is my mistake ? Thanks by advance.

Kind regards,

Laurent

----------------------------------------------------------------------------------------------------------------------------
----------------------------------------------------------------------------------------------------------------------------

ERROR MESSAGE:

p { margin-bottom: 0.21cm; } [2] #3



[1] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
[1] #4 [3] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
[3] #4 [0] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
[0] #4
[2] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
[2] #4

[1] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
[1] #5 __libc_start_main
[3] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
[3] #5 __libc_start_main[2] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
[2] #5 __libc_start_main[0] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
[0] #5 __libc_start_main in "/lib/tls/i686/cmov/libc.so.6"
[3] #6 in "/lib/tls/i686/cmov/libc.so.6"
[1] #6 in "/lib/tls/i686/cmov/libc.so.6"
[2] #6 in "/lib/tls/i686/cmov/libc.so.6"
[0] #6



--------------------------------------------------------------------------
MPI_ABORT was invoked on rank 3 in communicator MPI_COMM_WORLD
with errorcode 1.

NOTE: invoking MPI_ABORT causes Open MPI to kill all MPI processes.
You may or may not see output from other processes, depending on
exactly when Open MPI kills them.
--------------------------------------------------------------------------
[2] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
[3] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
[1] in "/home/laurent/OpenFOAM/laurent-1.7.1/applications/bin/linuxGccDPOpt/bioFoam2"
--------------------------------------------------------------------------
mpirun has exited due to process rank 2 with PID 9779 on
node etna exiting without calling "finalize". This may
have caused other processes in the application to be
terminated by signals sent by mpirun (as reported here).
--------------------------------------------------------------------------
[etna:09776] 2 more processes have sent help message help-mpi-api.txt / mpi-abort
[etna:09776] Set MCA parameter "orte_base_help_aggregate" to 0 to see all help / error messages


-----------------------------------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------------------------------------



CREATEFIELDS.H of bioFoam2:

Info<< "Reading transportProperties\n" << endl;

IOdictionary transportProperties
(
IOobject
(
"transportProperties",
runTime.constant(),
mesh,
IOobject::MUST_READ,
IOobject::NO_WRITE
)
);

dimensionedScalar Deau
(
transportProperties.lookup("Deau")
);

dimensionedScalar Dbio
(
transportProperties.lookup("Dbio")
);

dimensionedScalar Adsbio
(
transportProperties.lookup("Adsbio")
);

dimensionedScalar cinj
(
transportProperties.lookup("cinj")
);

Info<< "Reading field c\n" << endl;
volScalarField c
(
IOobject
(
"c",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
mesh
);

Info<< "Reading field alpha1\n" << endl;
volScalarField alpha1
(
IOobject
(
"alpha1",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
mesh
);

Info<< "Reading field D\n" << endl;
volScalarField D
(
IOobject
(
"D",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
mesh
);

Info<< "Reading field Ads\n" << endl;
volScalarField Ads
(
IOobject
(
"Ads",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
mesh
);


Info<< "Reading field U\n" << endl;
volVectorField U
(
IOobject
(
"U",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
mesh
);


# include "createPhi.H"



-----------------------------------------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------------------------

BIOFOAM2.C, source code of bioFoam2:

\*---------------------------------------------------------------------------*/

#include "fvCFD.H"

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

int main(int argc, char *argv[])
{
#include "setRootCase.H"

#include "createTime.H"
#include "createMesh.H"
#include "createFields.H"
#include "initContinuityErrs.H"

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

Info<< "\nStarting time loop\n" << endl;


while (runTime.loop())
{

Info<< "Time = " << runTime.timeName() << nl << endl;

#include "CourantNo.H"

D = alpha1*Deau+(1-alpha1)*Dbio;

Ads = (1-alpha1)*Adsbio;

solve
(
fvm::ddt(c)
- fvm::laplacian(D,c)
+ Ads*c
==
- fvm::div((phi),c)
);

D = alpha1*cinj+(1-alpha1)*cinj;

Ads = alpha1*0+(1-alpha1)*0;

c = min(max(c,Ads),D);

runTime.write();

Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
<< nl << endl;
}

Info<< "End\n" << endl;

return 0;
}


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


------------------------------------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------------------------------------


LOG OF THE RUN WHICH GIVE ME THE ERROR MESSAGE SHOWN ABOVE

/*---------------------------------------------------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 1.7.x |
| \\ / A nd | Web: www.OpenFOAM.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
Build : 1.7.x-131caa989cd3
Exec : bioFoam2 -parallel
Date : Jun 01 2011
Time : 16:35:08
Host : etna
PID : 9777
Case : /home/laurent/OpenFOAM/laurent-1.7.1/run/LO_OF_1.7.1/biofilmLCPME/cell3Dtransport
nProcs : 4
Slaves :
3
(
etna.9778
etna.9779
etna.9780
)

Pstream initialized with:
floatTransfer : 0
nProcsSimpleSum : 0
commsType : nonBlocking
SigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Create mesh for time = 0.099952

Reading transportProperties

Reading field c

Reading field alpha1

Reading field D

Reading field Ads

Reading field U

Reading/calculating face flux field phi


Starting time loop

Time = 0.100352

Courant Number mean: 6.3162635e-05 max: 0.40167238
GAMG: Solving for c, Initial residual = 1, Final residual = 7.4663329e-10, No Iterations 3
Orgogozo is offline   Reply With Quote

Reply

Tags
boundedness, solute transport, solvers


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
bug in dnsFOAM cfdmarkus OpenFOAM Bugs 1 January 29, 2010 06:01
Serious bug in LES interface fs82 OpenFOAM Bugs 21 November 16, 2009 09:15
Bug in twoPhaseEulerFoam wallfunctions alberto OpenFOAM Bugs 1 February 9, 2007 15:15
Bug reports Mattijs Janssens (Mattijs) OpenFOAM 0 January 10, 2005 11:05
Forum y2k Bug Jonas Larsson Main CFD Forum 1 January 5, 2000 11:22


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