mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#875 Fixed wrong number of digits after punctation for numbers < 1000
This commit is contained in:
parent
a4fb6a37ae
commit
382bf84036
2
ThirdParty/NRLib/nrlib/well/laswell.cpp
vendored
2
ThirdParty/NRLib/nrlib/well/laswell.cpp
vendored
@ -454,7 +454,7 @@ int calculatePrecision(double value)
|
||||
{
|
||||
double absVal = fabs(value);
|
||||
if (1e-16 < absVal && absVal < 1.0e3){
|
||||
int logVal = static_cast<int>(log(absVal));
|
||||
int logVal = static_cast<int>(log10(absVal));
|
||||
int numDigitsAfterPoint = abs(logVal - 6);
|
||||
return numDigitsAfterPoint;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user