CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Meshing & Mesh Conversion (https://www.cfd-online.com/Forums/openfoam-meshing/)
-   -   [Netgen] Netgen now on Sourceforge (https://www.cfd-online.com/Forums/openfoam-meshing/61942-netgen-now-sourceforge.html)

philippose March 8, 2010 13:40

Hello and a Good Evening...!

Just wanted to inform the OpenFOAM community that Netgen-4.9.12 is now available for download on the Sourceforge project page.

Some of the changes in the version are:
1. Meshes can now be directly exported in the OpenFOAM 1.5+ Format
2. Improved Colourisation of meshes as a function of mesh size
3. Bugfixes for surface mesh size specification in OpenCascade Geometry
4. Netgen now also works with the Windows SDK v7.0
5. Improvements to the mesh optimisation core system
6. Various fixes to the higher order meshing core system
7. Mesh refinement functions added to nglib


I guess the direct export to OpenFOAM format would be quite interesting... :-)! Hope there are no bugs which I did not catch!

Windows installers are also available for 32-bit and 64-bit with OpenCascade support.

Unfortunately, "official" versions of Linux RPMs are not yet out, but I guess (hope ;-)!) Alberto will update his Linux RPM to the 4.9.12 version.

If anyone finds any critical bugs it will be nice if I could be informed, and ofcourse, "realistic" feature requests are always welcome :-)!

Have a nice day!

Philippose

alberto March 8, 2010 15:54

Quote:

Originally Posted by philippose (Post 249007)
Unfortunately, "official" versions of Linux RPMs are not yet out, but I guess (hope ;-)!) Alberto will update his Linux RPM to the 4.9.12 version.

It all depends on the number of dependencies that changed, and how many weird libraries were included in addition to the previous version :D

Best,

philippose March 8, 2010 16:49

Hello Alberto :-)!

Nice to hear from you so soon :-)!

I guess I have good news for you.... we have made no changes to any of the dependencies for Netgen-4.9.12... everything is as it has always been. The only changes made are internal to Netgen itself.

I am quite sure the SPEC file that you used for Netgen-4.9.11 should work without any modifications for Netgen-4.9.12 too....

Have a nice evening !

Philippose

alberto March 8, 2010 17:03

Quote:

Originally Posted by philippose (Post 249044)
Hello Alberto :-)!

Nice to hear from you so soon :-)!

I guess I have good news for you.... we have made no changes to any of the dependencies for Netgen-4.9.12... everything is as it has always been. The only changes made are internal to Netgen itself.

I am quite sure the SPEC file that you used for Netgen-4.9.11 should work without any modifications for Netgen-4.9.12 too....

Have a nice evening !

Philippose

You're correct :-)

At the moment I just packaged it for openSUSE 11.2 in my home repository. Packages for the supported versions (11.0 and newer) of openSUSE will come soon.

alberto March 9, 2010 00:04

The new version of netgen is now available for the following platforms (both 32 and 64 bit):
Simply click on the corresponding link and the usual 1-click guided installation procedure will appear.

Notes:

  1. I did not test the packages, so, if they do not work, please report it.
  2. As soon as the packages will be approved, they'll become part of the openSUSE/science repository
Thanks Philippose for informing me of the new version, and to openSUSE, who offer the amazing build service :D

linnemann March 9, 2010 08:29

Hi

and thx for the big effort.

I'm uploading a freshly compiled Netgen, with OCC included, to my centFOAM SF page.

again this is verified to work on CentOS/SL/RHEL and derivations from 5.x 64bit.

philippose March 9, 2010 11:38

Hey guys,

Thanks a million Alberto and Linnemann..... for creating and maintaining the OpenSUSE and CentOS binary versions of Netgen :-)!

I shall link to these files from the Netgen Mediawiki site as contributed linux binaries.... I am sure there are a lot of people who would prefer the ease of an automated install !!

Currently I am back to my efforts of putting together an RPM version for Fedora :-)! I had done this earlier (as Alberto might remember), but then I got stuck with some issues with paths and install philosophies......

I am tinkering with the idea of creating a "plugin" in netgen specifically for OpenFOAM :-)! Lets see how that pans out....

Have a nice day!

Philippose

vaina74 May 11, 2010 08:19

Granted that I've been learning OpenFOAM (and Ubuntu) since March and I'm a beginner, I have a problem with Netgen installing - and it could be a stupid question.

First I added PPA CAE Team to my system (Lucid Lynx) and tried to install Netgen and all dependencies, but I got the output:
Code:

netgen:
Depends: libtogl1  but it is not installable

So I tried the manual installation, according to this procedure. I think I had a problem in Togl compiling or in the last commands (and Netgen doesn't find Toegl library):
Code:

/opt/netgen/bin/netgen
Please, can anyone help me?

Maurizio

UPDATE1

There was a stupid error: the right path is /usr/lib/Togl1.7 and not
/usr/lib/Togl-1.7. Netgen seems to start but I immediately have an other error:
Code:

/opt/netgen/bin/netgen
NETGEN-4.9.12
Developed at RWTH Aachen University, Germany
and Johannes Kepler University Linz, Austria
Error in Tcl-Script:
result = couldn't read file "./ng.tcl": no such file or directory

Any idea?

UPDATE2

I added the command
Code:

export NETGENDIR=/opt/netgen/bin
and finally I can start Netgen. It only complains that
Code:

optfile ./ng.opt does not exist - using default value
but I think it's not a critical error.

philippose May 11, 2010 13:48

Hello there,

A Good Evening to you :-)!

Looks like you finally solved the problem without any external help :-)! Thanks for sharing the steps required on the forum here for others....

I am not sure who maintains the Ubuntu packages, so I don't know how the installation looks finally, but as you rightly found out, you need to necessarily use Togl-1.7 (Netgen does not work with the latest version Togl-2.0 yet).

In addition, unless the .tcl files which netgen uses are not located in the folder in which the netgen executable is present, you need to set the environment variable "NETGENDIR" to the correct location.

If you have further questions, you can always pop by the Netgen Sourceforge page and post your query in the discussion board there....

Have a nice day ahead!

Philippose

vaina74 May 14, 2010 06:42

My compiled Netgen can't import IGES geometries and I'd manually compile OpenCascade geometry kernel. Quite a mess for me, I'm not a linux expert. In the meantime I reported PPA CAE Team Togl bug and Mr Taverne fixed it. Then I installed NETGEN via PPA CAE Team and it works, now I can import IGES geometries without other compiling operations and so on. I recommend PPA CAE Team to all Ubuntu newbie users.

ggruber May 16, 2010 14:43

Quote:

Originally Posted by vaina74 (Post 258765)
My compiled Netgen can't import IGES geometries and I'd manually compile OpenCascade geometry kernel. Quite a mess for me, I'm not a linux expert. In the meantime I reported PPA CAE Team Togl bug and Mr Taverne fixed it. Then I installed NETGEN via PPA CAE Team and it works, now I can import IGES geometries without other compiling operations and so on. I recommend PPA CAE Team to all Ubuntu newbie users.

Installing Netgen from the PPA CAE Team works fine. But every time I select an item from the Menu Bar i get the following error:

Code:

ggruber@vostro1710:~$ netgen
NETGEN-4.9.12
Developed at RWTH Aachen University, Germany
and Johannes Kepler University Linz, Austria
Including OpenCascade geometry kernel
Parsing ng.tcl
optfile ./ng.opt does not exist - using default values
ERROR: can't read "data(isActive)": no such element in array
errinfo: can't read "data(isActive)": no such element in array
    while executing
"if {$data(isActive)} {
    tixBalloon:Deactivate $w
    } else {
    set data(cancel) 1
    }"
    (procedure "tixBalloon:XXButton" line 8)
    invoked from within
"tixBalloon:XXButton $w $rootX $rootY $b"
    (procedure "tixBalloon_XXButton" line 5)
    invoked from within
"tixBalloon_XXButton  667 251 1"
    (command bound to event)


vaina74 May 17, 2010 07:40

Sorry, I can't help you :-(
Post your problem in the Netgen forum (if you don't find any similar thread) or contact the CAE Team to report your bug (you must register to Launchpad).

vaina74 May 26, 2010 06:50

I installed NETGEN via PPA CAE Team on Ubuntu 10.04 LTS, but I have a problem with the GUI. The terminal output is:
Code:

NETGEN-4.9.12
Developed  at RWTH Aachen University, Germany
and  Johannes Kepler University Linz, Austria
Including OpenCascade  geometry kernel
Parsing ng.tcl
optfile ./ng.opt does not exist -  using default values
ERROR: can't read "data(isActive)": no such  element in array
errinfo: can't read "data(isActive)": no such  element in array
    while executing
"if {$data(isActive)} {
      tixBalloon:Deactivate $w
    } else {
    set data(cancel) 1
      }"
    (procedure "tixBalloon:XXButton" line 8)
    invoked from  within
"tixBalloon:XXButton $w $rootX $rootY $b"
    (procedure  "tixBalloon_XXButton" line 5)
    invoked from within
"tixBalloon_XXButton    872 563 1"
    (command bound to event)
ERROR: can't read  "data(isActive)": no such element in array
errinfo: can't read  "data(isActive)": no such element in array
    while executing
"if  {$data(isActive)} {
    tixBalloon:Deactivate $w
    } else {
      set data(cancel) 1
    }"
    (procedure "tixBalloon:XXButton"  line 8)
    invoked from within
"tixBalloon:XXButton $w $rootX  $rootY $b"
    (procedure "tixBalloon_XXButton" line 5)
    invoked from within
"tixBalloon_XXButton  1222 927 1"
    (command bound to event)
ERROR: can't read "data(isActive)": no such  element in array
errinfo: can't read "data(isActive)": no such  element in array
    while executing
"if {$data(isActive)} {
      tixBalloon:Deactivate $w
    } else {
    set data(cancel) 1
      }"
    (procedure "tixBalloon:XXButton" line 8)
    invoked from  within
"tixBalloon:XXButton $w $rootX $rootY $b"
    (procedure  "tixBalloon_XXButton" line 5)
    invoked from within
"tixBalloon_XXButton    1222 927 1"
    (command bound to event)

I already installed NETGEN on a notebook without troubles, with the same OS. I was suggested I miss Tix package but I checked it out but I have already Tix 8.4.0 installed. Please, can you help me?

vaina74 May 26, 2010 10:54

I noticed that Ubuntu 'standard' repositories - and my pc too - include Tix 8.4.0 and not Tix 8.4.3. On the base of this guide, I installed the required packages (some of them already installed):
Code:

sudo apt-get
install build-essential tcl8.5 tcl8.5-dev tk8.5 tk8.5-dev glutg3
glutg3-dev libxmu-dev liblapack-dev

and downloaded Tix8.4.3-src.tar.gz
Code:

tar xfs
Tix8.4.3-src.tar.gz
cd Tix8.4.3
./configure --with-tcl=/usr/lib/tcl8.5/ --with-tk=/usr/lib/tk8.5/
make
sudo make install

So I installed again NETGEN via PPA CAE Team and now everything is ok.

zhuqin September 7, 2010 05:49

I want to write .in2d format file as my input file in Netgen.

Is there a detailed description of this file format? such as "# dl dr np p1 p1 flaglist" in "Segments", how many flags int the "flaglist" totally? What they mean?

Aslo, Is there a flaglist in "materials"? What are they?

philippose September 7, 2010 12:52

Hi there,

This is a Netgen specific question, and should be posted as a question on the Netgen Mesher forum available at the following link:

Netgen Help Forum

Anyway, I shall see if I can find something regarding this particular file format.

Have a great day ahead!

Philippose

zhuqin September 7, 2010 20:54

Thanks very much for your reply! I will see the link: Netgen Help Forum.

Also, I am expecting a detailed description of in2d file format!

Best wishes!

zhuqin

philippose September 8, 2010 03:01

Hello again,

A Good Day to you!

I was just looking up, and I found that the ".in2d" file format has been described in sufficient detail on pages 17 and 18 of the Netgen user manual "ng4.pdf" which is provided within the "doc" folder of a normal Netgen installation (in Windows and Linux).

In addition, there are a couple of examples of ".in2d" files in the samples folder (called "tutorials" in Windows and "share\netgen" in Linux) to illustrate the explanation in the PDF file.

Hope this helps!

Have a nice day!

Philippose

run_cfd May 6, 2011 08:45

Help in installing Netgen with OCC library on win x32
 
Hi Philipose,

Greetings!!!

I installed Netgen 4.9.13 on windows x32, I have to import *.iges file, and for that it asks for Opencascade library. I downloaded OpenCASCADE650.exe from the OpenCascade website and installed, but still not able to load iges file in Netgen. Could you please help me in getting the OpenCascade library & Clubbing it with Netgen installation?

thanks in advance,
Regards,

MLD

philippose May 7, 2011 12:20

Hello and a Good Evening :-)!

Great to see that you are trying out Netgen :-)!

Did you install Netgen for windows using the Installer, or did you compile it yourself? If you used the installer, you can ask it to install the version of Netgen with OpenCascade support by selecting the right option in the GUI of the Installer.

When you choose to install Netgen with OpenCascade support, the Installer also automatically installs the required OpenCascade DLLs too.... Then things should work automatically.

- Philippose

crixman July 19, 2014 12:42

Netgen cmake installation problem
 
Hi all,
I am trying to install Netgen Cmake on CentOS6.4.
I unpacked the folder netgen-cmake-master, made a netgen folder and then tried the following:
cd netgen
cmake /home/chris/netgen-cmake-master

and I get the following:
[chris@localhost netgen]$ sudo cmake /home/chris/netgen-cmake-master
-- Netgen Version: 5.2.0-dev
-- Build type: 64bit
CMake Error at /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:97 (MESSAGE):
Could NOT find Togl1.7 (missing: TOGL1.7_LIBRARY TOGL1.7_INCLUDE_PATH)
Call Stack (most recent call first):
/usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:288 (_FPHSA_FAILURE_MESSAGE)
cmake/modules/FindTogl1.7.cmake:124 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
CMakeLists.txt:244 (FIND_PACKAGE)


How can I tell cmake where to find the libraries? I got Togl, Tk and Tcl from Netgen repositories and have them in a Tcl folder in the home directory!
Any help would be appreciated!

CFDUser_ August 8, 2014 01:12

1 Attachment(s)
Hi All,

Sorry if this post may be repeated but I didn't find the solution any ware I searched. I have created one simple STL cylinder file. I don't exactly what's wrong with STL but I believe there is something wrong that file only. The reason is snappy meshing complete geometry provided in blockMeshDict but my selected region is point inside the cylinder. I am unable to see any leak in STL. I taught to repair with netgen but STL doctor not showing any inconsistent triangles. Can somebody help me.

I want to see is there any defected triangles or volume is closed or not. How to do that.


PFA: STL file

Regards,
CFDUser_

philippose August 8, 2014 02:52

Hello there,
A good day to you.

I am not sure posting requests for help in unrelated threads will help you find a solution to your problem. Please reconsider in the future.

Anyway, I had a look at your STL file using an STL viewer, and found that half your triangles have the wrong orientation, hence resulting in snappyHexMesh meshing the entire domain instead of only the cylinder.

For a solid to be valid, all the triangles must have their normals facing out of the solid domain. In your case, the normals of all your triangles must face outwards with respect to the cylinder volume.

The STL "solids" - Inlet and Outlet are facing inwards, and so are all the triangles on the CylinderSurface connected to the Outlet. The triangles of CylinderSurface connected to the Inlet patch are facing the right way.

Hope this helps.

Have a nice day ahead!

Philippose

CFDUser_ August 8, 2014 03:33

Quote:

Originally Posted by philippose (Post 504967)
Hello there,
A good day to you.

I am not sure posting requests for help in unrelated threads will help you find a solution to your problem. Please reconsider in the future.

Anyway, I had a look at your STL file using an STL viewer, and found that half your triangles have the wrong orientation, hence resulting in snappyHexMesh meshing the entire domain instead of only the cylinder.

For a solid to be valid, all the triangles must have their normals facing out of the solid domain. In your case, the normals of all your triangles must face outwards with respect to the cylinder volume.

The STL "solids" - Inlet and Outlet are facing inwards, and so are all the triangles on the CylinderSurface connected to the Outlet. The triangles of CylinderSurface connected to the Inlet patch are facing the right way.

Hope this helps.

Have a nice day ahead!

Philippose

Thanks a lot Philippose. How can I find the orientation of all the triangles? Netgen or any other software or any library in OpenFOAM does that job?

By the way, I taught its the correct place to post my problem because I taught netgen may provide solution for this issue.

Thanks & Regards,
CFDUser_

CFDUser_ August 8, 2014 04:07

1 Attachment(s)
Still no success Philippose. I have attached the corrected stl file. Can you please have a look?


Regards
CFDUser_

philippose August 8, 2014 04:24

Hi,
I used some free STL viewer I found on the Internet to view the file since I dont have Netgen on the system I am working on currently.

However, if you open the STL file using Netgen, the colours of the surface should (if I remember right) give you an insight into the orientation. Usually, the "outside" of a geometry is coloured in bright green, and the "inside" in darker green.

Since "outside" and "inside" are determined by the Surface normals, you should see two different shades of green on the "outside" surfaces of your cylinder due to the wrongly oriented surface normals.

Then, there is an option in one of the Netgen menus to change the orientation of surface normals. You can click one triangle, and tell Netgen to change all other triangles to the same orientation as that of the one you selected.


Regards,
Philippose

philippose August 8, 2014 04:33

1 Attachment(s)
The new STL you posted is still exactly the same as the old one... still the wrongly oriented surfaces.

I have added an image to this post in which you can see the different orientations... The blue surfaces are oriented in the opposite direction compared to the surfaces in brown/gold.


Philippose

CFDUser_ August 8, 2014 16:04

Quote:

Originally Posted by philippose (Post 504993)
The new STL you posted is still exactly the same as the old one... still the wrongly oriented surfaces.

I have added an image to this post in which you can see the different orientations... The blue surfaces are oriented in the opposite direction compared to the surfaces in brown/gold.


Philippose

Can you tel me which software it is?

philippose August 8, 2014 16:33

Hi again,
The software I used can be downloaded from: http://www.freestlview.com/

How are you creating the STL file originally? Are you using something like Salome-Platform, or a CAD software? Or are you programmatically creating it using some custom code?

Have a great weekend!

Philippose

CFDUser_ August 8, 2014 16:52

Quote:

Originally Posted by philippose (Post 505112)
Hi again,
The software I used can be downloaded from: http://www.freestlview.com/

How are you creating the STL file originally? Are you using something like Salome-Platform, or a CAD software? Or are you programmatically creating it using some custom code?

Have a great weekend!

Philippose

Wow thanks for the info. Its custom code :).

Happy weekend too :)

Regards,
CFDUser_

philippose August 9, 2014 05:10

Hello,
I think the best idea idea would be to try to do the same geometry and export it to STL using one of the many free CAD / Geometry tools, and see if snappyHexMesh works as you expect it to with that geometry.

Once that works, you can compare the STL exported from that tool with the one you are writing using the custom code. That way, you will be able to figure out where the error in your code is hidden :-) It looks like a bug has sneaked into your code somewhere...

Enjoy!

Philippose

vaina74 November 13, 2014 07:44

Netgen 5.3.1 on Ubuntu 12.04 LTS (64 bit)
 
Hi all,
I know that Netgen 4.9.13 is included in Ubuntu packages but I'd like to test the last version. Togl-1.7 and Tix8.4.3 should be already set. If I try to configure, compile and install
Code:

./configure --with-tcl=/usr/lib/tcl8.5/ --with-tk=/usr/lib/tk8.5/ --with-togl=/usr/lib/Togl1.7 --enable-occ --with-occ=/usr/lib/
make
sudo make install

I obtain an error message:
Code:

make  all-recursive
make[1]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1'
Making all in libsrc
make[2]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc'
Making all in general
make[3]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/general'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/general'
Making all in gprim
make[3]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/gprim'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/gprim'
Making all in linalg
make[3]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/linalg'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/linalg'
Making all in include
make[3]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/include'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/include'
Making all in meshing
make[3]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/meshing'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/meshing'
Making all in interface
make[3]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/interface'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/interface'
Making all in csg
make[3]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/csg'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/csg'
Making all in geom2d
make[3]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/geom2d'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/geom2d'
Making all in occ
make[3]: Entering directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/occ'
/bin/bash ../../libtool --tag=CXX  --mode=compile g++ -DHAVE_CONFIG_H -I. -I../..  -I../../libsrc/include  -DOCCGEOMETRY -I/usr/lib//inc -I/usr/include/opencascade -D_OCC64 -DHAVE_IOSTREAM -DHAVE_LIMITS -DHAVE_LIMITS_H -DHAVE_IOMANIP -I"/usr/include/tcl8.5"  -g -O2 -fopenmp -MT Partition_Inter2d.lo -MD -MP -MF .deps/Partition_Inter2d.Tpo -c -o Partition_Inter2d.lo Partition_Inter2d.cxx
libtool: compile:  g++ -DHAVE_CONFIG_H -I. -I../.. -I../../libsrc/include -DOCCGEOMETRY -I/usr/lib//inc -I/usr/include/opencascade -D_OCC64 -DHAVE_IOSTREAM -DHAVE_LIMITS -DHAVE_LIMITS_H -DHAVE_IOMANIP -I/usr/include/tcl8.5 -g -O2 -fopenmp -MT Partition_Inter2d.lo -MD -MP -MF .deps/Partition_Inter2d.Tpo -c Partition_Inter2d.cxx  -fPIC -DPIC -o .libs/Partition_Inter2d.o
In file included from Partition_Inter2d.ixx:28:0,
                from Partition_Inter2d.cxx:33:
Partition_Inter2d.jxx:31:30: fatal error: BRepAlgo_AsDes.hxx: No such file or directory
compilation terminated.
make[3]: *** [Partition_Inter2d.lo] Error 1
make[3]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc/occ'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1/libsrc'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/user-a5/Downloads/netgen-5.3.1'
make: *** [all] Error 2

Can anyone help me to fix the installation procudure?
Thanks for your attention.


All times are GMT -4. The time now is 19:20.