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

using rhoReactingFoam for 2D DLR scamjet

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 11, 2020, 07:42
Unhappy using rhoReactingFoam for 2D DLR scamjet
  #1
New Member
 
Yan Chong
Join Date: Apr 2020
Posts: 1
Rep Power: 0
yanchong13 is on a distinguished road
I'm A PHD student major in combustion. Recently, I want to simulate a supersonic combustion case using OpenFoam. I thought rhoReactingFoam maybe capable for the case. But the position of the shock wave is ayways incorrect. I thought that may caused by th boundry condition of U or P or something else,but i cant figure is out. can anyon give me some suggestions?


p
Code:
/*--------------------------------*- C++ -*----------------------------------*\
  =========                 |
  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
   \\    /   O peration     | Website:  https://openfoam.org
    \\  /    A nd           | Version:  dev
     \\/     M anipulation  |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       volScalarField;
    location    "0";
    object      p;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [1 -1 -2 0 0 0 0];

internalField   uniform 101325;

boundaryField
{
    inletfuel
    {
        type            fixedValue;
        value           uniform 101325;
    }
    inletair
    {
        type            fixedValue;
        value           uniform 101325;
    }
    outlet
    {
        type            zeroGradient;
    }

    frontAndBackPlanes
    {
        type            empty;
    }
    WALL_TOP
    {
        type            zeroGradient;
    }
    WALL_BOT
    {
        type            zeroGradient;
    }
    WALL_INSIDE
    {
        type            zeroGradient;
    }
}


// ************************************************************************* //
Code:
/*--------------------------------*- C++ -*----------------------------------*\
  =========                 |
  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
   \\    /   O peration     | Website:  https://openfoam.org
    \\  /    A nd           | Version:  dev
     \\/     M anipulation  |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       volVectorField;
    location    "0";
    object      U;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 1 -1 0 0 0 0];

internalField   uniform (730 0 0);

boundaryField
{
    inletfuel
    {
        type            fixedValue;
        value           uniform (1200 0 0);
    }
    inletair
    {
        type            fixedValue;
        value           uniform (730 0 0);
    }
    outlet
    {
        type            inletOutlet;
        inletValue      uniform (730 0 0);
        value           uniform (730 0 0);
    }
    frontAndBackPlanes
    {
        type            empty;
    }
    WALL_TOP
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }
    WALL_BOT
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }
    WALL_INSIDE
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }
}


// ************************************************************************* //
Code:
/*--------------------------------*- C++ -*----------------------------------*\
  =========                 |
  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
   \\    /   O peration     | Website:  https://openfoam.org
    \\  /    A nd           | Version:  dev
     \\/     M anipulation  |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       volScalarField;
    location    "0";
    object      T;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 0 0 1 0 0 0];

internalField   uniform 1200;

boundaryField
{
    inletfuel
    {
        type            fixedValue;
        value           uniform 250;
    }
    inletair
    {
        type            fixedValue;
        value           uniform 1200;
    }
    outlet
    {
        type            inletOutlet;
        inletValue      uniform 340;
        value           uniform 340;
    }
    frontAndBackPlanes
    {
        type            empty;
    }
    WALL_TOP
    {
        type            zeroGradient;
    }
    WALL_BOT
    {
        type            zeroGradient;
    }
    WALL_INSIDE
    {
        type            zeroGradient;
    }
}


// ************************************************************************* //
fvSchemes
Code:
/*--------------------------------*- C++ -*----------------------------------*\
  =========                 |
  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
   \\    /   O peration     | Website:  https://openfoam.org
    \\  /    A nd           | Version:  dev
     \\/     M anipulation  |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system";
    object      fvSchemes;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

ddtSchemes
{
    default         Euler;
}

gradSchemes
{
    default         Gauss linear;
}

divSchemes
{
    default             none;

    div(phi,U)      Gauss linearUpwindV grad(U);
    div(phi,Yi)         Gauss linearUpwind;
    div(phi,h)          Gauss linearUpwind;
    div(phi,K)          Gauss linearUpwind grad(U);
    div(phid,p)         Gauss linearUpwind;
    div(phi,omega)      Gauss upwind;
    div(phi,epsilon)    Gauss upwind;
    div(phi,Yi_h)       Gauss upwind;
    div(phi,k)          Gauss upwind;
    div(((rho*nuEff)*dev2(T(grad(U)))))     Gauss linear;
    div(phiv,p)         Gauss linearUpwind grad(U);
}

laplacianSchemes
{
    default         Gauss linear corrected;
}    

interpolationSchemes
{
    default         linear;
    //interpolate(rho)              upwind phi;
    //interpolate((rho*(1|A(U))))   upwind phi;
    //flux(HbyA)                    upwind phi;
    //dotInterpolate(S,(rho_0*U_0)) linear;
}

snGradSchemes
{
    default         corrected;
}

wallDist
{
    method meshWave;
}

// ************************************************************************* //
fvSolution
Code:
/*--------------------------------*- C++ -*----------------------------------*\
  =========                 |
  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
   \\    /   O peration     | Website:  https://openfoam.org
    \\  /    A nd           | Version:  dev
     \\/     M anipulation  |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system";
    object      fvSolution;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

solvers
{
    "rho.*"
    {
        solver          diagonal;
    }

    p
    {
        solver           PBiCGStab;
        preconditioner   DIC;
        tolerance        1e-6;
        relTol           1e-6;
    }

    pFinal
    {
        $p;
        relTol           0;
    }

    "(U|e|k|epsilon|omega)"
    {
        solver          PBiCGStab;
        preconditioner  DILU;
        tolerance       1e-6;
        relTol          1e-6;
    }

    "(U|e|k|epsilon|omega)Final"
    {
        $U;
    }

    "Yi.*"
    {
        solver          PBiCGStab;
        preconditioner  DILU;
        tolerance       1e-8;
        relTol          1e-6;
    }
}

PIMPLE
{
    momentumPredictor   yes;
    nOuterCorrectors    1;
    nCorrectors         2;
    nNonOrthogonalCorrectors 1;

    maxDeltaT           1e-7;
    maxCo               0.25;
    alphaTemp           0.05;
    alphaY              0.05;
    Yref
    {
        O2                  0.1;
        H2                  0.1;
    }
    rDeltaTSmoothingCoeff   0.05;
    rDeltaTDampingCoeff     1;
}

relaxationFactors
{
    equations
    {
        ".*"    1;
    }
}

// ************************************************************************* //
yanchong13 is offline   Reply With Quote

Old   April 13, 2020, 03:43
Default
  #2
New Member
 
CHEUNG WING KI
Join Date: May 2017
Posts: 16
Rep Power: 9
as020002 is on a distinguished road
Hi,

I am doing combustion research on this geometry at the moment.
You can try the "waveTransmissive" boundary on the p.outlet

Regards,
Rick
as020002 is offline   Reply With Quote

Old   May 15, 2024, 16:52
Default
  #3
New Member
 
mustafa
Join Date: Mar 2024
Posts: 1
Rep Power: 0
ozyz21 is on a distinguished road
hello. im simulating supersonic air hydrogen mixing in DLR Scramjet combustion too if you solve this problem or not can yol share case file? thank you.
ozyz21 is offline   Reply With Quote

Reply

Tags
supersonic.combustion


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
The pressure equation in reactingFoam and rhoReactingFoam cryabroad OpenFOAM Running, Solving & CFD 14 January 21, 2024 14:09
No way to use DLR in-house code? spalartallmaras Main CFD Forum 2 November 6, 2019 18:26
reactingFoam vs rhoReactingFoam Scot OpenFOAM Running, Solving & CFD 8 June 2, 2016 12:28
Governing Equations of RhoReactingFoam Sermengi OpenFOAM Programming & Development 2 March 23, 2015 11:24
Bug in rhoReactingFoam francesco_capuano OpenFOAM Bugs 2 February 6, 2012 16:11


All times are GMT -4. The time now is 22:20.