dolfin team mailing list archive
-
dolfin team
-
Mailing list archive
-
Message #08679
Re: Built-in meshes. UnitSphere
On Mon, Jul 14, 2008 at 11:44:53PM +0100, ndl@xxxxxxxxxxxxxx wrote:
> I Hope this works, and that i didn't forget anything.
> I've followed the manual..clone add commit bundle
Yes, works great.
> By the way about the smooth( ) function,
> does it works only with convex meshes?
Yes, there are problems for conconvex meshes. I wasn't aware of that,
but consider a vertex at (0, 0) surrounded by 4 neighboring vertices
located at
(0, -epsilon), (0, epsilon), (-1, -C), (1, -C)
and say that the vertex at (0, -epsilon) is fixed (it's a boundary
vertex).
Then after averaging the neighboring vertices, the new y-coordinate for
the vertex will be
(-epsilon + epsilon -C -C) / 4 = -C/2
so by increasing C, we can move the new vertex location arbitrarily
far below 0 (outside of the domain).
I don't know if there's an easy fix.
--
Anders
> (i really don't know about the method...)
> But if it is supposed to be generic, test the following code:
>
> ---------------------------------------------------------------------------------
> UnitCircle mesh30(40,UnitCircle::left ,UnitCircle::sumn);
> for (dolfin::uint i=0;i<5;i++)
> mesh30.smooth();
> File fmesh30("not_circle_smooth.pvd");
> fmesh30<<mesh30;
>
> UnitCircle mesh31(40,UnitCircle::left ,UnitCircle::sumn);
> File fmesh31("not_circle_not_smooth.pvd");
> fmesh31<<mesh31;
> ---------------------------------------------------------------------------------
>
> and look at the non-convex corners of the meshes.
> The smoothed one is broken....
> By the way if we replace 'left' by 'crisscross' it seems that
> there is no problem.
>
> On Monday 14 July 2008, Anders Logg wrote:
> > It looks like you forgot to commit the added files before creating
> > the bundle. I can't find UnitSphere.{cpp,h}:
> >
> > # hg incoming -v ~/contrib/dolfin-lopes-2008-07-10.hg | grep files
> > files: dolfin/io/File.cpp dolfin/io/File.h dolfin/io/XYZFile.cpp
> > dolfin/io/XYZFile.h files: site-packages/dolfin/meshconvert.py
> > files: site-packages/dolfin/meshconvert.py
> > files: dolfin/mesh/dolfin_mesh.h
>
>
>
> _______________________________________________
> DOLFIN-dev mailing list
> DOLFIN-dev@xxxxxxxxxx
> http://www.fenics.org/mailman/listinfo/dolfin-dev
Attachment:
signature.asc
Description: Digital signature
Follow ups
References