[Gmsh] BooleanDifference problem

Sabrina Zacarias szacarias at ikp.tu-darmstadt.de
Wed Oct 30 17:34:54 CET 2019


Hello Gmsh team, 

I am getting a syntax error when using the boolean difference. This did not happen before, so I don’t know what the problem is. Here is the code:

Include "gf_cylinder.geo";


// Create outer cylinder. first set parameters and then return values.
x0 = 0; y0 = 0; z0 = 0; lc = 1; R = 200;  L = 400;
vol = -1; s1 = -1; s2 = -1; s3 = -1; s4 = -1; s5 = -1; s6 = -1;
Call gf_cylinder;

vol_env = vol;
Printf("vol_env = %g",vol);

// Create the main structure, the top and bottom of which will be assigned voltages.
x0 = 0; y0 = 0; z0 = 0; lc = 1; R = 110; L = 300;
vol = -1; s1 = -1; s2 = -1; s3 = -1; s4 = -1; s5 = -1; s6 = -1;
Call gf_cylinder;

// Save the surface IDs for the top and bottom of the inner box and volume.
s_top_plate = s1;
s_bottom_plate = s2;
vol_tpc = vol;

vol_tot = newv;
BooleanDifference(vol_tot) = { Volume{vol_env};Delete;}{vol_tpc};
And this is the output:

Info    : Done reading '/Users/home/Desktop/gf_cylinder.geo'
vol_env = 1
vol_tpc = 2
Error   : '/Users/home/Desktop/main_cylinder.geo', line 38 : syntax error (vol_tpc)
Info    : Done reading '/Users/home/Desktop/main_cylinder.geo'

Can somebody please help?

Cheers,

Sabrina
-- 
Sabrina Zacarias
Institut für Kernphysik
Technische Universität Darmstadt
S2|14 / office 319
Schlossgartenstr. 9

64289 Darmstadt

Office: +49 6151 16 23589

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://onelab.info/pipermail/gmsh/attachments/20191030/b8d16b84/attachment.html>


More information about the gmsh mailing list