← Back to team overview

dolfin team mailing list archive

Re: Bug when iterating over meshes

 

We might need a signature() function in the mesh class. It could be
a function of the number of vertices, edges etc. That should cover
many cases (but not if someone moves the coordinates).

--
Anders

On Sun, Jan 31, 2010 at 03:26:30PM -0800, Johan Hake wrote:
> Hello.
>
> The mesh registered in the forms (a and L) is the original mesh from the first
> itteration, as it is cached in the form_data. ffc.jit does not recognize when
> a mesh is changed.
>
> Not sure how this can be fixed. We might use the form together with the
> id(mesh) as keys in the cache.
>
> Johan
>
> On Sunday 31 January 2010 13:34:00 Marie Rognes wrote:
> > This gives me a terrible PETSc crash:
> >
> > from dolfin import *
> >
> > def run(mesh):
> >
> >     V = FunctionSpace(mesh, "CG", 1)
> >     v = TestFunction(V)
> >     u = TrialFunction(V)
> >     f = Expression("1.0")
> >
> >     a = dot(v, u)*dx
> >     L = dot(v, f)*dx
> >
> >     pde = VariationalProblem(a, L)
> >     w = pde.solve()
> >     plot(w)
> >
> > meshes = [UnitSquare(n, n) for n in range(1, 3)]
> >
> > for mesh in meshes:
> >     run(mesh)
> >
> >
> >
> > _______________________________________________
> > Mailing list: https://launchpad.net/~dolfin
> > Post to     : dolfin@xxxxxxxxxxxxxxxxxxx
> > Unsubscribe : https://launchpad.net/~dolfin
> > More help   : https://help.launchpad.net/ListHelp
> >
>
> _______________________________________________
> Mailing list: https://launchpad.net/~dolfin
> Post to     : dolfin@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~dolfin
> More help   : https://help.launchpad.net/ListHelp

Attachment: signature.asc
Description: Digital signature


References