Skip to main content
Jump to: navigation, search

Difference between revisions of "Netgen"

(File Format Specification)
Line 61: Line 61:
 
* orthobrick ( ax, ay, az; bx, by, bz )
 
* orthobrick ( ax, ay, az; bx, by, bz )
  
Polygons can be represented with : poly(ax, ay, az; bx, by, bz; cx, cy, cz; ... ;; a, d, c; b, c, e; ...) where a is the point (ax,ay,az) and the triplets after the ;; define triangles using the points a, b, c, .. and so on. The polygon must be closed.  
+
Polygons can be represented with : poly(x1, y1, z1; x2, y2, z2; x3, 3y, z3; ... ;; 1, 4, 3; 2, 3, 5; ...) where 1 is the point (x1, y1, z1) and the triplets after the ;; define triangles using the points 1, 2, 3, .. and so on. The polygon must be closed.
  
 
== Ease of Use ==
 
== Ease of Use ==
  
 
Netgen is simple and light to use, although there is little documentation on importing geometries from file formats other than STEP and IGES, both of which require Open Cascade to be installed. There are a lot of meshing options, and meshing exactly how a user wants requires some digging into the many toolbars and sub-menus Netgen has to offer. In all, however, Netgen is a useful tool and has strong potential to be a meshing tool that is launched from ICE.
 
Netgen is simple and light to use, although there is little documentation on importing geometries from file formats other than STEP and IGES, both of which require Open Cascade to be installed. There are a lot of meshing options, and meshing exactly how a user wants requires some digging into the many toolbars and sub-menus Netgen has to offer. In all, however, Netgen is a useful tool and has strong potential to be a meshing tool that is launched from ICE.

Revision as of 12:35, 2 June 2016

Attributes and Installation

Netgen is a mesh generator and geometry editor and is fairly easy to download and compile, but does have certain dependencies. Netgen will need a c++ compiler like g++ along with the Tcl/Tk libraries with Tix and the Togl library. There is a executable for Windows that takes care of dependencies (except for Visual C++ and Python). If downloading on Windows it is possible to see "***.dll is missing from you computer" error when opening Netgen. You must download the right dll file and install it in the system library files, likely in both the 64 bit and 32 bit system library folders. On Mac, Netgen comes as an application install package, just double click the download and open the compressed file. Ubuntu/Fedora users can use apt-get install or dnf install, installing the netgen-mesher libraries. Then launch Netgen using the bash command netgen-mesher.

Editor Features

The editor is simple to use, and has good visualization of the geometries and meshes. It will be mostly useful as a mesh generator tool.

File Types

Netgen can read in CSG or BRep Geometries and generate corresponding tetrahedral meshes. It can also read IGES and STEP formats when compiled with Open Cascade. Here is a more complete list of input file formats:

Extension Format
.iges IGES format *
.stp/.step STEP format *
.dlo 3ds MAX format
.nam Office name file
.msh Mesh format
.vol Volume image data
.frd Frequency response data
.inp Abaqus input File
.geo Geometry file (CSG) **
.stl STereoLithography(STL)

* Needs OpenCascade kernel to read ** Custom CSG file format specification.

File Format Specification

Netgen accepts Constructive Solid Geometry (CSG) files with its own specifications, using the extension .geo (standing for Geometry). This is not to be confused with the image specification file type or the geographical location data (both also having .geo as a file extension). The format is a ASCII file. From http://netgen-mesher.sourceforge.net/docs/ng4.pdf, Netgen uses a CSG file format as such:

Invalid language.

You need to specify a language like this: <source lang="html4strict">...</source>

Supported languages for syntax highlighting:

4cs, 6502acme, 6502kickass, 6502tasm, 68000devpac, abap, actionscript, actionscript3, ada, algol68, apache, applescript, apt_sources, arm, asm, asp, asymptote, autoconf, autohotkey, autoit, avisynth, awk, bascomavr, bash, basic4gl, bf, bibtex, blitzbasic, bnf, boo, c, c_loadrunner, c_mac, caddcl, cadlisp, cfdg, cfm, chaiscript, cil, clojure, cmake, cobol, coffeescript, cpp, cpp-qt, csharp, css, cuesheet, d, dcl, dcpu16, dcs, delphi, diff, div, dos, dot, e, ecmascript, eiffel, email, epc, erlang, euphoria, f1, falcon, fo, fortran, freebasic, freeswitch, fsharp, gambas, gdb, genero, genie, gettext, glsl, gml, gnuplot, go, groovy, gwbasic, haskell, haxe, hicest, hq9plus, html4strict, html5, icon, idl, ini, inno, intercal, io, j, java, java5, javascript, jquery, kixtart, klonec, klonecpp, latex, lb, ldif, lisp, llvm, locobasic, logtalk, lolcode, lotusformulas, lotusscript, lscript, lsl2, lua, m68k, magiksf, make, mapbasic, matlab, mirc, mmix, modula2, modula3, mpasm, mxml, mysql, nagios, netrexx, newlisp, nsis, oberon2, objc, objeck, ocaml, ocaml-brief, octave, oobas, oorexx, oracle11, oracle8, otj, oxygene, oz, parasail, parigp, pascal, pcre, per, perl, perl6, pf, php, php-brief, pic16, pike, pixelbender, pli, plsql, postgresql, povray, powerbuilder, powershell, proftpd, progress, prolog, properties, providex, purebasic, pycon, pys60, python, q, qbasic, rails, rebol, reg, rexx, robots, rpmspec, rsplus, ruby, sas, scala, scheme, scilab, sdlbasic, smalltalk, smarty, spark, sparql, sql, stonescript, systemverilog, tcl, teraterm, text, thinbasic, tsql, typoscript, unicon, upc, urbi, uscript, vala, vb, vbnet, vedit, verilog, vhdl, vim, visualfoxpro, visualprolog, whitespace, whois, winbatch, xbasic, xml, xorg_conf, xpp, yaml, z80, zxbasic


algebraic3d
solid cube = orthobrick ( ax, ay, az; bx, by, bz )
tlo cube;

The file must begin with "algebraic3d". Define solids using the "solid" keyword, and orthobrick is a primitive block, orthogonal to the primary axes, with one corner located at (ax, ay, az) and the opposite corner located at (bx, by, bz). The line "tlo cube" makes the solid cube a top level object- necessary for meshing. The available primitive types are: Plane with point and normal vector

  • plane (px, py, pz; nx, ny, nz)

Cylinder with points on central axis and radius

  • cylinder (ax, ay, az; bx, by, bz; r)

Sphere with central point and radius

  • sphere (cx, cy, cz; r)

Elliptical Cylinder with center point, larger vector, and smaller vector

  • ellipticcylinder (cx, cy, cz; vx, vy, vz; wx, wy, wz)

Ellipsoid with center point and three vectors describing the ellipsoid

  • ellipsoid (cx, cy, cz; ux, uy, uz; vx, vy, vz; wx, wy, wz)

Cone with center points along the central axis, with radius at each end point

  • cone (ax, ay, az; ra; bx, by, bz; rb)

Rectangular prism, orthogonal to coordinate axes, with smallest point and largest point.

  • orthobrick ( ax, ay, az; bx, by, bz )

Polygons can be represented with : poly(x1, y1, z1; x2, y2, z2; x3, 3y, z3; ... ;; 1, 4, 3; 2, 3, 5; ...) where 1 is the point (x1, y1, z1) and the triplets after the ;; define triangles using the points 1, 2, 3, .. and so on. The polygon must be closed.

Ease of Use

Netgen is simple and light to use, although there is little documentation on importing geometries from file formats other than STEP and IGES, both of which require Open Cascade to be installed. There are a lot of meshing options, and meshing exactly how a user wants requires some digging into the many toolbars and sub-menus Netgen has to offer. In all, however, Netgen is a useful tool and has strong potential to be a meshing tool that is launched from ICE.

Back to the top