[Gmsh] [Fwd: Re: RE The direction of normal vectors on the surface elements]

Theler German Guillermo gtheler at cites-gss.com
Fri Jan 30 14:32:25 CET 2015


Sorry, I sent my reply directly to Christophe.



-------- Forwarded Message --------
From: German Theler <gtheler at cites-gss.com>
To: Christophe Geuzaine <cgeuzaine at ulg.ac.be>
Subject: Re: [Gmsh] RE The direction of normal vectors on the surface
elements
Date: Fri, 30 Jan 2015 09:24:09 -0300

On Thu, 2015-01-29 at 19:32 +0100, Christophe Geuzaine wrote:
> >> In what sense? All the data you need is there...
> > I woukd like a mechanism for obtaining the normal pointing away from the bulk domain, not just following the face orientation.
> The problem is that if this surface is now shared by two volumes, the orientation will be "wrong" for one of those volumes. So the only way is really to keep track of the orientation in the definition of the volume... which is what we do.

This is true generally speaking. But surfaces that are in the border of
the domain, which is where I would like to set boundary conditions are
not shared by several volumes. There is only one "volumetric" element
attached to the "surface" element, and the direction of the outward
normal is such that the inner product between the normal (either n1 or
n2 in the attached figure) and vector v that joins the baricenter of the
surface element the baricenter of the volumetric element is negative
(that would be n1 in see attached figure). This is the normal I would
like to have saved in the output mesh file.

I am also attaching again the image of the cube with the normals
computed by Gmsh. If only the shown normals are saved in the mesh file
(which would be an improvement anyhow), the solver has to check for the
sign of the inner product and reverse those normals that point inwards.
The check itself is not a big deal, but in order to find where the
"bulk" of the domain is, the solver has to find which is the volumetric
element attached to the surface element. If Gmsh cannot compute the true
outward normals, at least a simple mechanishm for linking surface and
volumetric elements should be provided. Indeed, this link would serve
for the next paragraph.

> > Moreover, the attached geometry files is composed of two blocks which correspond to different physical groups (say they are made of different materials). In the case that the boundary condition involves a bulk property (say the thermal conductivity in a neumann-type bondary condition for the heat conduction equation) there is no way to directly link the surface elements in physical entities 101 and to the the corresponding attached volume element, which is the one that belongs to either physical entity 204 or 205 that refers to the actual material.
> Mathematically, your Neumann condition is expressed on a surface (and not on a surface element). The right level to define the condition is thus at the level of the geometrical entity (the physical group) ; not at the element (or even worse at the node) level. We leave it to the user to name the surface physical groups that are needed by the mathematical problem at hand.

The condition is evaluated on a surface, but this expression may be a
function of space. Please consider again the boundary condition of fixed
heat flux in bc.pdf:


$- k(x,y,z) \cdot \nabla T(x,y,z) \cdot \vec{n} = q$

k is the thermal conductivity, which is a property of the bulk material.
So in order to evaluate k(x,y,z) I have to know to which material the
surface element belongs to. Now, as I understood, physical groups of
volumetric elements refer to materials but physical groups of surface
elements refer only to boundary conditions, as referring to materials
would be a duplication of information.
Again, in the attached normals.geo, I have two physical surfaces 101 and
102 and two physical volumes 204 and 205. Say I want to set fixed
temperatures (Dirichlet) in surface 101 (bottom and top of the box) and
fixed heat flux (Neumann) in surface 102 (the four sides of the box).
But the box is composed of two materials (physical volumes). So the four
combinations of two boundary condition types and two thermal
conductivities (not necesarrily uniform, as they can depend on space but
they are continuous within the same material) are present using only two
physical surfaces and two physical volumes.

That is wht I would like to link the surface element to the volumetric
element, which BTW would solve the outward normals issue discused in the
previous paragraph. Moreover, uf a list of the neighbors of each element
is written then the resulting mesh can be easily used in
finite-volumes-based solvers.


> > What about adding optional sections like $Normals$/$EndNormals$, $Neighbors$/$EndNeighbors$?
> Sure, why not. Some file format store such information (see e.g. GModelIO_CELUM, which keeps track of normals at vertices).

Thanks for pointing this file out. I will take a closer look.

> > Is the ANN library only used for the nearest-neighbor plugin or Gmsh uses it when computing the mesh?
> It's used at several places in the code when we need to perform nearest neighbor calculations.

Can in principle a list of all the neighbors of all the elements be
performed within Gmsh?

Thanks for your time!

--
jeremy
________________________________
 Imprima este mensaje sólo si es absolutamente necesario.
Para imprimir, en lo posible utilice el papel de ambos lados.
El Grupo Sancor Seguros se compromete con el cuidado del medioambiente.



************AVISO DE CONFIDENCIALIDAD************

El Grupo Sancor Seguros comunica que:

Este mensaje y todos los archivos adjuntos a el son para uso exclusivo del destinatario y pueden contener información confidencial o propietaria, cuya divulgación es sancionada por ley. Si usted recibió este mensaje erróneamente, por favor notifíquenos respondiendo al remitente, borre el mensaje original y destruya las copias (impresas o grabadas en cualquier medio magnético) que pueda haber realizado del mismo. Todas las opiniones contenidas en este mail son propias del autor del mensaje. La publicación, uso, copia o impresión total o parcial de este mensaje o documentos adjuntos queda prohibida.

Disposición DNDP 10-2008. El titular de los datos personales tiene la facultad de ejercer el derecho de acceso a los mismos en forma gratuita a intervalos no inferiores a seis meses, salvo que acredite un interés legítimo al efecto conforme lo establecido en el artículo 14, inciso 3 de la Ley 25.326. La DIRECCIÓN NACIONAL DE PROTECCIÓN DE DATOS PERSONALES, Organo de Control de la Ley 25.326, tiene la atribución de atender las denuncias y reclamos que se interpongan con relación al incumplimiento de las normas sobre la protección de datos personales.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: inner.pdf
Type: application/pdf
Size: 4453 bytes
Desc: inner.pdf
URL: <http://www.geuz.org/pipermail/gmsh/attachments/20150130/32816af5/attachment.pdf>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: normals.png
Type: image/png
Size: 94476 bytes
Desc: normals.png
URL: <http://www.geuz.org/pipermail/gmsh/attachments/20150130/32816af5/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: bc.pdf
Type: application/pdf
Size: 8853 bytes
Desc: bc.pdf
URL: <http://www.geuz.org/pipermail/gmsh/attachments/20150130/32816af5/attachment-0001.pdf>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: normals.geo
URL: <http://www.geuz.org/pipermail/gmsh/attachments/20150130/32816af5/attachment.geo>