> On 29 Nov 2019, at 11:58, Frederic Dubois <[email protected]> 
> wrote:
> 
> Hi,
> 
> You are right gmsh.fltk.run()is my problem ; I thought that once you close 
> the graphical interface it finishes the script ...

This is now fixed in the latest snapshot: you can run, quit, relaunch the GUI, 
etc. from the same script.

Much nicer... and intuitive indeed :-)

Christophe



> 
> Regards
> 
> ----- Mail original -----
>> De: "Christophe Geuzaine" <[email protected]>
>> À: "Frederic Dubois" <[email protected]>
>> Cc: "gmsh" <[email protected]>
>> Envoyé: Vendredi 29 Novembre 2019 09:39:38
>> Objet: Re: [Gmsh] question about python api
> 
>>> On 29 Nov 2019, at 09:06, Frederic Dubois <[email protected]>
>>> wrote:
>>> 
>>> Hi Christophe,
>>> 
>>> In fact I did things in the "complicated" way to be able to recover the 2D
>>> elements on the skin of the grains.
>>> 
>>> Using fragments, these elements are not created or saved even if I create a 
>>> 2D
>>> physical group (here "itz".
>>> 
>> 
>> Works fine here. (Maybe you left gmsh.fltk.run() in the script? Saving the 
>> mesh
>> happens afterwards...)
>> 
>> Christophe
>> 
>>> Using the "complicated" way, how can I remove the duplicated nodes (like 
>>> using
>>> coherence in .geo file) ?
>>> I tried to do this by fusing the two meshes but I am not confident in the
>>> result.
>>> 
>>> Regards
>>> 
>>> ----- Mail original -----
>>>> De: "Christophe Geuzaine" <[email protected]>
>>>> À: "Frederic Dubois" <[email protected]>
>>>> Cc: "gmsh" <[email protected]>
>>>> Envoyé: Jeudi 28 Novembre 2019 23:12:28
>>>> Objet: Re: [Gmsh] question about python api
>>> 
>>>>> On 28 Nov 2019, at 22:42, Frederic Dubois 
>>>>> <[email protected]>
>>>>> wrote:
>>>>> 
>>>>> Hi Christophe,
>>>>> 
>>>>> You are right, this is the best way.
>>>>> 
>>>>> Can you comment this ?
>>>>> f.remove(sphere1)
>>>>> f.remove(sphere2)
>>>> 
>>>> Fragment tries hard to keep intact the tags of those entities that have 
>>>> not been
>>>> modified, here the two spheres. So I remove these two from the list of 
>>>> returned
>>>> entities, which gives me the remaining (new) volume - the paste.
>>>> 
>>>> Christophe
>>>> 
>>>> 
>>>>> 
>>>>> Regards
>>>>> 
>>>>> ----- Mail original -----
>>>>>> De: "Christophe Geuzaine" <[email protected]>
>>>>>> À: "Frederic Dubois" <[email protected]>
>>>>>> Cc: "gmsh" <[email protected]>
>>>>>> Envoyé: Jeudi 28 Novembre 2019 21:31:12
>>>>>> Objet: Re: [Gmsh] question about python api
>>>>> 
>>>>>>> On 28 Nov 2019, at 20:06, Frederic Dubois 
>>>>>>> <[email protected]>
>>>>>>> wrote:
>>>>>>> 
>>>>>>> Dear all,
>>>>>>> 
>>>>>>> I am trying to mesh a composite material made of paste and grains.
>>>>>>> Since I have to do some Boolean operation on a 3D volume of composite I 
>>>>>>> tried to
>>>>>>> use the occ factory.
>>>>>>> At the end of the day I need a continuous mesh where paste elements of 
>>>>>>> the mesh
>>>>>>> belong to a paste physical group and grains elements belong to an other
>>>>>>> physical group.
>>>>>>> 
>>>>>>> In the attached script I first create a cylinder and two grains.
>>>>>>> Using a cut I was able to obtain a mesh with all the elements belonging 
>>>>>>> to the
>>>>>>> paste.
>>>>>>> Using a fuse I was able to obtain a mesh with all the elements 
>>>>>>> belonging to the
>>>>>>> grains.
>>>>>>> Unfortunately, it seems that the two meshes are separated.
>>>>>>> 
>>>>>>> I tried to fuse them to obtain a continuous mesh but I am not sure it 
>>>>>>> works fine
>>>>>>> and that it is the proper method.
>>>>>>> 
>>>>>>> Any advice ?
>>>>>> 
>>>>>> Simpler to use fragments:
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> Christophe
>>>>>> 
>>>>>> 
>>>>>>> 
>>>>>>> Regards
>>>>>>> 
>>>>>>> --
>>>>>>> Frédéric Dubois, PhD, Eng.
>>>>>>> ---
>>>>>>> Directeur adjoint du LMGC.
>>>>>>> Laboratoire de Mécanique et Génie Civil - CNRS/UM
>>>>>>> cc 048, 163 rue Auguste Broussonnet, 34090 Montpellier
>>>>>>> http://www.lmgc.univ-montp2.fr/~dubois
>>>>>>> Tel: 33/0 467144984
>>>>>>> Mobile: 33/0 635490843
>>>>>>> <composite.py>_______________________________________________
>>>>>>> gmsh mailing list
>>>>>>> [email protected]
>>>>>>> http://onelab.info/mailman/listinfo/gmsh
>>>>>> 
>>>>>> —
>>>>>> Prof. Christophe Geuzaine
>>>>>> University of Liege, Electrical Engineering and Computer Science
>>>>>> http://www.montefiore.ulg.ac.be/~geuzaine
>>>>> 
>>>>> --
>>>>> Frédéric Dubois, PhD, Eng.
>>>>> ---
>>>>> Directeur adjoint du LMGC.
>>>>> Laboratoire de Mécanique et Génie Civil - CNRS/UM
>>>>> cc 048, 163 rue Auguste Broussonnet, 34090 Montpellier
>>>>> http://www.lmgc.univ-montp2.fr/~dubois
>>>>> Tel: 33/0 467144984
>>>>> Mobile: 33/0 635490843
>>>> 
>>>> —
>>>> Prof. Christophe Geuzaine
>>>> University of Liege, Electrical Engineering and Computer Science
>>>> http://www.montefiore.ulg.ac.be/~geuzaine
>>> 
>>> --
>>> Frédéric Dubois, PhD, Eng.
>>> ---
>>> Directeur adjoint du LMGC.
>>> Laboratoire de Mécanique et Génie Civil - CNRS/UM
>>> cc 048, 163 rue Auguste Broussonnet, 34090 Montpellier
>>> http://www.lmgc.univ-montp2.fr/~dubois
>>> Tel: 33/0 467144984
>>> Mobile: 33/0 635490843
>>> <composite.py><composite_simpler.py>
>> 
>> —
>> Prof. Christophe Geuzaine
>> University of Liege, Electrical Engineering and Computer Science
>> http://www.montefiore.ulg.ac.be/~geuzaine
> 
> -- 
> Frédéric Dubois, PhD, Eng.
> ---
> Directeur adjoint du LMGC.
> Laboratoire de Mécanique et Génie Civil - CNRS/UM
> cc 048, 163 rue Auguste Broussonnet, 34090 Montpellier
> http://www.lmgc.univ-montp2.fr/~dubois
> Tel: 33/0 467144984
> Mobile: 33/0 635490843
> 
> _______________________________________________
> gmsh mailing list
> [email protected]
> http://onelab.info/mailman/listinfo/gmsh

— 
Prof. Christophe Geuzaine
University of Liege, Electrical Engineering and Computer Science 
http://www.montefiore.ulg.ac.be/~geuzaine




_______________________________________________
gmsh mailing list
[email protected]
http://onelab.info/mailman/listinfo/gmsh

Reply via email to