Commit aece285c authored by Markus Blatt's avatar Markus Blatt

Modification due to deprecated InterSectionIterator methods.

[[Imported from SVN: r73]]
parent 981bb88f
......@@ -16,7 +16,7 @@ void evolve (const G& grid, const M& mapper, V& c, double t, double& dt)
typedef typename G::template Codim<0>::LeafIterator LeafIterator;
// intersection iterator type
typedef typename G::template Codim<0>::IntersectionIterator IntersectionIterator;
typedef typename G::template Codim<0>::LeafIntersectionIterator IntersectionIterator;
// entity pointer type
typedef typename G::template Codim<0>::EntityPointer EntityPointer;
......@@ -56,8 +56,8 @@ void evolve (const G& grid, const M& mapper, V& c, double t, double& dt)
std::cout << "LEAF ELEMENT "<< " pos=" << global << " index=" << indexi << std::endl;
// run through all intersections with neighbors and boundary
IntersectionIterator isend = it->iend();
for (IntersectionIterator is = it->ibegin(); is!=isend; ++is)
IntersectionIterator isend = it->ileafend();
for (IntersectionIterator is = it->ileafbegin(); is!=isend; ++is)
{
// get geometry type of face
Dune::GeometryType gtf = is.intersectionSelfLocal().type();
......@@ -86,7 +86,7 @@ void evolve (const G& grid, const M& mapper, V& c, double t, double& dt)
if (factor>=0) sumfactor += factor;
// handle interior face
if (is.leafNeighbor()) // "correct" version
if (is.neighbor()) // "correct" version
{
// access neighbor
EntityPointer outside = is.outside();
......
......@@ -31,7 +31,7 @@ bool finitevolumeadapt (G& grid, M& mapper, V& c, int lmin, int lmax, int k)
typedef typename G::template Codim<0>::EntityPointer EntityPointer;
// intersection iterator type
typedef typename G::template Codim<0>::IntersectionIterator IntersectionIterator;
typedef typename G::template Codim<0>::LeafIntersectionIterator IntersectionIterator;
// global id set types
typedef typename G::template Codim<0>::LocalIdSet IdSet;
......@@ -51,9 +51,9 @@ bool finitevolumeadapt (G& grid, M& mapper, V& c, int lmin, int lmax, int k)
globalmax = std::max(globalmax,c[indexi]);
globalmin = std::min(globalmin,c[indexi]);
IntersectionIterator isend = it->iend();
for (IntersectionIterator is = it->ibegin(); is!=isend; ++is)
if (is.leafNeighbor())
IntersectionIterator isend = it->ileafend();
for (IntersectionIterator is = it->ileafbegin(); is!=isend; ++is)
if (is.neighbor())
{
// access neighbor
EntityPointer outside = is.outside();
......@@ -81,9 +81,9 @@ bool finitevolumeadapt (G& grid, M& mapper, V& c, int lmin, int lmax, int k)
{
grid.mark(1,it);
marked++;
IntersectionIterator isend = it->iend();
for (IntersectionIterator is = it->ibegin(); is!=isend; ++is)
if (is.leafNeighbor())
IntersectionIterator isend = it->ileafend();
for (IntersectionIterator is = it->ileafbegin(); is!=isend; ++is)
if (is.neighbor())
if (is.outside().level()<lmax || !is.outside()->isRegular())
grid.mark(1,is.outside());
}
......
......@@ -20,7 +20,7 @@ void parevolve (const G& grid, const M& mapper, V& c, double t, double& dt)
template Partition<Dune::All_Partition>::LeafIterator LeafIterator;
// intersection iterator type
typedef typename G::template Codim<0>::IntersectionIterator IntersectionIterator;
typedef typename G::template Codim<0>::LeafIntersectionIterator IntersectionIterator;
// entity pointer type
typedef typename G::template Codim<0>::EntityPointer EntityPointer;
......@@ -59,8 +59,8 @@ void parevolve (const G& grid, const M& mapper, V& c, double t, double& dt)
double sumfactor = 0.0;
// run through all intersections with neighbors and boundary
IntersectionIterator isend = it->iend();
for (IntersectionIterator is = it->ibegin(); is!=isend; ++is)
IntersectionIterator isend = it->ileafend();
for (IntersectionIterator is = it->ileafbegin(); is!=isend; ++is)
{
// get geometry type of face
Dune::GeometryType gtf = is.intersectionSelfLocal().type();
......@@ -89,7 +89,7 @@ void parevolve (const G& grid, const M& mapper, V& c, double t, double& dt)
if (factor>=0) sumfactor += factor;
// handle interior face
if (is.leafNeighbor())
if (is.neighbor())
{
// access neighbor
EntityPointer outside = is.outside();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment