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

Implement Temperature-dependent Solid Volumetric Heat Capacity #3088

Open
wants to merge 16 commits into
base: develop
Choose a base branch
from

Conversation

sytuannguyen
Copy link
Contributor

@sytuannguyen sytuannguyen commented Apr 22, 2024

This PR is part of the Non-Linear Thermal Behavior project. It aims to implement the linear temperature dependent of the solid volumetric specific heat capacity.

C = C0 + dC_dT * (T-T0)

where C0 is the reference solid volumetric heat capacity at the reference temperature T0 and dC_dT is the gradient of the volumetric heat capacity w.r.t. temperature. They are both provided by users in XML input files.

The existing linear constitutive model corresponds to the particular case with dC_dT = 0.

  • Implement the constitutive model
  • Validation script and examples
  • Unit tests
  • Integrated test
  • Change the xml files

@sytuannguyen sytuannguyen added type: feature New feature or request flag: requires rebaseline Requires rebaseline branch in integratedTests changes XML input labels Apr 22, 2024
@sytuannguyen sytuannguyen self-assigned this Apr 22, 2024
Copy link
Contributor

@herve-gross herve-gross left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for this contribution and for documenting it properly.

@sytuannguyen sytuannguyen marked this pull request as ready for review May 30, 2024 02:22
@sytuannguyen sytuannguyen added the ci: run CUDA builds Allows to triggers (costly) CUDA jobs label May 30, 2024
Copy link

codecov bot commented May 30, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 53.57%. Comparing base (85f6d0c) to head (88dce23).
Report is 5 commits behind head on develop.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #3088   +/-   ##
========================================
  Coverage    53.57%   53.57%           
========================================
  Files         1003     1003           
  Lines        85297    85305    +8     
========================================
+ Hits         45695    45703    +8     
  Misses       39602    39602           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sytuannguyen sytuannguyen added the ci: run integrated tests Allows to run the integrated tests in GEOS CI label May 30, 2024
setDescription( "Reference solid volumetric heat capacity [J/(kg.K)]" );

registerWrapper( viewKeyStruct::dVolumetricHeatCapacity_dTemperatureString(), &m_dVolumetricHeatCapacity_dTemperature ).
setInputFlag( InputFlags::REQUIRED ).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
setInputFlag( InputFlags::REQUIRED ).
setApplyDefaultValue( 0.0 ).

@@ -109,7 +109,8 @@ char const * xmlInput =
referencePressure="0.0"
compressibility="1.0e-9" />
<SolidInternalEnergy name="rockInternalEnergy"
volumetricHeatCapacity="1.95e6"
referenceVolumetricHeatCapacity="1.95e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

@@ -94,7 +94,8 @@ char const * xmlInput =
referencePressure="0.0"
compressibility="1.0e-9" />
<SolidInternalEnergy name="rockInternalEnergy"
volumetricHeatCapacity="1.95e6"
referenceVolumetricHeatCapacity="1.95e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

@@ -63,7 +63,8 @@

<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="1.95e6"
referenceVolumetricHeatCapacity="1.95e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

volumetricHeatCapacity="4.56e6"
name="rockInternalEnergy_linear"
referenceVolumetricHeatCapacity="4.56e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

@@ -104,7 +104,8 @@
compressibility="1.0e-9"/>
<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="1.95e6"
referenceVolumetricHeatCapacity="1.95e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

@@ -80,7 +80,8 @@

<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="2.3345e6"
referenceVolumetricHeatCapacity="2.3345e6"
dVolumetricHeatCapacity_dTemperature="1e6"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dVolumetricHeatCapacity_dTemperature for this case should be zero (default value)?

Suggested change
dVolumetricHeatCapacity_dTemperature="1e6"

@@ -47,7 +47,8 @@

<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="1.672e5"
referenceVolumetricHeatCapacity="1.672e5"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

@@ -49,7 +49,8 @@
<!-- SPHINX_INTERNAL_ENERGY -->
<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="1.672e5"
referenceVolumetricHeatCapacity="1.672e5"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

@@ -188,7 +188,8 @@

<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="1.95e6"
referenceVolumetricHeatCapacity="1.95e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

@@ -37,7 +37,8 @@

<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="1.672e5"
referenceVolumetricHeatCapacity="1.672e5"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

@@ -219,7 +219,8 @@

<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="1.672e5"
referenceVolumetricHeatCapacity="1.672e5"
dVolumetricHeatCapacity_dTemperature="1e6"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dVolumetricHeatCapacity_dTemperature for this case should be zero (default value)?

Suggested change
dVolumetricHeatCapacity_dTemperature="1e6"

@@ -168,19 +168,22 @@
<!-- SPHINX_HeatCapacityProperties -->
<SolidInternalEnergy
name="casingInternalEnergy"
volumetricHeatCapacity="1.375e6"
referenceVolumetricHeatCapacity="1.375e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

referenceTemperature="0"
referenceInternalEnergy="0"/>

<SolidInternalEnergy
name="cementInternalEnergy"
volumetricHeatCapacity="4.2e6"
referenceVolumetricHeatCapacity="4.2e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

referenceTemperature="0"
referenceInternalEnergy="0"/>

<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="4.56e6"
referenceVolumetricHeatCapacity="4.56e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

@@ -110,19 +110,22 @@
<!-- SPHINX_HeatCapacityProperties -->
<SolidInternalEnergy
name="casingInternalEnergy"
volumetricHeatCapacity="1.375e6"
referenceVolumetricHeatCapacity="1.375e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

referenceTemperature="0"
referenceInternalEnergy="0"/>

<SolidInternalEnergy
name="cementInternalEnergy"
volumetricHeatCapacity="4.2e6"
referenceVolumetricHeatCapacity="4.2e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

referenceTemperature="0"
referenceInternalEnergy="0"/>

<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="4.56e6"
referenceVolumetricHeatCapacity="4.56e6"
dVolumetricHeatCapacity_dTemperature="0"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dVolumetricHeatCapacity_dTemperature="0"

@@ -73,7 +73,8 @@
<!-- SPHINX_HeatCapacityProperties -->
<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="1.89e6"
referenceVolumetricHeatCapacity="1.89e6"
dVolumetricHeatCapacity_dTemperature="1e6"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dVolumetricHeatCapacity_dTemperature for this case should be zero (default value)?

Suggested change
dVolumetricHeatCapacity_dTemperature="1e6"

solidModelName="nullSolid"
porosityModelName="rockPorosity"
permeabilityModelName="rockPerm"
solidInternalEnergyModelName="rockInternalEnergy_linear"/>
Copy link
Contributor

@jhuang2601 jhuang2601 Jun 4, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggest to use the name as rockInternalEnergy_constant

solidModelName="nullSolid"
porosityModelName="rockPorosity"
permeabilityModelName="rockPerm"
solidInternalEnergyModelName="rockInternalEnergy"/>
solidInternalEnergyModelName="rockInternalEnergy_nonLinear"/>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggest to use the name as rockInternalEnergy_linear

@@ -51,12 +51,22 @@

<!-- SPHINX_SolidInternalEnergy -->
<SolidInternalEnergy
name="rockInternalEnergy"
volumetricHeatCapacity="4.56e6"
name="rockInternalEnergy_linear"
Copy link
Contributor

@jhuang2601 jhuang2601 Jun 4, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggest to use the name as rockInternalEnergy_constant

referenceTemperature="0"
referenceInternalEnergy="0"/>
<!-- SPHINX_SolidInternalEnergyEnd -->

<!-- SPHINX_SolidInternalEnergy_nonLinear -->
<SolidInternalEnergy
name="rockInternalEnergy_nonLinear"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggest to use the name as rockInternalEnergy_linear

@@ -5162,12 +5162,14 @@ If you want to do a three-phase simulation, please use instead wettingIntermedia
<xsd:attribute name="name" type="groupName" use="required" />
</xsd:complexType>
<xsd:complexType name="SolidInternalEnergyType">
<!--dVolumetricHeatCapacity_dTemperature => Derivative of the solid volumetric heat capacity w.r.t. temperature [J/(m^3.K^2)]-->
<xsd:attribute name="dVolumetricHeatCapacity_dTemperature" type="real64" use="required" />
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<xsd:attribute name="dVolumetricHeatCapacity_dTemperature" type="real64" use="required" />
<xsd:attribute name="dVolumetricHeatCapacity_dTemperature" type="real64" default="0.0" />

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changes XML input ci: run CUDA builds Allows to triggers (costly) CUDA jobs ci: run integrated tests Allows to run the integrated tests in GEOS CI flag: ready for review flag: requires rebaseline Requires rebaseline branch in integratedTests type: feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants