Skip to content

Commit

Permalink
Merge pull request #463 from akva2/fix_polyhedral_print
Browse files Browse the repository at this point in the history
fixed: print output to passed stream
  • Loading branch information
dr-robertk authored Apr 14, 2020
2 parents 9915012 + a39c66a commit 4d13b91
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions opm/grid/polyhedralgrid/grid.hh
Original file line number Diff line number Diff line change
Expand Up @@ -1674,27 +1674,27 @@ namespace Dune
const int numCells = grid.number_of_cells;
for( int c=0; c<numCells; ++c )
{
std::cout << "cell " << c << " : faces = " << std::endl;
out << "cell " << c << " : faces = " << std::endl;
for (int hf=grid.cell_facepos[ c ]; hf < grid.cell_facepos[c+1]; ++hf)
{
int f = grid_.cell_faces[ hf ];
const int* fnbeg = grid_.face_nodes + grid_.face_nodepos[f];
const int* fnend = grid_.face_nodes + grid_.face_nodepos[f+1];
std::cout << f << " vx = " ;
out << f << " vx = " ;
while( fnbeg != fnend )
{
std::cout << *fnbeg << " ";
out << *fnbeg << " ";
++fnbeg;
}
std::cout << std::endl;
out << std::endl;
}
std::cout << std::endl;
out << std::endl;

const auto& vx = cellVertices_[ c ];
std::cout << "cell " << c << " : vertices = ";
out << "cell " << c << " : vertices = ";
for( size_t i=0; i<vx.size(); ++i )
std::cout << vx[ i ] << " ";
std::cout << std::endl;
out << vx[ i ] << " ";
out << std::endl;
}

}
Expand Down

0 comments on commit 4d13b91

Please sign in to comment.