[Gmsh] error: Cannot bind multiple faces to single tag

Christophe Geuzaine cgeuzaine at uliege.be
Mon Feb 12 21:38:29 CET 2018



> On 12 Feb 2018, at 20:16, Sathyanarayan Rao <sathyanarayan.rao at uclouvain.be> wrote:
> 
> Dear Gmsh team,
> 
> I am following the same syntax as https://gitlab.onelab.info/gmsh/gmsh/blob/master/demos/boolean/boolean.geo <https://gitlab.onelab.info/gmsh/gmsh/blob/master/demos/boolean/boolean.geo>
> 
> for generating boolean unioun of surfaces. But however it gives me error as in the subject line. Can you please
>  help me to correctly combine surfaces 1:3 into one surface by a boolean unioun ?
> 

You can only use the declarative syntax

  BooleanUnion(7) = { Surface {1}; Delete; }{ Surface {2:3}; Delete; };

If the operation results in the creation of a single shape. If not, use

 BooleanUnion { Surface {1}; Delete; }{ Surface {2:3}; Delete; }

or

 out() = BooleanUnion { Surface {1}; Delete; }{ Surface {2:3}; Delete; };

If you need the result.


> SetFactory("OpenCASCADE");
> 
> // mesh size description
> 
> cl_1   =  5;
> cl_2   =  0.01;
> 
> Geometry.NumSubEdges = 100; // nicer display of curve
> 
> var1 = 0.02; 
> var2 = 0.1;
> 
> 
> // Define Segment coordinates
> 
> X1 ={0,0.000811,0.001097,0.001233,0.00129,0.001325,0.001335,0.001343,0.001346,0.001347,0.001348,0.001348,0.001349,0.001349,0.001349,0.001349,0.001349,0.001349,0.001349,0.0013487};
> Y1 ={0,-2.4,-4,-5.6,-7.2,-8.8,-10.4,-12,-13.6,-15.2,-16.8,-18.4,-20,-21.6,-23.2,-24.8,-26.4,-28,-28.96,-29.118};
> 
> Point(newp)  =    {X1[1], Y1[1], 0, cl_2};
> 
> // Line 1
> Extrude {var1, var1, 0} {
>   Point{newp-1}; 
> }
> 
> // Line 2
> Extrude {var2, var2, 0} {
>   Point{newp-1}; 
> }
> 
> // Line 3
> Extrude {var1, var1, 0} {
>   Point{newp-1}; 
> }
> 
> 
> // Define 1 segment
> 
> l0 = newl;
> l  = l0;
> nR = #X1[];
> p0  =  newp;
> p   =  p0;
> For i In {0:nR-1}
> Point(newp)  =    {X1[i], Y1[i], 0, cl_2};
> EndFor
> p2  =  newp-1;
> Spline(l0)   =  {p:p2};
> 
> Wire(l0) = {l0};
> Extrude { Line{l0-3}; } Using Wire {l0}   //left
> Extrude { Line{l0-2}; } Using Wire {l0}   // center
> Extrude { Line{l0-1}; } Using Wire {l0}   // right
> 
> BooleanUnion(7) = { Surface {1}; Delete; }{ Surface {2:3}; Delete; };
> 
> 
> 
> 
> 
> Best Regards,
> 
> Sathyanarayan Rao, PhD student
> Earth and Life Institute/Environmental Sciences (ELI-e)
> Université catholique de Louvain
> c.037, Croix du Sud 2, Louvain-la-Neuve, Belgium
> Phone: 010473827 ( intercom 73827)
> _______________________________________________
> gmsh mailing list
> gmsh at onelab.info <mailto:gmsh at onelab.info>
> http://onelab.info/mailman/listinfo/gmsh <http://onelab.info/mailman/listinfo/gmsh>
— 
Prof. Christophe Geuzaine
University of Liege, Electrical Engineering and Computer Science 
http://www.montefiore.ulg.ac.be/~geuzaine

Free software: http://gmsh.info | http://getdp.info | http://onelab.info

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://onelab.info/pipermail/gmsh/attachments/20180212/37fc1204/attachment-0001.html>


More information about the gmsh mailing list