[Gmsh] Rotate all
Zenker, Dr. Matthias
Matthias.Zenker at erbe-med.com
Wed Oct 26 17:17:56 CEST 2011
It works, thank you!
Best regards,
Matthias
________________________________
Von: Ruth V. Sabariego [mailto:r.sabariego at ulg.ac.be]
Gesendet: Mittwoch, 26. Oktober 2011 16:46
An: Zenker, Dr. Matthias
Cc: gmsh
Betreff: Re: [Gmsh] Rotate all
You can get arrays with all the point, line, surface or volume numbers :
allPoints[] = Point "*" ;
allLines[] = Line "*" ;
allSurfaces[] = Surface "*";
allVolumes[] = Volume "*";
and then rotate then (possibly with duplication):
Rotate {{0, 1, 0}, {0, 0, 0}, Pi/2} { Point{ allPoints[] } ; }
Rotate {{0, 1, 0}, {0, 0, 0}, Pi/2} { Duplicata { Point{ allPoints[] } ; } }
It is possible to do the operation directly on volumes or surfaces.
Rotate {{0, 1, 0}, {0, 0, 0}, Pi/2} { Surface{ allSurfaces[] } ; }
Rotate {{0, 1, 0}, {0, 0, 0}, Pi/2} { Duplicata { Surface{ allSurfaces[] } ; } }
Pay attention to centers of circles or spheres, though...
Regards,
Ruth
--
Dr. Ir. Ruth V. Sabariego
University of Liege, Electrical Engineering & Computer Science,
Applied & Computational Electromagnetics (ACE),
phone: +32-4-3663737 - fax: +32-4-3662910 - http://ace.montefiore.ulg.ac.be/
On 26 Oct 2011, at 16:18, Zenker, Dr. Matthias wrote:
Hi,
I have a simple question: I want to rotate an entire model (STEP or geo). It seems to me that I have to delete all surfaces and volumes, rotate the points, and redefine everything. Is there a more elegant way to do it? I have tried with
Rotate {{0, 1, 0}, {0, 0, 0}, Pi/2} {"*";}
but I get a syntax error.
(gmsh 2.5.1, Windoze XP)
Any hint?
Thank you,
Matthias
_____________________________________________________________________
ERBE Elektromedizin GmbH
Firmensitz: 72072 Tuebingen
Geschaeftsfuehrer: Christian O. Erbe, Reiner Thede
Registergericht: Stuttgart HRB 380137
_______________________________________________
gmsh mailing list
gmsh at geuz.org<mailto:gmsh at geuz.org>
http://www.geuz.org/mailman/listinfo/gmsh
_____________________________________________________________________
ERBE Elektromedizin GmbH
Firmensitz: 72072 Tuebingen
Geschaeftsfuehrer: Christian O. Erbe, Reiner Thede
Registergericht: Stuttgart HRB 380137
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.geuz.org/pipermail/gmsh/attachments/20111026/fd696cb9/attachment.html>