Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove EOS template parameter from compositional fluid model #3166

Merged
merged 42 commits into from
Jul 3, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
3c1ccc5
Add generic parameters
dkachuma Jun 3, 2024
1771190
uncrustify
dkachuma Jun 3, 2024
9a6a6eb
Fix tests
dkachuma Jun 3, 2024
eb33b36
Fix LBC test
dkachuma Jun 3, 2024
dd0be87
Update schema files
dkachuma Jun 3, 2024
ddebea4
Change component properties
dkachuma Jun 4, 2024
a04a6e2
Revert file
dkachuma Jun 4, 2024
2f50df8
Add include files
dkachuma Jun 4, 2024
c616848
Remove helper class
dkachuma Jun 4, 2024
0a910b1
Remove file from list
dkachuma Jun 4, 2024
4d0b965
Fix some typos
dkachuma Jun 4, 2024
9cc60af
Merge branch 'develop' into feature/dkachuma/fluid-parameters
dkachuma Jun 4, 2024
4855a22
Merge branch 'develop' into feature/dkachuma/fluid-parameters
dkachuma Jun 5, 2024
38acd9e
Rename input field
dkachuma Jun 5, 2024
1e11446
getParameters -> get
dkachuma Jun 5, 2024
e18adc9
Initial pass
dkachuma Jun 5, 2024
13b56b2
Remove bad rst files
dkachuma Jun 5, 2024
abd2ac9
Merge remote-tracking branch 'origin/feature/dkachuma/fluid-parameter…
dkachuma Jun 5, 2024
bd40c6d
Simulator changes
dkachuma Jun 5, 2024
5002346
Change catalog entries
dkachuma Jun 5, 2024
c098a9e
Merge branch 'develop' into feature/dkachuma/fluid-parameters
dkachuma Jun 11, 2024
d6e8edd
Merge branch 'develop' into feature/dkachuma/fluid-parameters
dkachuma Jun 12, 2024
2e9191d
Fix test
dkachuma Jun 12, 2024
7614356
Merge branch 'develop' into feature/dkachuma/eos-parameters
dkachuma Jun 12, 2024
20032f9
Fix unit test
dkachuma Jun 12, 2024
78e758b
Fix unit tests
dkachuma Jun 12, 2024
a2c82a8
Merge branch 'feature/dkachuma/fluid-parameters' into feature/dkachum…
dkachuma Jun 12, 2024
cdb4cab
Merge branch 'develop' into feature/dkachuma/fluid-parameters
paveltomin Jun 13, 2024
c0a1a79
Merge branch 'develop' into feature/dkachuma/fluid-parameters
paveltomin Jun 14, 2024
fd9dd2c
Merge branch 'feature/dkachuma/fluid-parameters' into feature/dkachum…
dkachuma Jun 18, 2024
5c0a3aa
Merge develop
dkachuma Jun 18, 2024
cc0b596
Merge branch 'develop' into feature/dkachuma/eos-parameters
dkachuma Jun 26, 2024
d5fe6c6
Add EOS parameters to flash
dkachuma Jun 26, 2024
a5ea449
Merge branch 'feature/dkachuma/eos-parameters' of https://github.com/…
dkachuma Jun 26, 2024
6fac536
Fix unit tests
dkachuma Jun 26, 2024
03d59f2
Fix compositional density
dkachuma Jun 27, 2024
934d211
Merge branch 'develop' into feature/dkachuma/eos-parameters
dkachuma Jun 27, 2024
0546d6b
Remove EOS parameter from stability test
dkachuma Jun 27, 2024
85aadc7
Merge branch 'develop' into feature/dkachuma/eos-parameters
dkachuma Jul 2, 2024
08db652
postProcessInput > postInputInitialization
dkachuma Jul 2, 2024
33dc84f
Merge branch 'develop' into feature/dkachuma/eos-parameters
rrsettgast Jul 3, 2024
8fbfdae
Merge branch 'develop' into feature/dkachuma/eos-parameters
rrsettgast Jul 3, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Change catalog entries
  • Loading branch information
dkachuma committed Jun 5, 2024
commit 5002346db11843f312c5e99307f4acd567b900c3
Original file line number Diff line number Diff line change
Expand Up @@ -88,19 +88,10 @@ integer CompositionalMultiphaseFluid< FLASH, PHASE1, PHASE2, PHASE3 >::getWaterP
return PVTProps::PVTFunctionHelpers::findName( m_phaseNames, expectedWaterPhaseNames, viewKeyStruct::phaseNamesString() );
}

// Naming conventions
namespace compositional
{
template< int NP > struct PhaseName {};
template<> struct PhaseName< 2 > { static constexpr char const * catalogName() { return "TwoPhase"; } };
template<> struct PhaseName< 3 > { static constexpr char const * catalogName() { return "ThreePhase"; } };
}

template< typename FLASH, typename PHASE1, typename PHASE2, typename PHASE3 >
string CompositionalMultiphaseFluid< FLASH, PHASE1, PHASE2, PHASE3 >::catalogName()
{
return GEOS_FMT( "Compositional{}Fluid{}{}",
compositional::PhaseName< FLASH::KernelWrapper::getNumberOfPhases() >::catalogName(),
return GEOS_FMT( "Compositional{}Fluid{}",
FLASH::catalogName(),
PHASE1::Viscosity::catalogName() );
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,18 @@ namespace constitutive
namespace compositional
{

CompositionalDensity::KernelWrapper
CompositionalDensity::createKernelWrapper() const
{
return KernelWrapper( m_componentDimensionalVolumeShift, m_equationOfState );
}

std::unique_ptr< ModelParameters >
CompositionalDensity::createParameters( std::unique_ptr< ModelParameters > parameters )
{
return EquationOfState::create( std::move( parameters ) );
}

void CompositionalDensity::calculateDimensionalVolumeShift( ComponentProperties const & componentProperties,
EquationOfStateType const & equationOfState,
arraySlice1d< real64 > componentDimensionalVolumeShift )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,10 @@ class CompositionalDensity : public FunctionBase
* @brief Create an update kernel wrapper.
* @return the wrapper
*/
KernelWrapper createKernelWrapper() const
{
return KernelWrapper( m_componentDimensionalVolumeShift, m_equationOfState );
}
KernelWrapper createKernelWrapper() const;

// Create parameters unique to this model
static std::unique_ptr< ModelParameters > createParameters( std::unique_ptr< ModelParameters > parameters );

private:
static void calculateDimensionalVolumeShift( ComponentProperties const & componentProperties,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ class ConstantViscosity : public FunctionBase

array1d< real64 > m_constantPhaseViscosity;

private:
protected:
void registerParametersImpl( MultiFluidBase * fluid ) override;
void postProcessInputImpl( MultiFluidBase const * fluid, ComponentProperties const & componentProperties ) override;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class EquationOfState : public ModelParameters

string_array m_equationsOfStateNames;

private:
protected:
void registerParametersImpl( MultiFluidBase * fluid ) override
{
fluid->registerWrapper( viewKeyStruct::equationsOfStateString(), &m_equationsOfStateNames ).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ class LohrenzBrayClarkViscosity : public FunctionBase
integer const phaseIndex,
ModelParameters const & modelParameters );

static string catalogName() { return "LBC"; }
static string catalogName() { return "LohrenzBrayClark"; }

FunctionType functionType() const override
{
Expand All @@ -297,7 +297,7 @@ class LohrenzBrayClarkViscosity : public FunctionBase
string m_componentMixingType;
array1d< real64 > m_componentCriticalVolume;

private:
protected:
void registerParametersImpl( MultiFluidBase * fluid ) override;
void postProcessInputImpl( MultiFluidBase const * fluid, ComponentProperties const & componentProperties ) override;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ class ModelParameters
return parameters;
}

private:
protected:
virtual void registerParametersImpl( MultiFluidBase * fluid )
{
GEOS_UNUSED_VAR( fluid );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ NegativeTwoPhaseFlashModel::NegativeTwoPhaseFlashModel( string const & name,
NegativeTwoPhaseFlashModel::KernelWrapper
NegativeTwoPhaseFlashModel::createKernelWrapper() const
{
static constexpr integer liquidIndex = 0;
static constexpr integer vapourIndex = 1;
constexpr integer liquidIndex = 0;
constexpr integer vapourIndex = 1;
EquationOfStateType const liquidEos = EnumStrings< EquationOfStateType >::fromString( m_parameters->m_equationsOfStateNames[liquidIndex] );
EquationOfStateType const vapourEos = EnumStrings< EquationOfStateType >::fromString( m_parameters->m_equationsOfStateNames[vapourIndex] );
return KernelWrapper( m_componentProperties.getNumberOfComponents(), liquidIndex, vapourIndex, liquidEos, vapourEos );
Expand Down
Loading