Dear Sir,
I am a student at the University of Liège using gmsh for my thesis with
Professor D. Ruffoni. I use it to produce stl files for a 3D printer. As it is
a multi-material 3D printer, I need several stl files (one per material). I
tried to divide the part into several physical entities, but it did not work.
It works if I do not define physical entities and if I do it only part per part
but then the orientation of the elements is not good. Could you give me a hint
on how to solve this problem?
Thanks for your help,
--
Maxime Legrand
2nd master in biomedical engineering
University of Liège
// Parameters :
//=====================================================================================
LX = 100;
LY = 10;
Nparts = 10;
ep = 1;
nl=1;
lel = LY/NelementsY;
// Geometry
//=====================================================================================
idx=0;
For i In {1:Nparts+1}
Point(2*i-1) = {LX*(i-1)/Nparts,0,0,lel};
Point(2*i) = {LX*(i-1)/Nparts,LY,0,lel};
Line(i*10+1) = {2*i-1,2*i};
If (i > 1)
Line(i*10+3) = {2*i-3,2*i-1};
Line(10*i+2) = {2*i,2*i-2};
Line Loop (i) = {10*i+1,10*i+2,-(10*(i-1)+1),10*i+3};
Plane Surface(i) = {i};
SurfNb[idx] = i;
VolIdx[idx] = idx+1;
idx++;
EndIf
EndFor
AllVol [] = Extrude {0, 0, ep} {
Surface{SurfNb[]}; Layers{nl};
};
For i In{0:#VolIdx[]-1}
Physical Volume(i+1) = {VolIdx[i]};
EndFor
}
_______________________________________________
gmsh mailing list
[email protected]
http://www.geuz.org/mailman/listinfo/gmsh