← Back to team overview

dolfin team mailing list archive

Re: Missing Hierarchical interface in Python

 

On Tue, Feb 01, 2011 at 09:47:08PM +0100, Anders Logg wrote:
> On Tue, Feb 01, 2011 at 12:42:37PM -0800, Johan Hake wrote:
> > On Tuesday February 1 2011 12:36:06 Anders Logg wrote:
> > > On Tue, Feb 01, 2011 at 12:31:28PM -0800, Johan Hake wrote:
> > > > On Tuesday February 1 2011 12:23:10 Anders Logg wrote:
> > > > > The Hierarchical interface seems to be missing in Python. I can't do
> > > > >
> > > > >   mesh.has_child()
> > > > >   mesh.child()
> > > > >   etc
> > > >
> > > > I can:
> > > >
> > > > In [1]: from dolfin import *
> > > >
> > > > In [2]: mesh = UnitCube(8, 8, 8)
> > > >
> > > > In [3]: V = FunctionSpace(mesh, 'CG', 1)
> > > >
> > > > In [4]: V.has_child()
> > > > Out[4]: False
> > > >
> > > > In [5]: mesh.has_child()
> > > > Out[5]: True
> > > >
> > > > Seams a bit silly that mesh should have a child though...
> > >
> > > Why? Isn't that natural that if a mesh has been refined, then it has a
> > > child mesh. And the refined mesh has a parent.
> >
> > Sure! But the above mesh is a fresh UnitCube which has not been refined. Still
> > it reports, having a child. The FunctionSpace reports no child though.
>
> That's a bug. I thought you were talking about a Mesh having a child
> in general. Will fix it as soon as I get the SWIG interface to run.
>
> > > > What SWIG version do you have.
> > >
> > > 1.3.40
> >
> > Same here...
> >
> > Do you have the latest tip?
>
> Yes. Will try to wipe my build directory and rebuild
> everything. Something may not have been rebuilt correctly.

Rebuilding did the trick. Will continue to debug now.

--
Anders



References