ufz / ogs5

OpenGeoSys THM/C simulator version 5
https://www.opengeosys.org/ogs-5
Other
39 stars 97 forks source link

Unify the temperaure unit #115

Closed wenqing closed 5 years ago

wenqing commented 5 years ago

As titled.

With the changes, the temperature unit is set to Kelvin in the calculation.

For the input data, there is an option to select the the temperature unit by a new keyword of process: $TEMPERATURE_UNIT with a value of KELVIN or CELSIUS.

If CELSIUS is selected for $TEMPERATURE_UNIT, the temperature data in initial conditions, Dirichlet boundary conditions and material properties are converted to the data in Kelvin during the initialization of the instance of process class, and the output of temperature result keeps in Celsius.

Questions:

  1. Do we need temperature unit option?
  2. If we need it, which temperature unit should be the default one? One can omit the keyword of $TEMPERATURE_UNIT if the temperature unit is the same as the default. In the present implementation, the default temperature is Celsius. Most of temperature related benchmarks take Kelvin, while some applications of projects use Celsius. If Kelvin is set as default temperature unit, the changes in PR ufz/ogs5-benchmarks#20 will drop.

Benchmarks results: Most of temperature related benchmarks satisfy with the current changes and keep quiet during the result comparison. Only the THM benchmarks show tiny difference in the result comparison (see ufz/ogs5-benchmarks_ref#30).

wenqing commented 5 years ago

Benchmarking works only after ufz/ogs5-benchmarks#20 and ufz/ogs5-benchmarks_ref#30 being merged.

norihiro-w commented 5 years ago

:+100. i prefer Celsius as the default

wenqing commented 5 years ago

@norihiro-w I agree with you that the Celsius is the default temperature unit. I am going to merge the benchmarks updates.

wenqing commented 5 years ago

@norihiro-w All tests run. Do you have any further comments?

norihiro-w commented 5 years ago

no i have no further comments. please merge this. it seems I don't have write access anymore.