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

rhosimplefoam : error in solving the energy equation

Register Blogs Community New Posts Updated Threads Search

Like Tree6Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 8, 2018, 16:17
Default
  #21
Member
 
Yijiu Jiang
Join Date: Jan 2013
Location: Michigan, US
Posts: 49
Rep Power: 13
y_jiang is on a distinguished road
Hi Sufjanst,

Thank you for the suggestions.

I have made it work by change the BCs to the following combo
p:
inlet: totalPressure
outlet: fixedValue
U:
inlet: pressureInletVelocity
outlet: zeroGradient
Then, I gradually increase the inlet pressure to reach the desired pressure difference. It finally gave me reasonable result.
I have not really tried to use potentialFoam to initialize the field. But your suggestion of replacing sensibleInternalEnergy by sensibleEnthalpy do help me. It makes the model converge faster and more stable. Could you explain what is the reason?

Thank you very much!
y_jiang is offline   Reply With Quote

Old   April 21, 2022, 20:10
Default
  #22
Senior Member
 
Sakun
Join Date: Nov 2019
Location: United Kingdom
Posts: 152
Rep Power: 7
Sakun is on a distinguished road
Quote:
Originally Posted by y_jiang View Post
Hello Antoine,


I got the same issue as you had. The calculation stopped at 9th iteration and came up with the error when solving energy equation.

My goal is to solve a pressure driven problem for a tank with 1 inlet and 2 outlet. As you guys discussed here, I knew that a given value of outlet pressure should work fine with a flow rate inlet. So I set my boundary conditions like below. But I still got the error.

Do you have any idea on it?

Any of your input would be appreciated. Thank you!


Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  5                                     |
|   \\  /    A nd           | Web:      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 600000;

boundaryField
{

    geofull_inlet1 
    {
        type            zeroGradient;
        refValue        uniform 600000;
        refGradient     uniform 0;
    }

    geofull_outlet2 
    {
        type            fixedValue;
        value           uniform 600000;
    }

    geofull_outlet3 
    {
        type            fixedValue;
        value           uniform 600000;
    }

    geofull_needle1
    {
        type            zeroGradient;
    }

    geofull_needle2
    {
        type            zeroGradient;
    }

    geofull_needle3
    {
        type            zeroGradient;
    }

    geofull_tank 
    {
        type            zeroGradient;
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  5                                     |
|   \\  /    A nd           | Web:      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
{

    geofull_inlet1 
    {
        type            flowRateInletVelocity;
        volumetricFlowRate    constant 0.5;
        rhoInlet        1;
//        massFlowRate    0.5;
//        rhoInlet        0.5;
    }

    geofull_outlet2 
    {
        type            pressureInletOutletVelocity; 
        value           uniform (0 0 0);
    }

    geofull_outlet3 
    {
        type            pressureInletOutletVelocity; 
        value           uniform (0 0 0);
    }

    geofull_needle1 
    {
        type           noSlip;
    }

    geofull_needle2 
    {
        type           noSlip;
    }

    geofull_needle3 
    {
        type           noSlip;
    }

    geofull_tank 
    {
        type           noSlip;
    }

}

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



sorry for commenting on an old thread,



did you get the solution for your problem ? cause i have use 2 pressure values as well.
Sakun is offline   Reply With Quote

Reply

Tags
rhosimplefoam error


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
How I can introduce my power heat (W) in chtMultiRegionFoam? aminem OpenFOAM Pre-Processing 32 August 29, 2019 03:23
Extrusion with OpenFoam problem No. Iterations 0 Lord Kelvin OpenFOAM Running, Solving & CFD 8 March 28, 2016 12:08
Floating point exception error lpz_michele OpenFOAM Running, Solving & CFD 53 October 19, 2015 03:50
simpleFoam error - "Floating point exception" mbcx4jc2 OpenFOAM Running, Solving & CFD 12 August 4, 2015 03:20
Orifice Plate with a fully developed flow - Problems with convergence jonmec OpenFOAM Running, Solving & CFD 3 July 28, 2011 06:24


All times are GMT -4. The time now is 17:23.