|
[Sponsors] |
[swak4Foam] groovyBC results in negative alpha |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
October 11, 2011, 11:30 |
groovyBC results in negative alpha
|
#1 |
New Member
Andreas Otto
Join Date: Sep 2009
Posts: 12
Rep Power: 17 |
Hello everyone,
I'm trying to implement groovyBc's in my calculations. I'm using OpenFOAM 2.0.x and started with the circulatingSplash-tutorial from within the latest swak4FOAM-version withot changing anything. Unfortunately the solution run after blockMesh and interDyMFOAM led to strongly negative values for alpha1 and consequently broke very soon after only 4 time steps: /*---------------------------------------------------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.0.x | | \\ / A nd | Web: www.OpenFOAM.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ Build : 2.0.x-d31ba4c8844f Exec : interDyMFoam Date : Oct 11 2011 Time : 16:17:23 Host : donaldduck PID : 11393 Case : /home/.../OpenFOAM/OpenFOAM-2.0.x/applications/utilities/swak4Foam/Examples/groovyBC/circulatingSplash nProcs : 1 sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE). fileModificationChecking : Monitoring run-time modified files using timeStampMaster allowSystemOperations : Disallowing user-supplied system call operations // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // Create time Create mesh for time = 0 Selecting dynamicFvMesh dynamicRefineFvMesh Reading field p_rgh Reading field alpha1 Reading field U Reading/calculating face flux field phi Reading transportProperties Selecting incompressible transport model Newtonian Selecting incompressible transport model Newtonian Selecting turbulence model type laminar Reading g Calculating field g.h PIMPLE: Operating solver in PISO mode time step continuity errors : sum local = 0, global = 0, cumulative = 0 GAMGPCG: Solving for pcorr, Initial residual = 0, Final residual = 0, No Iterations 0 time step continuity errors : sum local = 0, global = 0, cumulative = 0 Courant Number mean: 0 max: 0 Starting time loop Interface Courant Number mean: 0 max: 0 Courant Number mean: 0 max: 0 deltaT = 0.00025 Time = 0.00025 Selected 0 cells for refinement out of 32768. Selected 0 split points out of a possible 0. MULES: Solving for alpha1 Liquid phase volume fraction = 0 Min(alpha1) = 0 Max(alpha1) = 1 MULES: Solving for alpha1 Liquid phase volume fraction = 0 Min(alpha1) = 0 Max(alpha1) = 1 MULES: Solving for alpha1 Liquid phase volume fraction = 0 Min(alpha1) = 0 Max(alpha1) = 1 swak4Foam: Allocating new repository for sampledGlobalVariables GAMG: Solving for p_rgh, Initial residual = 1, Final residual = 0.001340854, No Iterations 1 time step continuity errors : sum local = 1.306237e-07, global = -3.144612e-08, cumulative = -3.144612e-08 GAMG: Solving for p_rgh, Initial residual = 0.9365981, Final residual = 0.01857663, No Iterations 3 time step continuity errors : sum local = 8.123623e-07, global = -8.57249e-08, cumulative = -1.17171e-07 GAMGPCG: Solving for p_rgh, Initial residual = 0.004712629, Final residual = 1.693463e-09, No Iterations 6 time step continuity errors : sum local = 2.931039e-13, global = -4.719646e-15, cumulative = -1.17171e-07 ExecutionTime = 1.06 s ClockTime = 1 s Interface Courant Number mean: 0 max: 0 Courant Number mean: 0.0001562778 max: 0.1799902 deltaT = 0.0001346154 Time = 0.000384615 Selected 0 cells for refinement out of 32768. Selected 0 split points out of a possible 0. MULES: Solving for alpha1 Liquid phase volume fraction = -3.943487e-06 Min(alpha1) = -0.03230549 Max(alpha1) = 1 MULES: Solving for alpha1 Liquid phase volume fraction = -7.886973e-06 Min(alpha1) = -0.06461096 Max(alpha1) = 1 MULES: Solving for alpha1 Liquid phase volume fraction = -1.183046e-05 Min(alpha1) = -0.09691642 Max(alpha1) = 1 GAMG: Solving for p_rgh, Initial residual = 0.527714, Final residual = 0.01038129, No Iterations 3 time step continuity errors : sum local = 5.175253e-07, global = -2.021781e-07, cumulative = -3.193491e-07 GAMG: Solving for p_rgh, Initial residual = 0.009505424, Final residual = 0.0004487535, No Iterations 3 time step continuity errors : sum local = 3.3844e-08, global = -8.449231e-09, cumulative = -3.277983e-07 GAMGPCG: Solving for p_rgh, Initial residual = 0.0004157884, Final residual = 4.699711e-09, No Iterations 4 time step continuity errors : sum local = 3.91228e-13, global = -3.629063e-14, cumulative = -3.277984e-07 ExecutionTime = 1.42 s ClockTime = 1 s Does anybody know the reason for this behaviour? |
|
October 12, 2011, 04:59 |
|
#2 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Andreas
Two comments on this: 1. You are beginning with an empty domain and take alpha out of it. Is that what you want? 2. Try to add the momentum predictor in fvSolution and run the simulation again. My experience with the inter***Foam type solvers is that "2" is required, but in your case it is most probably caused by beginning with an empty domain. Kind regards, Niels |
|
October 12, 2011, 05:37 |
|
#3 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
If you get it too run I'd very much apprechiate it if you contribute the relevant changes (I'm sorry, but I currently don't have the time for this) Just some hints that might be helpful: - write out every timestep for a failing run and see where the trouble (negative alpha) starts - try to isolate the problem (although I'm afraid the problem is a mixture of the two): - make the inlet "stationary" by multiplying all instances of time() with 0 - try to run the transient inlet without mesh refinement Bernhard |
||
October 13, 2011, 09:58 |
problem solved
|
#4 |
New Member
Andreas Otto
Join Date: Sep 2009
Posts: 12
Rep Power: 17 |
Dear Bernhard,
you were right, it was a problem with the boundary conditions. I left alpha1-BCs as given in the example and changed U-BCs to /*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: dev | | \\ / A nd | Web: http://www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class volVectorField; object U; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [0 1 -1 0 0 0 0]; internalField uniform (0 0 0); boundaryField { floor { type fixedValue; value uniform (0 0 0); } atmosphere { type groovyBC; value uniform (0 0 0); variables "r1=0.25*(max(pts().x)-min(pts().x));r2=r1*0.2*(1-0.5*cos(54*time()));"; valueExpression "(sqrt(pow(pos().x-r1*sin(10*time()),2)+pow(pos().z-r1*cos(15*time()),2))<r2) ? vector(0,-1,0) : vector(0,0,0)"; } spill { type pressureInletOutletVelocity; phi phi; value uniform (0 0 0); } sides { type pressureInletOutletVelocity; phi phi; value uniform (0 0 0); } } and p_rgh-Bcs to /*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 1.6 | | \\ / A nd | Web: http://www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class volScalarField; object p; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [1 -1 -2 0 0 0 0]; internalField uniform 0; boundaryField { floor { type buoyantPressure; value uniform 0; } sides { type totalPressure; value uniform 0; p0 uniform 0; U U; phi phi; gamma 1; value uniform 0; } spill { type buoyantPressure; value uniform 0; p0 uniform 0; U U; phi phi; gamma 1; value uniform 0; } atmosphere { type buoyantPressure; p0 uniform 0; U U; phi phi; rho rho; psi none; gamma 1; value uniform 0; } // ************************************************** *********************** // Now the case runs fine at least until the time 0.35s where I stopped the calculation after 16 hours runtime. By the way: very nice example. Perhaps you can include it in your next version of swak4FOAM. Andreas |
|
October 13, 2011, 16:12 |
|
#5 | ||
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Hi Andreas!
Quote:
Quote:
hg commit hg bundle splashFixBundle and send me the splashFixBundle-file. That way I can inject it into the repository, the changes will be attributed to you and I can't take credit for fixes I was too lazy to do myself Bernhard |
|||
December 12, 2013, 04:42 |
|
#6 |
New Member
Faraj
Join Date: Feb 2010
Posts: 22
Rep Power: 16 |
set alpha = 0.5 to all field
|
|
December 12, 2013, 05:29 |
|
#7 |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
I've been meditating on this sentence all morning. Is this the interFoam-equivalent to "Kill'em all"?
__________________
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 |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Problem with blockMesh | cshsgy | OpenFOAM Pre-Processing | 2 | October 2, 2017 12:46 |
[swak4Foam] reactingMultiPhaseEulerFoam problems with groovyBC | zanilu70 | OpenFOAM Community Contributions | 4 | December 13, 2016 07:46 |
[blockMesh] blockMesh error - Negative Volume Block | adoledin | OpenFOAM Meshing & Mesh Conversion | 2 | June 22, 2016 11:44 |
Problem: Very long "write" time (~2h-3h) for results and transient results | Shawn_A | CFX | 16 | April 12, 2016 21:49 |
[swak4Foam] groovyBC results diferent from funkySetBoundaryField?! | xisto | OpenFOAM Community Contributions | 8 | October 23, 2012 11:15 |