Dear Kostas,

The dal::dynamic_tree_sorted implements an array with a sorted index. It is 
closed from std::map. The difference is that the values are stored in an 
array. It is an old implementation (1995). At that time the STL was not yet 
stabilized and available on all implementations ! (In fact I did not know its 
existence when I programmed dal::dynamic_tree_sorted).

Normally, it is stable. It is used in several algorithm in getfem. So, i am a 
bit surprised that it does not work ... !

However, the use of dal::dynamic_tree_sorted should be avoided now and 
replaced by the use of a std::map. So, if it is working with a std::map, 
please commit your changes.

Regards,

Yves.



On dimanche 21 mars 2010, Konstantinos Poulios wrote:
> Trying to import the attached gmsh file in getfem results to the
> following error:
>
> Traceback (most recent call last):
>   File "tmp.py", line 23, in <module>
>     m_2 = Mesh('import', 'gmsh', './TransmissionC_3D2.msh')
>   File
> "/opt/getfem-rev3507-mumps/lib/python2.6/site-packages/getfem/getfem.py",
> line 1446, in __init__
>     generic_constructor(self,'mesh',*args)
>   File
> "/opt/getfem-rev3507-mumps/lib/python2.6/site-packages/getfem/getfem.py",
> line 66, in generic_constructor
>     self.id = getfem_from_constructor(clname,*args)
> RuntimeError: (Getfem::InterfaceError) -- Error in getfem_import.cc, line
> 234 : Invalid node ID 2845 in gmsh convex 13831
>
> It seems that the problem is related to the following object used to
> map the gmsh node ids to getfem node ids:
>
> dal::dynamic_tree_sorted<size_type> msh_node_2_getfem_node;
>
> After I replaced this object in getfem_import.cc with:
>
> std::map<size_type, size_type> msh_node_2_getfem_node;
>
> the mesh can be imported without errors.
>
> Since I have not much experience with the dal::dynamic_tree_sorted
> object, every hint could be helpful.
>
> Regards.
>
> Kostas



-- 

  Yves Renard ([email protected])       tel : (33) 04.72.43.87.08
  Pole de Mathematiques, INSA-Lyon             fax : (33) 04.72.43.85.29
  20, rue Albert Einstein
  69621 Villeurbanne Cedex, FRANCE
  http://math.univ-lyon1.fr/~renard

---------

_______________________________________________
Getfem-users mailing list
[email protected]
https://mail.gna.org/listinfo/getfem-users

Reply via email to