[Dune] [Dune-Commit] dune-grid r5015 - trunk/grid/test

Carsten Graeser graeser at math.fu-berlin.de
Fri Apr 3 10:15:03 CEST 2009


Dear Dune Developers,
from the messages below the current state on the subIndex method seems to be:

*Oliver wants the template-arg method to have the same numbering
*Peter wants the template-arg method to remain
*Sven thinks that having different numbering conflicts with keeping the template-arg method
 but remembers that is was decided differently
*Martin thinks that the numbering should be different and changed the test accordingly

So currently there seems to be no definite agreement about this issue.
Perhaps it would be a good idea to decide this before further changes are
applied. (Especially for maintainers of a grid implementation like me. ;-) )

Best regard
Carsten


Oliver Sander schrieb:
> Shouldn't the old method use the new numbering as well?
> Then the test would be okay as it is.

Peter Bastian schrieb:
>> - Do we keep the old member template methods?
> I would keep it, as it might be more efficient.

Sven Marnach schrieb:
> As I remember the discussion, the idea was to keep the old methods
> with the old numbering for a smooth transition, providing backward
> compatibility for one release.  After the transition period, the old
> methods are to be deleted.
>
> That idea somehow conflicts with the idea to keep the old subIndex
> method with a template codim parameter.


mnolte at dune-project.org schrieb:
> Author: mnolte
> Date: 2009-04-03 09:43:03 +0200 (Fri, 03 Apr 2009)
> New Revision: 5015
> Modified: trunk/grid/test/checkindexset.cc
> ===================================================================
> --- trunk/grid/test/checkindexset.cc	2009-04-03 07:40:07 UTC (rev 5014)
> +++ trunk/grid/test/checkindexset.cc	2009-04-03 07:43:03 UTC (rev 5015)
> @@ -448,9 +448,17 @@
>          
>          // the subIndex and the index for subEntity must be the same 
>          assert( vxidx == lset.index( *vxp ));
> +        
> +        typedef GenericGeometry::MapNumberingProvider< dim > Numbering;
> +        const unsigned int tid = GenericGeometry::topologyId( it->type() );
> +        const int gi = Numbering::template dune2generic< dim >( tid, i );
>  
>          // static and dynamic method must yield the same result
> -        assert( vxidx == lset.subIndex(*it,i,dim));
> +        if( vxidx != lset.subIndex( *it, gi, dim ) )
> +        {
> +          std::cerr << "Error: subIndex< dim >( entity, i ) != subIndex( entity, dune2generic( i ), dim )" << std::endl;
> +          assert( vxidx == lset.subIndex( *it, gi, dim ) );
> +        }
>            
>          // check whether the coordinates are the same 
>        	assert(vertexCoordsMap.find(vxidx)!=vertexCoordsMap.end());


-- 
----------------------------------------------------------------------
Carsten Gräser           | phone: +49-30 / 838-75349
Freie Universität Berlin | fax  : +49-30 / 838-54977
Institut für Mathematik  | email: graeser at math.fu-berlin.de
Arnimallee 6             |
14195 Berlin, Germany    | URL  : http://page.mi.fu-berlin.de/graeser
----------------------------------------------------------------------




More information about the Dune mailing list