semiImplicitSource: Made operable on multiple different types

The scalarSemiImplicitSource, vectorSemiImplicitSource, etc...,
fvOptions have been replaced by a single semiImplicitSource fvOption.
This allows sources to be specified for multiple fields regardless of
type. For example:

    massSource
    {
        type            semiImplicitSource;

        timeStart       1;
        duration        500;

        selectionMode   points;
        points
        (
            (0.075 0.2 0.05)
        );

        volumeMode      absolute;

        sources
        {
            thermo:rho.steam
            {
                explicit    1.0e-3; // kg/s
                implicit    0;
            }

            U.steam
            {
                explicit    (0 1e-1 0); // kg*m/s^2
                implicit    0;
            }

            h.steam
            {
                explicit    3700; // kg*m^2/s^3
                implicit    0;
            }
        }
    }
This commit is contained in:
Jakub Knir
2020-04-07 15:57:52 +01:00
committed by Will Bainbridge
parent ad12d3a8c1
commit b6f91de72c
16 changed files with 774 additions and 612 deletions

View File

@ -10,7 +10,7 @@ FoamFile
version 2.0;
format ascii;
class dictionary;
object porousZone;
object fvOptions;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -27,7 +27,7 @@ fixedTemperature
fixedPower
{
type scalarSemiImplicitSource;
type semiImplicitSource;
active no;
selectionMode all;

View File

@ -19,7 +19,7 @@ options
{
energySource
{
type scalarSemiImplicitSource;
type semiImplicitSource;
timeStart 0;
duration 1e6;

View File

@ -19,7 +19,7 @@ options
{
energySource
{
type scalarSemiImplicitSource;
type semiImplicitSource;
timeStart 0;
duration 1;

View File

@ -17,7 +17,7 @@ FoamFile
momentumSource
{
type vectorSemiImplicitSource;
type semiImplicitSource;
timeStart 0.0;
duration 1000;

View File

@ -44,9 +44,9 @@ filter1
}
massSource1
massSource
{
type scalarSemiImplicitSource;
type semiImplicitSource;
timeStart 0.2;
duration 2.0;
@ -66,9 +66,9 @@ massSource1
implicit 0;
}
H2O
U
{
explicit 1e-4; // kg/s
explicit (0 0.005 0);
implicit 0;
}
@ -77,29 +77,10 @@ massSource1
explicit 10;
implicit 0;
}
}
}
momentumSource1
{
type vectorSemiImplicitSource;
timeStart 0.2;
duration 2.0;
selectionMode points;
points
(
(2.75 0.5 0)
);
volumeMode absolute;
sources
{
U
H2O
{
explicit (0 0.005 0);
explicit 1e-4; // kg/s
implicit 0;
}
}

View File

@ -15,24 +15,20 @@ FoamFile
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
injector1
{
timeStart 0;
duration 1e6;
selectionMode points;
points
(
(0.075 0.925 0.05)
);
}
options
{
massSource1
massSource
{
type scalarSemiImplicitSource;
type semiImplicitSource;
$injector1;
timeStart 0;
duration 1e6;
selectionMode points;
points
(
(0.075 0.925 0.05)
);
volumeMode absolute;

View File

@ -15,24 +15,20 @@ FoamFile
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
injector1
{
timeStart 0.1;
duration 5;
selectionMode points;
points
(
(0.075 0.2 0.05)
);
}
options
{
massSource1
massSource
{
type scalarSemiImplicitSource;
type semiImplicitSource;
$injector1;
timeStart 0.1;
duration 5;
selectionMode points;
points
(
(0.075 0.2 0.05)
);
volumeMode absolute;
@ -44,6 +40,12 @@ options
implicit 0;
}
U.air
{
explicit (0 -1e-2 0); // kg*m/s^2
implicit 0;
}
e.air
{
explicit 500; // kg*m^2/s^3
@ -51,24 +53,6 @@ options
}
}
}
momentumSource1
{
type vectorSemiImplicitSource;
$injector1;
volumeMode absolute;
sources
{
U.air
{
explicit (0 -1e-2 0); // kg*m/s^2
implicit 0; // kg*m/s^2
}
}
}
}

View File

@ -15,24 +15,20 @@ FoamFile
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
injector1
{
timeStart 1;
duration 500;
selectionMode points;
points
(
(0.075 0.2 0.05)
);
}
options
{
massSource1
massSource
{
type scalarSemiImplicitSource;
type semiImplicitSource;
$injector1;
timeStart 1;
duration 500;
selectionMode points;
points
(
(0.075 0.2 0.05)
);
volumeMode absolute;
@ -44,29 +40,17 @@ options
implicit 0;
}
h.steam
{
explicit 3700; // kg*m^2/s^3
implicit 0;
}
}
}
momentumSource1
{
type vectorSemiImplicitSource;
$injector1;
volumeMode absolute;
sources
{
U.steam
{
explicit (0 1e-1 0); // kg*m/s^2
implicit 0;
}
h.steam
{
explicit 3700; // kg*m^2/s^3
implicit 0;
}
}
}

View File

@ -15,24 +15,20 @@ FoamFile
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
injector1
{
timeStart 0.1;
duration 5;
selectionMode points;
points
(
(0.075 0.2 0.05)
);
}
options
{
massSource1
massSource
{
type scalarSemiImplicitSource;
type semiImplicitSource;
$injector1;
timeStart 0.1;
duration 5;
selectionMode points;
points
(
(0.075 0.2 0.05)
);
volumeMode absolute;
@ -44,6 +40,12 @@ options
implicit 0;
}
U.air
{
explicit (0 -1e-2 0); // kg*m/s^2
implicit 0;
}
e.air
{
explicit 500; // kg*m^2/s^3
@ -51,24 +53,6 @@ options
}
}
}
momentumSource1
{
type vectorSemiImplicitSource;
$injector1;
volumeMode absolute;
sources
{
U.air
{
explicit (0 -1e-2 0); // kg*m/s^2
implicit 0; // kg*m/s^2
}
}
}
}