From 71596fe8a334bba7bdf9ba2ea60c53f19e55a349 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?B=C3=A5rd=20Skaflestad?= Date: Tue, 19 Aug 2014 18:17:18 +0200 Subject: [PATCH] CornerpointChopper::writeGrdecl(): Write fewer items per line This is in preparation of increasing the vector output precision to reduce the impact of rounding errors in subsequent upscaling. The change impacts floating-point vectors only. Background: The ECL simulator stipulates an upper bound on the number of characters in a record (i.e., one line) and while we don't have such limits, there's no reason to emit lines that can't be input by other tools. --- opm/core/io/eclipse/CornerpointChopper.hpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/opm/core/io/eclipse/CornerpointChopper.hpp b/opm/core/io/eclipse/CornerpointChopper.hpp index c6aaa435..46db8050 100644 --- a/opm/core/io/eclipse/CornerpointChopper.hpp +++ b/opm/core/io/eclipse/CornerpointChopper.hpp @@ -309,16 +309,16 @@ namespace Opm out << "SPECGRID\n" << new_dims_[0] << ' ' << new_dims_[1] << ' ' << new_dims_[2] << " 1 F\n/\n\n"; - outputField(out, new_COORD_, "COORD", /* nl = */ 6); - outputField(out, new_ZCORN_, "ZCORN", /* nl = */ 8); + outputField(out, new_COORD_, "COORD", /* nl = */ 3); + outputField(out, new_ZCORN_, "ZCORN", /* nl = */ 4); outputField(out, new_ACTNUM_, "ACTNUM"); - outputField(out, new_PORO_, "PORO"); - if (hasNTG()) {outputField(out, new_NTG_, "NTG");} - if (hasSWCR()) {outputField(out, new_SWCR_, "SWCR");} - if (hasSOWCR()) {outputField(out, new_SOWCR_, "SOWCR");} - outputField(out, new_PERMX_, "PERMX"); - outputField(out, new_PERMY_, "PERMY"); - outputField(out, new_PERMZ_, "PERMZ"); + outputField(out, new_PORO_, "PORO", 4); + if (hasNTG()) {outputField(out, new_NTG_, "NTG", 4);} + if (hasSWCR()) {outputField(out, new_SWCR_, "SWCR", 4);} + if (hasSOWCR()) {outputField(out, new_SOWCR_, "SOWCR", 4);} + outputField(out, new_PERMX_, "PERMX", 4); + outputField(out, new_PERMY_, "PERMY", 4); + outputField(out, new_PERMZ_, "PERMZ", 4); outputField(out, new_SATNUM_, "SATNUM"); } bool hasNTG() const {return !new_NTG_.empty(); }