/*--------------------------------*- 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      binary;
    class       dictionary;
    location    "constant";
    object      cloudProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

type        sprayCloud;

solution
{
    coupled         true;
    transient       yes;
    cellValueSourceCorrection on;
    maxCo           0.3;

    sourceTerms
    {
        schemes
        {
            rho             explicit 1;
            U               explicit 1;
            Yi              explicit 1;
            h               explicit 1;
            radiation       explicit 1;
        }
    }

    interpolationSchemes
    {
        rho             cell;
        U               cellPoint;
        thermo:mu       cell;
        T               cell;
        Cp              cell;
        kappa           cell;
        p               cell;
    }

    integrationSchemes
    {
        U               Euler;
        T               analytical;
    }
}


constantProperties
{
    T0              320;

    // place holders for rho0 and Cp0
    // - reset from liquid properties using T0
    rho0            1000;
    Cp0             4187;

    constantVolume  false;
}


subModels
{
    particleForces
    {
        sphereDrag;
    }

    injectionModels
    {
        model1
        {
            type            coneInjection;
            SOI             0;
            massTotal       6.0e-6;
            parcelBasisType mass;
            injectionMethod disc;
            flowType        flowRateAndDischarge;
            dInner          0;
            dOuter          1.9e-4;
            duration        1.25e-3;
            position        (0 0.0995 0);
            direction       (0 -1 0);
            parcelsPerSecond 20000000;
            flowRateProfile table
            (
                (0              0.1272)
                (4.16667e-05    6.1634)
                (8.33333e-05    9.4778)
                (0.000125       9.5806)
                (0.000166667    9.4184)
                (0.000208333    9.0926)
                (0.00025        8.7011)
                (0.000291667    8.2239)
                (0.000333333    8.0401)
                (0.000375       8.8450)
                (0.000416667    8.9174)
                (0.000458333    8.8688)
                (0.0005         8.8882)
                (0.000541667    8.6923)
                (0.000583333    8.0014)
                (0.000625       7.2582)
                (0.000666667    7.2757)
                (0.000708333    6.9680)
                (0.00075        6.7608)
                (0.000791667    6.6502)
                (0.000833333    6.7695)
                (0.000875       5.5774)
                (0.000916667    4.8649)
                (0.000958333    5.0805)
                (0.001          4.9547)
                (0.00104167     4.5613)
                (0.00108333     4.4536)
                (0.001125       5.2651)
                (0.00116667     5.2560)
                (0.00120833     5.1737)
                (0.00125        3.9213)
                (0.001251       0.0000)
                (1000           0.0000)
            );

            Cd              constant 0.9;

            thetaInner      constant 0.0;
            thetaOuter      constant 10.0;

            sizeDistribution
            {
                type        RosinRammler;

                RosinRammlerDistribution
                {
                    minValue        1e-06;
                    maxValue        0.00015;
                    d               0.00015;
                    n               3;
                }
            }
        }
    }

    dispersionModel none;

    patchInteractionModel standardWallInteraction;

    heatTransferModel RanzMarshall;

    compositionModel singlePhaseMixture;

    phaseChangeModel liquidEvaporationBoil;

    surfaceFilmModel none;

    atomizationModel none;

    breakupModel    ReitzDiwakar; // ReitzKHRT;

    stochasticCollisionModel none;

    radiation       off;

    standardWallInteractionCoeffs
    {
        type            rebound;
    }

    RanzMarshallCoeffs
    {
        BirdCorrection  true;
    }

    singlePhaseMixtureCoeffs
    {
        phases
        (
            liquid
            {
                C7H16               1;
            }
        );
    }

    liquidEvaporationBoilCoeffs
    {
        enthalpyTransfer enthalpyDifference;

        activeLiquids    ( C7H16 );
    }

    ReitzDiwakarCoeffs
    {
        solveOscillationEq yes;
        Cbag            6;
        Cb              0.785;
        Cstrip          0.5;
        Cs              10;
    }

/*
    ReitzKHRTCoeffs
    {
        solveOscillationEq yes;
        B0              0.61;
        B1              40;
        Ctau            1;
        CRT             0.1;
        msLimit         0.2;
        WeberLimit      6;
    }
*/
    TABCoeffs
    {
        y0              0;
        yDot0           0;
        Cmu             10;
        Comega          8;
        WeCrit          12;
    }
}


cloudFunctions
{}


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