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

Use Existing Cartesian-to-IJK Functionality to Determine NNCs in MULTREGT #3639

Merged
merged 3 commits into from
Aug 22, 2023

Conversation

bska
Copy link
Member

@bska bska commented Aug 18, 2023

This PR replaces the data members nx, ny, and nz with a copy of the GridDims object passed as an argument to the constructor. In turn, this enables using GridDims::getIJK() to compute the cell's IJK tuple from its global Cartesian index instead of implementing the same calculation locally (and incorrectly).

While here, also include the layer index (K) in determining whether or not a connection is an NNC, and do this just once instead of once for each MULTREGT record. Cells (I,J,K) and (I,J,K+3) might be connected across pinched-out layers and for the purposes of MULTREGT that connection should be treated as an NNC.

@bska
Copy link
Member Author

bska commented Aug 18, 2023

jenkins build this please

@bska bska force-pushed the multregt-revise-nnc-identification branch from 112bf6e to 3afc1fe Compare August 18, 2023 13:10
@bska
Copy link
Member Author

bska commented Aug 18, 2023

jenkins build this please

@bska bska force-pushed the multregt-revise-nnc-identification branch from 3afc1fe to 8bbbf13 Compare August 18, 2023 13:26
@bska
Copy link
Member Author

bska commented Aug 18, 2023

jenkins build this please

1 similar comment
@bska
Copy link
Member Author

bska commented Aug 18, 2023

jenkins build this please

A numeric index serves the same purpose as a pointer in this very
specific instance and also has the benefit of being easily
transferable between processes.  This, in turn, means we can remove
the 'getSearchMap()' and 'constructSearchMap()' member functions.
In particular, ensure that we include all requisite headers, hide
type aliases that are not needed outside the class, consistently use
std::size_t, split a few long lines, and switch to range-for in one
location.
This commit replaces the data members 'nx', 'ny', and 'nz' with a
copy of the GridDims object passed as an argument to the
constructor.  In turn, this enables using GridDims::getIJK() to
compute the cell's IJK tuple from its global Cartesian index instead
of implementing the same calculation locally (and incorrectly).

While here, also include the layer index (K) in determining whether
or not a connection is an NNC, and do this just once instead of once
for each MULTREGT record.  Cells (I,J,K) and (I,J,K+3) might be
connected across pinched-out layers and for the purposes of MULTREGT
that connection should be treated as an NNC.
@bska bska force-pushed the multregt-revise-nnc-identification branch from 8bbbf13 to f32ff86 Compare August 21, 2023 09:50
@bska
Copy link
Member Author

bska commented Aug 21, 2023

jenkins build this please

@blattms
Copy link
Member

blattms commented Aug 21, 2023

I am curious: What did you do to make the number of NNCs match again? I recall that some tests were failing previously because the number of NNCs did change.

@bska
Copy link
Member Author

bska commented Aug 21, 2023

What did you do to make the number of NNCs match again?

Probably #3644. It's not completely clear to me, however.

@blattms blattms merged commit d9cdfac into OPM:master Aug 22, 2023
1 check passed
@bska bska deleted the multregt-revise-nnc-identification branch August 22, 2023 06:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants