mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Merge dev into pre-proto
This commit is contained in:
@@ -21,6 +21,7 @@
|
||||
#include "cafAppEnum.h"
|
||||
|
||||
#include "cvfAssert.h"
|
||||
#include <cmath>
|
||||
|
||||
namespace caf
|
||||
{
|
||||
@@ -57,3 +58,27 @@ double RiaEclipseUnitTools::darcysConstant(UnitSystem unitSystem)
|
||||
return 0.0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
double RiaEclipseUnitTools::convertConductivtyValue(double Kw, UnitSystem fromUnit, UnitSystem toUnit)
|
||||
{
|
||||
|
||||
if (fromUnit == toUnit) return Kw;
|
||||
|
||||
else if (fromUnit == UNITS_METRIC && toUnit == UNITS_FIELD)
|
||||
{
|
||||
return meterToFeet(Kw);
|
||||
}
|
||||
else if (fromUnit == UNITS_METRIC && toUnit == UNITS_FIELD)
|
||||
{
|
||||
return feetToMeter(Kw);
|
||||
}
|
||||
|
||||
CVF_ASSERT(false);
|
||||
|
||||
return HUGE_VAL;
|
||||
}
|
||||
|
||||
|
||||
@@ -44,5 +44,8 @@ public:
|
||||
static double inchToFeet (double inch) { return (inch / 12.0); }
|
||||
|
||||
static double darcysConstant(UnitSystem unitSystem);
|
||||
|
||||
static double convertConductivtyValue(double Kw, UnitSystem fromUnit, UnitSystem toUnit);
|
||||
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user