|
[Sponsors] |
March 4, 2014, 12:36 |
buoyantBoussinesqPisoFoam
|
#1 |
New Member
Join Date: Feb 2014
Posts: 16
Rep Power: 12 |
Hi all,
I have been working on a new solver by modifying the "buoyantBoussinesqPisoFoam". I have added an explicit source to the temperature equation (as done in the tutorial "porousExplicitSourceReactingParcelFoam" and also an implict source to the momentum equation. // Solve the momentum equation fvVectorMatrix UEqn ( fvm::ddt(U) + fvm::div(phi, U) + turbulence->divDevReff(U) // - fvm::Sp(0.5*Cd*LAD*mag(U),U) // -fvm::Sp(mag(fvc::Sp(Cd*LAD*0.5,U) ),U) ); UEqn.relax(); if (momentumPredictor) { solve ( UEqn == fvc::reconstruct ( ( fvc::interpolate(rhok)*(g & mesh.Sf()) - fvc::snGrad(p)*mesh.magSf() ) ) -fvc::Sp(mag(fvc::Sp(Cd*LAD*0.5,U) ),U) ); } where Cd is a constant and LAD is a scalarField. I set non uniform values by means of setFieldDict. //solve the temperature equation { volScalarField kappaEff ( "kappaEff", turbulence->nu()/Pr + turbulence->nut()/Prt ); fvScalarMatrix TEqn ( fvm::ddt(T) + fvm::div(phi, T) - fvm::laplacian(kappaEff, T) == temperatureSource.Su() ); TEqn.relax(); TEqn.solve(); rhok = 1.0 - beta*(T - TRef); } The temperature source is set to a determined reion by means of cellset. The solver compiles (see attached), but when I intend to run a case, the velocity increases really fast and the simulation crashes. I cannot find the error... ¿maybe in my boundary conditions? (see also case attached). I would really appretiate any help! Thanks in advance Cristina |
|
March 5, 2014, 04:43 |
|
#2 |
New Member
Join Date: Feb 2014
Posts: 16
Rep Power: 12 |
Can anyone help me? This case is driving me crazy. I think it is a question of the pressure boundary conditions....
I attach the error: Time = 1 Courant Number mean: 0 max: 0 velocity magnitude: 0 deltaT = 1.2 DILUPBiCG: Solving for Ux, Initial residual = 1, Final residual = 3.85069e-07, No Iterations 2 DILUPBiCG: Solving for Uy, Initial residual = 1, Final residual = 2.56645e-06, No Iterations 4 DILUPBiCG: Solving for Uz, Initial residual = 1, Final residual = 3.41222e-07, No Iterations 2 DILUPBiCG: Solving for T, Initial residual = 1, Final residual = 7.92614e-07, No Iterations 3 DICPCG: Solving for p, Initial residual = 1, Final residual = 0.0849405, No Iterations 58 time step continuity errors : sum local = 0.130643, global = -0.00370545, cumulative = -0.00370545 DICPCG: Solving for p, Initial residual = 0.416228, Final residual = 9.55017e-08, No Iterations 121 time step continuity errors : sum local = 1.74235e-06, global = 6.31575e-08, cumulative = -0.00370539 DILUPBiCG: Solving for epsilon, Initial residual = 0.946356, Final residual = 5.44074e-06, No Iterations 4 DILUPBiCG: Solving for k, Initial residual = 1, Final residual = 4.69753e-06, No Iterations 24 bounding k, min: 0 max: 1.26149 average: 0.731538 ExecutionTime = 0.87 s ClockTime = 0 s Calculating averages Time = 2.2 Courant Number mean: 3.273 max: 108.448 velocity magnitude: 25.3325 deltaT = 0.00553259 DILUPBiCG: Solving for Ux, Initial residual = 0.0131585, Final residual = 7.80769e-07, No Iterations 2 DILUPBiCG: Solving for Uy, Initial residual = 0.00882209, Final residual = 3.03072e-07, No Iterations 2 DILUPBiCG: Solving for Uz, Initial residual = 0.026238, Final residual = 3.4694e-08, No Iterations 3 DILUPBiCG: Solving for T, Initial residual = 0.0121135, Final residual = 1.79591e-07, No Iterations 2 DICPCG: Solving for p, Initial residual = 0.806607, Final residual = 0.0711915, No Iterations 9 time step continuity errors : sum local = 0.00013445, global = 5.87015e-06, cumulative = -0.00369952 DICPCG: Solving for p, Initial residual = 0.205045, Final residual = 9.95087e-08, No Iterations 127 time step continuity errors : sum local = 3.6426e-10, global = -1.26168e-11, cumulative = -0.00369952 |
|
November 19, 2020, 14:02 |
|
#3 |
New Member
damu
Join Date: Feb 2017
Posts: 24
Rep Power: 9 |
Hi Cristina
Thanks for the post. I have been trying to simulate flow over a heated cylinder using buoyantBoussinesqPisoFoam(foam-extend-4.1). Part of my error has similarities with yours. In addition to the immediate surge in velocity magnitudes, I get the forceCoefficients as 0. I know this is an old post however, I would like to know if you solved this. Thank you |
|
|
|