├── netgen-6.1-src ├── NEWS ├── TODO ├── ChangeLog ├── doc │ ├── Makefile.am │ ├── CMakeLists.txt │ ├── ng4.pdf │ └── pictures │ │ ├── menufile.jpg │ │ ├── menumesh.jpg │ │ ├── menuview.jpg │ │ ├── menu_file.jpg │ │ ├── menu_help.jpg │ │ ├── menu_mesh.jpg │ │ ├── menu_solve.jpg │ │ ├── menu_view.jpg │ │ ├── screenshot.jpg │ │ ├── clippingplane.jpg │ │ ├── main_window.jpg │ │ ├── menu_geometry.jpg │ │ ├── menu_special.jpg │ │ ├── menugeometry.jpg │ │ ├── solutiondata.jpg │ │ ├── MeshingOptions1.jpg │ │ ├── menu_refinement.jpg │ │ ├── menurefinement.jpg │ │ ├── meshingoptions_1.jpg │ │ ├── meshingoptions_2.jpg │ │ ├── meshingoptions_3.jpg │ │ ├── meshingoptions_4.jpg │ │ ├── meshingoptions_5.jpg │ │ ├── meshingoptions_6.jpg │ │ ├── topologyexplorer.jpg │ │ ├── viewingoptions_1.jpg │ │ ├── viewingoptions_2.jpg │ │ ├── viewingoptions_3.jpg │ │ ├── viewingoptions_4.jpg │ │ ├── viewingoptions_5.jpg │ │ └── viewingoptions_6.jpg ├── libsrc │ ├── include │ │ ├── csg.hpp │ │ ├── gprim.hpp │ │ ├── opti.hpp │ │ ├── linalg.hpp │ │ ├── myadt.hpp │ │ ├── occgeom.hpp │ │ ├── meshing.hpp │ │ ├── parallel.hpp │ │ ├── stlgeom.hpp │ │ ├── visual.hpp │ │ ├── geometry2d.hpp │ │ ├── acisgeom.hpp │ │ ├── CMakeLists.txt │ │ ├── incvis.hpp │ │ ├── inctcl.hpp │ │ ├── Makefile.am │ │ ├── incopengl.hpp │ │ ├── parallelinterface.hpp │ │ ├── mystdlib.h │ │ └── mydefs.hpp │ ├── linalg │ │ ├── opti.hpp │ │ ├── CMakeLists.txt │ │ ├── Makefile.am │ │ ├── linalg.hpp │ │ └── polynomial.hpp │ ├── Makefile.am │ ├── csg │ │ ├── manifold.cpp │ │ ├── geoml.hpp │ │ ├── manifold.hpp │ │ ├── vscsg.hpp │ │ ├── CMakeLists.txt │ │ ├── Makefile.am │ │ ├── csg.hpp │ │ ├── triapprox.cpp │ │ ├── curve2d.hpp │ │ ├── curve2d.cpp │ │ └── gencyl.hpp │ ├── occ │ │ ├── Partition_Loop2d.ixx │ │ ├── Partition_Loop3d.ixx │ │ ├── CMakeLists.txt │ │ ├── Partition_Loop2d.jxx │ │ ├── Partition_Loop3d.jxx │ │ ├── vsocc.hpp │ │ ├── Makefile.am │ │ ├── Partition_Loop.ixx │ │ ├── Partition_Inter3d.ixx │ │ ├── Partition_Spliter.ixx │ │ ├── Partition_Inter2d.ixx │ │ ├── Partition_Spliter.jxx │ │ ├── Partition_Loop.jxx │ │ ├── Partition_Inter2d.jxx │ │ └── Partition_Inter3d.jxx │ ├── gprim │ │ ├── CMakeLists.txt │ │ ├── Makefile.am │ │ ├── gprim.hpp │ │ └── splinegeometry.hpp │ ├── meshing │ │ ├── specials.hpp │ │ ├── boundarylayer.hpp │ │ ├── validate.hpp │ │ ├── meshfunc.hpp │ │ ├── clusters.hpp │ │ ├── meshing.hpp │ │ ├── CMakeLists.txt │ │ ├── meshfunc2d.cpp │ │ ├── basegeom.cpp │ │ ├── global.hpp │ │ ├── Makefile.am │ │ └── basegeom.hpp │ ├── CMakeLists.txt │ ├── visualization │ │ ├── visual_dummy.cpp │ │ ├── Makefile.am │ │ ├── CMakeLists.txt │ │ ├── visual.hpp │ │ └── meshdoc.hpp │ ├── general │ │ ├── CMakeLists.txt │ │ ├── Makefile.am │ │ ├── ngexception.cpp │ │ ├── parthreads.cpp │ │ ├── ngexception.hpp │ │ ├── autoptr.hpp │ │ ├── seti.hpp │ │ ├── sort.hpp │ │ ├── symbolta.cpp │ │ ├── seti.cpp │ │ ├── myadt.hpp │ │ ├── optmem.hpp │ │ ├── mpi_interface.cpp │ │ ├── spbita2d.hpp │ │ ├── ngpython.hpp │ │ ├── profiler.hpp │ │ └── array.cpp │ ├── geom2d │ │ ├── Makefile.am │ │ ├── CMakeLists.txt │ │ ├── vsgeom2d.hpp │ │ ├── geom2dpkg.cpp │ │ └── geom2dmesh.hpp │ ├── stlgeom │ │ ├── CMakeLists.txt │ │ ├── Makefile.am │ │ └── vsstl.hpp │ └── interface │ │ ├── Makefile.am │ │ └── CMakeLists.txt ├── python │ ├── meshing.py │ ├── Makefile.am │ ├── shaft.vol.gz │ ├── CMakeLists.txt │ ├── __init__.py │ ├── gengeom.py │ ├── csg.py │ └── gengeom_curve.py ├── ng │ ├── onetcl.cpp │ ├── Togl-1.7 │ │ ├── ben.rgb │ │ ├── tree2.rgba │ │ ├── pkgIndex.tcl.in │ │ ├── togl_ws.h.in │ │ ├── aclocal.m4 │ │ ├── image.h │ │ ├── TODO │ │ ├── tclconfig │ │ │ └── README.txt │ │ ├── tkMacOSX.h │ │ ├── README.stubs │ │ ├── overlay.tcl │ │ ├── index.tcl │ │ ├── LICENSE │ │ └── .indent.pro │ ├── Togl2.1 │ │ ├── ben.rgb │ │ ├── tree2.rgba │ │ ├── doc │ │ │ ├── README.txt │ │ │ └── header.js │ │ ├── pkgIndex.tcl.in │ │ ├── togl_ws.h.in │ │ ├── Xmu │ │ │ └── README.togl │ │ ├── image.h │ │ ├── overlay.tcl │ │ ├── README.stubs │ │ ├── toglStubLib.c │ │ ├── index.tcl │ │ ├── LICENSE │ │ ├── toglProcAddr.c │ │ └── CMakeLists.txt │ ├── parallelfunc.hpp │ ├── acisgeom.tcl │ ├── netgen.ocf │ ├── stlgeom.tcl │ ├── netgenpy.cpp │ ├── parameters.tcl │ └── CMakeLists.txt ├── AUTHORS ├── config.h.cmake ├── netgen.icns ├── Makefile.cvs ├── windows │ ├── netgen.ico │ ├── Netgen_Installer │ │ ├── LGPL_Licenses │ │ │ ├── Makefile.am │ │ │ ├── LGPL_French.txt │ │ │ └── LGPL_German.txt │ │ ├── netgen_installer.nsi │ │ ├── Makefile.am │ │ └── netgen_installer.dat │ ├── CMakeLists.txt │ ├── Makefile.am │ ├── resource.h │ └── nglib.sln ├── py_tutorials │ ├── Makefile.am │ ├── CMakeLists.txt │ ├── mesh.py │ ├── cube.geo │ ├── exportNeutral.py │ ├── opengl_thread.py │ └── merge.py ├── tutorials │ ├── sphere.geo │ ├── torus.geo │ ├── ellipsoid.geo │ ├── ortho.geo │ ├── shell.geo │ ├── ellipticcyl.geo │ ├── cylinder.geo │ ├── cylsphere.geo │ ├── revolution.geo │ ├── cone.geo │ ├── cube.geo │ ├── twocyl.geo │ ├── sculpture.geo │ ├── boundarycondition.geo │ ├── cubemsphere.geo │ ├── cubemcyl.geo │ ├── sphereincube.geo │ ├── twobricks.geo │ ├── twocubes.geo │ ├── lshape3d.geo │ ├── test.dem │ ├── manyholes.geo │ ├── cubeandspheres.geo │ ├── manyholes2.geo │ ├── circle_on_cube.geo │ ├── Makefile.am │ ├── boxcyl.geo │ ├── fichera.geo │ ├── CMakeLists.txt │ ├── period.geo │ ├── matrix.geo │ ├── square.in2d │ ├── cubeandring.geo │ ├── squarecircle.in2d │ ├── squarehole.in2d │ ├── extrusion.geo │ ├── lense.in2d │ └── trafo.geo ├── tests │ ├── build.sh │ ├── docker_15.10 │ └── docker_16.04 ├── .gitmodules ├── Makefile.am ├── nglib │ ├── netgen.py │ ├── cube.surf │ └── Makefile.am ├── README.md ├── cmake_modules │ ├── mic.cmake │ ├── cmake_uninstall.cmake.in │ └── netgen_fixup.cmake └── rules │ └── makerlsfile.cpp ├── netgen-6.1 ├── fix-element2d.patch ├── build.sh ├── bld.bat ├── remove_warnings.patch ├── fix_mystdlib_h.patch ├── meta.yaml ├── fix_occvis.patch └── netgen-patch.patch ├── netgen-6.2-dev ├── build.sh ├── bld.bat ├── remove_warnings.patch ├── fix_mystdlib_h.patch ├── meta.yaml ├── fix_occvis.patch └── netgen-patch.patch └── README.md /netgen-6.1-src/NEWS: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /netgen-6.1-src/TODO: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /netgen-6.1-src/ChangeLog: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /netgen-6.1-src/doc/Makefile.am: -------------------------------------------------------------------------------- 1 | dist_doc_DATA = ng4.pdf 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/csg.hpp: -------------------------------------------------------------------------------- 1 | #include "../csg/csg.hpp" 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/python/meshing.py: -------------------------------------------------------------------------------- 1 | from libngpy._meshing import * 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/gprim.hpp: -------------------------------------------------------------------------------- 1 | #include "../gprim/gprim.hpp" 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/opti.hpp: -------------------------------------------------------------------------------- 1 | #include "../linalg/opti.hpp" 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/onetcl.cpp: -------------------------------------------------------------------------------- 1 | const char * ngscript[] = { " hi " }; 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/AUTHORS: -------------------------------------------------------------------------------- 1 | Joachim Schoeberl 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/linalg.hpp: -------------------------------------------------------------------------------- 1 | #include "../linalg/linalg.hpp" 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/myadt.hpp: -------------------------------------------------------------------------------- 1 | #include <../general/myadt.hpp> 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/occgeom.hpp: -------------------------------------------------------------------------------- 1 | #include "../occ/occgeom.hpp" 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/meshing.hpp: -------------------------------------------------------------------------------- 1 | #include <../meshing/meshing.hpp> 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/parallel.hpp: -------------------------------------------------------------------------------- 1 | #include "../parallel/parallel.hpp" 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/stlgeom.hpp: -------------------------------------------------------------------------------- 1 | #include <../stlgeom/stlgeom.hpp> 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/visual.hpp: -------------------------------------------------------------------------------- 1 | #include "../visualization/visual.hpp" 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/geometry2d.hpp: -------------------------------------------------------------------------------- 1 | #include "../geom2d/geometry2d.hpp" 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/doc/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | INSTALL(FILES ng4.pdf DESTINATION doc COMPONENT netgen_doc) 2 | -------------------------------------------------------------------------------- /netgen-6.1-src/python/Makefile.am: -------------------------------------------------------------------------------- 1 | python_PYTHON = __init__.py meshing.py csg.py geom2d.py 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /netgen-6.1-src/config.h.cmake: -------------------------------------------------------------------------------- 1 | #cmakedefine HAVE_DLFCN_H 1 2 | #define PACKAGE_VERSION "${NETGEN_VERSION}" 3 | -------------------------------------------------------------------------------- /netgen-6.1-src/doc/ng4.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/ng4.pdf -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/acisgeom.hpp: -------------------------------------------------------------------------------- 1 | #ifdef ACIS 2 | #include "../acisgeom/acisgeom.hpp" 3 | #endif 4 | -------------------------------------------------------------------------------- /netgen-6.1-src/netgen.icns: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/netgen.icns -------------------------------------------------------------------------------- /netgen-6.1-src/Makefile.cvs: -------------------------------------------------------------------------------- 1 | default: all 2 | 3 | all: 4 | aclocal 5 | autoheader 6 | automake 7 | autoconf 8 | 9 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/ben.rgb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/ng/Togl-1.7/ben.rgb -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/ben.rgb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/ng/Togl2.1/ben.rgb -------------------------------------------------------------------------------- /netgen-6.1-src/python/shaft.vol.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/python/shaft.vol.gz -------------------------------------------------------------------------------- /netgen-6.1-src/windows/netgen.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/windows/netgen.ico -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/linalg/opti.hpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/libsrc/linalg/opti.hpp -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/tree2.rgba: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/ng/Togl-1.7/tree2.rgba -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/tree2.rgba: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/ng/Togl2.1/tree2.rgba -------------------------------------------------------------------------------- /netgen-6.1-src/py_tutorials/Makefile.am: -------------------------------------------------------------------------------- 1 | METASOURCES = AUTO 2 | 3 | dist_pkgdata_DATA = shaft.geo mesh.py exportNeutral.py 4 | 5 | -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menufile.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menufile.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menumesh.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menumesh.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menuview.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menuview.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menu_file.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menu_file.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menu_help.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menu_help.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menu_mesh.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menu_mesh.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menu_solve.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menu_solve.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menu_view.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menu_view.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/screenshot.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/screenshot.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/clippingplane.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/clippingplane.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/main_window.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/main_window.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menu_geometry.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menu_geometry.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menu_special.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menu_special.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menugeometry.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menugeometry.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/solutiondata.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/solutiondata.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | install(FILES nginterface.h nginterface_v2.hpp DESTINATION include COMPONENT netgen_devel) 2 | 3 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/sphere.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | 3 | solid main = sphere (0, 0, 0; 1); 4 | 5 | tlo main; 6 | point (0, 0, 0); 7 | 8 | 9 | -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/MeshingOptions1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/MeshingOptions1.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menu_refinement.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menu_refinement.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/menurefinement.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/menurefinement.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/torus.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## a torus 3 | # 4 | algebraic3d 5 | 6 | solid tor = torus ( 0, 0, 0; 1, 0, 0; 2 ; 1 ); 7 | 8 | tlo tor; 9 | -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/meshingoptions_1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/meshingoptions_1.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/meshingoptions_2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/meshingoptions_2.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/meshingoptions_3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/meshingoptions_3.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/meshingoptions_4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/meshingoptions_4.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/meshingoptions_5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/meshingoptions_5.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/meshingoptions_6.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/meshingoptions_6.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/topologyexplorer.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/topologyexplorer.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/viewingoptions_1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/viewingoptions_1.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/viewingoptions_2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/viewingoptions_2.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/viewingoptions_3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/viewingoptions_3.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/viewingoptions_4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/viewingoptions_4.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/viewingoptions_5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/viewingoptions_5.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/doc/pictures/viewingoptions_6.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/doc/pictures/viewingoptions_6.jpg -------------------------------------------------------------------------------- /netgen-6.1-src/tests/build.sh: -------------------------------------------------------------------------------- 1 | cd 2 | mkdir -p build/netgen 3 | cd build/netgen 4 | cmake ../../src/netgen -DUSE_CCACHE=ON 5 | make -j12 6 | make install 7 | -------------------------------------------------------------------------------- /netgen-6.1-src/windows/Netgen_Installer/LGPL_Licenses/Makefile.am: -------------------------------------------------------------------------------- 1 | dist_noinst_DATA = LGPL_English.txt \ 2 | LGPL_French.txt LGPL_German.txt 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /netgen-6.1-src/.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "external_dependencies/pybind11"] 2 | path = external_dependencies/pybind11 3 | url = https://github.com/pybind/pybind11.git 4 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/incvis.hpp: -------------------------------------------------------------------------------- 1 | // libraries for User interface: 2 | 3 | nicht mehr verwendet 4 | 5 | #include "inctcl.hpp" 6 | #include "incopengl.hpp" 7 | -------------------------------------------------------------------------------- /netgen-6.1-src/windows/Netgen_Installer/netgen_installer.nsi: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/windows/Netgen_Installer/netgen_installer.nsi -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CPPFLAGS = 2 | 3 | METASOURCES = AUTO 4 | 5 | SUBDIRS = general gprim linalg include meshing visualization csg geom2d occ stlgeom interface 6 | -------------------------------------------------------------------------------- /netgen-6.1-src/windows/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # dist_noinst_DATA = netgen.sln netgen.vcproj \ 2 | # postBuild_netgen.bat nglib.sln nglib.vcproj \ 3 | # postBuild_nglib.bat netgen.ico netgen.rc 4 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/pkgIndex.tcl.in: -------------------------------------------------------------------------------- 1 | # 2 | # Tcl package index file 3 | # 4 | package ifneeded @PACKAGE_NAME@ @PACKAGE_VERSION@ \ 5 | [list load [file join $dir @PKG_LIB_FILE@]] 6 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/doc/README.txt: -------------------------------------------------------------------------------- 1 | This directory contains the documentation of Togl, the Tk OpenGL widget. 2 | The documentation also doubles as the contents of the Togl home page. 3 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/pkgIndex.tcl.in: -------------------------------------------------------------------------------- 1 | # 2 | # Tcl package index file 3 | # 4 | package ifneeded @PACKAGE_NAME@ @PACKAGE_VERSION@ \ 5 | [list load [file join $dir @PKG_LIB_FILE@]] 6 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/ellipsoid.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## An elliptic cylinder 3 | # 4 | algebraic3d 5 | 6 | solid test = ellipsoid (0, 0, 0; 2, 0, 0; 0, 1, 0; 0, 0, 1) -maxh=0.5; 7 | 8 | tlo test; 9 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/togl_ws.h.in: -------------------------------------------------------------------------------- 1 | #ifndef TOGL_WS_H 2 | # define TOGL_WS_H 3 | 4 | /* define windowing system togl is compiled with */ 5 | # define @TOGL_WINDOWINGSYSTEM@ 6 | 7 | #endif 8 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/togl_ws.h.in: -------------------------------------------------------------------------------- 1 | #ifndef TOGL_WS_H 2 | # define TOGL_WS_H 3 | 4 | /* define windowing system togl is compiled with */ 5 | # define @TOGL_WINDOWINGSYSTEM@ 6 | 7 | #endif 8 | -------------------------------------------------------------------------------- /netgen-6.1-src/windows/Netgen_Installer/LGPL_Licenses/LGPL_French.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/windows/Netgen_Installer/LGPL_Licenses/LGPL_French.txt -------------------------------------------------------------------------------- /netgen-6.1-src/windows/Netgen_Installer/LGPL_Licenses/LGPL_German.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tpaviot/netgen-conda/master/netgen-6.1-src/windows/Netgen_Installer/LGPL_Licenses/LGPL_German.txt -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/inctcl.hpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #if TK_MAJOR_VERSION==8 && TK_MINOR_VERSION>=4 5 | #define tcl_const const 6 | #else 7 | #define tcl_const 8 | #endif 9 | -------------------------------------------------------------------------------- /netgen-6.1-src/python/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | install(FILES __init__.py meshing.py csg.py geom2d.py 2 | DESTINATION ${PYTHON_PACKAGES_INSTALL_DIR}/netgen 3 | COMPONENT netgen 4 | ) 5 | 6 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/ortho.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## A cube 3 | # 4 | algebraic3d 5 | 6 | # cube consisting of 6 planes: 7 | 8 | solid cube = orthobrick (0, 0, 0; 1, 1, 1); 9 | 10 | tlo cube; 11 | 12 | -------------------------------------------------------------------------------- /netgen-6.1-src/py_tutorials/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | install( FILES 2 | shaft.geo mesh.py exportNeutral.py 3 | DESTINATION share/netgen/py_tutorials 4 | COMPONENT netgen_tutorial 5 | ) 6 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/manifold.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | namespace netgen 4 | { 5 | Manifold :: Manifold () 6 | { 7 | ; 8 | } 9 | 10 | Manifold :: ~Manifold () 11 | { 12 | ; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /netgen-6.1-src/windows/Makefile.am: -------------------------------------------------------------------------------- 1 | dist_noinst_DATA = netgen.sln netgen.vcxproj netgenlib.vcxproj netgenpy.vcxproj resource.h \ 2 | postBuild_netgen.bat nglib.sln nglib.vcxproj \ 3 | postBuild_nglib.bat netgen.ico netgen.rc 4 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/aclocal.m4: -------------------------------------------------------------------------------- 1 | # 2 | # Include the TEA standard macro set 3 | # 4 | 5 | builtin(include,tclconfig/tcl.m4) 6 | 7 | # 8 | # Add here whatever m4 macros you want to define for your package 9 | # 10 | -------------------------------------------------------------------------------- /netgen-6.1-src/windows/Netgen_Installer/Makefile.am: -------------------------------------------------------------------------------- 1 | dist_noinst_DATA = netgen_installer.nsi netgen_installer.dat \ 2 | Netgen_Installer_All.bat Netgen_Installer_Win32.bat \ 3 | Netgen_Installer_x64.bat README!.TXT 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/linalg/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_library( la OBJECT 2 | densemat.cpp polynomial.cpp bfgs.cpp linopt.cpp linsearch.cpp 3 | ) 4 | 5 | set_target_properties(la PROPERTIES POSITION_INDEPENDENT_CODE ON ) 6 | -------------------------------------------------------------------------------- /netgen-6.1-src/Makefile.am: -------------------------------------------------------------------------------- 1 | ACLOCAL_AMFLAGS = -I m4 2 | 3 | METASOURCES = AUTO 4 | 5 | SUBDIRS = libsrc ng tutorials python py_tutorials doc windows nglib 6 | # nglib 7 | # TESTS = ng/netgen -batchmode 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/Xmu/README.togl: -------------------------------------------------------------------------------- 1 | The source code in this directory is a subset of the Jun 12, 1995 X11R6 Xmu 2 | library that is needed for the Togl widget. The Xmu library is no longer 3 | installed by default on many Linux systems. 4 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/shell.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | 3 | solid main = sphere (0, 0, 0; 1) 4 | and not sphere (0, 0, 0; 0.98); 5 | # or orthobrick (-0.4, -0.4, -0.4; 0.4, 0.4, 0.4); 6 | 7 | tlo main -maxh=0.02; 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/ellipticcyl.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## An elliptic cylinder 3 | # 4 | algebraic3d 5 | 6 | solid cutcone = ellipticcylinder ( 0, 0, 0; 1, 0, 0; 0, 0.5, 0) 7 | and plane (0, 0, 0; 0, 0, -1) 8 | and plane (0, 0, 1; 0, 0, 1); 9 | 10 | tlo cutcone; 11 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/cylinder.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## a cylinder 3 | # 4 | algebraic3d 5 | 6 | # cut cylinder by planes: 7 | 8 | solid fincyl = cylinder ( 3, 0, 0; -1, 0, 0; 0.5 ) 9 | and plane (0, 0, 0; -1, 0, 0) 10 | and plane (2, 0, 0; 1, 0, 0); 11 | 12 | tlo fincyl; 13 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Loop2d.ixx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 CEA/DEN, EDF R&D 4 | // 5 | // 6 | // 7 | // File : Partition_Loop2d.ixx 8 | // Module : GEOM 9 | 10 | #include "Partition_Loop2d.jxx" 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Loop3d.ixx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 CEA/DEN, EDF R&D 4 | // 5 | // 6 | // 7 | // File : Partition_Loop3d.ixx 8 | // Module : GEOM 9 | 10 | #include "Partition_Loop3d.jxx" 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /netgen-6.1-src/tests/docker_15.10: -------------------------------------------------------------------------------- 1 | FROM ubuntu:15.10 2 | MAINTAINER Matthias Hochsteger 3 | RUN apt-get update && apt-get -y install python3 libpython3-dev libxmu-dev libboost-python-dev tk-dev tcl-dev cmake git g++ libglu1-mesa-dev ccache 4 | ADD . /root/src/netgen 5 | -------------------------------------------------------------------------------- /netgen-6.1-src/tests/docker_16.04: -------------------------------------------------------------------------------- 1 | FROM ubuntu:16.04 2 | MAINTAINER Matthias Hochsteger 3 | RUN apt-get update && apt-get -y install python3 libpython3-dev libxmu-dev libboost-python-dev tk-dev tcl-dev cmake git g++ libglu1-mesa-dev ccache 4 | ADD . /root/src/netgen 5 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/cylsphere.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## Cylinder and Spehre 3 | # 4 | algebraic3d 5 | solid cyl = cylinder ( 3, 0, 0; -3, 0, 0; 0.5 ) 6 | and plane (-2, 0, 0; -1, 0, 0) 7 | and plane (2, 0, 0; 1, 0, 0); 8 | solid sp = sphere (0, 0, 0; 1); 9 | 10 | solid main = sp or cyl; 11 | 12 | tlo main; 13 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/revolution.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | 3 | curve2d testcurve=(7; 4 | 1,0; 5 | 1,1; 6 | 1.5,1.5; 7 | 2,3; 8 | 2.5,1.5; 9 | 3,1; 10 | 3,0; 11 | 3; 12 | 3,1,2,3; 13 | 3,3,4,5; 14 | 3,5,6,7); 15 | 16 | solid something = revolution(0,0,0;1,0,0;testcurve); 17 | 18 | tlo something; -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/cone.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## A cone 3 | # 4 | algebraic3d 5 | 6 | # Cone given by bottom circle and top circle 7 | # and cut by planes: 8 | 9 | solid cutcone = cone ( 0, 0, 0; 1; 3, 0, 0; 0.1 ) 10 | and plane (0, 0, 0; -1, 0, 0) 11 | and plane (3, 0, 0; 1, 0, 0); 12 | 13 | tlo cutcone; 14 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/image.h: -------------------------------------------------------------------------------- 1 | /* image.h */ 2 | 3 | #ifndef IMAGE_H 4 | # define IMAGE_H 5 | 6 | typedef struct _TK_RGBImageRec 7 | { 8 | int sizeX, sizeY, sizeZ; 9 | unsigned char *data; 10 | } TK_RGBImageRec; 11 | 12 | extern TK_RGBImageRec *tkRGBImageLoad(char *fileName); 13 | 14 | #endif 15 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/image.h: -------------------------------------------------------------------------------- 1 | /* image.h */ 2 | 3 | #ifndef IMAGE_H 4 | # define IMAGE_H 5 | 6 | typedef struct _TK_RGBImageRec 7 | { 8 | int sizeX, sizeY, sizeZ; 9 | unsigned char *data; 10 | } TK_RGBImageRec; 11 | 12 | extern TK_RGBImageRec *tkRGBImageLoad(const char *fileName); 13 | 14 | #endif 15 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/gprim/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_definitions(-DNGINTERFACE_EXPORTS) 2 | add_library(gprim OBJECT 3 | adtree.cpp geom2d.cpp geom3d.cpp geomfuncs.cpp 4 | geomtest3d.cpp transform3d.cpp spline.cpp splinegeometry.cpp 5 | ) 6 | 7 | set_target_properties( gprim PROPERTIES POSITION_INDEPENDENT_CODE ON ) 8 | 9 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/parallelfunc.hpp: -------------------------------------------------------------------------------- 1 | das braucht keiner mehr 2 | 3 | 4 | 5 | #ifndef FILE_PARALLELFUNC 6 | #define FILE_PARALLELFUNC 7 | 8 | 9 | void ParallelRun(); 10 | 11 | void LoadPDEParallel ( const char* filename ); 12 | 13 | 14 | #ifdef NGSOLVE 15 | // void NGS_ParallelRun ( const string & message); 16 | #endif 17 | 18 | #endif 19 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/specials.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_SPECIALS 2 | #define FILE_SPECIALS 3 | 4 | /* 5 | 6 | Very special implementations .. 7 | 8 | */ 9 | 10 | 11 | /// 12 | DLL_HEADER extern void CutOffAndCombine (Mesh & mesh, const Mesh & othermesh); 13 | 14 | DLL_HEADER extern void HelmholtzMesh (Mesh & mesh); 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_subdirectory(general) 2 | add_subdirectory(gprim) 3 | add_subdirectory(linalg) 4 | add_subdirectory(include) 5 | add_subdirectory(meshing) 6 | add_subdirectory(visualization) 7 | add_subdirectory(csg) 8 | add_subdirectory(geom2d) 9 | add_subdirectory(occ) 10 | add_subdirectory(stlgeom) 11 | add_subdirectory(interface) 12 | 13 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/linalg/Makefile.am: -------------------------------------------------------------------------------- 1 | noinst_HEADERS = densemat.hpp linalg.hpp polynomial.hpp vector.hpp opti.hpp 2 | AM_CPPFLAGS = -I$(top_srcdir)/libsrc/include 3 | METASOURCES = AUTO 4 | noinst_LTLIBRARIES = libla.la 5 | libla_la_SOURCES = densemat.cpp polynomial.cpp bfgs.cpp linopt.cpp linsearch.cpp 6 | 7 | # vector.cpp 8 | 9 | # libla_la_LDFLAGS = -rdynamic 10 | -------------------------------------------------------------------------------- /netgen-6.1-src/nglib/netgen.py: -------------------------------------------------------------------------------- 1 | import sys 2 | try: 3 | # Linux 4 | from libmesh import meshing 5 | from libgeom2d import geom2d 6 | from libcsg import csg 7 | except: 8 | # Windows 9 | from nglib import * 10 | 11 | sys.modules['netgen.meshing'] = meshing 12 | sys.modules['netgen.geom2d'] = geom2d 13 | sys.modules['netgen.csg'] = csg 14 | del sys 15 | 16 | -------------------------------------------------------------------------------- /netgen-6.1-src/py_tutorials/mesh.py: -------------------------------------------------------------------------------- 1 | from netgen.meshing import * 2 | from netgen.csg import * 3 | 4 | geo = CSGeometry("shaft.geo") 5 | 6 | param = MeshingParameters() 7 | param.maxh = 10 8 | print (param) 9 | 10 | m1 = GenerateMesh (geo, param) 11 | 12 | 13 | import exportNeutral 14 | exportNeutral.Export (m1, "shaft.mesh") 15 | 16 | 17 | 18 | Save (m1, "mesh.vol", geo) 19 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/visualization/visual_dummy.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #include 4 | #include "../include/nginterface.h" 5 | 6 | void Ng_ClearSolutionData () { ; } 7 | void Ng_InitSolutionData (Ng_SolutionData * soldata) { ; } 8 | void Ng_SetSolutionData (Ng_SolutionData * soldata) { ; } 9 | void Ng_Redraw (bool blocking) { ; } 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/Makefile.am: -------------------------------------------------------------------------------- 1 | noinst_HEADERS = acisgeom.hpp gprim.hpp meshing.hpp occgeom.hpp \ 2 | visual.hpp csg.hpp incvis.hpp myadt.hpp opti.hpp geometry2d.hpp \ 3 | linalg.hpp mydefs.hpp parallel.hpp stlgeom.hpp mystdlib.h \ 4 | nginterface_v2_impl.hpp inctcl.hpp incopengl.hpp 5 | 6 | include_HEADERS = nginterface.h nginterface_v2.hpp 7 | 8 | AM_CPPFLAGS = 9 | METASOURCES = AUTO 10 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/cube.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## A cube 3 | # 4 | algebraic3d 5 | 6 | # cube consisting of 6 planes: 7 | 8 | solid cube = plane (0, 0, 0; 0, 0, -1) 9 | and plane (0, 0, 0; 0, -1, 0) 10 | and plane (0, 0, 0; -1, 0, 0) 11 | and plane (1, 1, 1; 0, 0, 1) 12 | and plane (1, 1, 1; 0, 1, 0) 13 | and plane (1, 1, 1; 1, 0, 0); 14 | 15 | tlo cube; 16 | 17 | -------------------------------------------------------------------------------- /netgen-6.1-src/py_tutorials/cube.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## A cube 3 | # 4 | algebraic3d 5 | 6 | # cube consisting of 6 planes: 7 | 8 | solid cube = plane (0, 0, 0; 0, 0, -1) 9 | and plane (0, 0, 0; 0, -1, 0) 10 | and plane (0, 0, 0; -1, 0, 0) 11 | and plane (1, 1, 1; 0, 0, 1) 12 | and plane (1, 1, 1; 0, 1, 0) 13 | and plane (1, 1, 1; 1, 0, 0); 14 | 15 | tlo cube; 16 | 17 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/twocyl.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | 3 | # 4 | # two intersecting cylinderes 5 | # 6 | 7 | solid cyl1 = cylinder ( 1, 0, 0; -1, 0, 0; 0.5 ) 8 | and plane (-1, 0, 0; -1, 0, 0) 9 | and plane (1, 0, 0; 1, 0, 0); 10 | solid cyl2 = cylinder ( 0, 1, 0.3; 0, -1, 0.3; 0.5 ) 11 | and plane (0, -1, 0; 0, -1, 0) 12 | and plane (0, 1, 0; 0, 1, 0); 13 | solid main = cyl1 or cyl2; 14 | 15 | 16 | tlo main; 17 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/acisgeom.tcl: -------------------------------------------------------------------------------- 1 | if { [Ng_ACISCommand isACISavailable] == "yes" } { 2 | .ngmenu.geometry add command -label "ACIS Topology Explorer..." \ 3 | -command { acisdialog; } 4 | 5 | .ngmenu.geometry add command -label "ACIS combine all" \ 6 | -command { Ng_ACISCommand combineall } 7 | .ngmenu.geometry add command -label "ACIS Create CT" \ 8 | -command { Ng_ACISCommand createct } 9 | } 10 | 11 | 12 | -------------------------------------------------------------------------------- /netgen-6.1/fix-element2d.patch: -------------------------------------------------------------------------------- 1 | diff --git a/libsrc/meshing/meshtype.hpp b/libsrc/meshing/meshtype.hpp 2 | index a9ca7f5..eddc8a9 100644 3 | --- a/libsrc/meshing/meshtype.hpp 4 | +++ b/libsrc/meshing/meshtype.hpp 5 | @@ -338,7 +338,7 @@ namespace netgen 6 | /// 7 | Element2d (); 8 | /// 9 | - Element2d (int anp); 10 | + DLL_HEADER Element2d (int anp); 11 | /// 12 | DLL_HEADER Element2d (ELEMENT_TYPE type); 13 | /// 14 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/gprim/Makefile.am: -------------------------------------------------------------------------------- 1 | noinst_HEADERS = adtree.hpp geom3d.hpp geomobjects2.hpp geomops2.hpp geomtest3d.hpp transform3d.hpp geom2d.hpp geomfuncs.hpp geomobjects.hpp geomops.hpp gprim.hpp spline.hpp splinegeometry.hpp 2 | 3 | AM_CPPFLAGS = -I$(top_srcdir)/libsrc/include 4 | METASOURCES = AUTO 5 | noinst_LTLIBRARIES = libgprim.la 6 | libgprim_la_SOURCES = adtree.cpp geom2d.cpp geom3d.cpp geomfuncs.cpp \ 7 | geomtest3d.cpp transform3d.cpp spline.cpp splinegeometry.cpp 8 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/sculpture.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | # 3 | # intersection of sphere and cylinders 4 | # motivated by a sculpture found in St. Gallen 5 | # 6 | 7 | solid cyls = cylinder ( -100, 0, 0; 200, 0, 0; 40 ) 8 | or cylinder ( 100, -100, 100; 100, 200, 100; 40) 9 | or cylinder ( 0, 100, -100; 0, 100, 200; 40); 10 | solid sculpture = sphere (50, 50, 50; 80) and not cyls 11 | and not sphere (50, 50, 50; 50); 12 | 13 | tlo sculpture -col=[0.5, 0.5, 0.5]; 14 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/boundarycondition.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | 3 | solid p1 = plane (0.5, 0, 0; 1, 0, 0); 4 | 5 | # since surfaces of both bricks are identic they get the same bc id: 6 | solid brick1 = orthobrick (0,0,0; 1,1,1) and p1 -bc=1; 7 | solid brick2 = orthobrick (0,0,-1; 1,1,0) and p1 -bc=2; 8 | 9 | 10 | tlo brick1; 11 | tlo brick2; 12 | 13 | # override bc number: 14 | # all faces of solid p1 belonging to the boundary of tlo brick1 get bc=3 15 | 16 | boundarycondition p1 brick1 3; 17 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/cubemsphere.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## Cube minus Cylinder 3 | # 4 | algebraic3d 5 | 6 | solid cube = plane (0, 0, 0; 0, 0, -1) 7 | and plane (0, 0, 0; 0, -1, 0) 8 | and plane (0, 0, 0; -1, 0, 0) 9 | and plane (1, 1, 1; 0, 0, 1) 10 | and plane (1, 1, 1; 0, 1, 0) 11 | and plane (1, 1, 1; 1, 0, 0); 12 | solid sp = sphere (0.5, 0.5, 0; 0.001); 13 | 14 | # cut off small sphere: 15 | 16 | solid main = cube and not sp; 17 | 18 | tlo main; 19 | 20 | -------------------------------------------------------------------------------- /netgen-6.1-src/README.md: -------------------------------------------------------------------------------- 1 | Netgen mesh generator 2 | 3 | NETGEN is an automatic 3d tetrahedral mesh generator. It accepts input from constructive solid geometry (CSG) or boundary representation (BRep) from STL file format. The connection to a geometry kernel allows the handling of IGES and STEP files. NETGEN contains modules for mesh optimization and hierarchical mesh refinement. Netgen 6.x supports scripting via a Python interface. Netgen is open source based on the LGPL license. It is available for Unix/Linux, Windows, and OSX. -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/cubemcyl.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## Cube minus Cylinder 3 | # 4 | algebraic3d 5 | 6 | solid cube = plane (0, 0, 0; 0, 0, -1) 7 | and plane (0, 0, 0; 0, -1, 0) 8 | and plane (0, 0, 0; -1, 0, 0) 9 | and plane (1, 1, 1; 0, 0, 1) 10 | and plane (1, 1, 1; 0, 1, 0) 11 | and plane (1, 1, 1; 1, 0, 0); 12 | solid cyl = cylinder (0.5, 0.5, 0; 0.5, 0.5, 1; 0.03); 13 | 14 | # cut off small cylinder from cube: 15 | 16 | solid main = cube and not cyl; 17 | 18 | tlo main; 19 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/sphereincube.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | # 3 | # Example with two sub-domains: 4 | # 5 | solid cube = plane (0, 0, 0; 0, 0, -1) 6 | and plane (0, 0, 0; 0, -1, 0) 7 | and plane (0, 0, 0; -1, 0, 0) 8 | and plane (1, 1, 1; 0, 0, 1) 9 | and plane (1, 1, 1; 0, 1, 0) 10 | and plane (1, 1, 1; 1, 0, 0); 11 | solid sph = sphere (0.5, 0.5, 0.5; 0.3); 12 | 13 | solid rest = cube and not sph; 14 | 15 | tlo rest -transparent -col=[0,0,1]; 16 | tlo sph -col=[1,0,0]; 17 | 18 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/twobricks.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | solid cube = plane (0, 0, 0; 0, 0, -1) 3 | and plane (0, 0, 0; 0, -1, 0) 4 | and plane (0, 0, 0; -1, 0, 0) 5 | and plane (1, 1, 1; 0, 0, 1) 6 | and plane (1, 1, 1; 0, 1, 0) 7 | and plane (1, 1, 1; 1, 0, 0); 8 | solid cutplane = plane (0.5, 0, 0; -1, 0, 0); 9 | 10 | solid right = cube and cutplane; 11 | solid left = cube and not cutplane; 12 | 13 | tlo right -col=[1,0,0] -material=copper; 14 | tlo left -col=[0,0,1]; 15 | 16 | -------------------------------------------------------------------------------- /netgen-6.1/build.sh: -------------------------------------------------------------------------------- 1 | mkdir build 2 | cd build 3 | 4 | # Configure step 5 | cmake -G Ninja -DCMAKE_INSTALL_PREFIX=$PREFIX \ 6 | -DCMAKE_BUILD_TYPE=RelWithDebInfo \ 7 | -DCMAKE_PREFIX_PATH=$PREFIX \ 8 | -DCMAKE_SYSTEM_PREFIX_PATH=$PREFIX \ 9 | -DINSTALL_DIR=$PREFIX \ 10 | -DUSE_PYTHON=OFF \ 11 | -DUSE_GUI=OFF \ 12 | -DUSE_OCC=ON \ 13 | -DUSE_GUI=OFF \ 14 | -DUSE_SUPERBUILD=OFF \ 15 | -DOCC_INCLUDE_DIR=$PREFIX/include/oce \ 16 | .. 17 | 18 | # Build step 19 | ninja -j 3 20 | 21 | # Install step 22 | ninja install 23 | -------------------------------------------------------------------------------- /netgen-6.2-dev/build.sh: -------------------------------------------------------------------------------- 1 | mkdir build 2 | cd build 3 | 4 | # Configure step 5 | cmake -G Ninja -DCMAKE_INSTALL_PREFIX=$PREFIX \ 6 | -DCMAKE_BUILD_TYPE=RelWithDebInfo \ 7 | -DCMAKE_PREFIX_PATH=$PREFIX \ 8 | -DCMAKE_SYSTEM_PREFIX_PATH=$PREFIX \ 9 | -DINSTALL_DIR=$PREFIX \ 10 | -DUSE_PYTHON=OFF \ 11 | -DUSE_GUI=OFF \ 12 | -DUSE_OCC=ON \ 13 | -DUSE_GUI=OFF \ 14 | -DUSE_SUPERBUILD=OFF \ 15 | -DOCC_INCLUDE_DIR=$PREFIX/include/oce \ 16 | .. 17 | 18 | # Build step 19 | ninja -j 3 20 | 21 | # Install step 22 | ninja install 23 | -------------------------------------------------------------------------------- /netgen-6.1/bld.bat: -------------------------------------------------------------------------------- 1 | mkdir build 2 | cd build 3 | REM Configure step 4 | cmake -G "Ninja" -DINSTALL_DIR="%LIBRARY_PREFIX%" ^ 5 | -DCMAKE_BUILD_TYPE=Release ^ 6 | -DINSTALL_DIR="%LIBRARY_PREFIX%" ^ 7 | -DCMAKE_SYSTEM_PREFIX_PATH="%LIBRARY_PREFIX%" ^ 8 | -DUSE_OCC=ON ^ 9 | -DUSE_PYTHON=OFF ^ 10 | -DUSE_GUI=OFF ^ 11 | -DOCC_INCLUDE_DIR="%LIBRARY_PREFIX%"/include/oce ^ 12 | .. 13 | if errorlevel 1 exit 1 14 | 15 | REM Build step 16 | ninja 17 | if errorlevel 1 exit 1 18 | 19 | REM Install step 20 | ninja install 21 | if errorlevel 1 exit 1 22 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/twocubes.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | 3 | # example with two sub-domains 4 | 5 | solid cube = plane (0, 0, 0; 0, 0, -1) 6 | and plane (0, 0, 0; 0, -1, 0) 7 | and plane (0, 0, 0; -1, 0, 0) 8 | and plane (1, 1, 1; 0, 0, 1) 9 | and plane (1, 1, 1; 0, 1, 0) 10 | and plane (1, 1, 1; 1, 0, 0); 11 | solid cutplane = plane (0.5, 0, 0; -1, 0, 0); 12 | 13 | solid right = cube and cutplane; 14 | solid left = cube and not cutplane; 15 | 16 | tlo right -col=[1,0,0]; 17 | tlo left -col=[0,0,1]; 18 | 19 | -------------------------------------------------------------------------------- /netgen-6.1-src/cmake_modules/mic.cmake: -------------------------------------------------------------------------------- 1 | set(CMAKE_SYSTEM_NAME Linux) 2 | set(CMAKE_SYSTEM_PROCESSOR k1om) 3 | set(CMAKE_SYSTEM_VERSION 1) 4 | 5 | # specify the cross compiler 6 | set(CMAKE_C_COMPILER icc) 7 | set(CMAKE_CXX_COMPILER icpc) 8 | set(MPI_C_COMPILER mpiicc) 9 | set(_CMAKE_TOOLCHAIN_PREFIX x86_64-k1om-linux-) 10 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mmic") 11 | set(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} -limf -lsvml -lirng -lintlc") 12 | 13 | # where is the target environment 14 | set(CMAKE_FIND_ROOT_PATH /usr/linux-k1om-4.7) 15 | 16 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_definitions(-DNGINTERFACE_EXPORTS) 2 | add_library(gen OBJECT 3 | array.cpp bitarray.cpp dynamicmem.cpp flags.cpp 4 | hashtabl.cpp mystring.cpp ngexception.cpp optmem.cpp parthreads.cpp 5 | profiler.cpp seti.cpp sort.cpp spbita2d.cpp symbolta.cpp table.cpp 6 | mpi_interface.cpp gzstream.cpp 7 | ) 8 | 9 | set_target_properties( gen PROPERTIES POSITION_INDEPENDENT_CODE ON ) 10 | 11 | install( FILES ngexception.hpp DESTINATION include COMPONENT netgen_devel ) 12 | 13 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/lshape3d.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | 3 | # 4 | ## 3D Lshape - domain 5 | # 6 | 7 | solid c1 = plane (-1, -1, 0; 0, 0, -1) 8 | and plane (-1, -1, 0; 0, -1, 0) 9 | and plane (-1, -1, 0; -1, 0, 0) 10 | and plane (1, 1, 1; 0, 0, 1) 11 | and plane (1, 1, 1; 0, 1, 0) 12 | and plane (1, 1, 1; 1, 0, 0); 13 | 14 | solid f1 = plane (0, 0, 0; -1, 0, 0); 15 | solid f2 = plane (0, 0, 0; 0, 1, 0); 16 | 17 | solid main = c1 and not (f1 and f2); 18 | 19 | tlo main; 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | [![Travis Build Status](https://travis-ci.org/tpaviot/netgen-conda.png?branch=master)](https://travis-ci.org/tpaviot/netgen-conda) 2 | [![Appveyor Build status](https://ci.appveyor.com/api/projects/status/qi7u98mcjcdly34g/branch/master?svg=true)](https://ci.appveyor.com/project/tpaviot/pythonocc-core) 3 | 4 | netgen-6.2 conda receipe for win32/win64/linux64/osx64. 5 | 6 | travis and appveyor builds are sync'ed with git repository, nigthly 7 | builds are planned using a cron. 8 | 9 | See netgen homepage at https://sourceforge.net/projects/netgen-mesher/ 10 | 11 | -------------------------------------------------------------------------------- /netgen-6.2-dev/bld.bat: -------------------------------------------------------------------------------- 1 | mkdir build 2 | cd build 3 | REM Configure step 4 | cmake -G "Ninja" -DINSTALL_DIR="%LIBRARY_PREFIX%" ^ 5 | -DCMAKE_BUILD_TYPE=Release ^ 6 | -DINSTALL_DIR="%LIBRARY_PREFIX%" ^ 7 | -DCMAKE_SYSTEM_PREFIX_PATH="%LIBRARY_PREFIX%" ^ 8 | -DUSE_OCC=ON ^ 9 | -DUSE_PYTHON=OFF ^ 10 | -DUSE_GUI=OFF ^ 11 | -DUSE_SUPERBUILD=OFF ^ 12 | -DOCC_INCLUDE_DIR="%LIBRARY_PREFIX%"/include/oce ^ 13 | .. 14 | if errorlevel 1 exit 1 15 | 16 | REM Build step 17 | ninja 18 | if errorlevel 1 exit 1 19 | 20 | REM Install step 21 | ninja install 22 | if errorlevel 1 exit 1 23 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_library(occ ${NG_LIB_TYPE} 2 | Partition_Inter2d.cxx Partition_Inter3d.cxx 3 | Partition_Loop.cxx Partition_Loop2d.cxx Partition_Loop3d.cxx Partition_Spliter.cxx 4 | occconstruction.cpp occgenmesh.cpp occgeom.cpp occmeshsurf.cpp 5 | ) 6 | 7 | add_library(occvis ${NG_LIB_TYPE} vsocc.cpp) 8 | 9 | if(NOT WIN32) 10 | target_link_libraries( occ ${OCC_LIBRARIES} ${PYTHON_LIBS}) 11 | target_link_libraries( occvis occ ) 12 | install( TARGETS occ occvis ${ng_install_dir}) 13 | endif(NOT WIN32) 14 | 15 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/test.dem: -------------------------------------------------------------------------------- 1 | # Demo file 2 | 3 | t = 0; 4 | 5 | camerapos (0 : -7,0,0; 1: -6,0,0; 10: -5,0,0); 6 | camerapos (10: -5,0,0; 11: -5,-5,0; 12: 0,-5,0); 7 | camerapos (12: 0,-5,0); 8 | 9 | camerapos (14: 0,-5,0; 15: 0,-4,0); 10 | camerapos (15: 0,-4,0; 16: 4,-4,0; 17: 4,0,0); 11 | camerapos (17: 4,0,0; 18: 4,4,0; 19: 0,4,0); 12 | camerapos (19: 0,4,0; 20: -4,4,0; 21: -4,0,0); 13 | 14 | camerapos (21: -4,0,0); 15 | camerapos (22: 0,-4,-4); 16 | camerapos (23: -4,0,-4); 17 | camerapos (24: -4,-4,-4); 18 | 19 | camerapos (25: -4,-4,-4; 30: 4,-4,-4; 35: 4,4,4); 20 | 21 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/manyholes.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | # 3 | ## CSG feature copy 4 | # 5 | 6 | 7 | # define a axis parallel brick: 8 | 9 | solid br = orthobrick (0, 0, 0; 10, 10, 1); 10 | 11 | # define reference cylinder: 12 | 13 | solid cyl1 = cylinder (0.5, 0.5, -1; 0.5, 0.5, 3; 0.2); 14 | 15 | 16 | # make copies: 17 | solid cylx = multitranslate (1, 0, 0; 9; cyl1); 18 | solid cyls = multitranslate (0, 1, 0; 9; cylx); 19 | 20 | solid main = br and not cyls; 21 | 22 | tlo main; 23 | 24 | # provide bounding-box for fastening bisection alg: 25 | 26 | boundingbox (-1, -1, -1; 11, 11, 2); 27 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/geom2d/Makefile.am: -------------------------------------------------------------------------------- 1 | noinst_HEADERS = geom2dmesh.hpp geometry2d.hpp vsgeom2d.hpp 2 | 3 | AM_CPPFLAGS = -I$(top_srcdir)/libsrc/include $(TCL_INCLUDES) 4 | 5 | METASOURCES = AUTO 6 | 7 | lib_LTLIBRARIES = libgeom2d.la 8 | 9 | if NGGUI 10 | lib_LTLIBRARIES += libgeom2dvis.la 11 | endif 12 | 13 | 14 | 15 | libgeom2d_la_SOURCES = genmesh2d.cpp geom2dmesh.cpp geometry2d.cpp python_geom2d.cpp 16 | libgeom2d_la_LIBADD = $(top_builddir)/libsrc/meshing/libmesh.la 17 | 18 | libgeom2dvis_la_SOURCES = geom2dpkg.cpp vsgeom2d.cpp 19 | libgeom2dvis_la_LIBADD = libgeom2d.la 20 | 21 | 22 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/cubeandspheres.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## Cube and Spheres 3 | # 4 | algebraic3d 5 | 6 | # a cube 7 | solid cube = plane (0, 0, 0; 0, 0, -1) 8 | and plane (0, 0, 0; 0, -1, 0) 9 | and plane (0, 0, 0; -1, 0, 0) 10 | and plane (1, 1, 1; 0, 0, 1) 11 | and plane (1, 1, 1; 0, 1, 0) 12 | and plane (1, 1, 1; 1, 0, 0); 13 | 14 | # two shperes 15 | solid sph1 = sphere (0.5, 0.5, 0.5; 0.58); 16 | solid sph2 = sphere (0.5, 0.5, 0.5; 0.75); 17 | 18 | # cut cube with inner and outer sphere 19 | solid main = cube and sph2 and not sph1; 20 | 21 | tlo main; 22 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/manyholes2.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | # 3 | ## CSG feature copy 4 | # 5 | 6 | 7 | # define a axis parallel brick: 8 | 9 | solid br = orthobrick (0, 0, 0; 20, 20, 1); 10 | 11 | # define reference cylinder: 12 | 13 | solid cyl1 = cylinder (0.5, 0.5, -1; 0.5, 0.5, 3; 0.2); 14 | 15 | 16 | # make copies: 17 | solid cylx = multitranslate (1, 0, 0; 19; cyl1); 18 | solid cyls = multitranslate (0, 1, 0; 19; cylx); 19 | 20 | solid main = br and not cyls; 21 | 22 | tlo main; 23 | 24 | # provide bounding-box for fastening bisection alg: 25 | 26 | boundingbox (-1, -1, -1; 21, 21, 2); 27 | -------------------------------------------------------------------------------- /netgen-6.1-src/python/__init__.py: -------------------------------------------------------------------------------- 1 | from os import environ 2 | from sys import path 3 | from sys import platform as __platform 4 | if __platform.startswith('linux'): 5 | path.append(environ['NETGENDIR']+'/../lib') 6 | if __platform.startswith('win'): 7 | path.append(environ['NETGENDIR']) 8 | if __platform.startswith('darwin'): 9 | path.append(environ['NETGENDIR']) 10 | 11 | 12 | # from libngpy import * 13 | import libngpy 14 | # from libngpy import * 15 | 16 | # import libngpy 17 | 18 | # from . import csg 19 | # from . import meshing 20 | # from . import geom2d 21 | 22 | del environ 23 | del path 24 | -------------------------------------------------------------------------------- /netgen-6.1/remove_warnings.patch: -------------------------------------------------------------------------------- 1 | diff --git a/CMakeLists.txt b/CMakeLists.txt 2 | index 128ea99..89c0a0a 100644 3 | --- a/CMakeLists.txt 4 | +++ b/CMakeLists.txt 5 | @@ -138,7 +138,7 @@ if(WIN32) 6 | add_definitions(-DMSVC_EXPRESS -D_CRT_SECURE_NO_WARNINGS -DHAVE_STRUCT_TIMESPEC) 7 | # build convenience (aka object) libraries in windows) 8 | set(NG_LIB_TYPE OBJECT) 9 | - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP /wd4244 /wd4800") 10 | + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP /wd4244 /wd4800 /wd4251 /wd4273 /wd4275 ") 11 | else(WIN32) 12 | # build shared libraries 13 | set(NG_LIB_TYPE SHARED) 14 | -------------------------------------------------------------------------------- /netgen-6.2-dev/remove_warnings.patch: -------------------------------------------------------------------------------- 1 | diff --git a/CMakeLists.txt b/CMakeLists.txt 2 | index 128ea99..89c0a0a 100644 3 | --- a/CMakeLists.txt 4 | +++ b/CMakeLists.txt 5 | @@ -138,7 +138,7 @@ if(WIN32) 6 | add_definitions(-DMSVC_EXPRESS -D_CRT_SECURE_NO_WARNINGS -DHAVE_STRUCT_TIMESPEC) 7 | # build convenience (aka object) libraries in windows) 8 | set(NG_LIB_TYPE OBJECT) 9 | - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP /wd4244 /wd4800") 10 | + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP /wd4244 /wd4800 /wd4251 /wd4273 /wd4275 ") 11 | else(WIN32) 12 | # build shared libraries 13 | set(NG_LIB_TYPE SHARED) 14 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Loop2d.jxx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 CEA/DEN, EDF R&D 4 | // 5 | // 6 | // 7 | // File : Partition_Loop2d.jxx 8 | // Module : GEOM 9 | 10 | #ifndef _TopoDS_Face_HeaderFile 11 | #include 12 | #endif 13 | #ifndef _TopoDS_Edge_HeaderFile 14 | #include 15 | #endif 16 | #ifndef _TopTools_ListOfShape_HeaderFile 17 | #include 18 | #endif 19 | #ifndef _BRepAlgo_Image_HeaderFile 20 | #include 21 | #endif 22 | #ifndef _Partition_Loop2d_HeaderFile 23 | #include "Partition_Loop2d.hxx" 24 | #endif 25 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/geoml.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_GEOML 2 | #define FILE_GEOML 3 | 4 | /* *************************************************************************/ 5 | /* File: geoml.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 21. Jun. 98 */ 8 | /* *************************************************************************/ 9 | 10 | #include 11 | 12 | #include 13 | #include 14 | #include 15 | #include 16 | #endif 17 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/TODO: -------------------------------------------------------------------------------- 1 | In no particular order: 2 | ----------------------- 3 | 4 | stubify C API. 5 | 6 | replace EPS support with TK photo image support 7 | 8 | Add command arguments for create, destroy, etc. so there would be a 9 | -createcommand option to the togl command (etc.) (and phase out 10 | Togl_*Func from the C API) 11 | 12 | multisampling support (can be worked-around by passing in a pixelformat) 13 | 14 | add vertical sync control 15 | 16 | update documention 17 | - update build instructions 18 | - update stereo documentation 19 | - separate Tcl API from C API 20 | - say togl hides window system dependent (glX/wgl/agl) calls 21 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/circle_on_cube.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## A cube 3 | # 4 | algebraic3d 5 | 6 | # cube consisting of 6 planes: 7 | 8 | solid cube = plane (0, 0, 0; 0, 0, -1) 9 | and plane (0, 0, 0; 0, -1, 0) 10 | and plane (0, 0, 0; -1, 0, 0) 11 | and plane (1, 1, 1; 0, 0, 1) 12 | and plane (1, 1, 1; 0, 1, 0) 13 | and plane (1, 1, 1; 1, 0, 0); 14 | 15 | 16 | solid top = plane (1,1,1; 0, 0, 1); 17 | solid cyl = top 18 | and plane (0,0,0; 0, 0, -1) 19 | and cylinder (0.5, 0.5, 0; 0.5, 0.5, 1; 0.2); 20 | 21 | 22 | tlo cube; 23 | 24 | # take just surface 'top' of solid 'cyl' 25 | tlo cyl top -col=[1,0,0]; 26 | 27 | 28 | -------------------------------------------------------------------------------- /netgen-6.1-src/nglib/cube.surf: -------------------------------------------------------------------------------- 1 | 8 2 | 0 0 0 3 | 1 0 0 4 | 1 1 1 5 | 1 0 1 6 | 0 1 1 7 | 0 0 1 8 | 0 1 0 9 | 1 1 0 10 | 12 11 | 2 1 7 12 | 8 2 7 13 | 6 1 2 14 | 4 6 2 15 | 4 3 5 16 | 5 6 4 17 | 8 3 4 18 | 8 4 2 19 | 5 3 8 20 | 7 5 8 21 | 1 6 5 22 | 7 1 5 23 | -------------------------------------------------------------------------------- /netgen-6.1-src/python/gengeom.py: -------------------------------------------------------------------------------- 1 | 2 | geom = SplineGeometry() 3 | 4 | # Define Points 5 | pi1 = geom.AppendPoint(0,0) 6 | pi2 = geom.AppendPoint(1,0) 7 | pi3 = geom.AppendPoint(1,1) 8 | pi4 = geom.AppendPoint(0,1) 9 | 10 | # Define Segments 11 | geom.AppendSegment([pi1,pi2]) 12 | geom.AppendSegment([pi2,pi3]) 13 | geom.AppendSegment([pi3,pi4]) 14 | geom.AppendSegment([pi4,pi1]) 15 | 16 | # Plot Geometry 17 | geom.Plot() 18 | 19 | # Plot Point Index 20 | geom.ShowPoints() 21 | # Plot Domain Numbers 22 | geom.ShowDomains() 23 | 24 | # Set Meshing Parameters 25 | mparam = MeshingParameters() 26 | mparam.maxh = 0.1 27 | 28 | mesh = geom.GenerateMesh(mparam) -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CPPFLAGS = 2 | METASOURCES = AUTO 3 | dist_pkgdata_DATA = boxcyl.geo circle_on_cube.geo cone.geo cube.geo \ 4 | cubeandring.geo cubeandspheres.geo cubemcyl.geo cubemsphere.geo cylinder.geo \ 5 | cylsphere.geo ellipsoid.geo ellipticcyl.geo extrusion.geo fichera.geo lshape3d.geo \ 6 | manyholes.geo manyholes2.geo matrix.geo ortho.geo period.geo revolution.geo \ 7 | sculpture.geo shaft.geo shell.geo sphere.geo sphereincube.geo torus.geo trafo.geo \ 8 | twobricks.geo twocubes.geo twocyl.geo boundarycondition.geo \ 9 | hinge.stl part1.stl frame.step screw.step \ 10 | squarehole.in2d squarecircle.in2d square.in2d 11 | 12 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/geom2d/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_definitions(-DNGLIB_EXPORTS) 2 | add_library(geom2d ${NG_LIB_TYPE} genmesh2d.cpp geom2dmesh.cpp geometry2d.cpp python_geom2d.cpp ) 3 | if(APPLE) 4 | set_target_properties( geom2d PROPERTIES SUFFIX ".so") 5 | endif(APPLE) 6 | 7 | if(NOT WIN32) 8 | target_link_libraries(geom2d mesh ${PYTHON_LIBS}) 9 | install( TARGETS geom2d ${ng_install_dir}) 10 | endif(NOT WIN32) 11 | 12 | if(USE_GUI) 13 | add_library(geom2dvis ${NG_LIB_TYPE} vsgeom2d.cpp) 14 | if(NOT WIN32) 15 | target_link_libraries(geom2dvis geom2d) 16 | install( TARGETS geom2dvis ${ng_install_dir}) 17 | endif(NOT WIN32) 18 | endif(USE_GUI) 19 | 20 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/incopengl.hpp: -------------------------------------------------------------------------------- 1 | #define GL_GLEXT_PROTOTYPES 2 | 3 | 4 | # if defined(TOGL_AGL) || defined(TOGL_AGL_CLASSIC) || defined(TOGL_NSOPENGL) 5 | # include 6 | # include 7 | # else 8 | # include 9 | # include 10 | # endif 11 | 12 | 13 | #ifdef TOGL_X11 14 | // parallel 15 | #define GLX_GLXEXT_PROTOTYPES 16 | #include 17 | #include 18 | #endif 19 | 20 | 21 | 22 | 23 | 24 | // part of OpenGL 1.2, but not in Microsoft's OpenGL 1.1 header: 25 | // GL version sould be checked at runtime 26 | #ifndef GL_CLAMP_TO_EDGE 27 | #define GL_CLAMP_TO_EDGE 0x812F 28 | #endif 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /netgen-6.1-src/py_tutorials/exportNeutral.py: -------------------------------------------------------------------------------- 1 | import sys 2 | 3 | def Export (mesh, filename): 4 | """ export Netgen mesh to neutral format """ 5 | 6 | print ("export mesh in neutral format to file = ", filename) 7 | 8 | f = open (filename, 'w') 9 | 10 | points = mesh.Points() 11 | print (len(points), file=f) 12 | for p in points: 13 | print (p.p[0], p.p[1], p.p[2], file=f) 14 | 15 | 16 | volels = mesh.Elements3D(); 17 | print (len(volels), file=f) 18 | for el in volels: 19 | print (el.index, end=" ", file=f) 20 | for j in el.vertices: 21 | print (j.nr, end=" ", file=f) 22 | print(file=f) 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/stlgeom/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_library(stl ${NG_LIB_TYPE} 2 | meshstlsurface.cpp stlgeom.cpp stlgeomchart.cpp 3 | stlgeommesh.cpp stlline.cpp stltool.cpp stltopology.cpp 4 | ) 5 | 6 | if(NOT WIN32) 7 | target_link_libraries( stl mesh ${PYTHON_LIBS}) 8 | target_link_libraries( stl ${PYTHON_LIBS}) 9 | install( TARGETS stl ${ng_install_dir}) 10 | endif(NOT WIN32) 11 | 12 | if(USE_GUI) 13 | add_library(stlvis ${NG_LIB_TYPE} 14 | vsstl.cpp 15 | ) 16 | if(NOT WIN32) 17 | target_link_libraries( stlvis stl ) 18 | install( TARGETS stlvis ${ng_install_dir}) 19 | endif(NOT WIN32) 20 | endif(USE_GUI) 21 | 22 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/visualization/Makefile.am: -------------------------------------------------------------------------------- 1 | noinst_HEADERS = meshdoc.hpp mvdraw.hpp vispar.hpp \ 2 | visual.hpp vssolution.hpp 3 | 4 | include_HEADERS = soldata.hpp 5 | 6 | AM_CPPFLAGS = $(MPI_INCLUDES) -I$(top_srcdir)/libsrc/include -DOPENGL -D$(TOGL_WINDOWINGSYSTEM) $(OCCFLAGS) $(TCL_INCLUDES) 7 | METASOURCES = AUTO 8 | 9 | lib_LTLIBRARIES = libvisual.la 10 | 11 | 12 | libvisual_la_SOURCES = 13 | 14 | if NGGUI 15 | libvisual_la_LIBADD = $(LIBGLU) $(TCL_LIB_SPEC) 16 | libvisual_la_SOURCES += meshdoc.cpp mvdraw.cpp \ 17 | vsfieldlines.cpp vsmesh.cpp vssolution.cpp importsolution.cpp visualpkg.cpp 18 | else 19 | libvisual_la_SOURCES += visual_dummy.cpp 20 | endif 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/boxcyl.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## Two cylinders on a box 3 | # 4 | algebraic3d 5 | 6 | #define box: 7 | 8 | solid box = plane (0, 0, 0.5; -1, 0, 0) 9 | and plane (0, 0, 0.5; 0, -1, 0) 10 | and plane (0, 0, 0.5; 0, 0, -1) 11 | and plane (2, 1.5, 1; 1, 0, 0) 12 | and plane (2, 1.5, 1; 0, 1, 0) 13 | and plane (2, 1.5, 1; 0, 0, 1); 14 | 15 | #define cylinders: 16 | 17 | solid cyls = (cylinder (0.5, 0.75, 0; 0.5, 0.75, 2; 0.3) 18 | or cylinder (1.5, 0.75, 0; 1.5, 0.75, 2; 0.3) ) 19 | and plane (0, 0, 0.7; 0, 0, -1) 20 | and plane (0, 0, 1.5; 0, 0, 1); 21 | 22 | #combine both: 23 | 24 | solid main = box or cyls; 25 | 26 | 27 | #define sub-domains: 28 | tlo main; 29 | 30 | singular edge box cyls; 31 | 32 | 33 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/fichera.geo: -------------------------------------------------------------------------------- 1 | # 2 | ## Fichera Cube 3 | # 4 | algebraic3d 5 | solid c1 = plane (0, 0, 0; 0, 0, -1) 6 | and plane (0, 0, 0; 0, -1, 0) 7 | and plane (0, 0, 0; -1, 0, 0) 8 | and plane (1, 1, 1; 0, 0, 1) 9 | and plane (1, 1, 1; 0, 1, 0) 10 | and plane (1, 1, 1; 1, 0, 0) -bc=2; 11 | 12 | solid c2 = plane (-0.5, -0.5, -0.5; 0, 0, -1) 13 | and plane (-0.5, -0.5, -0.5; 0, -1, 0) 14 | and plane (-0.5, -0.5, -0.5; -1, 0, 0) 15 | and plane (0.5, 0.5, 0.5; 0, 0, 1) 16 | and plane (0.5, 0.5, 0.5; 0, 1, 0) 17 | and plane (0.5, 0.5, 0.5; 1, 0, 0); 18 | 19 | # cut off small cube 20 | 21 | solid main = c1 and not c2 -bc=1; 22 | 23 | tlo main; 24 | 25 | -------------------------------------------------------------------------------- /netgen-6.1/fix_mystdlib_h.patch: -------------------------------------------------------------------------------- 1 | diff --git a/libsrc/include/mystdlib.h b/libsrc/include/mystdlib.h 2 | index 5cbaca6..b9a6fae 100644 3 | --- a/libsrc/include/mystdlib.h 4 | +++ b/libsrc/include/mystdlib.h 5 | @@ -54,26 +54,6 @@ namespace metis { extern "C" { 6 | #endif 7 | 8 | 9 | -/*** Windows headers ***/ 10 | -#ifdef _MSC_VER 11 | -# define WIN32_LEAN_AND_MEAN 12 | -# ifndef NO_PARALLEL_THREADS 13 | -# ifdef MSVC_EXPRESS 14 | -# else 15 | -# include 16 | -# include 17 | -# endif // MSVC_EXPRESS 18 | -# endif 19 | -# include 20 | -# undef WIN32_LEAN_AND_MEAN 21 | -# include 22 | - 23 | -#else // Not using MC VC++ 24 | - 25 | - 26 | -#endif 27 | - 28 | - 29 | using namespace std; 30 | 31 | #endif 32 | -------------------------------------------------------------------------------- /netgen-6.1/meta.yaml: -------------------------------------------------------------------------------- 1 | package: 2 | name: netgen 3 | version: 6.1 4 | 5 | source: 6 | path: ../netgen-6.1-src 7 | 8 | build: 9 | detect_binary_files_with_prefix: True 10 | number: 1 11 | features: 12 | - vc9 [win and py27] 13 | - vc10 [win and py34] 14 | - vc14 [win and py35] 15 | 16 | requirements: 17 | build: 18 | - patch [win] 19 | - ninja 20 | - cmake 21 | - oce ==0.17.2 22 | - gcc-5 ==5.4.0 [linux or osx] 23 | - binutils ==2.26 [linux] 24 | 25 | run: 26 | - oce ==0.17.2 27 | 28 | about: 29 | home: https://sourceforge.net/projects/netgen-mesher/ 30 | license: LGPLv2 31 | summary: NETGEN is an automatic 3d tetrahedral mesh generator. 32 | -------------------------------------------------------------------------------- /netgen-6.2-dev/fix_mystdlib_h.patch: -------------------------------------------------------------------------------- 1 | diff --git a/libsrc/include/mystdlib.h b/libsrc/include/mystdlib.h 2 | index 5cbaca6..b9a6fae 100644 3 | --- a/libsrc/include/mystdlib.h 4 | +++ b/libsrc/include/mystdlib.h 5 | @@ -54,26 +54,6 @@ namespace metis { extern "C" { 6 | #endif 7 | 8 | 9 | -/*** Windows headers ***/ 10 | -#ifdef _MSC_VER 11 | -# define WIN32_LEAN_AND_MEAN 12 | -# ifndef NO_PARALLEL_THREADS 13 | -# ifdef MSVC_EXPRESS 14 | -# else 15 | -# include 16 | -# include 17 | -# endif // MSVC_EXPRESS 18 | -# endif 19 | -# include 20 | -# undef WIN32_LEAN_AND_MEAN 21 | -# include 22 | - 23 | -#else // Not using MC VC++ 24 | - 25 | - 26 | -#endif 27 | - 28 | - 29 | using namespace std; 30 | 31 | #endif 32 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/boundarylayer.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_BOUNDARYLAYER 2 | #define FILE_BOUNDARYLAYER 3 | 4 | 5 | /// 6 | DLL_HEADER extern void InsertVirtualBoundaryLayer (Mesh & mesh); 7 | 8 | /// Create a typical prismatic boundary layer on the given 9 | /// surfaces 10 | 11 | class BoundaryLayerParameters 12 | { 13 | public: 14 | // parameters by Philippose .. 15 | Array surfid; 16 | Array heights; 17 | Array new_matnrs; 18 | int prismlayers = 1; 19 | int bulk_matnr = 1; 20 | int new_matnr = 1; 21 | double hfirst = 0.01; 22 | double growthfactor = 1; 23 | bool optimize = true; 24 | }; 25 | 26 | DLL_HEADER extern void GenerateBoundaryLayer (Mesh & mesh, BoundaryLayerParameters & blp); 27 | 28 | 29 | #endif 30 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/manifold.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_MANIFOLD 2 | #define FILE_MANIFOLD 3 | 4 | /**************************************************************************/ 5 | /* File: manifold.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 7. Aug. 96 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | 14 | /** 15 | Basis class for manifolds in 2d and 3d 16 | */ 17 | class Manifold 18 | { 19 | public: 20 | /// 21 | Manifold (); 22 | /// 23 | virtual ~Manifold (); 24 | }; 25 | 26 | } 27 | 28 | 29 | #endif 30 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | install( FILES 2 | boxcyl.geo circle_on_cube.geo cone.geo cube.geo 3 | cubeandring.geo cubeandspheres.geo cubemcyl.geo cubemsphere.geo cylinder.geo 4 | cylsphere.geo ellipsoid.geo ellipticcyl.geo extrusion.geo fichera.geo lshape3d.geo 5 | manyholes.geo manyholes2.geo matrix.geo ortho.geo period.geo revolution.geo 6 | sculpture.geo shaft.geo shell.geo sphere.geo sphereincube.geo torus.geo trafo.geo 7 | twobricks.geo twocubes.geo twocyl.geo boundarycondition.geo 8 | hinge.stl part1.stl frame.step screw.step 9 | squarehole.in2d squarecircle.in2d square.in2d 10 | DESTINATION share/netgen 11 | COMPONENT netgen_tutorial 12 | ) 13 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/Makefile.am: -------------------------------------------------------------------------------- 1 | noinst_HEADERS = array.hpp myadt.hpp optmem.hpp sort.hpp table.hpp autodiff.hpp flags.hpp mystring.hpp spbita2d.hpp template.hpp autoptr.hpp hashtabl.hpp netgenout.hpp profiler.hpp stack.hpp bitarray.hpp seti.hpp symbolta.hpp dynamicmem.hpp parthreads.hpp mpi_interface.hpp gzstream.h archive_base.hpp ngpython.hpp 2 | 3 | include_HEADERS = ngexception.hpp 4 | 5 | AM_CPPFLAGS = $(MPI_INCLUDES) -I$(top_srcdir)/libsrc/include 6 | METASOURCES = AUTO 7 | noinst_LTLIBRARIES = libgen.la 8 | libgen_la_SOURCES = array.cpp bitarray.cpp dynamicmem.cpp flags.cpp \ 9 | hashtabl.cpp mystring.cpp ngexception.cpp optmem.cpp parthreads.cpp \ 10 | profiler.cpp seti.cpp sort.cpp spbita2d.cpp symbolta.cpp table.cpp \ 11 | mpi_interface.cpp gzstream.cpp 12 | -------------------------------------------------------------------------------- /netgen-6.1-src/python/csg.py: -------------------------------------------------------------------------------- 1 | import libngpy 2 | from libngpy._csg import * 3 | import libngpy.csgvis as csgvis 4 | from libngpy.csgvis import MouseMove 5 | from libngpy._meshing import MeshingParameters 6 | 7 | 8 | CSGeometry.VS = csgvis.VS 9 | SetBackGroundColor = csgvis.SetBackGroundColor 10 | del csgvis 11 | 12 | def VS (obj): 13 | return obj.VS() 14 | 15 | 16 | 17 | def csg_meshing_func (geom, **args): 18 | if "mp" in args: 19 | return GenerateMesh (geom, args["mp"]) 20 | else: 21 | return GenerateMesh (geom, MeshingParameters (**args)) 22 | # return GenerateMesh (geom, MeshingParameters (**args)) 23 | 24 | CSGeometry.GenerateMesh = csg_meshing_func 25 | 26 | 27 | unit_cube = CSGeometry() 28 | unit_cube.Add (OrthoBrick(Pnt(0,0,0), Pnt(1,1,1))) 29 | 30 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/stlgeom/Makefile.am: -------------------------------------------------------------------------------- 1 | noinst_HEADERS = meshstlsurface.hpp stlgeom.hpp stlline.hpp \ 2 | stltool.hpp stltopology.hpp vsstl.hpp 3 | 4 | AM_CPPFLAGS = -I$(top_srcdir)/libsrc/include $(TCL_INCLUDES) 5 | METASOURCES = AUTO 6 | 7 | lib_LTLIBRARIES = libstl.la 8 | 9 | 10 | libstl_la_SOURCES = meshstlsurface.cpp stlgeom.cpp stlgeomchart.cpp \ 11 | stlgeommesh.cpp stlline.cpp stltool.cpp stltopology.cpp 12 | 13 | 14 | libstl_la_LIBADD = $(top_builddir)/libsrc/meshing/libmesh.la 15 | 16 | 17 | 18 | 19 | if NGGUI 20 | lib_LTLIBRARIES += libstlvis.la 21 | libstlvis_la_SOURCES = stlpkg.cpp 22 | libstlvis_la_LIBADD = libstl.la $(top_builddir)/libsrc/visualization/libvisual.la 23 | libstl_la_SOURCES += vsstl.cpp 24 | libstl_la_LIBADD += $(top_builddir)/libsrc/visualization/libvisual.la 25 | endif 26 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/visualization/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_definitions(-DNGINTERFACE_EXPORTS) 2 | install(FILES soldata.hpp DESTINATION include COMPONENT netgen_devel ) 3 | 4 | # AM_CPPFLAGS = $(MPI_INCLUDES) -I$(top_srcdir)/libsrc/include -DOPENGL -D$(TOGL_WINDOWINGSYSTEM) $(OCCFLAGS) $(TCL_INCLUDES) 5 | 6 | if(USE_GUI) 7 | set( LIB_VISUAL_SOURCES meshdoc.cpp mvdraw.cpp vsfieldlines.cpp vsmesh.cpp vssolution.cpp importsolution.cpp ) 8 | else(USE_GUI) 9 | set( LIB_VISUAL_SOURCES visual_dummy.cpp ) 10 | endif(USE_GUI) 11 | 12 | add_library(visual ${NG_LIB_TYPE} ${LIB_VISUAL_SOURCES}) 13 | 14 | if(NOT WIN32) 15 | target_link_libraries( visual ${PYTHON_LIBS} ${MPI_CXX_LIBRARIES} ${OPENGL_LIBRARIES} ${TCL_LIBRARY} ) 16 | install( TARGETS visual ${ng_install_dir}) 17 | endif(NOT WIN32) 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Loop3d.jxx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 CEA/DEN, EDF R&D 4 | // 5 | // 6 | // 7 | // File : Partition_Loop3d.jxx 8 | // Module : GEOM 9 | 10 | #ifndef _TopoDS_Shape_HeaderFile 11 | #include 12 | #endif 13 | #ifndef _TopTools_ListOfShape_HeaderFile 14 | #include 15 | #endif 16 | #ifndef _TopTools_MapOfOrientedShape_HeaderFile 17 | #include 18 | #endif 19 | #ifndef _TopoDS_Edge_HeaderFile 20 | #include 21 | #endif 22 | #ifndef _TopoDS_Face_HeaderFile 23 | #include 24 | #endif 25 | #ifndef _gp_Vec_HeaderFile 26 | #include 27 | #endif 28 | #ifndef _Partition_Loop3d_HeaderFile 29 | #include "Partition_Loop3d.hxx" 30 | #endif 31 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/validate.hpp: -------------------------------------------------------------------------------- 1 | #ifndef VALIDATE_HPP 2 | #define VALIDATE_HPP 3 | 4 | namespace netgen 5 | { 6 | 7 | void GetPureBadness(Mesh & mesh, Array & pure_badness, 8 | const BitArray & isnewpoint); 9 | double Validate(const Mesh & mesh, Array & bad_elements, 10 | const Array & pure_badness, 11 | double max_worsening, const bool uselocalworsening, 12 | Array * quality_loss = NULL); 13 | void RepairBisection(Mesh & mesh, Array & bad_elements, 14 | const BitArray & isnewpoint, const Refinement & refinement, 15 | const Array & pure_badness, 16 | double max_worsening, const bool uselocalworsening, 17 | const Array< Array* > & idmaps); 18 | 19 | } 20 | 21 | #endif // VALIDATE_HPP 22 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/period.geo: -------------------------------------------------------------------------------- 1 | ## 2 | ## Example with periodic boundary conditions 3 | ## by Joachim Schoeberl 4 | ## 5 | ## 6 | 7 | algebraic3d 8 | 9 | solid p1 = plane (0, 0, 0; 0, 0, -1); 10 | solid p2 = plane (1, 1, 1; 0, 0, 1); 11 | 12 | solid p3 = plane (0, 0, 0; 0, -1, 0); 13 | solid p4 = plane (1, 1, 1; 0, 1, 0); 14 | 15 | solid p5 = plane (0, 0, 0; -1, 0, 0); 16 | solid p6 = plane (1, 1, 1; 1, 0, 0); 17 | 18 | 19 | solid cube = p1 and p2 and p3 and p4 and p5 and p6; 20 | 21 | solid cyls = 22 | cylinder (0.5, 0.5, 0; 0.5, 0.5, 1; 0.3) 23 | or cylinder (0, 0.5, 0.2; 1, 0.5, 0.2; 0.1); 24 | solid matrix = cube and not cyls; 25 | solid inner = cube and cyls; 26 | 27 | tlo matrix -transparent; 28 | tlo inner -col=[1,0,0]; 29 | 30 | identify periodic p1 p2; 31 | identify periodic p3 p4; 32 | identify periodic p5 p6; 33 | 34 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/visualization/visual.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_VISUAL 2 | #define FILE_VISUAL 3 | 4 | /* *************************************************************************/ 5 | /* File: visual.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 02. Dec. 01 */ 8 | /* *************************************************************************/ 9 | 10 | /* 11 | 12 | Visualization 13 | 14 | */ 15 | 16 | #ifdef PARALLEL 17 | #define PARALLELGL 18 | #endif 19 | 20 | #include "../include/incopengl.hpp" 21 | 22 | #include "vispar.hpp" 23 | #include "soldata.hpp" 24 | #include "mvdraw.hpp" 25 | 26 | #include 27 | #include "vssolution.hpp" 28 | #include "meshdoc.hpp" 29 | 30 | #endif 31 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/doc/header.js: -------------------------------------------------------------------------------- 1 | function displayHeader(pageTitle) 2 | { 3 | document.write("

" + pageTitle + "

"); 4 | } 5 | 6 | function NavigationBar() 7 | { 8 | document.write(""); 9 | document.write(" "); 10 | document.write(" "); 11 | document.write(" "); 12 | document.write(" "); 13 | document.write(" "); 14 | document.write(" "); 15 | document.write(" "); 16 | document.write(" "); 17 | document.write(" "); 18 | document.write("
IndexIntroDownload/InstallUsing ToglTcl APIC APIFAQ
"); 19 | document.write("
"); 20 | } 21 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/matrix.geo: -------------------------------------------------------------------------------- 1 | # 2 | # a matrix with holes 3 | # 4 | algebraic3d 5 | 6 | solid holes = sphere (0.3, 0.4, 0.4; 0.1) 7 | or sphere (0.7, 0.2, 0.8; 0.15) 8 | or sphere (0.8, 0.5, 0.4; 0.11) 9 | or sphere (0.6, 0.2, 0.8; 0.13) 10 | or sphere (0.4, 0.3, 0.6; 0.14) 11 | or sphere (0.6, 0.3, 0.4; 0.16) 12 | or sphere (0.2, 0.8, 0.6; 0.17) 13 | or sphere (0.4, 0.6, 0.5; 0.2); 14 | 15 | solid cube = plane (0, 0, 0; 0, 0, -1) 16 | and plane (0, 0, 0; 0, -1, 0) 17 | and plane (0, 0, 0; -1, 0, 0) 18 | and plane (1, 1, 1; 0, 0, 1) 19 | and plane (1, 1, 1; 0, 1, 0) 20 | and plane (1, 1, 1; 1, 0, 0); 21 | 22 | solid rest = cube and not holes; 23 | 24 | # two sub-domains 25 | 26 | tlo holes -col=[1,0,0]; 27 | tlo rest -col=[0,0,1] -transparent; 28 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/ngexception.cpp: -------------------------------------------------------------------------------- 1 | /**************************************************************************/ 2 | /* File: ngexception.cpp */ 3 | /* Author: Joachim Schoeberl */ 4 | /* Date: 16. Jan. 02 */ 5 | /**************************************************************************/ 6 | 7 | #include 8 | 9 | namespace netgen 10 | { 11 | //using namespace netgen; 12 | 13 | 14 | 15 | NgException :: NgException (const string & s) 16 | : what(s) 17 | { 18 | ; 19 | } 20 | 21 | 22 | NgException :: ~NgException () 23 | { 24 | ; 25 | } 26 | 27 | /// append string to description 28 | void NgException :: Append (const string & s) 29 | { 30 | what += s; 31 | } 32 | 33 | } 34 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/linalg/linalg.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_LINALG 2 | #define FILE_LINALG 3 | 4 | /* *************************************************************************/ 5 | /* File: linalg.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 01. Oct. 94 */ 8 | /* *************************************************************************/ 9 | 10 | /* 11 | 12 | Data types for basic linear algebra 13 | 14 | The basic concepts include the data types 15 | 16 | Vector 17 | SparseMatrix 18 | DenseMatrix 19 | 20 | */ 21 | 22 | 23 | #include "../include/myadt.hpp" 24 | namespace netgen 25 | { 26 | #include "vector.hpp" 27 | #include "densemat.hpp" 28 | #include "polynomial.hpp" 29 | } 30 | #endif 31 | 32 | 33 | -------------------------------------------------------------------------------- /netgen-6.1-src/python/gengeom_curve.py: -------------------------------------------------------------------------------- 1 | 2 | geom = SplineGeometry() 3 | 4 | # Define Points 5 | pi1 = geom.AppendPoint(0,0) 6 | pi2 = geom.AppendPoint(1,0) 7 | pi3 = geom.AppendPoint(1,0.5) 8 | pi4 = geom.AppendPoint(1,1) 9 | pi5 = geom.AppendPoint(0.5,1) 10 | pi6 = geom.AppendPoint(0,1) 11 | 12 | # Define Segments 13 | geom.Append(Line(pi1,pi2)) 14 | geom.Append(Line(pi2,pi3)) 15 | geom.Append(Spline3(pi3,pi4,pi5)) 16 | geom.Append(Line(pi5,pi6)) 17 | geom.Append(Line(pi6,pi1)) 18 | 19 | # Plot Geometry 20 | geom.Plot() 21 | 22 | # Plot Point Index 23 | geom.ShowPoints() 24 | # Plot Domain Numbers 25 | geom.ShowDomains() 26 | 27 | # Hide point indices and domain numbers 28 | geom.ShowPoints(False) 29 | geom.ShowDomains(False) 30 | 31 | # Set Meshing Parameters 32 | mparam = MeshingParameters() 33 | mparam.maxh = 0.1 34 | 35 | mesh = geom.GenerateMesh(mparam) -------------------------------------------------------------------------------- /netgen-6.1-src/ng/netgen.ocf: -------------------------------------------------------------------------------- 1 | # Netgen Mesher 2 | # Boundary Condition Colour Profile 3 | # 4 | # Name: netgen.ocf 5 | # 6 | # Description: Netgen default colour 7 | # profile file for colour based automatic 8 | # assignment of boundary condition numbers 9 | # 10 | # Format: 11 | # [boundary_colours] (mandatory keyword) 12 | # 13 | # 14 | # 15 | # .... 16 | # .... 17 | # NOTE: 18 | # * Currently, the default Boundary 19 | # Condition number assigned to faces without 20 | # any colour defined is "1" 21 | # * Boundary Condition number "0" is invalid, 22 | # and should not be used 23 | 24 | boundary_colours 25 | 7 26 | 2 0.0000 0.0000 0.0000 27 | 3 1.0000 0.0000 0.0000 28 | 4 0.0000 0.0000 1.0000 29 | 5 1.0000 1.0000 0.0000 30 | 6 0.0000 1.0000 1.0000 31 | 7 1.0000 0.0000 1.0000 32 | 8 1.0000 1.0000 1.0000 33 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/stlgeom.tcl: -------------------------------------------------------------------------------- 1 | #if { [catch { load libstlvis[info sharedlibextension] Ng_STL } result ] } { 2 | # puts "cannot load stl" 3 | # puts "error: $result" 4 | #} 5 | 6 | 7 | .ngmenu.geometry add separator 8 | 9 | .ngmenu.geometry add command -label "STL Doctor..." \ 10 | -command { stldoctordialog; } 11 | 12 | .ngmenu.geometry add command -label "STL Info" \ 13 | -command { 14 | set notriangles 0 15 | set minx 0 16 | set maxx 0 17 | set miny 0 18 | set maxy 0 19 | set minz 0 20 | set maxz 0 21 | set trigscons 0 22 | Ng_STLInfo notriangles minx maxx miny maxy minz maxz trigscons 23 | set msgtext "NO STL-Triangles : $notriangles\nGeometry:\nX = $minx - $maxx\nY = $miny - $maxy\nZ = $minz - $maxz\nConsistency Check = $trigscons\n" 24 | set msgtext "$msgtext Status: [Ng_STLInfo status]" 25 | tk_messageBox -title "STL Info" -message $msgtext -type ok 26 | } 27 | 28 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/gprim/gprim.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_GPRIM 2 | #define FILE_GPRIM 3 | 4 | /* *************************************************************************/ 5 | /* File: gprim.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 14. Aug. 97 */ 8 | /* *************************************************************************/ 9 | 10 | 11 | #include 12 | #include 13 | 14 | 15 | 16 | 17 | #include "geomobjects.hpp" 18 | #include "geomops.hpp" 19 | #include "geomfuncs.hpp" 20 | 21 | #include "geom2d.hpp" 22 | #include "geom3d.hpp" 23 | 24 | #include "geomtest3d.hpp" 25 | #include "transform3d.hpp" 26 | 27 | #include "adtree.hpp" 28 | 29 | #include "spline.hpp" 30 | #include "splinegeometry.hpp" 31 | 32 | 33 | #endif 34 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/square.in2d: -------------------------------------------------------------------------------- 1 | # keyword for 2D geometry, version 2 2 | splinecurves2dv2 3 | 4 | 5 | # a global grading factor 6 | 2 7 | 8 | 9 | # the points (point number, x and y coordinates) 10 | points 11 | 1 0 0 -maxh=0.01 12 | 2 1 0 13 | 3 1 1 14 | 4 0 1 15 | 16 | 17 | # boundary curves consisting of 18 | # dl dr np p1 p1 flaglist 19 | # with 20 | # dl ... sub-domain nr on left side 21 | # dr ... sub-domain nr on right side 22 | # np ... curve is given by 2 (or 3) points 23 | # p1, p2 ... points defining the curve 24 | # flagslist 25 | segments 26 | 1 0 2 1 2 -bc=1 -maxh=0.1 27 | 1 0 2 2 3 -bc=1 28 | 1 0 2 3 4 -bc=1 29 | 1 0 2 4 1 -bc=2 30 | 31 | 32 | materials 33 | 1 domain1 -maxh=0.3 34 | 35 | 36 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/interface/Makefile.am: -------------------------------------------------------------------------------- 1 | noinst_HEADERS = writeuser.hpp 2 | 3 | AM_CPPFLAGS = -I$(top_srcdir)/libsrc/include -I$(top_srcdir)/libsrc/interface $(MPI_INCLUDES) $(TCL_INCLUDES) -DOPENGL 4 | METASOURCES = AUTO 5 | lib_LTLIBRARIES = libinterface.la 6 | libinterface_la_SOURCES = nginterface.cpp nginterface_v2.cpp \ 7 | read_fnf_mesh.cpp readtetmesh.cpp readuser.cpp writeabaqus.cpp writediffpack.cpp \ 8 | writedolfin.cpp writeelmer.cpp writefeap.cpp writefluent.cpp writegmsh.cpp writejcm.cpp \ 9 | writepermas.cpp writetecplot.cpp writetet.cpp writetochnog.cpp writeuser.cpp \ 10 | wuchemnitz.cpp writegmsh2.cpp writeOpenFOAM15x.cpp 11 | 12 | 13 | libinterface_la_LIBADD = $(top_builddir)/libsrc/meshing/libmesh.la \ 14 | $(top_builddir)/libsrc/visualization/libvisual.la \ 15 | $(top_builddir)/libsrc/csg/libcsg.la \ 16 | $(top_builddir)/libsrc/geom2d/libgeom2d.la 17 | 18 | # libinterface_la_LDFLAGS = -rdynamic 19 | -------------------------------------------------------------------------------- /netgen-6.2-dev/meta.yaml: -------------------------------------------------------------------------------- 1 | package: 2 | name: netgen 3 | version: 6.2.dev 4 | 5 | source: 6 | git_url: https://github.com/live-clones/netgen.git 7 | patches: 8 | - netgen-patch.patch 9 | - remove_warnings.patch 10 | - fix_mystdlib_h.patch 11 | - fix_occvis.patch [osx] 12 | 13 | build: 14 | detect_binary_files_with_prefix: True 15 | number: 1 16 | features: 17 | - vc9 [win and py27] 18 | - vc10 [win and py34] 19 | - vc14 [win and py35] 20 | 21 | requirements: 22 | build: 23 | - patch [win] 24 | - ninja 25 | - cmake 26 | - oce ==0.17.2 27 | - gcc-5 ==5.4.0 [linux or osx] 28 | - binutils ==2.26 [linux] 29 | 30 | run: 31 | - oce ==0.17.2 32 | 33 | about: 34 | home: https://sourceforge.net/projects/netgen-mesher/ 35 | license: LGPLv2 36 | summary: NETGEN is an automatic 3d tetrahedral mesh generator. 37 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/cubeandring.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | 3 | curve2d testcurve=(8; 4 | -0.5,1; 5 | -0.55,1.5; 6 | # -0.275,1.775; 7 | -0.5,2; 8 | 0,2.05; 9 | 0.5,2; 10 | 0.55,1.5; 11 | 0.5,1; 12 | 0,0.95; 13 | 4; 14 | 3,8,1,2; 15 | 3,2,3,4; 16 | 3,4,5,6; 17 | 3,6,7,8); 18 | 19 | #curve2d testcurve=(8; 20 | # -0.5,1; 21 | # -0.55,1.5; 22 | # -0.5,2; 23 | # 0,2.05; 24 | # 0.5,2; 25 | # 0.55,1.5; 26 | # 0.5,1; 27 | # 0,0.95; 28 | # 4; 29 | # 3,8,1,2; 30 | # 3,2,3,4; 31 | # 3,4,5,6; 32 | # 3,6,7,8); 33 | 34 | curve2d testcurve1=(4; 35 | -0.55,1.5; 36 | 0,2.05; 37 | 0.55,1.5; 38 | 0,0.95; 39 | 4; 40 | 2,1,2; 41 | 2,2,3; 42 | 2,3,4; 43 | 2,4,1); 44 | 45 | 46 | solid mytorus = revolution(0,0,0.5;1,0,0.5;testcurve); 47 | #solid mytorus = revolution(0,0,0.5;1,0,0.5;testcurve1); 48 | 49 | solid bbb = orthobrick(-4,-4,-4;4,4,0.1); 50 | 51 | solid brickandring = mytorus or bbb; 52 | 53 | 54 | tlo brickandring; 55 | 56 | -------------------------------------------------------------------------------- /netgen-6.1/fix_occvis.patch: -------------------------------------------------------------------------------- 1 | diff --git a/libsrc/occ/CMakeLists.txt b/libsrc/occ/CMakeLists.txt 2 | index 8f7f7c3..fabb8d4 100644 3 | --- a/libsrc/occ/CMakeLists.txt 4 | +++ b/libsrc/occ/CMakeLists.txt 5 | @@ -5,12 +5,17 @@ add_library(occ ${NG_LIB_TYPE} 6 | occconstruction.cpp occgenmesh.cpp occgeom.cpp occmeshsurf.cpp 7 | ) 8 | 9 | -add_library(occvis ${NG_LIB_TYPE} vsocc.cpp) 10 | +if(USE_GUI) 11 | + add_library(occvis ${NG_LIB_TYPE} vsocc.cpp) 12 | +endif(USE_GUI) 13 | 14 | if(NOT WIN32) 15 | target_link_libraries( occ ${OCC_LIBRARIES} ${PYTHON_LIBRARIES}) 16 | - target_link_libraries( occvis occ ) 17 | - install( TARGETS occ occvis ${ng_install_dir}) 18 | + if(USE_GUI) 19 | + target_link_libraries( occvis occ ) 20 | + install( TARGETS occvis ${ng_install_dir}) 21 | + endif(USE_GUI) 22 | + install( TARGETS occ ${ng_install_dir}) 23 | endif(NOT WIN32) 24 | 25 | install(FILES 26 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/parthreads.cpp: -------------------------------------------------------------------------------- 1 | /**************************************************************************/ 2 | /* File: parthreads.cpp */ 3 | /* Author: Joachim Schoeberl */ 4 | /* Date: 01. Jun. 95 */ 5 | /**************************************************************************/ 6 | 7 | 8 | #include 9 | #include 10 | 11 | /* 12 | 13 | namespace netgen 14 | { 15 | using namespace netgen; 16 | 17 | #ifdef WIN32 18 | 19 | NgLock :: NgLock (NgMutex & mut) 20 | : sl(&mut.cs) 21 | { 22 | ; 23 | } 24 | 25 | void NgLock :: Lock () 26 | { 27 | sl.Lock(); 28 | } 29 | void NgLock :: UnLock () 30 | { 31 | sl.Unlock(); 32 | } 33 | 34 | 35 | #else 36 | 37 | #endif 38 | } 39 | 40 | */ 41 | -------------------------------------------------------------------------------- /netgen-6.2-dev/fix_occvis.patch: -------------------------------------------------------------------------------- 1 | diff --git a/libsrc/occ/CMakeLists.txt b/libsrc/occ/CMakeLists.txt 2 | index 8f7f7c3..fabb8d4 100644 3 | --- a/libsrc/occ/CMakeLists.txt 4 | +++ b/libsrc/occ/CMakeLists.txt 5 | @@ -5,12 +5,17 @@ add_library(occ ${NG_LIB_TYPE} 6 | occconstruction.cpp occgenmesh.cpp occgeom.cpp occmeshsurf.cpp 7 | ) 8 | 9 | -add_library(occvis ${NG_LIB_TYPE} vsocc.cpp) 10 | +if(USE_GUI) 11 | + add_library(occvis ${NG_LIB_TYPE} vsocc.cpp) 12 | +endif(USE_GUI) 13 | 14 | if(NOT WIN32) 15 | target_link_libraries( occ ${OCC_LIBRARIES} ${PYTHON_LIBRARIES}) 16 | - target_link_libraries( occvis occ ) 17 | - install( TARGETS occ occvis ${ng_install_dir}) 18 | + if(USE_GUI) 19 | + target_link_libraries( occvis occ ) 20 | + install( TARGETS occvis ${ng_install_dir}) 21 | + endif(USE_GUI) 22 | + install( TARGETS occ ${ng_install_dir}) 23 | endif(NOT WIN32) 24 | 25 | install(FILES 26 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/tclconfig/README.txt: -------------------------------------------------------------------------------- 1 | These files comprise the basic building blocks for a Tcl Extension 2 | Architecture (TEA) extension. For more information on TEA see: 3 | 4 | http://www.tcl.tk/doc/tea/ 5 | 6 | This package is part of the Tcl project at SourceForge, and latest 7 | sources should be available there: 8 | 9 | http://tcl.sourceforge.net/ 10 | 11 | This package is a freely available open source package. You can do 12 | virtually anything you like with it, such as modifying it, redistributing 13 | it, and selling it either in whole or in part. 14 | 15 | CONTENTS 16 | ======== 17 | The following is a short description of the files you will find in 18 | the sample extension. 19 | 20 | README.txt This file 21 | 22 | install-sh Program used for copying binaries and script files 23 | to their install locations. 24 | 25 | tcl.m4 Collection of Tcl autoconf macros. Included by a package's 26 | aclocal.m4 to define TEA_* macros. 27 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/geom2d/vsgeom2d.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_VSGEOM2D 2 | #define FILE_VSGEOM2D 3 | 4 | /**************************************************************************/ 5 | /* File: vsgeom2d.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 05. Jan. 2011 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | class DLL_HEADER VisualSceneGeometry2d : public VisualScene 14 | { 15 | const class SplineGeometry2d * geometry2d; 16 | public: 17 | VisualSceneGeometry2d (); 18 | virtual ~VisualSceneGeometry2d (); 19 | void SetGeometry (const class SplineGeometry2d * ageometry2d) { geometry2d = ageometry2d; } 20 | virtual void BuildScene (int zoomall = 0); 21 | virtual void DrawScene (); 22 | }; 23 | 24 | } 25 | 26 | 27 | 28 | #endif 29 | -------------------------------------------------------------------------------- /netgen-6.1-src/windows/resource.h: -------------------------------------------------------------------------------- 1 | //{{NO_DEPENDENCIES}} 2 | // Microsoft Visual C++ generated include file. 3 | // Used by netgen.rc and nglib.rc 4 | // 5 | #define _USE_DECLSPECS_FOR_SAL 0 6 | #define _USE_ATTRIBUTES_FOR_SAL 0 7 | #define VS_VERSION_INFO 1 8 | #define VFFF_ISSHAREDFILE 0x0001 9 | #define VFF_CURNEDEST 0x0001 10 | #define VIFF_FORCEINSTALL 0x0001 11 | #define VFF_FILEINUSE 0x0002 12 | #define VIFF_DONTDELETEOLD 0x0002 13 | #define VFF_BUFFTOOSMALL 0x0004 14 | #define VS_USER_DEFINED 100 15 | 16 | // Next default values for new objects 17 | // 18 | #ifdef APSTUDIO_INVOKED 19 | #ifndef APSTUDIO_READONLY_SYMBOLS 20 | #define _APS_NEXT_RESOURCE_VALUE 101 21 | #define _APS_NEXT_COMMAND_VALUE 40001 22 | #define _APS_NEXT_CONTROL_VALUE 1000 23 | #define _APS_NEXT_SYMED_VALUE 101 24 | #endif 25 | #endif 26 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/visualization/meshdoc.hpp: -------------------------------------------------------------------------------- 1 | namespace netgen 2 | 3 | { 4 | 5 | class VisualSceneMeshDoctor : public VisualScene 6 | { 7 | int filledlist; 8 | int outlinelist; 9 | int edgelist; 10 | 11 | int selelement, locpi; 12 | int selpoint, selpoint2; 13 | 14 | // for edgemarking: 15 | Array edgedist; 16 | int markedgedist; 17 | 18 | 19 | public: 20 | DLL_HEADER VisualSceneMeshDoctor (); 21 | DLL_HEADER virtual ~VisualSceneMeshDoctor (); 22 | 23 | DLL_HEADER virtual void BuildScene (int zoomall = 0); 24 | DLL_HEADER virtual void DrawScene (); 25 | DLL_HEADER virtual void MouseDblClick (int px, int py); 26 | 27 | DLL_HEADER void SetMarkEdgeDist (int dist); 28 | DLL_HEADER void ClickElement (int elnr); 29 | DLL_HEADER void UpdateTables (); 30 | DLL_HEADER int IsSegmentMarked (int segnr) const; 31 | }; 32 | 33 | class MeshDoctorParameters 34 | { 35 | public: 36 | int active; 37 | }; 38 | 39 | 40 | DLL_HEADER extern MeshDoctorParameters meshdoctor; 41 | 42 | } 43 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/vscsg.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_VSCSG 2 | #define FILE_VSCSG 3 | 4 | /**************************************************************************/ 5 | /* File: vscsg.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 05. Jan. 2011 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | class DLL_HEADER VisualSceneGeometry : public VisualScene 14 | { 15 | class CSGeometry * geometry; 16 | Array trilists; 17 | int selsurf; 18 | public: 19 | VisualSceneGeometry (); 20 | virtual ~VisualSceneGeometry (); 21 | 22 | void SetGeometry (class CSGeometry * ageometry) { geometry = ageometry; } 23 | virtual void SelectSurface (int aselsurf); 24 | virtual void BuildScene (int zoomall = 0); 25 | virtual void DrawScene (); 26 | }; 27 | 28 | 29 | 30 | } 31 | 32 | 33 | 34 | #endif 35 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/ngexception.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_NGEXCEPTION 2 | #define FILE_NGEXCEPTION 3 | 4 | /**************************************************************************/ 5 | /* File: ngexception.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 16. Jan. 2002 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | /// Base class for all ng exceptions 14 | class NgException 15 | { 16 | /// verbal description of exception 17 | string what; 18 | public: 19 | /// 20 | DLL_HEADER NgException (const string & s); 21 | /// 22 | DLL_HEADER virtual ~NgException (); 23 | 24 | /// append string to description 25 | DLL_HEADER void Append (const string & s); 26 | // void Append (const char * s); 27 | 28 | /// verbal description of exception 29 | const string & What() const { return what; } 30 | }; 31 | } 32 | 33 | #endif 34 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/vsocc.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_VSOCC 2 | #define FILE_VSOCC 3 | 4 | /**************************************************************************/ 5 | /* File: vsocc.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 05. Jan. 2011 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | class VisualSceneOCCGeometry : public VisualScene 14 | { 15 | Array trilists; 16 | Array linelists; 17 | int selsurf; 18 | class OCCGeometry * occgeometry; 19 | public: 20 | VisualSceneOCCGeometry (); 21 | virtual ~VisualSceneOCCGeometry (); 22 | void SetGeometry (class OCCGeometry * ageom) { occgeometry = ageom; } 23 | 24 | virtual void BuildScene (int zoomall = 0); 25 | virtual void DrawScene (); 26 | virtual void MouseDblClick (int px, int py); 27 | }; 28 | 29 | 30 | 31 | } 32 | 33 | #endif 34 | -------------------------------------------------------------------------------- /netgen-6.2-dev/netgen-patch.patch: -------------------------------------------------------------------------------- 1 | diff --git a/nglib/CMakeLists.txt b/nglib/CMakeLists.txt 2 | index eb18a63..6ddef05 100644 3 | --- a/nglib/CMakeLists.txt 4 | +++ b/nglib/CMakeLists.txt 5 | @@ -3,9 +3,9 @@ add_definitions(-DNGLIB_EXPORTS) 6 | if(WIN32) 7 | set(nglib_objects 8 | $ 9 | - $ 10 | + #$ 11 | $ 12 | - $ 13 | + #$ 14 | $ 15 | $ 16 | $ 17 | @@ -15,7 +15,7 @@ if(WIN32) 18 | $ 19 | 20 | $ 21 | - $ 22 | + #$ 23 | $ 24 | ) 25 | endif(WIN32) 26 | @@ -51,3 +51,4 @@ endif(USE_PYTHON) 27 | # endif(NOT WIN32) 28 | 29 | install(TARGETS nglib ${ng_install_dir}) 30 | +install(FILES nglib.h DESTINATION ${INCDIR} COMPONENT netgen_devel) 31 | -------------------------------------------------------------------------------- /netgen-6.1-src/windows/Netgen_Installer/netgen_installer.dat: -------------------------------------------------------------------------------- 1 | # ------------------------------------------------------------ 2 | # Common Data File for the automated compile batch routines 3 | # used to generate the Netgen Mesher Windows installers 4 | # 5 | # Modify this file as required 6 | # 7 | # Author: Philippose Rajan 8 | # Creation Date: 22 March 2010 9 | # ------------------------------------------------------------ 10 | # 11 | # History 12 | # ------- 13 | # 4.9.13-RC : 17-18/04/2010 14 | # 4.9.13 : 21/05/2010 15 | # 16 | # ------------------------------------------------------------ 17 | 18 | 19 | # Version of Netgen to be packaged by the installer 20 | VERSION=4.9.13 21 | 22 | # Root location of the Netgen Sources and binaries 23 | # for the various flavours 24 | NETGEN=D:\netgenWin\05_Netgen_Main 25 | 26 | # Root location of the NGSolve Sources and binaries 27 | # for the various flavours 28 | NGSOLVE=D:\netgenWin\07_NGSolve_Main 29 | 30 | # Root location of the OpenCascade DLLs which also 31 | # need to be packged into the installer 32 | OCC=D:\occ6.3.0 33 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/autoptr.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_AUTOPTR 2 | #define FILE_AUTOPTR 3 | 4 | /**************************************************************************/ 5 | /* File: autoptr.hpp */ 6 | /* Author: STL, Joachim Schoeberl */ 7 | /* Date: 29. Dec. 02 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | /* 14 | template 15 | class AutoPtr 16 | { 17 | private: 18 | T * ptr; 19 | public: 20 | typedef T* pT; 21 | explicit AutoPtr (T * p = 0) { ptr = p; } 22 | ~AutoPtr () { delete ptr; } 23 | 24 | T & operator*() const { return *ptr; } 25 | T* operator->() const { return ptr; } 26 | T *& Ptr() { return ptr; } 27 | T * Ptr() const { return ptr; } 28 | void Reset(T * p = 0) { if (p != ptr) { delete ptr; ptr = p; } } 29 | operator bool () { return ptr != 0; } 30 | private: 31 | AutoPtr (AutoPtr &) { ; } 32 | AutoPtr & operator= (AutoPtr &) { ; } 33 | }; 34 | */ 35 | } 36 | 37 | #endif 38 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Makefile.am: -------------------------------------------------------------------------------- 1 | noinst_HEADERS = occgeom.hpp occmeshsurf.hpp \ 2 | Partition_Inter2d.hxx Partition_Loop2d.hxx Partition_Loop.hxx \ 3 | Partition_Inter3d.hxx Partition_Loop3d.hxx Partition_Spliter.hxx \ 4 | Partition_Inter2d.ixx Partition_Loop2d.ixx Partition_Loop.ixx \ 5 | Partition_Inter3d.ixx Partition_Loop3d.ixx Partition_Spliter.ixx \ 6 | Partition_Inter2d.jxx Partition_Loop2d.jxx Partition_Loop.jxx \ 7 | Partition_Inter3d.jxx Partition_Loop3d.jxx Partition_Spliter.jxx \ 8 | utilities.h vsocc.hpp 9 | 10 | 11 | AM_CPPFLAGS = -I$(top_srcdir)/libsrc/include $(OCCFLAGS) $(TCL_INCLUDES) 12 | 13 | # $(OCC_INC_FLAG) 14 | 15 | METASOURCES = AUTO 16 | 17 | lib_LTLIBRARIES = libocc.la 18 | 19 | if NGGUI 20 | lib_LTLIBRARIES += liboccvis.la 21 | endif 22 | 23 | 24 | libocc_la_SOURCES = Partition_Inter2d.cxx Partition_Inter3d.cxx \ 25 | Partition_Loop.cxx Partition_Loop2d.cxx Partition_Loop3d.cxx Partition_Spliter.cxx \ 26 | occconstruction.cpp occgenmesh.cpp occgeom.cpp occmeshsurf.cpp 27 | 28 | libocc_la_LIBADD = $(OCCLIBS) 29 | 30 | liboccvis_la_SOURCES = occpkg.cpp vsocc.cpp 31 | liboccvis_la_LIBADD = libocc.la 32 | 33 | 34 | -------------------------------------------------------------------------------- /netgen-6.1/netgen-patch.patch: -------------------------------------------------------------------------------- 1 | diff --git a/nglib/CMakeLists.txt b/nglib/CMakeLists.txt 2 | index f172f7e..92b3b58 100644 3 | --- a/nglib/CMakeLists.txt 4 | +++ b/nglib/CMakeLists.txt 5 | @@ -3,9 +3,9 @@ add_definitions(-DNGLIB_EXPORTS) 6 | if(WIN32) 7 | set(nglib_objects 8 | $ 9 | - $ 10 | + #$ 11 | $ 12 | - $ 13 | + #$ 14 | $ 15 | $ 16 | $ 17 | @@ -15,7 +15,7 @@ if(WIN32) 18 | $ 19 | 20 | $ 21 | - $ 22 | + #$ 23 | $ 24 | ) 25 | endif(WIN32) 26 | @@ -47,4 +47,4 @@ endif(USE_PYTHON) 27 | # install(TARGETS nglib ng_vol ng_stl ${ng_install_dir}) 28 | # endif(NOT WIN32) 29 | 30 | -install(TARGETS nglib ${ng_install_dir}) 31 | +install(TARGETS nglib DESTINATION ${ng_install_dir}) 32 | -------------------------------------------------------------------------------- /netgen-6.1-src/cmake_modules/cmake_uninstall.cmake.in: -------------------------------------------------------------------------------- 1 | if(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") 2 | message(FATAL_ERROR "Cannot find install manifest: @CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") 3 | endif(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") 4 | 5 | file(READ "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt" files) 6 | string(REGEX REPLACE "\n" ";" files "${files}") 7 | foreach(file ${files}) 8 | message(STATUS "Uninstalling $ENV{DESTDIR}${file}") 9 | if(IS_SYMLINK "$ENV{DESTDIR}${file}" OR EXISTS "$ENV{DESTDIR}${file}") 10 | exec_program( 11 | "@CMAKE_COMMAND@" ARGS "-E remove \"$ENV{DESTDIR}${file}\"" 12 | OUTPUT_VARIABLE rm_out 13 | RETURN_VALUE rm_retval 14 | ) 15 | if(NOT "${rm_retval}" STREQUAL 0) 16 | message(FATAL_ERROR "Problem when removing $ENV{DESTDIR}${file}") 17 | endif(NOT "${rm_retval}" STREQUAL 0) 18 | else(IS_SYMLINK "$ENV{DESTDIR}${file}" OR EXISTS "$ENV{DESTDIR}${file}") 19 | message(STATUS "File $ENV{DESTDIR}${file} does not exist.") 20 | endif(IS_SYMLINK "$ENV{DESTDIR}${file}" OR EXISTS "$ENV{DESTDIR}${file}") 21 | endforeach(file) 22 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/seti.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_SETI 2 | #define FILE_SETI 3 | 4 | 5 | /**************************************************************************/ 6 | /* File: seti.hh */ 7 | /* Author: Joachim Schoeberl */ 8 | /* Date: 20. Mar. 98 */ 9 | /**************************************************************************/ 10 | 11 | namespace netgen 12 | { 13 | 14 | /** 15 | Set of Integers 16 | */ 17 | class IndexSet 18 | { 19 | Array set; 20 | BitArray flags; 21 | public: 22 | IndexSet (int maxind); 23 | 24 | ~IndexSet (); 25 | /// increase range to maxind 26 | void SetMaxIndex (int maxind); 27 | int IsIn (int ind) const 28 | { 29 | return flags.Test (ind); 30 | } 31 | 32 | void Add (int ind) 33 | { 34 | if (!flags.Test(ind)) 35 | { 36 | set.Append (ind); 37 | flags.Set (ind); 38 | } 39 | } 40 | 41 | void Del (int ind); 42 | void Clear (); 43 | 44 | const Array & GetArray() { return set; } 45 | }; 46 | 47 | } 48 | 49 | #endif 50 | 51 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_definitions(-DNGINTERFACE_EXPORTS) 2 | add_library(csg ${NG_LIB_TYPE} 3 | algprim.cpp brick.cpp 4 | bspline2d.cpp csgeom.cpp csgparser.cpp curve2d.cpp edgeflw.cpp 5 | explicitcurve2d.cpp extrusion.cpp gencyl.cpp genmesh.cpp identify.cpp 6 | manifold.cpp meshsurf.cpp polyhedra.cpp revolution.cpp singularref.cpp 7 | solid.cpp specpoin.cpp spline3d.cpp surface.cpp triapprox.cpp zrefine.cpp 8 | python_csg.cpp 9 | ) 10 | if(APPLE) 11 | set_target_properties( csg PROPERTIES SUFFIX ".so") 12 | endif(APPLE) 13 | 14 | if(NOT WIN32) 15 | target_link_libraries(csg mesh ${PYTHON_LIBS}) 16 | target_link_libraries(csg ${PYTHON_LIBS}) 17 | install( TARGETS csg ${ng_install_dir}) 18 | endif(NOT WIN32) 19 | 20 | 21 | if(USE_GUI) 22 | add_library(csgvis ${NG_LIB_TYPE} vscsg.cpp ) 23 | if(NOT WIN32) 24 | target_link_libraries(csgvis csg visual) 25 | if(APPLE) 26 | set_target_properties( csgvis PROPERTIES SUFFIX ".so") 27 | endif(APPLE) 28 | install( TARGETS csgvis ${ng_install_dir}) 29 | endif(NOT WIN32) 30 | endif(USE_GUI) 31 | 32 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/overlay.tcl: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # the next line restarts using tclsh \ 3 | exec tclsh "$0" "$@" 4 | 5 | # $Id: overlay.tcl,v 1.7 2007/08/03 16:48:50 gregcouch Exp $ 6 | 7 | # Togl - a Tk OpenGL widget 8 | # Copyright (C) 1996 Brian Paul and Ben Bederson 9 | # Copyright (C) 2006-2007 Greg Couch 10 | # See the LICENSE file for copyright details. 11 | 12 | 13 | # A Tk/OpenGL widget demo using an overlay. 14 | 15 | # add parent directory to path to find Togl's pkgIndex in current directory 16 | if { [file exists pkgIndex.tcl] } { 17 | set auto_path [linsert $auto_path 0 ..] 18 | } 19 | # following load also loads Tk and Togl packages 20 | load [file dirname [info script]]/overlay[info sharedlibextension] 21 | 22 | proc setup {} { 23 | wm title . "Overlay demo" 24 | 25 | togl .win -width 200 -height 200 -rgba true -double false -overlay true -create create_cb -reshape reshape_cb -display display_cb -overlaydisplay overlay_display_cb 26 | button .btn -text Quit -command exit 27 | 28 | pack .win -expand true -fill both 29 | pack .btn -expand true -fill both 30 | } 31 | 32 | 33 | # Execution starts here! 34 | # Execution starts here! 35 | if { [info script] == $argv0 } { 36 | setup 37 | } 38 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Loop.ixx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, 4 | // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 5 | // 6 | // This library is free software; you can redistribute it and/or 7 | // modify it under the terms of the GNU Lesser General Public 8 | // License as published by the Free Software Foundation; either 9 | // version 2.1 of the License. 10 | // 11 | // This library is distributed in the hope that it will be useful, 12 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | // Lesser General Public License for more details. 15 | // 16 | // You should have received a copy of the GNU Lesser General Public 17 | // License along with this library; if not, write to the Free Software 18 | // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | // 20 | // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 21 | // 22 | // 23 | // 24 | // File : Partition_Loop.ixx 25 | // Module : GEOM 26 | 27 | #include "Partition_Loop.jxx" 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Inter3d.ixx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, 4 | // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 5 | // 6 | // This library is free software; you can redistribute it and/or 7 | // modify it under the terms of the GNU Lesser General Public 8 | // License as published by the Free Software Foundation; either 9 | // version 2.1 of the License. 10 | // 11 | // This library is distributed in the hope that it will be useful, 12 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | // Lesser General Public License for more details. 15 | // 16 | // You should have received a copy of the GNU Lesser General Public 17 | // License along with this library; if not, write to the Free Software 18 | // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | // 20 | // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 21 | // 22 | // 23 | // 24 | // File : Partition_Inter3d.ixx 25 | // Module : GEOM 26 | 27 | #include "Partition_Inter3d.jxx" 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Spliter.ixx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, 4 | // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 5 | // 6 | // This library is free software; you can redistribute it and/or 7 | // modify it under the terms of the GNU Lesser General Public 8 | // License as published by the Free Software Foundation; either 9 | // version 2.1 of the License. 10 | // 11 | // This library is distributed in the hope that it will be useful, 12 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | // Lesser General Public License for more details. 15 | // 16 | // You should have received a copy of the GNU Lesser General Public 17 | // License along with this library; if not, write to the Free Software 18 | // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | // 20 | // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 21 | // 22 | // 23 | // 24 | // File : Partition_Spliter.ixx 25 | // Module : GEOM 26 | 27 | #include "Partition_Spliter.jxx" 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/sort.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_SORT 2 | #define FILE_SORT 3 | 4 | /**************************************************************************/ 5 | /* File: sort.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 07. Jan. 00 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | // order(i) is sorted index of element i 14 | extern void Sort (const Array & values, 15 | Array & order); 16 | 17 | extern void QuickSort (const Array & values, 18 | Array & order); 19 | 20 | 21 | 22 | 23 | template 24 | inline void BubbleSort (int size, T * data) 25 | { 26 | T hv; 27 | for (int i = 0; i < size; i++) 28 | for (int j = i+1; j < size; j++) 29 | if (data[i] > data[j]) 30 | { 31 | hv = data[i]; 32 | data[i] = data[j]; 33 | data[j] = hv; 34 | } 35 | } 36 | 37 | template 38 | inline void BubbleSort (Array & data) 39 | { 40 | if(data.Size() > 0) 41 | BubbleSort (data.Size(), &data[data.Begin()]); 42 | } 43 | 44 | } 45 | 46 | #endif 47 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Inter2d.ixx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, 4 | // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 5 | // 6 | // This library is free software; you can redistribute it and/or 7 | // modify it under the terms of the GNU Lesser General Public 8 | // License as published by the Free Software Foundation; either 9 | // version 2.1 of the License. 10 | // 11 | // This library is distributed in the hope that it will be useful, 12 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | // Lesser General Public License for more details. 15 | // 16 | // You should have received a copy of the GNU Lesser General Public 17 | // License along with this library; if not, write to the Free Software 18 | // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | // 20 | // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 21 | // 22 | // 23 | // 24 | // File : Partition_Inter2d.ixx 25 | // Module : GEOM 26 | 27 | #include 28 | #include "Partition_Inter2d.jxx" 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/tkMacOSX.h: -------------------------------------------------------------------------------- 1 | /* This file isn't installed by default */ 2 | /* 3 | * tkMacOSXInt.h -- 4 | * 5 | * Declarations of Macintosh specific exported variables and procedures. 6 | * 7 | * Copyright (c) 1995-1997 Sun Microsystems, Inc. 8 | * Copyright 2001, Apple Computer, Inc. 9 | * 10 | * See the file "license.terms" for information on usage and redistribution 11 | * of this file, and for a DISCLAIMER OF ALL WARRANTIES. 12 | * 13 | * RCS: @(#) $Id: tkMacOSX.h,v 1.1 2005/04/22 02:00:07 gregcouch Exp $ 14 | */ 15 | 16 | #ifndef _TKMAC 17 | #define _TKMAC 18 | 19 | #include 20 | #include "tkInt.h" 21 | 22 | /* 23 | * Structures and function types for handling Netscape-type in process 24 | * embedding where Tk does not control the top-level 25 | */ 26 | 27 | typedef int (Tk_MacOSXEmbedRegisterWinProc) (int winID, Tk_Window window); 28 | typedef GWorldPtr (Tk_MacOSXEmbedGetGrafPortProc) (Tk_Window window); 29 | typedef int (Tk_MacOSXEmbedMakeContainerExistProc) (Tk_Window window); 30 | typedef void (Tk_MacOSXEmbedGetClipProc) (Tk_Window window, RgnHandle rgn); 31 | typedef void (Tk_MacOSXEmbedGetOffsetInParentProc) (Tk_Window window, Point *ulCorner); 32 | 33 | #include "tkPlatDecls.h" 34 | 35 | #endif /* _TKMAC */ 36 | -------------------------------------------------------------------------------- /netgen-6.1-src/py_tutorials/opengl_thread.py: -------------------------------------------------------------------------------- 1 | from netgen.csg import * 2 | import netgen.meshing as meshing 3 | import libvisual 4 | 5 | from OpenGL.GLUT import * 6 | 7 | # import Window class from other file 8 | from opengl_window import Window 9 | 10 | sp1 = Sphere (Pnt(0,0,0), 0.2) 11 | sp2 = Sphere (Pnt(0.5,0,0), 0.2) 12 | 13 | all = sp1+sp2 14 | 15 | geom = CSGeometry() 16 | geom.Add (all) 17 | 18 | 19 | param = meshing.MeshingParameters() 20 | param.maxh = 0.1 21 | m1 = GenerateMesh (geom, param) 22 | 23 | 24 | vis = VS(geom) 25 | 26 | 27 | # window callback functions 28 | def mydraw(): 29 | vis.Draw() 30 | glutSwapBuffers() 31 | 32 | def mymouse(xold, yold, x, y, mode): 33 | MouseMove(vis,xold,yold, x,y, mode) 34 | 35 | 36 | ########################################### 37 | glutInit("mainwin") 38 | 39 | # IMPORTANT: create window in the mainloop - thread! 40 | 41 | ## not working: 42 | #win_geom = Window( name=b"ngs", drawfunc=mydraw, mousefunc=mymouse) 43 | 44 | def runVisualization(): 45 | ## working: 46 | win_geom = Window( name=b"ngs", drawfunc=mydraw, mousefunc=mymouse) 47 | glutMainLoop() 48 | 49 | # create thread 50 | from threading import Thread 51 | thread = Thread(target = runVisualization) 52 | thread.start() 53 | thread.join() 54 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/Makefile.am: -------------------------------------------------------------------------------- 1 | noinst_HEADERS = algprim.hpp csgparser.hpp extrusion.hpp manifold.hpp \ 2 | singularref.hpp surface.hpp brick.hpp curve2d.hpp gencyl.hpp \ 3 | meshsurf.hpp solid.hpp triapprox.hpp csgeom.hpp edgeflw.hpp geoml.hpp \ 4 | polyhedra.hpp specpoin.hpp csg.hpp explicitcurve2d.hpp identify.hpp \ 5 | revolution.hpp spline3d.hpp vscsg.hpp 6 | 7 | 8 | AM_CPPFLAGS = -I$(top_srcdir)/libsrc/include $(TCL_INCLUDES) 9 | METASOURCES = AUTO 10 | 11 | lib_LTLIBRARIES = libcsg.la 12 | 13 | 14 | libcsg_la_SOURCES = algprim.cpp brick.cpp \ 15 | bspline2d.cpp csgeom.cpp csgparser.cpp curve2d.cpp edgeflw.cpp \ 16 | explicitcurve2d.cpp extrusion.cpp gencyl.cpp genmesh.cpp identify.cpp \ 17 | manifold.cpp meshsurf.cpp polyhedra.cpp revolution.cpp singularref.cpp \ 18 | solid.cpp specpoin.cpp spline3d.cpp surface.cpp triapprox.cpp zrefine.cpp \ 19 | python_csg.cpp 20 | 21 | libcsg_la_LIBADD = $(top_builddir)/libsrc/meshing/libmesh.la 22 | 23 | 24 | 25 | if NGGUI 26 | lib_LTLIBRARIES += libcsgvis.la 27 | 28 | libcsgvis_la_SOURCES = csgpkg.cpp 29 | libcsgvis_la_LIBADD = libcsg.la $(top_builddir)/libsrc/visualization/libvisual.la 30 | libcsg_la_SOURCES += vscsg.cpp 31 | libcsg_la_LIBADD += $(top_builddir)/libsrc/visualization/libvisual.la 32 | endif 33 | 34 | 35 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/csg.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_CSG 2 | #define FILE_CSG 3 | 4 | /* *************************************************************************/ 5 | /* File: geoml.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 21. Jun. 98 */ 8 | /* *************************************************************************/ 9 | 10 | #include 11 | #include 12 | #include 13 | 14 | // #include 15 | #include "../gprim/spline.hpp" 16 | #include "../gprim/splinegeometry.hpp" 17 | 18 | 19 | 20 | #include "surface.hpp" 21 | #include "solid.hpp" 22 | #include "identify.hpp" 23 | #include "singularref.hpp" 24 | #include "csgeom.hpp" 25 | #include "csgparser.hpp" 26 | 27 | 28 | #include "triapprox.hpp" 29 | #include "algprim.hpp" 30 | #include "brick.hpp" 31 | #include "spline3d.hpp" 32 | #include "manifold.hpp" 33 | #include "curve2d.hpp" 34 | #include "explicitcurve2d.hpp" 35 | #include "gencyl.hpp" 36 | #include "polyhedra.hpp" 37 | #include "extrusion.hpp" 38 | #include "revolution.hpp" 39 | #include "specpoin.hpp" 40 | #include "edgeflw.hpp" 41 | #include "meshsurf.hpp" 42 | 43 | 44 | #endif 45 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/meshfunc.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_MESHFUNC 2 | #define FILE_MESHFUNC 3 | 4 | /**************************************************************************/ 5 | /* File: meshfunc.hpp */ 6 | /* Author: Johannes Gerstmayr, Joachim Schoeberl */ 7 | /* Date: 26. Jan. 98 */ 8 | /**************************************************************************/ 9 | 10 | 11 | /* 12 | Functions for mesh-generations strategies 13 | */ 14 | 15 | class Mesh; 16 | // class CSGeometry; 17 | 18 | /// Build tet-mesh 19 | MESHING3_RESULT MeshVolume (MeshingParameters & mp, Mesh& mesh3d); 20 | 21 | /// Build mixed-element mesh 22 | // MESHING3_RESULT MeshMixedVolume (MeshingParameters & mp, Mesh& mesh3d); 23 | 24 | /// Optimize tet-mesh 25 | MESHING3_RESULT OptimizeVolume (MeshingParameters & mp, Mesh& mesh3d); 26 | // const CSGeometry * geometry = NULL); 27 | 28 | void RemoveIllegalElements (Mesh & mesh3d); 29 | 30 | 31 | enum MESHING_STEP { 32 | MESHCONST_ANALYSE = 1, 33 | MESHCONST_MESHEDGES = 2, 34 | MESHCONST_MESHSURFACE = 3, 35 | MESHCONST_OPTSURFACE = 4, 36 | MESHCONST_MESHVOLUME = 5, 37 | MESHCONST_OPTVOLUME = 6 38 | }; 39 | 40 | 41 | #endif 42 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/clusters.hpp: -------------------------------------------------------------------------------- 1 | #ifndef CLUSTERS 2 | #define CLUSTERS 3 | 4 | /**************************************************************************/ 5 | /* File: clusers.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 28. Apr. 01 */ 8 | /**************************************************************************/ 9 | 10 | /* 11 | Anisotropic clusters 12 | 13 | nodes, edges, faces, elements 14 | */ 15 | 16 | 17 | class AnisotropicClusters 18 | { 19 | const Mesh & mesh; 20 | 21 | int nv, ned, nfa, ne; 22 | 23 | // connected nodes, nodes = vertices, edges, faces, elements 24 | Array cluster_reps; 25 | 26 | public: 27 | AnisotropicClusters (const Mesh & amesh); 28 | ~AnisotropicClusters(); 29 | 30 | void Update(); 31 | 32 | int GetVertexRepresentant (int vnr) const 33 | { return cluster_reps.Get(vnr); } 34 | int GetEdgeRepresentant (int ednr) const 35 | { return cluster_reps.Get(nv+ednr); } 36 | int GetFaceRepresentant (int fnr) const 37 | { return cluster_reps.Get(nv+ned+fnr); } 38 | int GetElementRepresentant (int enr) const 39 | { return cluster_reps.Get(nv+ned+nfa+enr); } 40 | }; 41 | 42 | #endif 43 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/README.stubs: -------------------------------------------------------------------------------- 1 | This version of Togl is entirely free from 2 | dependencies on Tcl/Tk's internal functions. It uses the public stubs 3 | interface, witch means that the same binary works with any stubs-aware 4 | wish (i.e. version >= 8.1) 5 | 6 | It has been tested on Windows NT/2000 and Linux for several Tcl/Tk versions up 7 | to 8.4a3. I haven't been able to test the Mac port, it propably needs mending 8 | but I can't see why it shouldn't work in principle. 9 | 10 | Implementation wise, what differs from Togl 1.5 is that Togl_MakeWindowExist() 11 | is replaced by Togl_CreateWindow(), a function that gets registered in Tk as a callback for window creation. In Tk/Tk 8.4a3, there is a new public API call 12 | Tk_SetClassProcs() to register this callback, but for earlier versions of Tk 13 | one needs to do this using some pointer magic. 14 | There is a run-time check to determine which method to use, hence the 15 | same binary runs on all versions of Wish from 8.1 and up. For this to 16 | work you need to compile against the headers from Tcl/Tk 8.4a3 or later, or 17 | the binary will only work for Tcl/Tk 8.1-8.4a2. 18 | The tk8.4a3 public headers (tk8.4a3.h + tkDecls.h) are included for 19 | conveniance, and they are used if the flag -DUSE_LOCAL_TK_H is specified. 20 | 21 | Jonas Beskow, December 2001 -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/README.stubs: -------------------------------------------------------------------------------- 1 | This version of Togl is entirely free from 2 | dependencies on Tcl/Tk's internal functions. It uses the public stubs 3 | interface, witch means that the same binary works with any stubs-aware 4 | wish (i.e. version >= 8.1) 5 | 6 | It has been tested on Windows NT/2000 and Linux for several Tcl/Tk versions up 7 | to 8.4a3. I haven't been able to test the Mac port, it propably needs mending 8 | but I can't see why it shouldn't work in principle. 9 | 10 | Implementation wise, what differs from Togl 1.5 is that Togl_MakeWindowExist() 11 | is replaced by Togl_CreateWindow(), a function that gets registered in Tk as a callback for window creation. In Tk/Tk 8.4a3, there is a new public API call 12 | Tk_SetClassProcs() to register this callback, but for earlier versions of Tk 13 | one needs to do this using some pointer magic. 14 | There is a run-time check to determine which method to use, hence the 15 | same binary runs on all versions of Wish from 8.1 and up. For this to 16 | work you need to compile against the headers from Tcl/Tk 8.4a3 or later, or 17 | the binary will only work for Tcl/Tk 8.1-8.4a2. 18 | The tk8.4a3 public headers (tk8.4a3.h + tkDecls.h) are included for 19 | conveniance, and they are used if the flag -DUSE_LOCAL_TK_H is specified. 20 | 21 | Jonas Beskow, December 2001 -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/triapprox.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #include 5 | #include 6 | 7 | 8 | namespace netgen 9 | { 10 | 11 | TriangleApproximation :: TriangleApproximation () 12 | { 13 | ; 14 | } 15 | 16 | int TriangleApproximation :: 17 | AddTriangle (const TATriangle & tri, bool invert) 18 | { 19 | trigs.Append (tri); 20 | if (invert) 21 | { 22 | trigs.Last()[1] = tri[2]; 23 | trigs.Last()[2] = tri[1]; 24 | } 25 | return trigs.Size()-1; 26 | } 27 | 28 | 29 | void TriangleApproximation :: RemoveUnusedPoints () 30 | { 31 | BitArray used(GetNP()); 32 | Array map (GetNP()); 33 | int i, j; 34 | int cnt = 0; 35 | 36 | used.Clear(); 37 | for (i = 0; i < GetNT(); i++) 38 | for (j = 0; j < 3; j++) 39 | used.Set (GetTriangle (i)[j]); 40 | 41 | for (i = 0; i < GetNP(); i++) 42 | if (used.Test(i)) 43 | map[i] = cnt++; 44 | 45 | for (i = 0; i < GetNT(); i++) 46 | for (j = 0; j < 3; j++) 47 | trigs[i][j] = map[trigs[i][j]]; 48 | 49 | for (i = 0; i < GetNP(); i++) 50 | if (used.Test(i)) 51 | { 52 | points[map[i]] = points[i]; 53 | normals[map[i]] = normals[i]; 54 | } 55 | 56 | points.SetSize (cnt); 57 | normals.SetSize (cnt); 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/interface/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_definitions(-DNGINTERFACE_EXPORTS) 2 | add_library(interface ${NG_LIB_TYPE} 3 | # $ 4 | # $ 5 | # $ 6 | # $ 7 | # $ 8 | # $ 9 | nginterface.cpp nginterface_v2.cpp 10 | read_fnf_mesh.cpp readtetmesh.cpp readuser.cpp writeabaqus.cpp writediffpack.cpp 11 | writedolfin.cpp writeelmer.cpp writefeap.cpp writefluent.cpp writegmsh.cpp writejcm.cpp 12 | writepermas.cpp writetecplot.cpp writetet.cpp writetochnog.cpp writeuser.cpp 13 | wuchemnitz.cpp writegmsh2.cpp writeOpenFOAM15x.cpp 14 | ) 15 | 16 | # TARGET_LINK_LIBRARIES(interface ${MPI_CXX_LIBRARIES} ${PYTHON_LIBS}) 17 | # TARGET_LINK_LIBRARIES( interface ${LIBPTHREAD} ${OCC_LIBRARIES} ${LIBTOGL} ${MPI_CXX_LIBRARIES} ${OPENGL_LIBRARIES} ${TK_LIBRARY} ${TCL_LIBRARY} ${CMAKE_THREAD_LIBS_INIT} ${X11_Xmu_LIB} ${JPEG_LIBRARIES} ${MKL_LIBRARIES} ${ZLIB_LIBRARIES} ) 18 | if(NOT WIN32) 19 | target_link_libraries(interface mesh csg geom2d) 20 | if(USE_GUI) 21 | target_link_libraries(interface visual) 22 | endif(USE_GUI) 23 | install( TARGETS interface ${ng_install_dir}) 24 | endif(NOT WIN32) 25 | 26 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/symbolta.cpp: -------------------------------------------------------------------------------- 1 | /**************************************************************************/ 2 | /* File: symbolta.cc */ 3 | /* Author: Joachim Schoeberl */ 4 | /* Date: 01. Jun. 95 */ 5 | /**************************************************************************/ 6 | 7 | /* 8 | Abstract data type Symbol Table 9 | */ 10 | 11 | #include 12 | #include 13 | 14 | 15 | #ifndef FILE_SYMBOLTABLECC 16 | #define FILE_SYMBOLTABLECC 17 | // necessary for SGI ???? 18 | 19 | 20 | namespace netgen 21 | { 22 | //using namespace netgen; 23 | 24 | BASE_SYMBOLTABLE :: BASE_SYMBOLTABLE () 25 | { 26 | ; 27 | } 28 | 29 | 30 | BASE_SYMBOLTABLE :: ~BASE_SYMBOLTABLE() 31 | { 32 | DelNames(); 33 | } 34 | 35 | 36 | void BASE_SYMBOLTABLE :: DelNames() 37 | { 38 | for (int i = 0; i < names.Size(); i++) 39 | delete [] names[i]; 40 | names.SetSize (0); 41 | } 42 | 43 | int BASE_SYMBOLTABLE :: Index (const char * name) const 44 | { 45 | if (!name) return 0; 46 | for (int i = 0; i < names.Size(); i++) 47 | if (strcmp (names[i], name) == 0) return i+1; 48 | return 0; 49 | } 50 | } 51 | 52 | #endif 53 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/seti.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | 5 | namespace netgen 6 | { 7 | //using namespace netgen; 8 | 9 | IndexSet :: IndexSet (int maxind) 10 | { 11 | SetMaxIndex (maxind); 12 | } 13 | 14 | IndexSet :: ~IndexSet () 15 | { 16 | Clear(); 17 | } 18 | 19 | 20 | void IndexSet :: SetMaxIndex (int maxind) 21 | { 22 | if (maxind > flags.Size()) 23 | { 24 | flags.SetSize (2 * maxind); 25 | flags.Clear(); 26 | } 27 | } 28 | 29 | /* 30 | int IndexSet :: IsIn (int ind) const 31 | { 32 | return flags.Test (ind); 33 | } 34 | */ 35 | 36 | /* 37 | void IndexSet :: Add (int ind) 38 | { 39 | if (ind > flags.Size()) 40 | { 41 | cerr << "out of range" << endl; 42 | exit (1); 43 | } 44 | 45 | if (!flags.Test(ind)) 46 | { 47 | set.Append (ind); 48 | flags.Set (ind); 49 | } 50 | } 51 | */ 52 | 53 | void IndexSet :: Del (int ind) 54 | { 55 | for (int i = 1; i <= set.Size(); i++) 56 | if (set.Get(i) == ind) 57 | { 58 | set.DeleteElement (ind); 59 | break; 60 | } 61 | flags.Clear (ind); 62 | } 63 | 64 | void IndexSet :: Clear () 65 | { 66 | for (int i = 1; i <= set.Size(); i++) 67 | flags.Clear (set.Get(i)); 68 | set.SetSize (0); 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /netgen-6.1-src/rules/makerlsfile.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | 5 | using namespace std; 6 | 7 | #define maxlen 1000 8 | 9 | int main (int argc, char ** argv) 10 | { 11 | if (argc != 3) 12 | { 13 | cout << "use: makerlsfile infile outfile" << endl; 14 | exit(1); 15 | } 16 | 17 | 18 | char line[maxlen], infile[maxlen], outfile[maxlen];\ 19 | char ch; 20 | int i, j; 21 | 22 | /* 23 | cout << "infile: "; 24 | cin >> infile; 25 | cout << "outfile: "; 26 | cin >> outfile; 27 | */ 28 | 29 | ifstream inf (argv[1]); 30 | ofstream outf (argv[2]); 31 | 32 | outf << "const char * ngscript[] = {" << endl; 33 | while (inf.good()) 34 | { 35 | i = 0; 36 | 37 | inf.get(ch); 38 | while (ch != '\n' && inf.good() && i < maxlen) 39 | { 40 | if (ch == '\"') 41 | { 42 | line[i] = '\\'; 43 | line[i+1] = '\"'; 44 | i+= 2; 45 | } 46 | else if (ch == '\\') 47 | { 48 | line[i] = '\\'; 49 | line[i+1] = '\\'; 50 | i+= 2; 51 | } 52 | else 53 | { 54 | line[i] = ch; 55 | i++; 56 | } 57 | inf.get(ch); 58 | } 59 | line[i] = 0; 60 | cout << line << endl; 61 | outf << "\"" << line << "\\n\",\\" << endl; 62 | } 63 | outf << "0};" << endl; 64 | return 0; 65 | } 66 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/squarecircle.in2d: -------------------------------------------------------------------------------- 1 | # keyword for 2D geometry, version 2 2 | splinecurves2dv2 3 | 4 | 5 | # a global grading factor 6 | 2 7 | 8 | 9 | # the points (point number, x and y coordinates) 10 | points 11 | 1 0 0 12 | 2 1 0 13 | 3 1 1 14 | 4 0 1 15 | 5 0.5 0.4 16 | 6 0.6 0.4 17 | 7 0.6 0.5 18 | 8 0.6 0.6 19 | 9 0.5 0.6 20 | 10 0.4 0.6 21 | 11 0.4 0.5 22 | 12 0.4 0.4 23 | 24 | 25 | # boundary curves consisting of 26 | # dl dr np p1 p1 flaglist 27 | # with 28 | # dl ... sub-domain nr on left side 29 | # dr ... sub-domain nr on right side 30 | # np ... curve is given by 2 (or 3) points 31 | # p1, p2 ... points defining the curve 32 | 33 | # flagslist 34 | segments 35 | 1 0 2 1 2 -bc=1 36 | 1 0 2 2 3 -bc=1 37 | 1 0 2 3 4 -bc=1 38 | 1 0 2 4 1 -bc=1 39 | 2 1 3 5 6 7 -bc=2 40 | 2 1 3 7 8 9 -bc=2 41 | 2 1 3 9 10 11 -bc=2 42 | 2 1 3 11 12 5 -bc=2 43 | 44 | materials 45 | 1 domain1 -maxh=0.2 46 | 2 domain2 -maxh=0.05 47 | 48 | 49 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/squarehole.in2d: -------------------------------------------------------------------------------- 1 | # keyword for 2D geometry, version 2 2 | splinecurves2dv2 3 | 4 | 5 | # a global grading factor 6 | 2 7 | 8 | 9 | # the points (point number, x and y coordinates) 10 | points 11 | 1 0 0 12 | 2 1 0 13 | 3 1 1 14 | 4 0 1 15 | 5 0.5 0.4 16 | 6 0.6 0.4 17 | 7 0.6 0.5 18 | 8 0.6 0.6 19 | 9 0.5 0.6 20 | 10 0.4 0.6 21 | 11 0.4 0.5 22 | 12 0.4 0.4 23 | 24 | 25 | # boundary curves consisting of 26 | # dl dr np p1 p1 flaglist 27 | # with 28 | # dl ... sub-domain nr on left side 29 | # dr ... sub-domain nr on right side 30 | # np ... curve is given by 2 (or 3) points 31 | # p1, p2 ... points defining the curve 32 | 33 | # flagslist 34 | segments 35 | 1 0 2 1 2 -bc=1 36 | 1 0 2 2 3 -bc=1 37 | 1 0 2 3 4 -bc=1 38 | 1 0 2 4 1 -bc=1 39 | 0 1 3 5 6 7 -bc=2 -maxh=0.05 40 | 0 1 3 7 8 9 -bc=2 -maxh=0.05 41 | 0 1 3 9 10 11 -bc=2 -maxh=0.05 42 | 0 1 3 11 12 5 -bc=2 -maxh=0.05 43 | 44 | materials 45 | 1 domain1 -maxh=0.2 46 | 47 | 48 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/myadt.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_MYADT 2 | #define FILE_MYADT 3 | 4 | /**************************************************************************/ 5 | /* File: myadt.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 01. Jun. 95 */ 8 | /**************************************************************************/ 9 | 10 | /* 11 | include for all abstract data types 12 | */ 13 | 14 | 15 | 16 | #include "../include/mystdlib.h" 17 | #include "../include/mydefs.hpp" 18 | 19 | 20 | #include "ngexception.hpp" 21 | #include "parthreads.hpp" 22 | // #include "moveablemem.hpp" 23 | #include "dynamicmem.hpp" 24 | 25 | #include "template.hpp" 26 | #include "array.hpp" 27 | #include "table.hpp" 28 | #include "hashtabl.hpp" 29 | 30 | 31 | #include "symbolta.hpp" 32 | #include "bitarray.hpp" 33 | #include "flags.hpp" 34 | #include "spbita2d.hpp" 35 | 36 | #include "seti.hpp" 37 | #include "optmem.hpp" 38 | #include "autoptr.hpp" 39 | #include "sort.hpp" 40 | #include "stack.hpp" 41 | #include "mystring.hpp" 42 | #include "profiler.hpp" 43 | 44 | #include "mpi_interface.hpp" 45 | #include "netgenout.hpp" 46 | #include "gzstream.h" 47 | #include "archive_base.hpp" 48 | 49 | #include "mysimd.hpp" 50 | 51 | 52 | #endif 53 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/geom2d/geom2dpkg.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | 6 | #include "vsgeom2d.hpp" 7 | 8 | // extern "C" int Ng_CSG_Init (Tcl_Interp * interp); 9 | 10 | namespace netgen 11 | { 12 | 13 | 14 | // extern DLL_HEADER NetgenGeometry * ng_geometry; 15 | static VisualSceneGeometry2d vsgeom2d; 16 | 17 | 18 | 19 | 20 | 21 | class SplineGeometryVisRegister : public GeometryRegister 22 | { 23 | public: 24 | virtual NetgenGeometry * Load (string filename) const { return NULL; } 25 | virtual VisualScene * GetVisualScene (const NetgenGeometry * geom) const; 26 | }; 27 | 28 | 29 | VisualScene * SplineGeometryVisRegister :: GetVisualScene (const NetgenGeometry * geom) const 30 | { 31 | const SplineGeometry2d * geometry = dynamic_cast (geom); 32 | if (geometry) 33 | { 34 | vsgeom2d.SetGeometry (geometry); 35 | return &vsgeom2d; 36 | } 37 | return NULL; 38 | } 39 | 40 | 41 | } 42 | 43 | 44 | using namespace netgen; 45 | #ifdef WIN32 46 | extern "C" __declspec(dllexport) int Ng_geom2d_Init (Tcl_Interp * interp); 47 | #else 48 | extern "C" int Ng_geom2d_Init (Tcl_Interp * interp); 49 | #endif 50 | 51 | int Ng_geom2d_Init (Tcl_Interp * interp) 52 | { 53 | geometryregister.Append (new SplineGeometryVisRegister); 54 | return TCL_OK; 55 | } 56 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/meshing.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_MESHING 2 | #define FILE_MESHING 3 | 4 | 5 | 6 | #include "../include/myadt.hpp" 7 | #include "../include/gprim.hpp" 8 | #include "../include/linalg.hpp" 9 | #include "../include/opti.hpp" 10 | 11 | 12 | 13 | namespace netgen 14 | { 15 | // extern int printmessage_importance; 16 | 17 | // class CSGeometry; 18 | class NetgenGeometry; 19 | } 20 | 21 | 22 | #include "msghandler.hpp" 23 | #include "meshtype.hpp" 24 | #include "localh.hpp" 25 | #include "topology.hpp" 26 | #include "meshclass.hpp" 27 | #include "global.hpp" 28 | 29 | 30 | namespace netgen 31 | { 32 | #include "meshtool.hpp" 33 | #include "ruler2.hpp" 34 | #include "adfront2.hpp" 35 | #include "meshing2.hpp" 36 | #include "improve2.hpp" 37 | 38 | 39 | #include "geomsearch.hpp" 40 | #include "adfront3.hpp" 41 | #include "ruler3.hpp" 42 | 43 | #define _INCLUDE_MORE 44 | 45 | 46 | #include "meshing3.hpp" 47 | #include "improve3.hpp" 48 | 49 | #include "findip.hpp" 50 | #include "findip2.hpp" 51 | 52 | #include "curvedelems.hpp" 53 | #include "clusters.hpp" 54 | 55 | #include "meshfunc.hpp" 56 | 57 | #include "bisect.hpp" 58 | #include "hprefinement.hpp" 59 | #include "boundarylayer.hpp" 60 | #include "specials.hpp" 61 | } 62 | 63 | #include "validate.hpp" 64 | #include "basegeom.hpp" 65 | 66 | #ifdef PARALLEL 67 | #include "paralleltop.hpp" 68 | #endif 69 | 70 | 71 | #endif 72 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/optmem.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_OPTMEM 2 | #define FILE_OPTMEM 3 | 4 | /**************************************************************************/ 5 | /* File: optmem.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 04. Apr. 97 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | /** 14 | Optimized Memory allocation classes 15 | */ 16 | 17 | class BlockAllocator 18 | { 19 | private: 20 | /// 21 | unsigned size, blocks; 22 | /// 23 | void * freelist; 24 | /// 25 | Array bablocks; 26 | public: 27 | /// 28 | BlockAllocator (unsigned asize, unsigned ablocks = 100); 29 | /// 30 | ~BlockAllocator (); 31 | /// 32 | 33 | void * Alloc (); 34 | /* 35 | { 36 | if (!freelist) 37 | Alloc2(); 38 | 39 | void * p = freelist; 40 | // freelist = *(void**)freelist; 41 | freelist = *static_cast (freelist); 42 | 43 | return p; 44 | } 45 | */ 46 | 47 | 48 | /// 49 | void Free (void * p); 50 | /* 51 | { 52 | if (!bablocks.Size()) return; 53 | *(void**)p = freelist; 54 | freelist = p; 55 | } 56 | */ 57 | 58 | 59 | private: 60 | // void Alloc2 (); 61 | }; 62 | 63 | } 64 | 65 | #endif 66 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/parallelinterface.hpp: -------------------------------------------------------------------------------- 1 | gibt's nicht mehr 2 | 3 | 4 | #ifndef FILE_PARALLELINTERFACE 5 | #define FILE_PARALLELINTERFACE 6 | 7 | #ifdef PARALLEL 8 | 9 | #ifdef __cplusplus 10 | extern "C" { 11 | #endif 12 | 13 | // this interface is 0-base !! 14 | 15 | 16 | int NgPar_GetLoc2Glob_VolEl ( int locnum ); 17 | 18 | // int NgPar_GetDistantNodeNums ( int nt, int locnum, int * procs, int * distnum); 19 | 20 | // number on distant processor 21 | 22 | // gibt anzahl an distant pnums zurueck 23 | // * pnums entspricht ARRAY 24 | int NgPar_GetDistantNodeNums ( int nodetype, int locnum, int * pnums ); 25 | int NgPar_GetNDistantNodeNums ( int nodetype, int locnum ); 26 | 27 | int NgPar_GetDistantPNum ( int proc, int locnum ) ; 28 | int NgPar_GetDistantEdgeNum ( int proc, int locnum ) ; 29 | int NgPar_GetDistantFaceNum ( int proc, int locnum ) ; 30 | int NgPar_GetDistantElNum ( int proc, int locnum ); 31 | 32 | bool NgPar_IsExchangeFace ( int fnr ) ; 33 | bool NgPar_IsExchangeVert ( int vnum ); 34 | bool NgPar_IsExchangeEdge ( int ednum ); 35 | bool NgPar_IsExchangeElement ( int elnum ); 36 | 37 | void NgPar_PrintParallelMeshTopology (); 38 | bool NgPar_IsElementInPartition ( int elnum, int dest ); 39 | 40 | bool NgPar_IsGhostFace ( int facenum ); 41 | bool NgPar_IsGhostEdge ( int edgenum ); 42 | 43 | #ifdef __cplusplus 44 | } 45 | #endif 46 | 47 | #endif 48 | 49 | #endif 50 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/netgenpy.cpp: -------------------------------------------------------------------------------- 1 | // a wrapper to load netgen-dll into python 2 | 3 | #include 4 | #include <../general/ngpython.hpp> 5 | 6 | #ifdef WIN32 7 | #define DLL_HEADER __declspec(dllimport) 8 | #else 9 | #define DLL_HEADER 10 | #endif 11 | 12 | 13 | void DLL_HEADER ExportNetgenMeshing(py::module &m); 14 | void DLL_HEADER ExportMeshVis(py::module &m); 15 | void DLL_HEADER ExportCSG(py::module &m); 16 | void DLL_HEADER ExportCSGVis(py::module &m); 17 | void DLL_HEADER ExportGeom2d(py::module &m); 18 | 19 | PYBIND11_PLUGIN(libngpy) 20 | { 21 | py::module ngpy("libngpy", "pybind netgen module"); 22 | py::module csg = ngpy.def_submodule("_csg", "pybind csg module"); 23 | ExportCSG(csg); 24 | py::module csgvis = ngpy.def_submodule("csgvis", "pybind csgvis module"); 25 | ExportCSGVis(csgvis); 26 | py::module meshing = ngpy.def_submodule("_meshing", "pybind meshing module"); 27 | ExportNetgenMeshing(meshing); 28 | py::module meshvis = ngpy.def_submodule("meshvis", "pybind meshvis module"); 29 | ExportMeshVis(meshvis); 30 | py::module geom2d = ngpy.def_submodule("_geom2d", "pybind geom2d module"); 31 | ExportGeom2d(geom2d); 32 | return ngpy.ptr(); 33 | } 34 | 35 | // Force linking libnglib to libnetgenpy 36 | namespace netgen 37 | { 38 | void MyBeep (int i); 39 | void MyDummyToForceLinkingNGLib() 40 | { 41 | MyBeep(0); 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/linalg/polynomial.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_POLYNOMIAL 2 | #define FILE_POLYNOMIAL 3 | 4 | /* *************************************************************************/ 5 | /* File: polynomial.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 25. Nov. 99 */ 8 | /* *************************************************************************/ 9 | 10 | 11 | class QuadraticPolynomial1V 12 | { 13 | double c, cx, cxx; 14 | public: 15 | QuadraticPolynomial1V (double ac, double acx, double acxx); 16 | double Value (double x); 17 | double MaxUnitInterval (); 18 | }; 19 | 20 | class LinearPolynomial2V 21 | { 22 | double c, cx, cy; 23 | public: 24 | LinearPolynomial2V (double ac, double acx, double acy); 25 | friend class QuadraticPolynomial2V; 26 | }; 27 | 28 | 29 | class QuadraticPolynomial2V 30 | { 31 | double c, cx, cy, cxx, cxy, cyy; 32 | public: 33 | QuadraticPolynomial2V (); 34 | QuadraticPolynomial2V (double ac, double acx, double acy, 35 | double acxx, double acxy, double acyy); 36 | void Square (const LinearPolynomial2V & lp); 37 | void Add (double lam, const QuadraticPolynomial2V & qp); 38 | 39 | double Value (double x, double y); 40 | // double MinUnitSquare (); 41 | double MaxUnitSquare (); 42 | double MaxUnitTriangle (); 43 | }; 44 | 45 | #endif 46 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/overlay.tcl: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # the next line restarts using wish \ 3 | exec wish "$0" "$@" 4 | 5 | # $Id: overlay.tcl,v 1.4 2001/12/20 13:59:31 beskow Exp $ 6 | 7 | # Togl - a Tk OpenGL widget 8 | # Copyright (C) 1996 Brian Paul and Ben Bederson 9 | # See the LICENSE file for copyright details. 10 | 11 | 12 | # $Log: overlay.tcl,v $ 13 | # Revision 1.4 2001/12/20 13:59:31 beskow 14 | # Improved error-handling in togl.c in case of window creation failure 15 | # Added pkgIndex target to makefile 16 | # Updated documentation to reflect stubs-interface (Togl.html + new README.stubs) 17 | # Added tk8.4a3 headers 18 | # Removed obsolete Tk internal headers 19 | # 20 | # Revision 1.3 2001/01/29 18:11:53 brianp 21 | # Jonas Beskow's changes to use Tcl/Tk stub interface 22 | # 23 | # Revision 1.2 1998/01/24 14:05:50 brianp 24 | # added quit button (Ben Bederson) 25 | # 26 | # Revision 1.1 1997/03/07 01:26:38 brianp 27 | # Initial revision 28 | # 29 | # 30 | 31 | 32 | # A Tk/OpenGL widget demo using an overlay. 33 | 34 | load [file dirname [info script]]/overlay[info sharedlibextension] 35 | 36 | proc setup {} { 37 | wm title . "Overlay demo" 38 | 39 | togl .win -width 200 -height 200 -rgba true -double false -overlay true 40 | button .btn -text Quit -command exit 41 | 42 | pack .win -expand true -fill both 43 | pack .btn -expand true -fill both 44 | } 45 | 46 | 47 | 48 | # Execution starts here! 49 | setup 50 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/mystdlib.h: -------------------------------------------------------------------------------- 1 | #ifndef FILE_MYSTDLIB 2 | #define FILE_MYSTDLIB 3 | 4 | #ifdef HAVE_CONFIG_H 5 | #include 6 | #endif 7 | 8 | 9 | #include 10 | #include 11 | #include 12 | #include 13 | 14 | 15 | #include 16 | #include 17 | #include 18 | #include 19 | #include 20 | #include 21 | #include 22 | #include 23 | #include 24 | #include 25 | #include 26 | 27 | 28 | #include 29 | #include 30 | #include 31 | 32 | #ifdef PARALLEL 33 | // #undef SEEK_SET 34 | // #undef SEEK_CUR 35 | // #undef SEEK_END 36 | #include 37 | #include // for usleep (only for parallel) 38 | #endif 39 | 40 | 41 | 42 | /* 43 | #ifdef METIS 44 | namespace metis { extern "C" { 45 | #include 46 | } } 47 | #endif 48 | */ 49 | 50 | 51 | 52 | #ifndef M_PI 53 | #define M_PI 3.14159265358979323846 54 | #endif 55 | 56 | 57 | /*** Windows headers ***/ 58 | #ifdef _MSC_VER 59 | # define WIN32_LEAN_AND_MEAN 60 | # ifndef NO_PARALLEL_THREADS 61 | # ifdef MSVC_EXPRESS 62 | # else 63 | # include 64 | # include 65 | # endif // MSVC_EXPRESS 66 | # endif 67 | # include 68 | # undef WIN32_LEAN_AND_MEAN 69 | # include 70 | 71 | #else // Not using MC VC++ 72 | 73 | 74 | #endif 75 | 76 | 77 | using namespace std; 78 | 79 | #endif 80 | 81 | -------------------------------------------------------------------------------- /netgen-6.1-src/py_tutorials/merge.py: -------------------------------------------------------------------------------- 1 | from netgen.meshing import * 2 | from netgen.csg import * 3 | 4 | from ngsolve import ngsglobals 5 | ngsglobals.msg_level = 2 6 | 7 | geo1 = CSGeometry() 8 | geo1.Add (OrthoBrick( Pnt(0,0,0), Pnt(1,1,1) )) 9 | m1 = geo1.GenerateMesh (maxh=0.1) 10 | m1.Refine() 11 | m1.Refine() 12 | 13 | 14 | geo2 = CSGeometry() 15 | geo2.Add (Sphere (Pnt(0.5,0.5,0.5), 0.1)) 16 | m2 = geo2.GenerateMesh (maxh=0.05) 17 | m2.Refine() 18 | m2.Refine() 19 | 20 | print ("********************") 21 | print ("** start merging **") 22 | print ("********************") 23 | 24 | mesh = Mesh() 25 | fd_outside = mesh.Add (FaceDescriptor(surfnr=1,domin=1)) 26 | fd_inside = mesh.Add (FaceDescriptor(surfnr=2,domin=2,domout=1)) 27 | 28 | 29 | pmap1 = { } 30 | for e in m1.Elements2D(): 31 | for v in e.vertices: 32 | if (v not in pmap1): 33 | pmap1[v] = mesh.Add (m1[v]) 34 | 35 | for e in m1.Elements2D(): 36 | mesh.Add (Element2D (fd_outside, [pmap1[v] for v in e.vertices])) 37 | 38 | 39 | 40 | pmap2 = { } 41 | for e in m2.Elements2D(): 42 | for v in e.vertices: 43 | if (v not in pmap2): 44 | pmap2[v] = mesh.Add (m2[v]) 45 | 46 | for e in m2.Elements2D(): 47 | mesh.Add (Element2D (fd_inside, [pmap2[v] for v in e.vertices])) 48 | 49 | 50 | print ("******************") 51 | print ("** merging done **") 52 | print ("******************") 53 | 54 | 55 | mesh.GenerateVolumeMesh() 56 | mesh.Save ("newmesh.vol") 57 | 58 | 59 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/mpi_interface.cpp: -------------------------------------------------------------------------------- 1 | /**************************************************************************/ 2 | /* File: mpi_interface.cpp */ 3 | /* Author: Joachim Schoeberl */ 4 | /* Date: 04. Apr. 97 */ 5 | /**************************************************************************/ 6 | 7 | #include 8 | #include 9 | 10 | 11 | namespace netgen 12 | { 13 | 14 | 15 | #ifdef PARALLEL 16 | 17 | void MyMPI_SendCmd (const char * cmd) 18 | { 19 | char buf[10000]; 20 | strcpy (buf, cmd); 21 | // MPI_Bcast (&buf, 100, MPI_CHAR, 0, MPI_COMM_WORLD); 22 | 23 | for (int dest = 1; dest < ntasks; dest++) 24 | MPI_Send( &buf, 10000, MPI_CHAR, dest, MPI_TAG_CMD, MPI_COMM_WORLD); 25 | } 26 | 27 | string MyMPI_RecvCmd () 28 | { 29 | char buf[10000]; 30 | // MPI_Bcast (&buf, 100, MPI_CHAR, 0, MPI_COMM_WORLD); 31 | 32 | // VT_OFF(); 33 | MPI_Status status; 34 | int flag; 35 | do 36 | { 37 | MPI_Iprobe (0, MPI_TAG_CMD, MPI_COMM_WORLD, &flag, &status); 38 | if (!flag) 39 | { 40 | VT_TRACER ("sleep"); 41 | usleep (1000); 42 | } 43 | } 44 | while (!flag); 45 | // VT_ON(); 46 | 47 | MPI_Recv( &buf, 10000, MPI_CHAR, 0, MPI_TAG_CMD, MPI_COMM_WORLD, &status); 48 | 49 | return string(buf); 50 | } 51 | 52 | #endif 53 | 54 | 55 | } 56 | 57 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/spbita2d.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_SPBITA2D 2 | #define FILE_SPBITA2D 3 | 4 | /**************************************************************************/ 5 | /* File: spbita2d.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 01. Jun. 95 */ 8 | /**************************************************************************/ 9 | 10 | /** 11 | Implementation of sparse 2 dimensional bitarray 12 | */ 13 | 14 | namespace netgen 15 | { 16 | 17 | class SPARSE_BIT_Array_2D 18 | { 19 | class linestruct { public: INDEX size; INDEX maxsize; INDEX * col; }; 20 | 21 | /// 22 | linestruct * lines; 23 | /// 24 | INDEX height, width; 25 | 26 | public: 27 | 28 | /// 29 | SPARSE_BIT_Array_2D (INDEX ah = 0, INDEX aw = 0); 30 | /// 31 | ~SPARSE_BIT_Array_2D (); 32 | 33 | /// 34 | void SetSize (INDEX ah, INDEX aw = 0); 35 | /// 36 | void DeleteElements (); 37 | 38 | /// 39 | int Get (INDEX i, INDEX j) const; 40 | 41 | /// 42 | INDEX Height () const { return height; } 43 | /// 44 | INDEX Width () const { return width; } 45 | 46 | /// 47 | void Set (INDEX i, INDEX j); 48 | /// 49 | int Test (INDEX i, INDEX j) const; 50 | 51 | /// 52 | INDEX BitsInLine (INDEX i) const { return lines[i-1].size; } 53 | /// 54 | INDEX GetIndex (INDEX i, INDEX nr) const { return lines[i-1].col[nr-1]; } 55 | }; 56 | 57 | } 58 | 59 | #endif 60 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_definitions(-DNGINTERFACE_EXPORTS) 2 | if(NOT WIN32) 3 | set(mesh_object_libs 4 | $ 5 | $ 6 | $ 7 | ) 8 | endif(NOT WIN32) 9 | 10 | add_library(mesh ${NG_LIB_TYPE} 11 | adfront2.cpp adfront3.cpp bisect.cpp boundarylayer.cpp 12 | clusters.cpp curvedelems.cpp delaunay.cpp delaunay2d.cpp 13 | geomsearch.cpp global.cpp hprefinement.cpp improve2.cpp 14 | improve2gen.cpp improve3.cpp localh.cpp meshclass.cpp 15 | meshfunc.cpp meshfunc2d.cpp meshing2.cpp meshing3.cpp 16 | meshtool.cpp meshtype.cpp msghandler.cpp netrule2.cpp 17 | netrule3.cpp parser2.cpp parser3.cpp prism2rls.cpp 18 | pyramid2rls.cpp pyramidrls.cpp quadrls.cpp refine.cpp 19 | ruler2.cpp ruler3.cpp secondorder.cpp smoothing2.5.cpp 20 | smoothing2.cpp smoothing3.cpp specials.cpp tetrarls.cpp 21 | topology.cpp triarls.cpp validate.cpp bcfunctions.cpp 22 | parallelmesh.cpp paralleltop.cpp paralleltop.hpp basegeom.cpp 23 | python_mesh.cpp hexarls.cpp 24 | ${mesh_object_libs} 25 | ) 26 | 27 | if(APPLE) 28 | set_target_properties( mesh PROPERTIES SUFFIX ".so") 29 | endif(APPLE) 30 | 31 | if(NOT WIN32) 32 | target_link_libraries( mesh ${ZLIB_LIBRARIES} ${MPI_CXX_LIBRARIES} ${PYTHON_LIBS} ${METIS_LIBRARY}) 33 | install( TARGETS mesh ${ng_install_dir}) 34 | endif(NOT WIN32) 35 | 36 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/index.tcl: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # the next line restarts using wish \ 3 | exec wish "$0" "$@" 4 | 5 | # $Id: index.tcl,v 1.5 2001/12/20 13:59:31 beskow Exp $ 6 | 7 | # Togl - a Tk OpenGL widget 8 | # Copyright (C) 1996 Brian Paul and Ben Bederson 9 | # See the LICENSE file for copyright details. 10 | 11 | 12 | # $Log: index.tcl,v $ 13 | # Revision 1.5 2001/12/20 13:59:31 beskow 14 | # Improved error-handling in togl.c in case of window creation failure 15 | # Added pkgIndex target to makefile 16 | # Updated documentation to reflect stubs-interface (Togl.html + new README.stubs) 17 | # Added tk8.4a3 headers 18 | # Removed obsolete Tk internal headers 19 | # 20 | # Revision 1.4 2001/01/29 18:11:53 brianp 21 | # Jonas Beskow's changes to use Tcl/Tk stub interface 22 | # 23 | # Revision 1.3 1998/01/24 14:05:50 brianp 24 | # added quit button (Ben Bederson) 25 | # 26 | # Revision 1.2 1997/04/11 01:37:34 brianp 27 | # added a timer to rotate the triangles 28 | # 29 | # Revision 1.1 1996/10/23 23:18:11 brianp 30 | # Initial revision 31 | # 32 | 33 | 34 | # A Tk/OpenGL widget demo using color-index mode. 35 | 36 | load [file dirname [info script]]/index[info sharedlibextension] 37 | 38 | proc setup {} { 39 | wm title . "Color index demo" 40 | 41 | togl .win -width 200 -height 200 -rgba false -double true -privatecmap false -time 10 42 | button .btn -text Quit -command exit 43 | 44 | pack .win -expand true -fill both 45 | pack .btn -expand true -fill both 46 | } 47 | 48 | 49 | 50 | # Execution starts here! 51 | setup 52 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/meshfunc2d.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include "meshing.hpp" 3 | 4 | namespace netgen 5 | { 6 | 7 | DLL_HEADER void Optimize2d (Mesh & mesh, MeshingParameters & mp) 8 | { 9 | static int timer = NgProfiler::CreateTimer ("optimize2d"); 10 | NgProfiler::RegionTimer reg(timer); 11 | 12 | mesh.CalcSurfacesOfNode(); 13 | 14 | const char * optstr = mp.optimize2d.c_str(); 15 | int optsteps = mp.optsteps2d; 16 | 17 | for (int i = 1; i <= optsteps; i++) 18 | for (size_t j = 1; j <= strlen(optstr); j++) 19 | { 20 | if (multithread.terminate) break; 21 | switch (optstr[j-1]) 22 | { 23 | case 's': 24 | { // topological swap 25 | MeshOptimize2d meshopt; 26 | meshopt.SetMetricWeight (mp.elsizeweight); 27 | meshopt.EdgeSwapping (mesh, 0); 28 | break; 29 | } 30 | case 'S': 31 | { // metric swap 32 | MeshOptimize2d meshopt; 33 | meshopt.SetMetricWeight (mp.elsizeweight); 34 | meshopt.EdgeSwapping (mesh, 1); 35 | break; 36 | } 37 | case 'm': 38 | { 39 | MeshOptimize2d meshopt; 40 | meshopt.SetMetricWeight (mp.elsizeweight); 41 | meshopt.ImproveMesh(mesh, mp); 42 | break; 43 | } 44 | case 'c': 45 | { 46 | MeshOptimize2d meshopt; 47 | meshopt.SetMetricWeight (mp.elsizeweight); 48 | meshopt.CombineImprove(mesh); 49 | break; 50 | } 51 | default: 52 | cerr << "Optimization code " << optstr[j-1] << " not defined" << endl; 53 | } 54 | } 55 | } 56 | 57 | } 58 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/LICENSE: -------------------------------------------------------------------------------- 1 | This software is copyrighted by Brian Paul (brian@mesa3d.org) 2 | and Benjamin Bederson (bederson@cs.umd.edu). The following 3 | terms apply to all files associated with the software unless explicitly 4 | disclaimed in individual files. 5 | 6 | The authors hereby grant permission to use, copy, modify, distribute, 7 | and license this software and its documentation for any purpose, provided 8 | that existing copyright notices are retained in all copies and that this 9 | notice is included verbatim in any distributions. No written agreement, 10 | license, or royalty fee is required for any of the authorized uses. 11 | Modifications to this software may be copyrighted by their authors 12 | and need not follow the licensing terms described here, provided that 13 | the new terms are clearly indicated on the first page of each file where 14 | they apply. 15 | 16 | IN NO EVENT SHALL THE AUTHORS OR DISTRIBUTORS BE LIABLE TO ANY PARTY 17 | FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES 18 | ARISING OUT OF THE USE OF THIS SOFTWARE, ITS DOCUMENTATION, OR ANY 19 | DERIVATIVES THEREOF, EVEN IF THE AUTHORS HAVE BEEN ADVISED OF THE 20 | POSSIBILITY OF SUCH DAMAGE. 21 | 22 | THE AUTHORS AND DISTRIBUTORS SPECIFICALLY DISCLAIM ANY WARRANTIES, 23 | INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY, 24 | FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT. THIS SOFTWARE 25 | IS PROVIDED ON AN "AS IS" BASIS, AND THE AUTHORS AND DISTRIBUTORS HAVE 26 | NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR 27 | MODIFICATIONS. 28 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/toglStubLib.c: -------------------------------------------------------------------------------- 1 | #ifndef USE_TCL_STUBS 2 | # define USE_TCL_STUBS 3 | #endif 4 | #undef USE_TCL_STUB_PROCS 5 | #ifndef USE_TK_STUBS 6 | # define USE_TK_STUBS 7 | #endif 8 | #undef USE_TK_STUB_PROCS 9 | 10 | #include "togl.h" 11 | 12 | const ToglStubs *toglStubsPtr; 13 | 14 | /* 15 | ** Ensure that Togl_InitStubs is built as an exported symbol. The other stub 16 | ** functions should be built as non-exported symbols. 17 | */ 18 | #undef TCL_STORAGE_CLASS 19 | #define TCL_STORAGE_CLASS DLLEXPORT 20 | 21 | /* 22 | * Togl_InitStubs -- 23 | * 24 | * Checks that the correct version of Togl is loaded and that it 25 | * supports stubs. It then initialises the stub table pointers. 26 | * 27 | * Results: 28 | * The actual version of Togl that satisfies the request, or 29 | * NULL to indicate that an error occurred. 30 | * 31 | * Side effects: 32 | * sets the stub table pointer. 33 | * 34 | */ 35 | 36 | #ifdef Togl_InitStubs 37 | # undef Togl_InitStubs 38 | #endif 39 | 40 | const char * 41 | Togl_InitStubs(Tcl_Interp *interp, const char *version, int exact) 42 | { 43 | const char *actualVersion; 44 | 45 | actualVersion = Tcl_PkgRequireEx(interp, "Togl", version, exact, 46 | (ClientData *) &toglStubsPtr); 47 | if (!actualVersion) { 48 | return NULL; 49 | } 50 | 51 | if (!toglStubsPtr) { 52 | Tcl_SetResult(interp, 53 | "This implementation of Togl does not support stubs", 54 | TCL_STATIC); 55 | return NULL; 56 | } 57 | 58 | return actualVersion; 59 | } 60 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/basegeom.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include "meshing.hpp" 3 | 4 | namespace netgen 5 | { 6 | 7 | DLL_HEADER GeometryRegisterArray geometryregister; 8 | //DLL_HEADER Array geometryregister; 9 | 10 | GeometryRegister :: ~GeometryRegister() 11 | { ; } 12 | 13 | 14 | 15 | 16 | 17 | int NetgenGeometry :: GenerateMesh (shared_ptr & mesh, MeshingParameters & mparam, 18 | int perfstepsstart, int perfstepsend) 19 | { 20 | if (!mesh) return 1; 21 | 22 | if (perfstepsstart <= MESHCONST_MESHVOLUME) 23 | { 24 | multithread.task = "Volume meshing"; 25 | 26 | MESHING3_RESULT res = 27 | MeshVolume (mparam, *mesh); 28 | 29 | if (res != MESHING3_OK) return 1; 30 | 31 | if (multithread.terminate) return 0; 32 | 33 | RemoveIllegalElements (*mesh); 34 | if (multithread.terminate) return 0; 35 | 36 | MeshQuality3d (*mesh); 37 | } 38 | 39 | 40 | if (multithread.terminate || perfstepsend <= MESHCONST_MESHVOLUME) 41 | return 0; 42 | 43 | 44 | if (perfstepsstart <= MESHCONST_OPTVOLUME) 45 | { 46 | multithread.task = "Volume optimization"; 47 | 48 | OptimizeVolume (mparam, *mesh); 49 | if (multithread.terminate) return 0; 50 | } 51 | 52 | return 0; 53 | } 54 | 55 | 56 | const Refinement & NetgenGeometry :: GetRefinement () const 57 | { 58 | return *new Refinement;; 59 | } 60 | 61 | 62 | void NetgenGeometry :: Save (string filename) const 63 | { 64 | throw NgException("Cannot save geometry - no geometry available"); 65 | } 66 | 67 | } 68 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/index.tcl: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # the next line restarts using tclsh \ 3 | exec tclsh "$0" "$@" 4 | 5 | # $Id: index.tcl,v 1.8 2007/08/03 16:48:50 gregcouch Exp $ 6 | 7 | # Togl - a Tk OpenGL widget 8 | # Copyright (C) 1996 Brian Paul and Ben Bederson 9 | # Copyright (C) 2006-2007 Greg Couch 10 | # See the LICENSE file for copyright details. 11 | 12 | 13 | # A Tk/OpenGL widget demo using color-index mode. 14 | 15 | package provide index 1.0 16 | 17 | # add parent directory to path to find Togl's pkgIndex in current directory 18 | if { [file exists pkgIndex.tcl] } { 19 | set auto_path [linsert $auto_path 0 ..] 20 | } 21 | # following load also loads Tk and Togl packages 22 | load [file dirname [info script]]/index[info sharedlibextension] 23 | 24 | # create ::index namespace 25 | namespace eval ::index { 26 | } 27 | 28 | proc ::index::setup {} { 29 | wm title . "Color index demo" 30 | 31 | togl .win -width 200 -height 200 -rgba false -double true -privatecmap false -time 10 -timer ::index::timer_cb -create ::index::create_cb -reshape ::index::reshape_cb -display ::index::display_cb 32 | button .photo -text "Take Photo" -command ::index::take_photo 33 | button .btn -text Quit -command exit 34 | 35 | pack .win -expand true -fill both 36 | pack .photo -expand true -fill both 37 | pack .btn -expand true -fill both 38 | } 39 | 40 | proc ::index::take_photo {} { 41 | image create photo img 42 | .win takephoto img 43 | img write image.ppm -format ppm 44 | } 45 | 46 | 47 | # Execution starts here! 48 | if { [info script] == $argv0 } { 49 | ::index::setup 50 | } 51 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Spliter.jxx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, 4 | // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 5 | // 6 | // This library is free software; you can redistribute it and/or 7 | // modify it under the terms of the GNU Lesser General Public 8 | // License as published by the Free Software Foundation; either 9 | // version 2.1 of the License. 10 | // 11 | // This library is distributed in the hope that it will be useful, 12 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | // Lesser General Public License for more details. 15 | // 16 | // You should have received a copy of the GNU Lesser General Public 17 | // License along with this library; if not, write to the Free Software 18 | // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | // 20 | // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 21 | // 22 | // 23 | // 24 | // File : Partition_Spliter.jxx 25 | // Module : GEOM 26 | 27 | #ifndef _BRepAlgo_AsDes_HeaderFile 28 | #include 29 | #endif 30 | #ifndef _TopoDS_Shape_HeaderFile 31 | #include 32 | #endif 33 | #ifndef _TopTools_ListOfShape_HeaderFile 34 | #include 35 | #endif 36 | #ifndef _TopoDS_Edge_HeaderFile 37 | #include 38 | #endif 39 | #ifndef _Partition_Spliter_HeaderFile 40 | #include "Partition_Spliter.hxx" 41 | #endif 42 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/include/mydefs.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_MYDEFS 2 | #define FILE_MYDEFS 3 | 4 | /**************************************************************************/ 5 | /* File: mydefs.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 10. Mar. 98 */ 8 | /**************************************************************************/ 9 | 10 | /* 11 | defines for graphics, testmodes, ... 12 | */ 13 | 14 | 15 | // #define DEBUG 16 | 17 | // Philippose - 31/01/2009 18 | // Hack for the Windows Version 19 | // in Linux, "PACKAGE_VERSION" is replaced 20 | // in the configure/make phases, with the 21 | // right version number 22 | #ifdef WIN32 23 | #ifndef PACKAGE_VERSION 24 | #define PACKAGE_VERSION "6.1.0" 25 | #endif 26 | #endif 27 | 28 | 29 | #ifdef WIN32 30 | #if NGINTERFACE_EXPORTS || NGLIB_EXPORTS || nglib_EXPORTS 31 | #define DLL_HEADER __declspec(dllexport) 32 | #else 33 | #define DLL_HEADER __declspec(dllimport) 34 | #endif 35 | #else 36 | #define DLL_HEADER 37 | #endif 38 | 39 | 40 | 41 | 42 | #ifndef __assume 43 | #ifdef __GNUC__ 44 | #define __assume(cond) if (!(cond)) __builtin_unreachable(); else; 45 | #else 46 | #define __assume(cond) 47 | #endif 48 | #endif 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | #define noDEMOVERSION 57 | #define noDEVELOP 58 | #define noSTEP 59 | #define noSOLIDGEOM 60 | 61 | #define noDEMOAPP 62 | #define noMODELLER 63 | 64 | #define noSTAT_STREAM 65 | #define noLOG_STREAM 66 | 67 | #endif 68 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/stlgeom/vsstl.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_VSSTL 2 | #define FILE_VSSTL 3 | 4 | /**************************************************************************/ 5 | /* File: vsstl.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 05. Jan. 2011 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | class VisualSceneSTLGeometry : public VisualScene 14 | { 15 | Array trilists; 16 | class STLGeometry * stlgeometry; 17 | 18 | public: 19 | DLL_HEADER VisualSceneSTLGeometry (); 20 | DLL_HEADER virtual ~VisualSceneSTLGeometry (); 21 | DLL_HEADER void SetGeometry (class STLGeometry * astlgeometry) { stlgeometry = astlgeometry; } 22 | 23 | DLL_HEADER virtual void BuildScene (int zoomall = 0); 24 | DLL_HEADER virtual void DrawScene (); 25 | }; 26 | 27 | 28 | class VisualSceneSTLMeshing : public VisualScene 29 | { 30 | Array trilists; 31 | int selecttrig, nodeofseltrig; 32 | class STLGeometry * stlgeometry; 33 | 34 | public: 35 | DLL_HEADER VisualSceneSTLMeshing (); 36 | DLL_HEADER virtual ~VisualSceneSTLMeshing (); 37 | 38 | void SetGeometry (class STLGeometry * astlgeometry) { stlgeometry = astlgeometry; } 39 | 40 | virtual void BuildScene (int zoomall = 0); 41 | virtual void DrawScene (); 42 | virtual void MouseDblClick (int px, int py); 43 | 44 | int seltria; 45 | }; 46 | 47 | 48 | 49 | } 50 | 51 | 52 | 53 | #endif 54 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Loop.jxx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, 4 | // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 5 | // 6 | // This library is free software; you can redistribute it and/or 7 | // modify it under the terms of the GNU Lesser General Public 8 | // License as published by the Free Software Foundation; either 9 | // version 2.1 of the License. 10 | // 11 | // This library is distributed in the hope that it will be useful, 12 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | // Lesser General Public License for more details. 15 | // 16 | // You should have received a copy of the GNU Lesser General Public 17 | // License along with this library; if not, write to the Free Software 18 | // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | // 20 | // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 21 | // 22 | // 23 | // 24 | // File : Partition_Loop.jxx 25 | // Module : GEOM 26 | 27 | #ifndef _TopoDS_Face_HeaderFile 28 | #include 29 | #endif 30 | #ifndef _TopoDS_Edge_HeaderFile 31 | #include 32 | #endif 33 | #ifndef _TopTools_ListOfShape_HeaderFile 34 | #include 35 | #endif 36 | #ifndef _TopTools_DataMapOfShapeShape_HeaderFile 37 | #include 38 | #endif 39 | #ifndef _Partition_Loop_HeaderFile 40 | #include "Partition_Loop.hxx" 41 | #endif 42 | -------------------------------------------------------------------------------- /netgen-6.1-src/nglib/Makefile.am: -------------------------------------------------------------------------------- 1 | include_HEADERS = nglib.h 2 | 3 | dist_pkgdata_DATA = cube.surf 4 | 5 | AM_CPPFLAGS = -I$(top_srcdir)/libsrc/include $(MPI_INCLUDES) $(OCCFLAGS) 6 | 7 | lib_LTLIBRARIES = libnglib.la 8 | libnglib_la_SOURCES = nglib.cpp 9 | 10 | libnglib_la_LIBADD = \ 11 | $(top_builddir)/libsrc/interface/libinterface.la \ 12 | $(top_builddir)/libsrc/geom2d/libgeom2d.la \ 13 | $(top_builddir)/libsrc/csg/libcsg.la \ 14 | $(top_builddir)/libsrc/stlgeom/libstl.la \ 15 | $(top_builddir)/libsrc/occ/libocc.la \ 16 | $(top_builddir)/libsrc/meshing/libmesh.la \ 17 | $(OCCLIBS) $(MPI_LIBS) 18 | 19 | libnglib_la_LDFLAGS = -avoid-version 20 | # -rdynamic 21 | 22 | 23 | bin_PROGRAMS = ng_vol ng_stl 24 | # ng_occ 25 | 26 | ng_vol_SOURCES = ng_vol.cpp 27 | ng_vol_LDADD = libnglib.la \ 28 | $(top_builddir)/libsrc/interface/libinterface.la \ 29 | $(top_builddir)/libsrc/geom2d/libgeom2d.la \ 30 | $(top_builddir)/libsrc/csg/libcsg.la \ 31 | $(top_builddir)/libsrc/stlgeom/libstl.la \ 32 | $(top_builddir)/libsrc/occ/libocc.la \ 33 | $(top_builddir)/libsrc/meshing/libmesh.la \ 34 | $(OCCLIBS) $(MPI_LIBS) 35 | 36 | 37 | 38 | ng_stl_SOURCES = ng_stl.cpp 39 | ng_stl_LDADD = libnglib.la \ 40 | $(top_builddir)/libsrc/interface/libinterface.la \ 41 | $(top_builddir)/libsrc/geom2d/libgeom2d.la \ 42 | $(top_builddir)/libsrc/csg/libcsg.la \ 43 | $(top_builddir)/libsrc/stlgeom/libstl.la \ 44 | $(top_builddir)/libsrc/occ/libocc.la \ 45 | $(top_builddir)/libsrc/meshing/libmesh.la \ 46 | $(OCCLIBS) $(MPI_LIBS) 47 | 48 | # ng_occ_SOURCES = ng_occ.cpp 49 | # ng_occ_LDADD = libnglib.la 50 | 51 | dist_bin_SCRIPTS = netgen.py 52 | 53 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/LICENSE: -------------------------------------------------------------------------------- 1 | This software is copyrighted by Brian Paul (brian@mesa3d.org), 2 | Benjamin Bederson (bederson@cs.umd.edu), and Greg Couch 3 | (gregcouch@users.sourceforge.net). The following terms apply to all 4 | files associated with the software unless explicitly disclaimed in 5 | individual files. 6 | 7 | The authors hereby grant permission to use, copy, modify, distribute, 8 | and license this software and its documentation for any purpose, provided 9 | that existing copyright notices are retained in all copies and that this 10 | notice is included verbatim in any distributions. No written agreement, 11 | license, or royalty fee is required for any of the authorized uses. 12 | Modifications to this software may be copyrighted by their authors 13 | and need not follow the licensing terms described here, provided that 14 | the new terms are clearly indicated on the first page of each file where 15 | they apply. 16 | 17 | IN NO EVENT SHALL THE AUTHORS OR DISTRIBUTORS BE LIABLE TO ANY PARTY 18 | FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES 19 | ARISING OUT OF THE USE OF THIS SOFTWARE, ITS DOCUMENTATION, OR ANY 20 | DERIVATIVES THEREOF, EVEN IF THE AUTHORS HAVE BEEN ADVISED OF THE 21 | POSSIBILITY OF SUCH DAMAGE. 22 | 23 | THE AUTHORS AND DISTRIBUTORS SPECIFICALLY DISCLAIM ANY WARRANTIES, 24 | INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY, 25 | FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT. THIS SOFTWARE 26 | IS PROVIDED ON AN "AS IS" BASIS, AND THE AUTHORS AND DISTRIBUTORS HAVE 27 | NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR 28 | MODIFICATIONS. 29 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/extrusion.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | 3 | curve2d procurve1=(8; 4 | -1,0; 5 | -0.7,0.7; 6 | 0,1; 7 | 0.7,0.7; 8 | 1,0; 9 | 0.7,-0.7; 10 | 0,-1; 11 | -0.7,-0.7; 12 | 4; 13 | 3,1,2,3; 14 | 3,3,4,5; 15 | 3,5,6,7; 16 | 3,7,8,1); 17 | 18 | curve2d procurve2=(4; 19 | 1,1; 20 | 1,-1; 21 | -1,-1; 22 | -1,1; 23 | 4; 24 | 2,1,2; 25 | 2,2,3; 26 | 2,3,4; 27 | 2,4,1); 28 | 29 | 30 | 31 | curve3d pathcurve1=(9; 32 | 0,0,0; 33 | 10,0,5; 34 | 10,10,10; 35 | 10,20,15; 36 | 0,20,20; 37 | -10,20,25; 38 | -10,10,30; 39 | -10,0,35; 40 | 0,0,40; 41 | 4; 42 | 3,1,2,3; 43 | 3,3,4,5; 44 | 3,5,6,7; 45 | 3,7,8,9); 46 | 47 | curve3d pathcurve2=(2; 48 | 0,0,0; 49 | 0,10,0; 50 | 1; 51 | 2,1,2); 52 | 53 | 54 | curve3d pathcurve3=(3; 55 | 0,0,0; 56 | 10,0,5; 57 | 10,10,10; 58 | 1; 59 | 3,1,2,3); 60 | 61 | curve3d pathcurve4=(9; 62 | 0,0,0; 63 | 10,0,0; 64 | 10,10,0; 65 | 10,20,0; 66 | 0,20,0; 67 | -10,20,0; 68 | -10,10,0; 69 | -10,0,0; 70 | 0,0,0; 71 | 4; 72 | 3,1,2,3; 73 | 3,3,4,5; 74 | 3,5,6,7; 75 | 3,7,8,9); 76 | 77 | 78 | solid p1 = plane(1,0,0;-1,0,0); 79 | solid p2 = plane(10,9,10;0,1,0); 80 | solid p3 = plane(0,1,0;0,-1,0); 81 | solid p4 = plane(0,9,0;0,1,0); 82 | 83 | solid ob1 = orthobrick(-1,-5,-5;1,5,45); 84 | 85 | solid ext = extrusion(pathcurve1;procurve2;0,0,1) and not ob1; 86 | 87 | #solid ext = extrusion(pathcurve4;procurve2;0,0,1); 88 | 89 | #solid ext = extrusion(pathcurve3;procurve1;0,0,1) and p1 and p2; 90 | 91 | #solid ext = extrusion(pathcurve2;procurve2;0,0,1) and p3 and p4; 92 | 93 | solid sp = sphere(0,0,0;4); 94 | 95 | solid comb = sp or ext; 96 | 97 | #tlo ext; 98 | 99 | tlo comb; -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/curve2d.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_CURVE2D 2 | #define FILE_CURVE2D 3 | 4 | /**************************************************************************/ 5 | /* File: curve2d.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 24. Jul. 96 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | 14 | /* 15 | 16 | 2D Curve repesentation 17 | 18 | */ 19 | 20 | 21 | 22 | /// 23 | class Curve2d : public Manifold 24 | { 25 | public: 26 | /// 27 | virtual void Project (Point<2> & p) const = 0; 28 | /// 29 | virtual void NormalVector (const Point<2> & p, Vec<2> & n) const = 0; 30 | }; 31 | 32 | /// 33 | class CircleCurve2d : public Curve2d 34 | { 35 | /// 36 | Point<2> center; 37 | /// 38 | double rad; 39 | public: 40 | /// 41 | CircleCurve2d (const Point<2> & acenter, double arad); 42 | /// 43 | virtual void Project (Point<2> & p) const; 44 | /// 45 | virtual void NormalVector (const Point<2> & p, Vec<2> & n) const; 46 | }; 47 | 48 | /// 49 | class QuadraticCurve2d : public Curve2d 50 | { 51 | /// 52 | double cxx, cyy, cxy, cx, cy, c; 53 | public: 54 | /// 55 | QuadraticCurve2d (); 56 | /// 57 | void Read (istream & ist); 58 | /// 59 | virtual void Project (Point<2> & p) const; 60 | /// 61 | virtual void NormalVector (const Point<2> & p, Vec<2> & n) const; 62 | }; 63 | 64 | 65 | } 66 | 67 | #endif 68 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/lense.in2d: -------------------------------------------------------------------------------- 1 | splinecurves2dv2 2 | 5 3 | 4 | 5 | points 6 | 7 | 1 -1.0 -1.0 8 | 2 -1.0 1.0 9 | 3 0.0 1.0 10 | 4 1.0 1.0 11 | 5 1.0 -1.0 12 | 6 0.0 -1.0 13 | 14 | 15 | segments 16 | 0 1 2 6 1 -bc=1 17 | 0 1 2 1 2 -bc=1 18 | 0 1 2 2 3 -bc=1 19 | 20 | 21 | 0 2 2 3 4 -bc=1 22 | 0 2 2 4 5 -bc=1 23 | 0 2 2 5 6 -bc=1 24 | 25 | 26 | 27 | 28 | 1 3 bsplinepoints 21 4 29 | 0 -1.0000 30 | -0.0380 -0.9000 31 | -0.0720 -0.8000 32 | -0.1020 -0.7000 33 | -0.1280 -0.6000 34 | -0.1500 -0.5000 35 | -0.1680 -0.4000 36 | -0.1820 -0.3000 37 | -0.1920 -0.2000 38 | -0.1980 -0.1000 39 | -0.2000 0 40 | -0.1980 0.1000 41 | -0.1920 0.2000 42 | -0.1820 0.3000 43 | -0.1680 0.4000 44 | -0.1500 0.5000 45 | -0.1280 0.6000 46 | -0.1020 0.7000 47 | -0.0720 0.8000 48 | -0.0380 0.9000 49 | 0 1.0000 50 | -bc=2 -maxh=0.1 51 | 52 | 3 2 bsplinepoints 21 3 53 | 0 -1.0000 54 | 0.0380 -0.9000 55 | 0.0720 -0.8000 56 | 0.1020 -0.7000 57 | 0.1280 -0.6000 58 | 0.1500 -0.5000 59 | 0.1680 -0.4000 60 | 0.1820 -0.3000 61 | 0.1920 -0.2000 62 | 0.1980 -0.1000 63 | 0.2000 0 64 | 0.1980 0.1000 65 | 0.1920 0.2000 66 | 0.1820 0.3000 67 | 0.1680 0.4000 68 | 0.1500 0.5000 69 | 0.1280 0.6000 70 | 0.1020 0.7000 71 | 0.0720 0.8000 72 | 0.0380 0.9000 73 | 0 1.0000 74 | -bc=2 -maxh=0.1 75 | 76 | 77 | materials 78 | 1 domain1 -maxh=0.2 79 | 2 domain2 -maxh=0.2 80 | 3 domain3 -maxh=0.2 81 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl-1.7/.indent.pro: -------------------------------------------------------------------------------- 1 | --blank-before-sizeof 2 | --blank-lines-after-declarations 3 | --blank-lines-after-procedures 4 | --blank-lines-before-block-comments 5 | --braces-after-struct-decl-line 6 | --braces-on-if-line 7 | --break-before-boolean-operator 8 | --case-brace-indentation0 9 | --case-indentation2 10 | --comment-line-length80 11 | --continuation-indentation8 12 | --cuddle-do-while 13 | --cuddle-else 14 | --declaration-indentation8 15 | --dont-line-up-parentheses 16 | --format-all-comments 17 | --format-first-column-comments 18 | --indent-level4 19 | --leave-optional-blank-lines 20 | --line-length80 21 | --no-space-after-function-call-names 22 | --no-space-after-parentheses 23 | --no-tabs 24 | --parameter-indentation8 25 | --preprocessor-indentation2 26 | --procnames-start-lines 27 | --space-after-cast 28 | --space-after-for 29 | --space-after-if 30 | --space-after-while 31 | --space-special-semicolon 32 | --start-left-side-of-comments 33 | --struct-brace-indentation0 34 | --tab-size8 35 | -T AGLContext 36 | -T CALLBACK 37 | -T ClientData 38 | -T Colormap 39 | -T Display 40 | -T GLXContext 41 | -T GLbitfield 42 | -T GLboolean 43 | -T GLenum 44 | -T GLfloat 45 | -T GLint 46 | -T GLuint 47 | -T HDC 48 | -T HGLRC 49 | -T HWND 50 | -T LPARAM 51 | -T PIXELFORMATDESCRIPTOR 52 | -T Tcl_Command 53 | -T Tcl_Interp 54 | -T TkClassCreateProc 55 | -T TkClassGeometryProc 56 | -T TkClassModalProc 57 | -T TkClassProcs 58 | -T TkWinColormap 59 | -T Tk_ConfigSpec 60 | -T Tk_Cursor 61 | -T Tk_Window 62 | -T Togl_Callback 63 | -T Togl_CmdProc 64 | -T UINT 65 | -T WPARAM 66 | -T WinFont 67 | -T Window 68 | -T XColor 69 | -T XEvent 70 | -T XVisualInfo 71 | -T TOGL_EXTERN 72 | -T Togl 73 | -------------------------------------------------------------------------------- /netgen-6.1-src/cmake_modules/netgen_fixup.cmake: -------------------------------------------------------------------------------- 1 | include(BundleUtilities) 2 | function(netgen_fixup_bundle app libs dirs) 3 | message(STATUS "fixup_bundle") 4 | message(STATUS " app='${app}'") 5 | message(STATUS " libs='${libs}'") 6 | message(STATUS " dirs='${dirs}'") 7 | 8 | get_bundle_and_executable("${app}" bundle executable valid) 9 | if(valid) 10 | get_filename_component(exepath "${executable}" PATH) 11 | 12 | message(STATUS "fixup_bundle: preparing...") 13 | get_bundle_keys("${app}" "${libs}" "${dirs}" keys) 14 | 15 | message(STATUS "fixup_bundle: copying...") 16 | list(LENGTH keys n) 17 | math(EXPR n ${n}*2) 18 | 19 | set(i 0) 20 | foreach(key ${keys}) 21 | math(EXPR i ${i}+1) 22 | if(${${key}_COPYFLAG}) 23 | set(item "${${key}_ITEM}") 24 | if(item MATCHES "[^/]+\\.framework/") 25 | copy_resolved_framework_into_bundle("${${key}_RESOLVED_ITEM}" 26 | "${${key}_RESOLVED_EMBEDDED_ITEM}") 27 | else() 28 | copy_resolved_item_into_bundle("${${key}_RESOLVED_ITEM}" 29 | "${${key}_RESOLVED_EMBEDDED_ITEM}") 30 | endif() 31 | endif() 32 | endforeach() 33 | 34 | message(STATUS "fixup_bundle: fixing...") 35 | foreach(key ${keys}) 36 | math(EXPR i ${i}+1) 37 | message(STATUS "${i}/${n}: fixing up '${${key}_RESOLVED_EMBEDDED_ITEM}'") 38 | fixup_bundle_item("${${key}_RESOLVED_EMBEDDED_ITEM}" "${exepath}" "${dirs}") 39 | endforeach() 40 | 41 | message(STATUS "fixup_bundle: cleaning up...") 42 | clear_bundle_keys(keys) 43 | 44 | else() 45 | message(SEND_ERROR "error: fixup_bundle: not a valid bundle") 46 | endif() 47 | 48 | message(STATUS "fixup_bundle: done") 49 | endfunction() 50 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/ngpython.hpp: -------------------------------------------------------------------------------- 1 | #ifdef NG_PYTHON 2 | 3 | #include 4 | #include 5 | namespace py = pybind11; 6 | #include 7 | #include 8 | 9 | namespace pybind11 { 10 | template 11 | bool CheckCast( py::handle obj ) { 12 | try{ 13 | obj.cast(); 14 | return true; 15 | } 16 | catch (py::cast_error &e) { 17 | return false; 18 | } 19 | } 20 | 21 | 22 | template 23 | struct extract 24 | { 25 | py::handle obj; 26 | extract( py::handle aobj ) : obj(aobj) {} 27 | 28 | bool check() { return CheckCast(obj); } 29 | T operator()() { return obj.cast(); } 30 | }; 31 | } 32 | 33 | struct NGDummyArgument {}; 34 | 35 | inline void NOOP_Deleter(void *) { ; } 36 | 37 | namespace netgen 38 | { 39 | 40 | ////////////////////////////////////////////////////////////////////// 41 | // Lambda to function pointer conversion 42 | template 43 | struct function_traits 44 | : public function_traits {}; 45 | 46 | template 47 | struct function_traits { 48 | typedef ReturnType (*pointer)(Args...); 49 | typedef ReturnType return_type; 50 | }; 51 | 52 | template 53 | typename function_traits::pointer 54 | FunctionPointer (const Function& lambda) { 55 | return static_cast::pointer>(lambda); 56 | } 57 | 58 | 59 | template 60 | inline std::string ToString (const T& t) 61 | { 62 | std::stringstream ss; 63 | ss << t; 64 | return ss.str(); 65 | } 66 | 67 | } 68 | 69 | #endif 70 | 71 | -------------------------------------------------------------------------------- /netgen-6.1-src/tutorials/trafo.geo: -------------------------------------------------------------------------------- 1 | algebraic3d 2 | # 3 | # a transformer 4 | # 5 | solid core = 6 | plane (-8, 0, 0; -1, 0, 0) 7 | and plane ( 8, 0, 0; 1, 0, 0) 8 | and plane ( 0, -6, 0; 0, -1, 0) 9 | and plane ( 0, 6, 0; 0, 1, 0) 10 | and plane ( 0, 0, -1; 0, 0, -1) 11 | and plane ( 0, 0, 1; 0, 0, 1) 12 | and not 13 | ( plane (-6, 0, 0; -1, 0, 0) 14 | and plane (-1, 0, 0; 1, 0, 0) 15 | and plane ( 0, -4, 0; 0, -1, 0) 16 | and plane ( 0, 4, 0; 0, 1, 0) ) 17 | and not 18 | ( plane ( 6, 0, 0; 1, 0, 0) 19 | and plane ( 1, 0, 0; -1, 0, 0) 20 | and plane ( 0, -4, 0; 0, -1, 0) 21 | and plane ( 0, 4, 0; 0, 1, 0) ); 22 | 23 | solid coil1 = 24 | cylinder (-7, -3, 0;-7, 3, 0; 3) 25 | and not cylinder (-7, -3, 0;-7, 3, 0; 2) 26 | and plane (0, -3, 0; 0, -1, 0) 27 | and plane (0, 3, 0; 0, 1, 0); 28 | solid coil2 = 29 | cylinder ( 0, -3, 0; 0, 3, 0; 3) 30 | and not cylinder ( 0, -3, 0; 0, 3, 0; 2) 31 | and plane (0, -3, 0; 0, -1, 0) 32 | and plane (0, 3, 0; 0, 1, 0); 33 | solid coil3 = 34 | cylinder ( 7, -3, 0; 7, 3, 0; 3) 35 | and not cylinder ( 7, -3, 0; 7, 3, 0; 2) 36 | and plane (0, -3, 0; 0, -1, 0) 37 | and plane (0, 3, 0; 0, 1, 0); 38 | 39 | solid box = 40 | plane (-12, 0, 0; -1, 0, 0) 41 | and plane ( 12, 0, 0; 1, 0, 0) 42 | and plane ( 0, 8, 0; 0, 1, 0) 43 | and plane ( 0,-8, 0; 0, -1, 0) 44 | and plane ( 0, 0, 5; 0, 0, 1) 45 | and plane ( 0, 0, -5; 0, 0, -1); 46 | 47 | solid air = box and not core and not coil1 and not coil2 and not coil3; 48 | 49 | tlo coil1 -col=[0,1,0]; 50 | tlo coil2 -col=[0,1,0]; 51 | tlo coil3 -col=[0,1,0]; 52 | tlo air -col=[0,0,1] -transparent; 53 | tlo core -col=[1,1,0]; 54 | 55 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/global.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_GLOBAL 2 | #define FILE_GLOBAL 3 | 4 | 5 | /**************************************************************************/ 6 | /* File: global.hh */ 7 | /* Author: Joachim Schoeberl */ 8 | /* Date: 01. Okt. 95 */ 9 | /**************************************************************************/ 10 | 11 | /* 12 | global functions and variables 13 | */ 14 | 15 | namespace netgen 16 | { 17 | 18 | /// 19 | DLL_HEADER extern double GetTime (); 20 | DLL_HEADER extern void ResetTime (); 21 | 22 | /// 23 | DLL_HEADER extern int testmode; 24 | 25 | /// calling parameters 26 | // extern Flags parameters; 27 | 28 | // extern DLL_HEADER MeshingParameters mparam; 29 | 30 | DLL_HEADER extern Array tets_in_qualclass; 31 | 32 | DLL_HEADER extern mutex tcl_todo_mutex; 33 | 34 | class multithreadt 35 | { 36 | public: 37 | int pause; 38 | int testmode; 39 | int redraw; 40 | int drawing; 41 | int terminate; 42 | int running; 43 | double percent; 44 | const char * task; 45 | bool demorunning; 46 | string * tcl_todo = new string(""); // tcl commands set from parallel thread 47 | multithreadt(); 48 | }; 49 | 50 | DLL_HEADER extern volatile multithreadt multithread; 51 | 52 | DLL_HEADER extern string ngdir; 53 | DLL_HEADER extern DebugParameters debugparam; 54 | DLL_HEADER extern bool verbose; 55 | 56 | DLL_HEADER extern int h_argc; 57 | DLL_HEADER extern char ** h_argv; 58 | 59 | 60 | DLL_HEADER extern weak_ptr global_mesh; 61 | DLL_HEADER void SetGlobalMesh (shared_ptr m); 62 | } 63 | 64 | #endif 65 | -------------------------------------------------------------------------------- /netgen-6.1-src/windows/nglib.sln: -------------------------------------------------------------------------------- 1 | 2 | Microsoft Visual Studio Solution File, Format Version 13.00 3 | # Visual Studio 2013 4 | Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "nglib", "nglib.vcxproj", "{2E260C8C-595C-442A-A962-51AC06EF8143}" 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 8 | Debug|Win32 = Debug|Win32 9 | Debug|x64 = Debug|x64 10 | Release(OCC)|Win32 = Release(OCC)|Win32 11 | Release(OCC)|x64 = Release(OCC)|x64 12 | Release|Win32 = Release|Win32 13 | Release|x64 = Release|x64 14 | EndGlobalSection 15 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 16 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Debug|Win32.ActiveCfg = Debug|Win32 17 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Debug|Win32.Build.0 = Debug|Win32 18 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Debug|x64.ActiveCfg = Debug|x64 19 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Debug|x64.Build.0 = Debug|x64 20 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Release(OCC)|Win32.ActiveCfg = Release(OCC)|Win32 21 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Release(OCC)|Win32.Build.0 = Release(OCC)|Win32 22 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Release(OCC)|x64.ActiveCfg = Release(OCC)|x64 23 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Release(OCC)|x64.Build.0 = Release(OCC)|x64 24 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Release|Win32.ActiveCfg = Release|Win32 25 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Release|Win32.Build.0 = Release|Win32 26 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Release|x64.ActiveCfg = Release|x64 27 | {2E260C8C-595C-442A-A962-51AC06EF8143}.Release|x64.Build.0 = Release|x64 28 | EndGlobalSection 29 | GlobalSection(SolutionProperties) = preSolution 30 | HideSolutionNode = FALSE 31 | EndGlobalSection 32 | EndGlobal 33 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CPPFLAGS = $(MPI_INCLUDES) -I$(top_srcdir)/libsrc/include 2 | 3 | 4 | noinst_HEADERS = adfront2.hpp hpref_quad.hpp meshfunc.hpp ruler3.hpp \ 5 | adfront3.hpp findip.hpp findip2.hpp hpref_segm.hpp meshing2.hpp \ 6 | specials.hpp bisect.hpp geomsearch.hpp hpref_tet.hpp meshing3.hpp \ 7 | topology.hpp boundarylayer.hpp global.hpp hpref_trig.hpp meshing.hpp \ 8 | validate.hpp classifyhpel.hpp hpref_hex.hpp improve2.hpp meshtool.hpp \ 9 | clusters.hpp hprefinement.hpp improve3.hpp meshtype.hpp \ 10 | hpref_prism.hpp localh.hpp msghandler.hpp curvedelems.hpp \ 11 | hpref_pyramid.hpp meshclass.hpp ruler2.hpp bcfunctions.hpp \ 12 | basegeom.hpp 13 | 14 | 15 | 16 | METASOURCES = AUTO 17 | 18 | lib_LTLIBRARIES = libmesh.la 19 | 20 | libmesh_la_SOURCES = adfront2.cpp adfront3.cpp bisect.cpp boundarylayer.cpp \ 21 | clusters.cpp curvedelems.cpp delaunay.cpp delaunay2d.cpp \ 22 | geomsearch.cpp global.cpp hprefinement.cpp improve2.cpp \ 23 | improve2gen.cpp improve3.cpp localh.cpp meshclass.cpp \ 24 | meshfunc.cpp meshfunc2d.cpp meshing2.cpp meshing3.cpp \ 25 | meshtool.cpp meshtype.cpp msghandler.cpp netrule2.cpp \ 26 | netrule3.cpp parser2.cpp parser3.cpp prism2rls.cpp \ 27 | pyramid2rls.cpp pyramidrls.cpp quadrls.cpp refine.cpp \ 28 | ruler2.cpp ruler3.cpp secondorder.cpp smoothing2.5.cpp \ 29 | smoothing2.cpp smoothing3.cpp specials.cpp tetrarls.cpp \ 30 | topology.cpp triarls.cpp validate.cpp bcfunctions.cpp \ 31 | parallelmesh.cpp paralleltop.cpp paralleltop.hpp basegeom.cpp \ 32 | python_mesh.cpp 33 | 34 | libmesh_la_LIBADD = $(top_builddir)/libsrc/linalg/libla.la \ 35 | $(top_builddir)/libsrc/gprim/libgprim.la \ 36 | $(top_builddir)/libsrc/general/libgen.la \ 37 | -lz $(MPI_LIBS) 38 | 39 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Inter2d.jxx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, 4 | // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 5 | // 6 | // This library is free software; you can redistribute it and/or 7 | // modify it under the terms of the GNU Lesser General Public 8 | // License as published by the Free Software Foundation; either 9 | // version 2.1 of the License. 10 | // 11 | // This library is distributed in the hope that it will be useful, 12 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | // Lesser General Public License for more details. 15 | // 16 | // You should have received a copy of the GNU Lesser General Public 17 | // License along with this library; if not, write to the Free Software 18 | // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | // 20 | // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 21 | // 22 | // 23 | // 24 | // File : Partition_Inter2d.jxx 25 | // Module : GEOM 26 | 27 | #include // netgen headers 28 | 29 | 30 | #ifndef _BRepAlgo_AsDes_HeaderFile 31 | #include 32 | #endif 33 | #ifndef _TopoDS_Face_HeaderFile 34 | #include 35 | #endif 36 | #ifndef _TopTools_MapOfShape_HeaderFile 37 | #include 38 | #endif 39 | #ifndef _TopoDS_Vertex_HeaderFile 40 | #include 41 | #endif 42 | #ifndef _TopTools_ListOfShape_HeaderFile 43 | #include 44 | #endif 45 | #ifndef _TopoDS_Edge_HeaderFile 46 | #include 47 | #endif 48 | #ifndef _Partition_Inter2d_HeaderFile 49 | #include "Partition_Inter2d.hxx" 50 | #endif 51 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/profiler.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_NG_PROFILER 2 | #define FILE_NG_PROFILER 3 | 4 | /**************************************************************************/ 5 | /* File: profiler.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 5. Jan. 2005 */ 8 | /**************************************************************************/ 9 | 10 | 11 | 12 | #ifdef VTRACE 13 | #include "vt_user.h" 14 | #else 15 | #define VT_USER_START(n) 16 | #define VT_USER_END(n) 17 | #define VT_TRACER(n) 18 | #endif 19 | 20 | namespace netgen 21 | { 22 | 23 | class NgProfiler 24 | { 25 | enum { SIZE = 1000 }; 26 | 27 | static long int tottimes[SIZE]; 28 | static long int starttimes[SIZE]; 29 | static long int counts[SIZE]; 30 | static string names[SIZE]; 31 | static int usedcounter[SIZE]; 32 | 33 | int total_timer; 34 | public: 35 | NgProfiler(); 36 | ~NgProfiler(); 37 | static int CreateTimer (const string & name); 38 | 39 | static void StartTimer (int nr) 40 | { 41 | starttimes[nr] = clock(); counts[nr]++; 42 | // VT_USER_START (const_cast (names[nr].c_str())); 43 | VT_USER_START ( (char * const) (names[nr].c_str())); 44 | } 45 | static void StopTimer (int nr) 46 | { 47 | tottimes[nr] += clock()-starttimes[nr]; 48 | VT_USER_END (const_cast (names[nr].c_str())); 49 | } 50 | 51 | //static void Print (ostream & ost); 52 | static void Print (FILE * prof); 53 | 54 | static void ClearTimers (); 55 | 56 | class RegionTimer 57 | { 58 | int nr; 59 | public: 60 | RegionTimer (int anr) : nr(anr) 61 | { StartTimer (nr); } 62 | ~RegionTimer () { StopTimer (nr); } 63 | }; 64 | }; 65 | 66 | } 67 | 68 | #endif 69 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/curve2d.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #include 4 | #include 5 | 6 | namespace netgen 7 | { 8 | CircleCurve2d :: CircleCurve2d (const Point<2> & acenter, double arad) 9 | { 10 | center = acenter; 11 | rad = arad; 12 | } 13 | 14 | void CircleCurve2d :: Project (Point<2> & p) const 15 | { 16 | Vec<2> v = p - center; 17 | v *= rad/v.Length(); 18 | p = center + v; 19 | } 20 | 21 | void CircleCurve2d :: NormalVector (const Point<2> & p, Vec<2> & n) const 22 | { 23 | n = p - center; 24 | n /= n.Length(); 25 | } 26 | 27 | 28 | 29 | 30 | 31 | 32 | QuadraticCurve2d :: QuadraticCurve2d () 33 | { 34 | cxx = cyy = cxy = cx = cy = c = 0; 35 | } 36 | 37 | void QuadraticCurve2d :: Read (istream & ist) 38 | { 39 | ist >> cxx >> cyy >> cxy >> cx >> cy >> c; 40 | } 41 | 42 | 43 | void QuadraticCurve2d :: Project (Point<2> & p) const 44 | { 45 | double f, x, y, gradx, grady, grad2; 46 | int its = 0; 47 | 48 | x = p(0); 49 | y = p(1); 50 | 51 | do 52 | { 53 | f = cxx * x * x + cyy * y * y + cxy * x * y + cx * x + cy * y + c; 54 | gradx = 2 * cxx * x + cxy * y + cx; 55 | grady = 2 * cyy * y + cxy * x + cy; 56 | grad2 = gradx * gradx + grady * grady; 57 | 58 | x -= f * gradx / grad2; 59 | y -= f * grady / grad2; 60 | 61 | // (*mycout) << "x = " << x << " y = " << y << " f = " << f << endl; 62 | its++; 63 | } 64 | while (fabs (f) > 1e-8 && its < 20); 65 | if (its >= 20) 66 | cerr << "QuadraticCurve2d::Project: many iterations, f = " << f << endl; 67 | p(0) = x; 68 | p(1) = y; 69 | } 70 | 71 | 72 | void QuadraticCurve2d :: NormalVector (const Point<2> & p, Vec<2> & n) const 73 | { 74 | n(0) = 2 * cxx * p(0) + cxy * p(1) + cx; 75 | n(1) = 2 * cyy * p(1) + cxy * p(0) + cy; 76 | n.Normalize(); 77 | } 78 | } 79 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/gprim/splinegeometry.hpp: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | 4 | JS, Nov 2007 5 | 6 | 7 | The 2D/3D template-base classes should go into the libsrc/gprim directory 8 | 9 | in geom2d only 2D - Geometry classes (with material properties etc.) 10 | 11 | 12 | */ 13 | 14 | #include "spline.hpp" 15 | 16 | 17 | #ifndef _FILE_SPLINEGEOMETRY 18 | #define _FILE_SPLINEGEOMETRY 19 | 20 | namespace netgen 21 | { 22 | 23 | 24 | template < int D > 25 | class SplineGeometry 26 | { 27 | // protected: 28 | public: 29 | Array < GeomPoint > geompoints; 30 | Array < SplineSeg* > splines; 31 | 32 | DLL_HEADER ~SplineGeometry(); 33 | 34 | DLL_HEADER int Load (const Array & raw_data, const int startpos = 0); 35 | 36 | DLL_HEADER void GetRawData (Array & raw_data) const; 37 | 38 | 39 | const Array*> & GetSplines () const 40 | { return splines; } 41 | 42 | int GetNSplines (void) const { return splines.Size(); } 43 | string GetSplineType (const int i) const { return splines[i]->GetType(); } 44 | SplineSeg & GetSpline (const int i) {return *splines[i];} 45 | const SplineSeg & GetSpline (const int i) const {return *splines[i];} 46 | 47 | DLL_HEADER void GetBoundingBox (Box & box) const; 48 | Box GetBoundingBox () const 49 | { Box box; GetBoundingBox (box); return box; } 50 | 51 | int GetNP () const { return geompoints.Size(); } 52 | const GeomPoint & GetPoint(int i) const { return geompoints[i]; } 53 | 54 | // void SetGrading (const double grading); 55 | DLL_HEADER void AppendPoint (const Point & p, const double reffac = 1., const bool hpref = false); 56 | 57 | 58 | void AppendSegment(SplineSeg * spline) 59 | { 60 | splines.Append (spline); 61 | } 62 | }; 63 | 64 | 65 | 66 | } 67 | 68 | #endif // _FILE_SPLINEGEOMETRY 69 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/geom2d/geom2dmesh.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_GEOM2DMESH 2 | #define FILE_GEOM2DMESH 3 | 4 | /**************************************************************************/ 5 | /* File: geom2dmesh.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 22. Jan. 01 */ 8 | /**************************************************************************/ 9 | 10 | 11 | namespace netgen 12 | { 13 | 14 | class Refinement2d : public Refinement 15 | { 16 | const class SplineGeometry2d & geometry; 17 | 18 | public: 19 | Refinement2d (const class SplineGeometry2d & ageometry); 20 | virtual ~Refinement2d (); 21 | 22 | virtual void PointBetween (const Point<3> & p1, const Point<3> & p2, double secpoint, 23 | int surfi, 24 | const PointGeomInfo & gi1, 25 | const PointGeomInfo & gi2, 26 | Point<3> & newp, PointGeomInfo & newgi) const; 27 | 28 | virtual void PointBetween (const Point<3> & p1, const Point<3> & p2, double secpoint, 29 | int surfi1, int surfi2, 30 | const EdgePointGeomInfo & ap1, 31 | const EdgePointGeomInfo & ap2, 32 | Point<3> & newp, EdgePointGeomInfo & newgi) const; 33 | 34 | 35 | virtual Vec<3> GetTangent (const Point<3> & p, int surfi1, int surfi2, 36 | const EdgePointGeomInfo & ap1) const; 37 | 38 | virtual Vec<3> GetNormal (const Point<3> & p, int surfi1, 39 | const PointGeomInfo & gi) const; 40 | 41 | virtual void ProjectToSurface (Point<3> & p, int surfi, const PointGeomInfo & /* gi */) const; 42 | 43 | virtual void ProjectToEdge (Point<3> & p, int surfi1, int surfi2, 44 | const EdgePointGeomInfo & egi) const; 45 | }; 46 | 47 | 48 | } 49 | 50 | 51 | 52 | #endif 53 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/parameters.tcl: -------------------------------------------------------------------------------- 1 | proc setgranularity { gran } { 2 | # 3 | # puts "set granularity $gran" 4 | # 5 | if {$gran == 6} { return } 6 | set gran [expr $gran - 1] 7 | # 8 | global options.curvaturesafety 9 | set surfcurvlist { 1 1.5 2 3 5 } 10 | set options.curvaturesafety [lindex $surfcurvlist $gran] 11 | 12 | global options.segmentsperedge 13 | set spelist { 0.3 0.5 1 2 3 } 14 | set options.segmentsperedge [lindex $spelist $gran] 15 | 16 | global stloptions.resthsurfcurvfac 17 | set surfcurvfaclist { 0.25 0.5 1 1.5 3 } 18 | set stloptions.resthsurfcurvfac [lindex $surfcurvfaclist $gran] 19 | 20 | global stloptions.resthchartdistfac 21 | set chartdistfaclist { 0.8 1 1.5 2 5 } 22 | set stloptions.resthchartdistfac [lindex $chartdistfaclist $gran] 23 | 24 | global stloptions.resthlinelengthfac 25 | set linelengthfaclist { 0.2 0.35 0.5 1.5 3 } 26 | set stloptions.resthlinelengthfac [lindex $linelengthfaclist $gran] 27 | 28 | global stloptions.resthcloseedgefac 29 | set closeedgefaclist { 0.5 1 2 3.5 5 } 30 | set stloptions.resthcloseedgefac [lindex $closeedgefaclist $gran] 31 | 32 | global stloptions.resthminedgelen 33 | set minedgelenlist { 0.002 0.02 0.2 1.0 2.0 5.0 10.0 } 34 | set stloptions.resthminedgelen [lindex $minedgelenlist $gran] 35 | 36 | global stloptions.resthedgeanglefac 37 | set edgeanglefaclist { 0.25 0.5 1 1.5 3 } 38 | set stloptions.resthedgeanglefac [lindex $edgeanglefaclist $gran] 39 | 40 | 41 | global stloptions.resthsurfmeshcurvfac 42 | set surfmeshcurvlist { 1 1.5 2 3 5 } 43 | set stloptions.resthsurfmeshcurvfac [lindex $surfmeshcurvlist $gran] 44 | 45 | 46 | global options.grading 47 | set gradinglist { 0.7 0.5 0.3 0.2 0.1 } 48 | set options.grading [lindex $gradinglist $gran] 49 | 50 | } 51 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/toglProcAddr.c: -------------------------------------------------------------------------------- 1 | /* $Id */ 2 | 3 | /* vi:set sw=4: */ 4 | 5 | /* 6 | * Togl - a Tk OpenGL widget 7 | * 8 | * Copyright (C) 1996-2002 Brian Paul and Ben Bederson 9 | * Copyright (C) 2005-2009 Greg Couch 10 | * See the LICENSE file for copyright details. 11 | */ 12 | 13 | #include "togl.h" 14 | 15 | #if defined(TOGL_OSMESA) || defined(TOGL_WGL) 16 | /* nothing extra to include */ 17 | #elif defined(__APPLE__) 18 | # include 19 | #else 20 | # if !defined(TOGL_X11) || !defined(GLX_VERSION_1_4) 21 | # include 22 | # endif 23 | #endif 24 | 25 | Togl_FuncPtr 26 | Togl_GetProcAddr(const char *funcname) 27 | { 28 | #if defined(TOGL_OSMESA) 29 | return (Togl_FuncPtr) OSMesaGetProcAddress(funcname); 30 | #elif defined(TOGL_WGL) 31 | return (Togl_FuncPtr) wglGetProcAddress(funcname); 32 | #elif defined(__APPLE__) 33 | char buf[256]; 34 | 35 | snprintf(buf, sizeof buf - 1, "_%s", funcname); 36 | buf[sizeof buf - 1] = '\0'; 37 | if (NSIsSymbolNameDefined(buf)) { 38 | NSSymbol nssym; 39 | 40 | nssym = NSLookupAndBindSymbol(buf); 41 | if (nssym) 42 | return (Togl_FuncPtr) NSAddressOfSymbol(nssym); 43 | } 44 | return NULL; 45 | #else 46 | # if defined(TOGL_X11) && defined(GLX_VERSION_1_4) 47 | /* Strictly speaking, we can only call glXGetProcAddress if glXQueryVersion 48 | * says we're using version 1.4 or later. */ 49 | return (Togl_FuncPtr) glXGetProcAddress(funcname); 50 | # else 51 | /* Linux, IRIX, OSF/1, ? */ 52 | static void *dlHandle = NULL; 53 | 54 | if (dlHandle == NULL) 55 | dlHandle = dlopen(NULL, RTLD_LAZY); 56 | /* Strictly speaking, the following cast of a data pointer to a function 57 | * pointer is not legal in ISO C, but we don't have any choice. */ 58 | return (Togl_FuncPtr) dlsym(dlHandle, funcname); 59 | # endif 60 | #endif 61 | } 62 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/meshing/basegeom.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_BASEGEOM 2 | #define FILE_BASEGEOM 3 | 4 | /**************************************************************************/ 5 | /* File: basegeom.hpp */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 23. Aug. 09 */ 8 | /**************************************************************************/ 9 | 10 | 11 | struct Tcl_Interp; 12 | 13 | namespace netgen 14 | { 15 | 16 | class DLL_HEADER NetgenGeometry 17 | { 18 | public: 19 | virtual ~NetgenGeometry () { ; } 20 | 21 | virtual int GenerateMesh (shared_ptr & mesh, MeshingParameters & mparam, 22 | int perfstepsstart, int perfstepsend); 23 | 24 | virtual const Refinement & GetRefinement () const; 25 | 26 | virtual void Save (string filename) const; 27 | virtual void SaveToMeshFile (ostream & /* ost */) const { ; } 28 | }; 29 | 30 | 31 | 32 | 33 | 34 | class DLL_HEADER GeometryRegister 35 | { 36 | public: 37 | virtual ~GeometryRegister(); 38 | virtual NetgenGeometry * Load (string filename) const = 0; 39 | virtual NetgenGeometry * LoadFromMeshFile (istream & /* ist */) const { return NULL; } 40 | virtual class VisualScene * GetVisualScene (const NetgenGeometry * /* geom */) const 41 | { return NULL; } 42 | virtual void SetParameters (Tcl_Interp * /* interp */) { ; } 43 | }; 44 | 45 | class DLL_HEADER GeometryRegisterArray : public Array 46 | { 47 | public: 48 | virtual ~GeometryRegisterArray() 49 | { 50 | for (int i = 0; i < Size(); i++) 51 | delete (*this)[i]; 52 | } 53 | }; 54 | 55 | // extern DLL_HEADER Array geometryregister; 56 | extern DLL_HEADER GeometryRegisterArray geometryregister; 57 | } 58 | 59 | 60 | 61 | #endif 62 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | set(netgen_sources demoview.cpp ngappinit.cpp onetcl.cpp parallelfunc.cpp ngpkg.cpp ../libsrc/stlgeom/stlpkg.cpp ../libsrc/visualization/visualpkg.cpp ../libsrc/csg/csgpkg.cpp ../libsrc/geom2d/geom2dpkg.cpp ../libsrc/occ/occpkg.cpp ../libsrc/occ/vsocc.cpp) 2 | 3 | if(USE_GUI) 4 | if(WIN32) 5 | # add icon to netgen executable 6 | enable_language(RC) 7 | set(netgen_sources ${netgen_sources} ../windows/netgen.rc) 8 | endif(WIN32) 9 | 10 | add_executable(netgen ${netgen_sources}) 11 | target_link_libraries( netgen nglib ${ZLIB_LIBRARIES} ${LIBTOGL} ${TK_LIBRARY} ${TCL_LIBRARY} ${JPEG_LIBRARIES} ${FFMPEG_LIBRARIES} ${X11_X11_LIB} ${OCC_LIBRARIES}) 12 | if(NOT WIN32) 13 | target_link_libraries( netgen mesh stlvis stl geom2dvis interface geom2d csg stl visual csgvis ) 14 | endif(NOT WIN32) 15 | 16 | install(TARGETS netgen ${ng_install_dir}) 17 | if(APPLE) 18 | set_target_properties(netgen PROPERTIES OUTPUT_NAME netgen) 19 | endif(APPLE) 20 | 21 | 22 | install(FILES 23 | dialog.tcl menustat.tcl ngicon.tcl ng.tcl 24 | ngvisual.tcl sockets.tcl nghelp.tcl ngshell.tcl 25 | ngtesting.tcl parameters.tcl variables.tcl csgeom.tcl stlgeom.tcl 26 | occgeom.tcl acisgeom.tcl netgen.ocf 27 | DESTINATION ${ng_install_dir_bin} COMPONENT netgen) 28 | 29 | add_subdirectory(Togl2.1) 30 | install(FILES drawing.tcl DESTINATION ${ng_install_dir_bin} COMPONENT netgen) 31 | 32 | endif(USE_GUI) 33 | 34 | if(USE_PYTHON) 35 | add_library(ngpy SHARED netgenpy.cpp) 36 | target_link_libraries( ngpy nglib ) 37 | if(APPLE) 38 | set_target_properties( ngpy PROPERTIES SUFFIX ".so") 39 | elseif(WIN32) 40 | set_target_properties( ngpy PROPERTIES SUFFIX ".pyd") 41 | set_target_properties( ngpy PROPERTIES OUTPUT_NAME "libngpy") 42 | endif() 43 | install(TARGETS ngpy ${ng_install_dir}) 44 | endif(USE_PYTHON) 45 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/csg/gencyl.hpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_GENCYL 2 | #define FILE_GENCYL 3 | 4 | /**************************************************************************/ 5 | /* File: gencyl.hh */ 6 | /* Author: Joachim Schoeberl */ 7 | /* Date: 14. Oct. 96 */ 8 | /**************************************************************************/ 9 | 10 | namespace netgen 11 | { 12 | 13 | 14 | /* 15 | 16 | Generalized Cylinder 17 | 18 | */ 19 | 20 | 21 | /// 22 | class GeneralizedCylinder : public Surface 23 | { 24 | /// 25 | ExplicitCurve2d & crosssection; 26 | /// 27 | Point<3> planep; 28 | /// 29 | Vec<3> planee1, planee2, planee3; 30 | 31 | /// Vec<3> ex, ey, ez; 32 | Vec2d e2x, e2y; 33 | /// 34 | Point<3> cp; 35 | 36 | public: 37 | /// 38 | GeneralizedCylinder (ExplicitCurve2d & acrosssection, 39 | Point<3> ap, Vec<3> ae1, Vec<3> ae2); 40 | 41 | /// 42 | virtual void Project (Point<3> & p) const; 43 | 44 | /// 45 | virtual int BoxInSolid (const BoxSphere<3> & box) const; 46 | /// 0 .. no, 1 .. yes, 2 .. maybe 47 | 48 | virtual double CalcFunctionValue (const Point<3> & point) const; 49 | /// 50 | virtual void CalcGradient (const Point<3> & point, Vec<3> & grad) const; 51 | /// 52 | virtual void CalcHesse (const Point<3> & point, Mat<3> & hesse) const; 53 | /// 54 | virtual double HesseNorm () const; 55 | /// 56 | virtual double MaxCurvatureLoc (const Point<3> & c, double rad) const; 57 | /// 58 | virtual Point<3> GetSurfacePoint () const; 59 | /// 60 | virtual void Print (ostream & str) const; 61 | 62 | /// 63 | virtual void Reduce (const BoxSphere<3> & box); 64 | /// 65 | virtual void UnReduce (); 66 | }; 67 | 68 | } 69 | 70 | #endif 71 | -------------------------------------------------------------------------------- /netgen-6.1-src/ng/Togl2.1/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | 2 | if(APPLE) 3 | set(CMAKE_C_COMPILER "/usr/bin/gcc") 4 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -x objective-c") 5 | endif(APPLE) 6 | 7 | if(WIN32) 8 | add_definitions("-DBUILD_togl -DUNICODE -D_UNICODE -DTOGL_USE_FONTS=0 -DSTDC_HEADERS -DSTDC_HEADER") 9 | add_library(togl SHARED togl.c toglProcAddr.c toglStubInit.c) 10 | install(TARGETS togl DESTINATION ${ng_install_dir} COMPONENT netgen) 11 | else(WIN32) 12 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fomit-frame-pointer -Wno-implicit-int") 13 | add_definitions("-DPACKAGE_NAME=\"Togl\" -DPACKAGE_TARNAME=\"togl\" -DPACKAGE_VERSION=\"2.1\" -DPACKAGE_STRING=\"Togl\ 2.1\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=0 -DHAVE_LIMITS_H=1 -DHAVE_SYS_PARAM_H=1 -DUSE_THREAD_ALLOC=1 -D_REENTRANT=1 -D_THREAD_SAFE=1 -DTCL_THREADS=1 -DMODULE_SCOPE=extern\ __attribute__\(\(__visibility__\(\"hidden\"\)\)\) -D_LARGEFILE64_SOURCE=1 -DTCL_WIDE_INT_IS_LONG=1 -DUSE_TCL_STUBS=1 -DUSE_TK_STUBS=1 -DAUTOSTEREOD=\"\"") 14 | 15 | include_directories(BEFORE "${TCL_INCLUDE_PATH}/tcl-private/generic" "${TCL_INCLUDE_PATH}/tcl-private/unix") 16 | include_directories(BEFORE "${TCL_INCLUDE_PATH}/tk-private/generic" "${TCL_INCLUDE_PATH}/tk-private/unix") 17 | include_directories(BEFORE "${TCL_INCLUDE_PATH}/tk-private/generic/ttk") 18 | include_directories(BEFORE "${TK_INCLUDE_PATH}/../PrivateHeaders") 19 | include_directories(BEFORE "${TCL_INCLUDE_PATH}") 20 | include_directories(BEFORE "${TK_INCLUDE_PATH}") 21 | 22 | add_library(togl togl.c toglProcAddr.c toglStubInit.c) 23 | target_link_libraries(togl -ldl) 24 | endif(WIN32) 25 | 26 | target_link_libraries(togl ${OPENGL_LIBRARIES} ${TK_LIBRARY} ${TCL_LIBRARY} ) 27 | set_target_properties(togl PROPERTIES POSITION_INDEPENDENT_CODE ON ) 28 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/general/array.cpp: -------------------------------------------------------------------------------- 1 | #ifndef FILE_NGSTD_ArrayCPP 2 | #define FILE_NGSTD_ArrayCPP 3 | // necessary for SGI ???? 4 | 5 | /**************************************************************************/ 6 | /* File: array.cpp */ 7 | /* Author: Joachim Schoeberl */ 8 | /* Date: 01. Jun. 95 */ 9 | /**************************************************************************/ 10 | 11 | /* 12 | Abstract data type Array 13 | */ 14 | 15 | #include 16 | #include 17 | #include 18 | 19 | 20 | namespace netgen 21 | { 22 | //using namespace netgen; 23 | 24 | #ifdef NONE 25 | void BASE_Array :: ReSize (int minsize, int elementsize) 26 | { 27 | cout << "resize, minsize = " << minsize << endl; 28 | 29 | if (inc == -1) 30 | throw Exception ("Try to resize fixed size array"); 31 | 32 | 33 | void * p; 34 | int nsize = (inc) ? allocsize + inc : 2 * allocsize; 35 | if (nsize < minsize) nsize = minsize; 36 | 37 | if (data) 38 | { 39 | p = new char [nsize * elementsize]; 40 | 41 | int mins = (nsize < actsize) ? nsize : actsize; 42 | memcpy (p, data, mins * elementsize); 43 | 44 | delete [] static_cast (data); 45 | data = p; 46 | } 47 | else 48 | { 49 | data = new char[nsize * elementsize]; 50 | } 51 | 52 | allocsize = nsize; 53 | cout << "resize done" << endl; 54 | } 55 | 56 | 57 | 58 | void BASE_Array :: RangeCheck (int i) const 59 | { 60 | if (i < 0 || i >= actsize) 61 | throw ArrayRangeException (); 62 | } 63 | 64 | void BASE_Array :: CheckNonEmpty () const 65 | { 66 | if (!actsize) 67 | { 68 | throw Exception ("Array should not be empty"); 69 | // cerr << "Array souldn't be empty"; 70 | } 71 | } 72 | #endif 73 | } 74 | #endif 75 | 76 | -------------------------------------------------------------------------------- /netgen-6.1-src/libsrc/occ/Partition_Inter3d.jxx: -------------------------------------------------------------------------------- 1 | // GEOM PARTITION : partition algorithm 2 | // 3 | // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, 4 | // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 5 | // 6 | // This library is free software; you can redistribute it and/or 7 | // modify it under the terms of the GNU Lesser General Public 8 | // License as published by the Free Software Foundation; either 9 | // version 2.1 of the License. 10 | // 11 | // This library is distributed in the hope that it will be useful, 12 | // but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | // Lesser General Public License for more details. 15 | // 16 | // You should have received a copy of the GNU Lesser General Public 17 | // License along with this library; if not, write to the Free Software 18 | // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | // 20 | // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 21 | // 22 | // 23 | // 24 | // File : Partition_Inter3d.jxx 25 | // Module : GEOM 26 | 27 | #ifndef _BRepAlgo_AsDes_HeaderFile 28 | #include 29 | #endif 30 | #ifndef _TopTools_ListOfShape_HeaderFile 31 | #include 32 | #endif 33 | #ifndef _TopTools_DataMapOfShapeShape_HeaderFile 34 | #include 35 | #endif 36 | #ifndef _TopoDS_Face_HeaderFile 37 | #include 38 | #endif 39 | #ifndef _TopTools_MapOfShape_HeaderFile 40 | #include 41 | #endif 42 | #ifndef _TopoDS_Shape_HeaderFile 43 | #include 44 | #endif 45 | #ifndef _TopoDS_Vertex_HeaderFile 46 | #include 47 | #endif 48 | #ifndef _TopoDS_Edge_HeaderFile 49 | #include 50 | #endif 51 | #ifndef _Partition_Inter3d_HeaderFile 52 | #include "Partition_Inter3d.hxx" 53 | #endif 54 | --------------------------------------------------------------------------------